Permalink
Browse files

avoid warn-on-reflection problem

  • Loading branch information...
1 parent 02a1d45 commit 2414eceafb87c22032a2d163434e972f2e68ef04 @arthuredelstein committed Jul 19, 2012
Showing with 3 additions and 5 deletions.
  1. +0 −1 src/clooj/collaj.clj
  2. +3 −4 src/clooj/repl.clj
View
@@ -13,4 +13,3 @@
(read-string (slurp (str "http://collaj.net/?format=raw&q="
(url-encode terms)))))
-
View
@@ -168,10 +168,9 @@
(catch Exception e false)))))
(defn read-string-at [source-text start-line]
- `(let [sr# (java.io.StringReader. ~source-text)
- rdr# (proxy [clojure.lang.LineNumberingPushbackReader] [sr#]
- (getLineNumber []
- (+ ~start-line (proxy-super getLineNumber))))]
+ `(let [sr# (java.io.StringReader. (str (apply str (repeat ~start-line "\n"))
+ ~source-text))
+ rdr# (clojure.lang.LineNumberingPushbackReader. sr#)]
(take-while #(not= % :EOF_REACHED)
(repeatedly #(try (read rdr#)
(catch Exception e# :EOF_REACHED))))))

0 comments on commit 2414ece

Please sign in to comment.