On Tue, Jul 8, 2014 at 10:38 AM, Alexander Burger <a...@software-lab.de> wrote: > Hi Christophe,
Hi Alex, thanks for this prompt answer. >> # In order to call <xml> with the default args and then the particular args, >> # decided to use apply: >> (apply <xml> (quote text text-anchor "middle" font-size 24 x 120 y 99 > > Yes, this is not possible. > > 'apply' can only be used for functions which evaluate their arguments > (EXPRs and SUBRs, but not FEXPRs). And '<xml>' is an FEXPR: Ouch. > For example: > > (setq A 1 B 2 C 3) > (apply println '(A B C)) > > This should print > > A B C > > and _not_ > > 1 2 3 > > Thus, it is equivalent to > > (println 'A 'B 'C) > > and not > > (println A B C) Even if I did not face this problem, this is counter-intuitive to me. I guess that there are serious reasons for this behaviour. This may be nice examples for the docs! But I'll understand that you don't want to clutter those pages. > If - instead of 'println' - a function is called which does not evaluate > its arguments, the results will be undefined (implementation-specific). OK, so what are my options? I'd say: 1) try to write a king of «apply» that would work for me, 2) rewrite <xml> so that it evaluates its args, then quote the args in my calls to it. Any suggestion? chri -- http://profgra.org/lycee/ (site pro) http://delicious.com/profgraorg (liens, favoris) https://twitter.com/profgraorg -- UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe