Debian Codegraph @

rpython/rlib/exports.py

raw symbols SCIP
1 from rpython.rtyper.lltypesystem.lltype import typeOf, ContainerType
2
3 # XXX kill me
4
5 def export_struct(name, struct):
6 assert name not in EXPORTS_names, "Duplicate export " + name
7 assert isinstance(typeOf(struct), ContainerType)
8 EXPORTS_names.add(name)
9 EXPORTS_obj2name[struct] = name
10
11 def clear():
12 global EXPORTS_names, EXPORTS_obj2name
13 EXPORTS_names = set()
14 EXPORTS_obj2name = {}
15 clear()