MCPcopy Index your code
hub / github.com/SourceCode-AI/aura / ASTNodeIdentifier

Class ASTNodeIdentifier

ngrams.py:15–26  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

13
14@dataclass
15class ASTNodeIdentifier:
16 label: Union[str, None] = None
17 node_type: Union[str, None] = ''
18 children: List[Any] = field(default_factory=list)
19
20 def __iadd__(self, other):
21 if other:
22 self.children.append(other)
23 return self
24
25 def to_tuple(self):
26 return (self.label, self.node_type, tuple(x.to_tuple() for x in self.children))
27
28
29@Analyzer.ID("ast_ngrams")

Callers 15

extract_identifierFunction · 0.85
node_function_defFunction · 0.85
node_callFunction · 0.85
node_moduleFunction · 0.85
node_exprFunction · 0.85
node_class_defFunction · 0.85
node_attributeFunction · 0.85
node_nameFunction · 0.85
node_strFunction · 0.85
node_assignFunction · 0.85
node_importFunction · 0.85
node_import_fromFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected