MCPcopy Create free account
hub / github.com/SourceCode-AI/aura / _compile_src

Method _compile_src

aura/pattern_matching.py:288–292  ·  view source on GitHub ↗
(cls, src: str)

Source from the content-addressed store, hash-verified

286
287 @classmethod
288 def _compile_src(cls, src: str) -> nodes.NodeType:
289 ast_tree = collect(dedent(src), minimal=True)
290 loc = ScanLocation(location="<unknown>")
291 v = visitor.Visitor.run_stages(location=loc, stages=("convert", "rewrite"), ast_tree=ast_tree)
292 return v.tree[-1] # TODO: assumption right now is it's a module with one body block
293
294 @property
295 def id(self) -> str:

Callers 5

__init__Method · 0.95
test_patternsFunction · 0.80
test_matching_triggersFunction · 0.80
test_any_ofFunction · 0.80
disabled_test_decoratorFunction · 0.80

Calls 3

collectFunction · 0.85
ScanLocationClass · 0.85
run_stagesMethod · 0.80

Tested by 4

test_patternsFunction · 0.64
test_matching_triggersFunction · 0.64
test_any_ofFunction · 0.64
disabled_test_decoratorFunction · 0.64