MCPcopy Index your code
hub / github.com/RustPython/RustPython / ast_to_object

Method ast_to_object

crates/vm/src/stdlib/_ast/basic.rs:6–9  ·  view source on GitHub ↗
(self, vm: &VirtualMachine, _source_file: &SourceFile)

Source from the content-addressed store, hash-verified

4
5impl Node for ast::Identifier {
6 fn ast_to_object(self, vm: &VirtualMachine, _source_file: &SourceFile) -> PyObjectRef {
7 let id = self.as_str();
8 vm.ctx.intern_str(id).to_object()
9 }
10
11 fn ast_from_object(
12 vm: &VirtualMachine,

Callers

nothing calls this directly

Calls 6

ruff_int_to_bigintFunction · 0.85
intern_strMethod · 0.80
as_strMethod · 0.45
to_objectMethod · 0.45
new_intMethod · 0.45
unwrapMethod · 0.45

Tested by

no test coverage detected