Lang.AddrSourceHeap addresses of Python objects.
Classes
Functions
type Mopsa.addr_kind += | A_py_class of class_address * (Mopsa.addr * Mopsa.expr option) listmro
*)| A_py_function of function_addressfunction
*)| A_py_method of Mopsa.addr * Mopsa.expr option
* Mopsa.addr * Mopsa.expr option
* string| A_py_module of module_addressThese addresses refer only to static objects
val eval_alloc :
?mode:Mopsa.mode ->
('a, 'b) Mopsa.man ->
Ast.Addr.addr_kind ->
Mopsa_utils.Location.range ->
'a Core.Flow.flow ->
('a, Ast.Addr.addr) Mopsa.Cases.casesAllocate an object on the heap and return its address as an evaluation
Lists of built-ins
Name of a builtin with an optional dot notation in case of sub-objects (methods of classes, etc.)
Return the base and the attribute of a dot name
Address of an object
Name of an object
Search for the address of a builtin given its name
Check whether a built-in exists given its name
Check whether an attribute of a built-in object exists, given its name
val find_builtin_attribute :
(Mopsa.addr * Mopsa.expr option) ->
string ->
Mopsa.addr * Mopsa.expr optionSearch for the address of a builtin attribute
Check whether a dot-named function f is a member of the class cls
val mk_py_issubclass_builtin_r :
Mopsa.expr ->
string ->
Mopsa_utils.Location.range ->
Mopsa.exprval mk_py_issubclass_builtin_l :
string ->
Mopsa.expr ->
Mopsa_utils.Location.range ->
Mopsa.exprval mk_py_isinstance_builtin :
Mopsa.expr ->
string ->
Mopsa_utils.Location.range ->
Mopsa.exprtype Mopsa.addr_kind += | A_py_c_module of stringname
*)| A_py_c_function of string
* int
* py_c_function_kind
* int option
* Mopsa.addr * Mopsa.expr optionself
*)| A_py_c_class of stringname
*)Computes the c3 linearization of an object. This is Python's approach to deal with redundant parents in the inheritance
val merge :
(Mopsa.addr * Mopsa.expr option) list list ->
(Mopsa.addr * Mopsa.expr option) listval search_c :
(Mopsa.addr * Mopsa.expr option) list list ->
(Mopsa.addr * Mopsa.expr option) optionval create_builtin_class :
class_address ->
'a ->
'b ->
(Mopsa.addr * Mopsa.expr option) list ->
'c ->
unitval register_addr_kind_nominal_type :
((Mopsa.addr_kind -> string) -> Mopsa.addr_kind -> string) ->
unitval register_addr_kind_structural_type :
((Mopsa.addr_kind -> string -> bool) -> Mopsa.addr_kind -> string -> bool) ->
unit