-
-
Notifications
You must be signed in to change notification settings - Fork 44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Incompatibilities with Clojurescript #150
Comments
Thanks for reporting, we should definitely have a cljs REPL type. The one you see above is for Clojure only IIRC. You can see there are customizations for Planck and Lumo in the code but not for "generic" cljs... probably nobody has ever used it - not even myself with it. I used to use Lumo quite extensively though. |
I started adding the CLJS REPL type: https://github.com/austinhaas/inf-clojure/blob/cljs/inf-clojure.el The eldoc stuff seems to work ok (I've barely tested), I also see a problem, both with this new CLJS stuff and with CLJ, where multiple prompts are printed. This may be related to the eldoc stuff, but I'm not sure. For instance, if I move the cursor to a function and for whatever reason the arguments can't be printed, a new prompt might be printed. Sometimes the prompts appear randomly. (I also don't understand why some output goes to the REPL and some goes to the JS console.) I haven't updated ":package-version" for the new custom functions. I assume that would be set to the next version number. I'm not sure what to do with inf-clojure-completion-form-cljs: https://github.com/austinhaas/inf-clojure/blob/cljs/inf-clojure.el#L974 The clojure version appears to use a library named clojure.complete. It is assumed that the user is including this library in their project? |
Btw, there's some historical context here #6
Multiple prompts get printed when you eval something with newlines in it. Haven't look at the code in a long time, but back in the day my solution was to simply create long single-line forms for everything.
Yes.
It's a lein dependency (by virtue of reply being a lein dep), which means a lot of people have it by default. The other should add this manually for the completion to work. I think at some point @arichiardi also added support for compliment. The cljs completion support should be implemented in terms of https://github.com/clojure-emacs/cljs-tooling |
Confirm that the Away from the keyboard for our two weeks but when I come back I can validate / help this PR |
inf-clojure included non-portable Clojure code, and it automatically enables an eldoc feature which triggers the non-portable code in a Clojurescript REPL.
https://github.com/clojure-emacs/inf-clojure/blob/master/inf-clojure.el#L859
Throwable isn't available in clojurescript. Additionally, when called from clojurescript, this code will throw an error stating that the argument to resolve must be a quoted symbol.
In spite of these issues, I don't think these "eldoc" helper functions should be called if the user doesn't have eldoc-mode enabled. I've resolved the issue by commenting out the call to inf-clojure-eldoc-setup
on Line 182: https://github.com/clojure-emacs/inf-clojure/blob/master/inf-clojure.el#L182
The text was updated successfully, but these errors were encountered: