Created
February 24, 2013 16:58
-
-
Save dcolish/5024561 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Exception in thread "main" java.lang.ClassCastException: sample$eval7$stream__8 cannot be cast to java.io.BufferedReader | |
at sample$eval7.invoke(meh.clj:11) | |
at clojure.lang.Compiler.eval(Compiler.java:6514) | |
at clojure.lang.Compiler.load(Compiler.java:6955) | |
at clojure.lang.Compiler.loadFile(Compiler.java:6915) | |
at clojure.main$load_script.invoke(main.clj:283) | |
at clojure.main$script_opt.invoke(main.clj:343) | |
at clojure.main$main.doInvoke(main.clj:427) | |
at clojure.lang.RestFn.invoke(RestFn.java:408) | |
at clojure.lang.Var.invoke(Var.java:415) | |
at clojure.lang.AFn.applyToHelper(AFn.java:161) | |
at clojure.lang.Var.applyTo(Var.java:532) | |
at clojure.main.main(main.java:37) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns sample | |
(:import [java.net URL] | |
[java.io BufferedReader InputStreamReader])) | |
(let [url "http://google.com" | |
^BufferedReader stream (->> (URL. url) | |
.openStream | |
InputStreamReader. | |
(fn [& args] (->> (reverse args) | |
(apply BufferedReader))))] | |
(println (.readLine stream))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment