-
Notifications
You must be signed in to change notification settings - Fork 47
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
support Symbol Highlight Transient State in Spacemacs #50
Comments
I have absolutely no idea how Clojure manages to do this, as I can find no modifications in either its layer or mode file that would enable it. The solution I added isn't what Clojure does. Edit: Missed the Function range part of this issue, I'll look at that. |
I checked clojure mode and it doesn't seem to support the Maybe we should report that for clojure, but to Spacemacs or clojure mode? |
It looks like the |
Are you familiar with the https://github.com/Foxboron/HyREPL project? I tried getting it to run a while back but it needs to be fixed. I'm not sure if attacking autocompletion through an nREPL protocol is the best course of action or not. |
I've not used it, so I'm not sure either. Extending IPython is another option. Hy's bundled command line repl also has tab completions via readline, I think. That might be the easiest place to start. There's probably some way to integrate that. HyREPL is written in a older version of Hy. I'm not sure how thorough the tests are, but if you want to try updating it in a fork, replacing You could start with a shim macro implementing something like the old, broken, (defmacro let [pairs &rest body]
`((fn [] (setv ~@pairs) ~@body))) Then see if the tests pass, or if anything else needs updating. Some other things have been removed and HyREPL might have been using them, but they have near or total equivalents. Check Hy's news file, or ask me if you can't tell what something missing meant. At that point, you could start testing it with emacs. Before making a PR from your fork, update the
This should work for any use of Once that's working, you can remove all the |
I'm likely to hold off on this in favor of an I've updated AHS to include dashes in symbols so eg. |
AHS? What's that? I do use I have noticed one more issue with |
Auto highlight symbol, the implementing emacs package. I typically use I'll look to fix the dots. |
For the dots, no matter how I work with the syntax table we either have the entire |
I'm not sure if this issue is in hy-mode itself or the Spacemacs layer, or both somehow.
In an Elisp buffer, in Evil normal mode, you can activate Symbol Highlight Transient State with
*
or#
to search backwards or forwards for the symbol under the cursor. Then you can change the effective range of the search withr
, cycling betweenDisplay
Function
andBuffer
.In a Hy buffer, the
Function
range is unavailable. This is important when renaming a local in a function definition.It also doesn't recognize all instances of a symbol. For example, if you put the point on the first
x
, and use*
in this elisp, then it finds all threex
symbols.But in the equivalent Hy,
(defn [x] `(x ~x))
It doesn't find the third
x
. But it can using the exact same code in clojure mode.The text was updated successfully, but these errors were encountered: