Re: Importing another data_readers

2013-07-19 Thread JvJ
Thanks. I'll make sure users know about it. It's a game engine, so I'll mostly be using it for things like Box2D vector literals (i.e. v#(1,2)), and floating-point numbers ( f#(1.4), so they don't have to say (float 1.4)). On Friday, 19 July 2013 13:48:50 UTC-7, Stuart Sierra wrote: > > Whe

Re: Importing another data_readers

2013-07-19 Thread Stuart Sierra
When Clojure starts it will search for files named data_readers.clj at the root the Java classpath. Every library JAR can have its own data_readers.clj and they will all be loaded and merged. Be careful with this: if there's a conflict in data reader bindings, Clojure won't start. If your libra

Importing another data_readers

2013-07-19 Thread JvJ
I'm not 100% on how the data_readers.clj file works. It's just a map with no namespace that appears to get loaded by some kind of black magic. Is it possible to provide a library which includes its reader macros, so that the library user's project doesn't need to include their own data_readers