cursive
cursive copied to clipboard
Cursive does not understand dot (.) and double-dot (..) forms
Cursive does not understand how to resolve symbols inside dot (. o method arg)
and double-dot (.. o (method arg) (method arg))
special-forms. Contrived example:
; "put" is not highlighted as a method
; and is marked as an unresolved symbol
(. (HashMap.) put "key" "value")
; "put" will be marked as unresolved symbol
(.. (HashMap.) (put "key" "value")
; But this is ok:
(.put (HashMap.) "key" "value")
; So is this:
(-> (HashMap.) (.put "key" "value")
Right - this is a little unfortunate. This relies on knowing the types of variables, which is not done yet but should be soon. Your third and fourth forms are marked as resolved but it's still pretty primitive - they just resolve to any method called put
in any imported class.
+1 This applies to all macros, not just . and ..
Even though Cursive now understands the types of the variables (I think?) ..
forms are still not resolved properly AFAICT.
Hello! I've started using Cursive more of late and this one thing that I keep on running into.
..
still gives errors:
+1
This occurs even when type hints seem to give all necessary type info.