Could nvim tree-sitter plugin user confirm that it is matching the missing parenthesis from the string (str ":& dissoc" with the parenthesis of str, causing positioning the cursor on ( of defmethod not highlight it's matching one at the end ?
(defmethod parse-frag "JSXSpreadAttribute" [{:keys [argument] :as step} _state]
(cond (= (:type argument) "Identifier")
;; TODO dissoc attributes
(str ":& (dissoc " (:name argument) " :class :className " )
:else (do
(js/console.error "Unhandled JSXMemberExpression"
(pr-str step))
(throw "Unhandled JSXMemberExpression"))))
I'm asking a tree-sitter user, because when I remove the plugin this problematic behaviour does not happen.I have treesitter installed. Interestingly, it does match the ( in (defmethod correctly:
And highlighting looks fine, as far as I can tell
However, it does get confused by the ( inside of the string. Note that both of these screenshots match the same )
If you deinstall treesitter, you'll see that while you are inside the string with unbalanced parenthesis it' ll match the ones outside of it, but as soon you move the cursor outside the string, the context ignores parenthesis inside the string, which is the correct behaviour. If you reinstall tree-sitter , it will mix the ones from strings with the ones from clojure syntax
I think this is https://github.com/nvim-treesitter/nvim-treesitter/issues/2966#issuecomment-1140408607