Get tests passing w/ new alias API
This commit is contained in:
parent
cb5fe80348
commit
09f4796f6b
18 changed files with 99 additions and 94 deletions
|
|
@ -33,10 +33,10 @@ static inline uint32_t ts_node__offset_row(TSNode self) {
|
|||
|
||||
static inline bool ts_node__is_relevant(TSNode self, bool include_anonymous) {
|
||||
const Tree *tree = ts_node__tree(self);
|
||||
if (tree->context.alias_symbol > 0) {
|
||||
return true;
|
||||
if (include_anonymous) {
|
||||
return tree->context.alias_symbol || tree->visible;
|
||||
} else {
|
||||
return include_anonymous ? tree->visible : tree->visible && tree->named;
|
||||
return tree->context.alias_is_named || (tree->visible && tree->named);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue