<< Back to previous view

[TANAL-118] ClassNotFoundException byte[] thrown when analyzing an expression Created: 06/Feb/16  Updated: 06/Feb/16

Status: Open
Project: tools.analyzer
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Defect Priority: Major
Reporter: Andy Fingerhut Assignee: Nicola Mometto
Resolution: Unresolved Votes: 0
Labels: None


 Description   

Steps to reproduce with latest t.a.j and t.a.jvm as of today (just after Jan 4 2016 t.a.jvm commit), and t.a.j 0.6.7):

user=> (require '[clojure.tools.analyzer.jvm :as j])
nil
user=> (def e1 (j/analyze+eval '(def Class-byte-array (.getClass (byte-array 0)))))

CompilerException java.lang.ClassNotFoundException: byte[], compiling:(form-init8714266273872228442.clj:1:9) 
user=> (pst *e)
CompilerException java.lang.ClassNotFoundException: byte[], compiling:(form-init8714266273872228442.clj:1:9)
	clojure.lang.Compiler$InvokeExpr.eval (Compiler.java:3656)
	clojure.lang.Compiler$DefExpr.eval (Compiler.java:450)
	clojure.lang.Compiler.eval (Compiler.java:6920)
	clojure.lang.Compiler.eval (Compiler.java:6878)
	clojure.core/eval (core.clj:3107)
	clojure.core/eval (core.clj:3103)
	clojure.main/repl/read-eval-print--7402/fn--7405 (main.clj:240)
	clojure.main/repl/read-eval-print--7402 (main.clj:240)
	clojure.main/repl/fn--7411 (main.clj:258)
	clojure.main/repl (main.clj:258)
	clojure.main/repl (main.clj:174)
	clojure.tools.nrepl.middleware.interruptible-eval/evaluate/fn--637 (interruptible_eval.clj:58)
Caused by:
ClassNotFoundException byte[]
	java.lang.Class.forName0 (Class.java:-2)
	java.lang.Class.forName (Class.java:270)
	clojure.lang.RT.classForName (RT.java:2168)
	clojure.reflect.JavaReflector (java.clj:169)
	clojure.reflect/fn--9870/G--9866--9873 (reflect.clj:44)
	clojure.reflect/fn--9870/G--9865--9877 (reflect.clj:44)
	clojure.core/partial/fn--4755 (core.clj:2517)
	clojure.reflect/type-reflect (reflect.clj:100)
	clojure.reflect/type-reflect (reflect.clj:58)
	clojure.core/apply (core.clj:651)
	clojure.core/apply (core.clj:640)
	clojure.tools.analyzer.jvm.utils/type-reflect (utils.clj:21)
nil

Found by Alan Thompson (@cloojure on github) and reported as this issue: https://github.com/jonase/eastwood/issues/188






Generated at Fri Feb 12 10:21:57 CST 2016 using JIRA 4.4#649-r158309.