Hi Colin! I've set it up to compile all. No doubt this will be very helpful as I will no longer need to compile using an external `lein compile`. But run still dies on the call (.getClass x), when x is a gen-class compiled class instance.
On the other hand I still can not credit this as a Cursive bug. Calling methods on gen-class compiled class instances is to basic. But it is likely related to Cursive, as 'lein test' works great. On Saturday, August 22, 2015 at 4:24:40 PM UTC-4, Colin Fleming wrote: > > Hi William, > > Right, you'll need to tell Cursive to compile that namespace in > *Settings->Build, > Execution, Deployment->Compiler->Clojure Compiler*. Once you've done that > things should work. Cursive doesn't currently pick the set of namespaces to > be compiled up from lein - it probably should. > > Cheers, > Colin > > On 22 August 2015 at 17:17, William la Forge <lafo...@gmail.com > <javascript:>> wrote: > >> I searched and did not see anything recent on gen-class problems in >> Cursive. I find when I have a reference to a gen-class instance that >> instance? works in Cursive but .getClass does not. (Everything works with >> lein, of course.) >> >> What I am trying to do is to call the count method via (.count x). What I >> do not want to do is call the clojure count function, (count x). Again, no >> issues with lein. >> >> I suspect I simply have not completed the setup cursive for compiles or >> something, as all the complaints about cursive/gen-class that I could find >> were a year old. >> >> I know I need to switch to emacs at some times. I mean, it's only been 30 >> years since I used it last. :D >> >> Here's the error I'm getting: >> >> Exception in thread "main" java.lang.NoClassDefFoundError: >> java/util/function/UnaryOperator, >> compiling:(C:\Users\Bill\Documents\GitHub\aa-collections\test\aa_collections\immutable_set_test.clj:22:10) >> at clojure.lang.Compiler.analyzeSeq(Compiler.java:6730) >> at clojure.lang.Compiler.analyze(Compiler.java:6524) >> at clojure.lang.Compiler.analyzeSeq(Compiler.java:6711) >> at clojure.lang.Compiler.analyze(Compiler.java:6524) >> at clojure.lang.Compiler.analyze(Compiler.java:6485) >> at clojure.lang.Compiler$InvokeExpr.parse(Compiler.java:3791) >> at clojure.lang.Compiler.analyzeSeq(Compiler.java:6725) >> at clojure.lang.Compiler.analyze(Compiler.java:6524) >> at clojure.lang.Compiler.analyze(Compiler.java:6485) >> at clojure.lang.Compiler$BodyExpr$Parser.parse(Compiler.java:5861) >> at clojure.lang.Compiler$LetExpr$Parser.parse(Compiler.java:6179) >> at clojure.lang.Compiler.analyzeSeq(Compiler.java:6723) >> at clojure.lang.Compiler.analyze(Compiler.java:6524) >> at clojure.lang.Compiler.analyze(Compiler.java:6485) >> at clojure.lang.Compiler$BodyExpr$Parser.parse(Compiler.java:5861) >> at clojure.lang.Compiler$FnMethod.parse(Compiler.java:5296) >> at clojure.lang.Compiler$FnExpr.parse(Compiler.java:3925) >> at clojure.lang.Compiler.analyzeSeq(Compiler.java:6721) >> at clojure.lang.Compiler.analyze(Compiler.java:6524) >> at clojure.lang.Compiler.eval(Compiler.java:6779) >> at clojure.lang.Compiler.load(Compiler.java:7227) >> at clojure.lang.Compiler.loadFile(Compiler.java:7165) >> at clojure.main$load_script.invoke(main.clj:275) >> at clojure.main$script_opt.invoke(main.clj:337) >> at clojure.main$main.doInvoke(main.clj:421) >> at clojure.lang.RestFn.invoke(RestFn.java:408) >> at clojure.lang.Var.invoke(Var.java:379) >> at clojure.lang.AFn.applyToHelper(AFn.java:154) >> at clojure.lang.Var.applyTo(Var.java:700) >> at clojure.main.main(main.java:37) >> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) >> at >> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) >> at >> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) >> at java.lang.reflect.Method.invoke(Method.java:606) >> at com.intellij.rt.execution.application.AppMain.main(AppMain.java:140) >> >> -- >> You received this message because you are subscribed to the Google >> Groups "Clojure" group. >> To post to this group, send email to clo...@googlegroups.com >> <javascript:> >> Note that posts from new members are moderated - please be patient with >> your first post. >> To unsubscribe from this group, send email to >> clojure+u...@googlegroups.com <javascript:> >> For more options, visit this group at >> http://groups.google.com/group/clojure?hl=en >> --- >> You received this message because you are subscribed to the Google Groups >> "Clojure" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to clojure+u...@googlegroups.com <javascript:>. >> For more options, visit https://groups.google.com/d/optout. >> > > -- 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 Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.