language_symbol_for_name {treesitter} | R Documentation |
Language symbols
Description
Get the integer symbol ID for a particular node name. Can be useful for exploring the grammar.
Usage
language_symbol_for_name(x, name, ..., named = TRUE)
Arguments
x |
A tree-sitter language object. |
name |
The names to look up symbols for. |
... |
These dots are for future extensions and must be empty. |
named |
Should named or anonymous nodes be looked up? Recycled to the
size of |
Value
An integer vector the same size as name
containing either:
The integer symbol ID of the node name, if known.
-
NA
if the node name was not known.
See Also
Examples
language <- treesitter.r::language()
language_symbol_for_name(language, "identifier")
[Package treesitter version 0.1.0 Index]