java.lang.ClassNotFoundException thrown
wrn opened this issue · 5 comments
wrn commented
When enter something like "clojure.repl/", java.lang.ClassNotFoundException exception will be thrown. Here is a patch to fix that:
(Sorry the formatting is all messed up. Basically, Just one line is changed on "when-let" clause)
((defun ac-nrepl-candidates-static-methods ()
"Return static method candidates."
(ac-nrepl-candidates*
(ac-nrepl-filtered-clj
"(let [prefix \"%s\"]
(if-not (.contains prefix \"/\")
'()
(let [scope (symbol (first (.split prefix \"/\")))]
(map (fn [memb] (str scope \"/\" memb))
(when-let [class (try (complete.core/resolve-class scope) (catch java.lang.ClassNotFoundException e nil))]
(complete.core/static-members class)))))) ")))
samaaron commented
Weird, I don't get an error when entering clojure.repl/
. I wonder what's different. I guess it causes no harm to wrap this up in a try
catch
- but really it would be good to figure out why complete.core
throws an exception here.
samaaron commented
@wrn out of interest, which versions of Emacs, Clojure, and the JVM are you using?