>
> Reader errors don't tell you the name of the file that had problems:
>
> eof.clj:
>
> (defn foo [a]
>    (println "hello")
>
> $ java -cp clojure.jar clojure.lang.Repl eof.clj
> java.lang.Exception: ReaderError:(3,1) EOF while reading
>         at clojure.lang.LispReader.read(LispReader.java:164)
>         at clojure.lang.Compiler.load(Compiler.java:4253)
>         at clojure.lang.Compiler.loadFile(Compiler.java:4224)
>         at clojure.lang.Repl.main(Repl.java:48)
> Caused by: java.lang.Exception: EOF while reading
>         at clojure.lang.LispReader.readDelimitedList(LispReader.java:847)
>         at clojure.lang.LispReader$ListReader.invoke(LispReader.java:784)
>         at clojure.lang.LispReader.read(LispReader.java:130)
>         ... 3 more
> Clojure
> user=>

Here's my attempt at a patch to fix the above problem

I made the existing LispReader.read() private. I made a new public
LispReader.read() that takes an extra argument, a sourcePath. The new
method pushes the sourcePath into a var and then calls the private
method. Then I modifed all existing calls to LispReader.read() to use
the new method.

http://clojure.googlegroups.com/web/reader-error.diff

Feedback?

Allen



--~--~---------~--~----~------------~-------~--~----~
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 [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/clojure?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to