On 2010 May 4, at 4:55 PM, Bryce wrote:
For reference, the deriv macro is at
http://github.com/liebke/incanter/blob/master/modules/incanter-core/src/incanter/symbolic.clj
Unquote splicing and switching to `(fn ~fn-args ~(deriv exp v degree))
both produce errors of the type "count not supported on this type:
Symbol". Macroexpand-1 seems to just return what was fed into it, ie
user=> (macroexpand-1 '(deriv-fn [x y] (+ (* x y) (* 3 y)) y 1))
(deriv-fn [x y] (+ (* x y) (* 3 y)) y 1))
When I copy the definition of drive-fn from your link above and then
invoke macroexpand-1, I get:
user=> (macroexpand-1 '(deriv-fn [a b c] foo bar baz))
(user/deriv-fn* (quote [a b c]) (quote foo) (quote bar) baz)
First step is to find out why you aren't getting the same expansion.
FWIW, I'm running clojure 1.1.0 on Mac OS X Leopard, from the command
line.
-Doug
--
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
Note that posts from new members are moderated - please be patient with your
first post.
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