I'm trying to learn something about error-kit and encountering some unexpected responses, as follows:
Clojure 1.3.0
user=> (use 'clojure.contrib.error-kit)
Warning: *handler-stack* not declared dynamic and thus is not dynamically rebindable, but its name suggests otherwise. Please either indicate ^:dynamic *handler-stack* or change the name.
Warning: *continues* not declared dynamic and thus is not dynamically rebindable, but its name suggests otherwise. Please either indicate ^:dynamic *continues* or change the name.
nil
user=> (def tm (throw-msg java.lang.IllegalArgumentException))
#'user/tm
user=> (tm "hi")
IllegalArgumentException sun.reflect.NativeConstructorAccessorImpl.newInstance0 (NativeConstructorAccessorImpl.java:-2)
First, note the dynamic variable warnings upon use...(might this possibly indicate an out-of-date version of error-kit (I'm using using clojure-contrib.jar from 1.2.0)?).
I'm just starting with error-kit but I would have expected that the last call (involving a previous throw-msg function) would have returned something like this:
-> java.lang.IllegalArgumentException: hiand would not have included the additional junk from 'sun.reflect.NativeConstructor....'. Is this some OSX Java bug or does this also happen on other JDKs?
Any help or suggestions appreciated.
-t