Skip to content
This repository has been archived by the owner on Sep 6, 2022. It is now read-only.

Disabling spell within comments for words matching a specific pattern? #70

Open
Galicarnax opened this issue Jun 4, 2022 · 1 comment

Comments

@Galicarnax
Copy link

When commenting out code blocks (say, in C++), almost all variable and function names with CamelCase or containing underscore are highlighted as bad words. Before using Tree-sitter, I was able to ignore such words using Vim's patterns. I've played around with queries in cpp/spell.scm, and could achieve only ignoring separate lines within comments that contain a specific pattern.

Is my understanding correct that with Tree-sitter it is impossible to ignore such words (without marking them as good), because the parser (at least in case of cpp) does not produce each word within comments as an individual node that could be matched against a pattern?

@matthewmazzanti
Copy link

Also interested in a similar thing, but for URLs. May look into the details here when I get some time - no promises though

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants