atom/language-c member operator #22116
-
(No atom/language-c discussion board yet) How does your dot In '"."': 'keyword.operator.member' ^^^ I'm thinking there's no work done by the tree-sitter grammar when using string literals directly in the atom language. And on 121 you have your 'number_literal': 'constant.numeric.decimal' For my floating point numbers, it's matching both my number node and the literal string |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
I'm thinking it's something to do with the language specificity. 'identifier': [
{match: '^[A-Z\\d_]+$', scopes: 'constant.other'}
] tree-sitter's build-in word function. word: $ => $.identifier, |
Beta Was this translation helpful? Give feedback.
-
Wrapping the number node function in tree-sitter with a token call addresses this distinction. number: $ => {
//...
return token(choice(
//...
))
}, |
Beta Was this translation helpful? Give feedback.
Wrapping the number node function in tree-sitter with a token call addresses this distinction.