Hi,

A couple of days ago I was having a lot of trouble getting the 
(ClassName. ctor-args...) form of constructors to work while (new 
ClassName ctor-args...) was fine. It eventually occurred to me that the 
problem had to do with those constructor calls being in macro bodies. 
Now it turns out those macros were very poorly written, and now the 
constructor code is isolated in a function called by the macro 
expansion (you might never know how ugly something can be until you 
(macroexpand ...) it!).

However, I am left wondering what exactly is the interaction that was 
causing the dot-suffix form of the constructor call to fail in a macro 
expansion. I sense it has to do with the fact that symbols (other than 
gensyms or syntax-unquoted macro arguments) used in macro definitions 
are qualified with the namespace of the macro definition when that 
macro is expanded.

Is this understanding correct? If so, is the behavior deliberate?


Randall Schulz

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To post to this group, send email to clojure@googlegroups.com
To unsubscribe from this group, send email to 
clojure+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/clojure?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to