Struct erg_compiler::ty::codeobj::CodeObj
source · pub struct CodeObj {Show 18 fields
pub argcount: u32,
pub posonlyargcount: u32,
pub kwonlyargcount: u32,
pub nlocals: u32,
pub stacksize: u32,
pub flags: u32,
pub code: Vec<u8>,
pub consts: Vec<ValueObj>,
pub names: Vec<Str>,
pub varnames: Vec<Str>,
pub freevars: Vec<Str>,
pub cellvars: Vec<Str>,
pub filename: Str,
pub name: Str,
pub qualname: Str,
pub firstlineno: u32,
pub lnotab: Vec<u8>,
pub exceptiontable: Vec<u8>,
}
Expand description
Implementation of PyCodeObject
, see Include/cpython/code.h in CPython for details.
各属性をErg側のObjに変換すると遅くなりそうなので、アクサスされたときのみ変換して提供する
Fields§
§argcount: u32
§posonlyargcount: u32
§kwonlyargcount: u32
§nlocals: u32
§stacksize: u32
§flags: u32
§code: Vec<u8>
§consts: Vec<ValueObj>
§names: Vec<Str>
§varnames: Vec<Str>
§freevars: Vec<Str>
§cellvars: Vec<Str>
§filename: Str
§name: Str
§qualname: Str
§firstlineno: u32
§lnotab: Vec<u8>
§exceptiontable: Vec<u8>