librelist archives

« back to archive

Steps to test Leiningen with my own private Clojure version?

Steps to test Leiningen with my own private Clojure version?

Andy Fingerhut
2013-02-21 @ 00:16
Color me ignorant on building Leiningen from source, and even whether 
Leiningen uses its own included version of Clojure within its 
distribution, and whether that matters for this question.

I'm working on

Am I correct in believing that if this issue is left unchanged, it would 
mean that if and when someone:

    (a) wanted a Leiningen project using Clojure 1.5.0 and
    (b) wanted to use the new command line 
option to the JVM to help find unsafe uses of clojure.core/read or 

then any Leiningen task that invoked "java" with and the -e option would fail?  It appears that
with Leiningen 2.0.0 at least "lein test" uses the -e option on the java 
command line, and I'm guessing there are others.  Corrections welcome.

The current patch on CLJ-1168 changes the behavior so that if is given on the command line, the 
clojure.core/read calls used to read the strings given after -e will first
bind *read-eval* to true.  That guarantees that whatever Leiningen gives 
after -e, it will work.

Steve Miner suggests instead binding *read-eval* to false when calling 
read on the string after the -e option.

Does anyone know whether Leiningen currently uses #=(expr) or expressions in the strings it gives after 
the -e option?  If it already does, or can, or you think someone might 
want to do that, then binding *read-eval* to true would be necessary.