Lines Matching refs:symtable
2 Test the API of the symtable module.
4 import symtable
54 top = symtable.symtable(TEST_CODE, "?", "exec")
174 st1 = symtable.symtable('def f():\n x: int\n', 'test', 'exec')
179 st3 = symtable.symtable('def f():\n x = 1\n', 'test', 'exec')
186 st5 = symtable.symtable('global x\nx: int', 'test', 'exec')
191 st6 = symtable.symtable('def g():\n'
215 symtable.symtable(brokencode, "spam", "exec")
223 checkfilename("def f(x): global x", 11) # symtable-build-time
224 symtable.symtable("pass", b"spam", "exec")
227 symtable.symtable("pass", bytearray(b"spam"), "exec")
229 symtable.symtable("pass", memoryview(b"spam"), "exec")
231 symtable.symtable("pass", list(b"spam"), "exec")
234 symbols = symtable.symtable("42", "?", "eval")
237 symbols = symtable.symtable("42", "?", "single")
240 symbols = symtable.symtable("def f(x): return x", "?", "exec")
243 top = symtable.symtable(TEST_CODE.encode('utf8'), "?", "exec")
248 top = symtable.symtable(code, "?", "exec")