-
Notifications
You must be signed in to change notification settings - Fork 38
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
Recognise alternative let-like formats #76
Comments
Hi, could you please check #77 first? Would it perhaps be enough if I merged something like that? |
Actually, I agree with your point that it makes sense having it "for free" for symbols that have names exactly like I'll keep this open for now. |
Ok nice! I have a patch around, should be at hand |
Brief
The following vars:
compliment/src/compliment/sources/local_bindings.clj
Lines 6 to 13 in a112bb8
represent closed sets and typically only will work over clojure.core symbols. So if one uses e.g.
my/let
, completion accuracy will degrade.Proposal
In:
compliment/src/compliment/sources/local_bindings.clj
Line 55 in a112bb8
Instead of doing
(first form)
(which will returnlet
,my/let
, etc), perform(-> form first name symbol)
. This waylet-like-forms
will work as usual, but also admitting alternative mechanisms that share thename
but use a differentnamespace
.Same for
defn
,doseq
,letfn
.Alternatives
Consumers could use
alter-var-root!
over the mentioned vars, although that doesn't seem a clean thing to do (and would also have to account for different ns aliases:my/let
,com.domain.my/let
, etc - which is not a closed set)Thanks - V
The text was updated successfully, but these errors were encountered: