• Home
  • Raw
  • Download

Lines Matching refs:compile

14         compile("hi", "<test>", "exec")
15 compile("hi\r", "<test>", "exec")
18 compile("", "<test>", "exec")
21 compile("\r\n", "<test>", "exec")
22 compile("\r", "<test>", "exec")
23 compile("hi\r\nstuff\r\ndef f():\n pass\r", "<test>", "exec")
24 compile("this_is\rreally_old_mac\rdef f():\n pass", "<test>", "exec")
28 self.assertRaises(SyntaxError, compile, '__debug__ = 1', '?', 'single')
56 self.assertRaises(SyntaxError, compile, "1+*3", "filename", "exec")
59 self.assertRaises(SyntaxError, compile, "f(None=1)", "<string>", "exec")
115 compile(c, "<code>", "exec")
241 compile(s, "<string>", "exec")
249 co = compile(s256, 'fn', 'exec')
351 self.assertRaises(SyntaxError, compile, stmt, 'tmp', 'single')
352 self.assertRaises(SyntaxError, compile, stmt, 'tmp', 'exec')
354 compile("from None import x", "tmp", "exec")
355 compile("from x import None as y", "tmp", "exec")
356 compile("import None as x", "tmp", "exec")
401 compile(stmt, 'tmp', 'exec')
403 self.assertRaises(SyntaxError, compile, stmt, 'tmp', 'exec')
421 self.assertRaises(SyntaxError, compile, code, 'tmp', 'exec')
423 self.assertRaises(SyntaxError, compile, code, "tmp", "exec")
541 co1 = compile(code, '%s1' % fname, 'exec')
542 ast = compile(code, '%s2' % fname, 'exec', _ast.PyCF_ONLY_AST)
544 co2 = compile(ast, '%s3' % fname, 'exec')
550 co1 = compile('print 1', '<string>', 'exec', _ast.PyCF_ONLY_AST)
551 self.assertRaises(TypeError, compile, co1, '<ast>', 'eval')
554 self.assertRaises(TypeError, compile, _ast.If(), '<ast>', 'exec')
559 self.assertRaises(TypeError, compile, ast, '<ast>', 'exec')
578 compile(u"123\x00", "<dummy>", "eval")
581 compile(buffer("123\x00"), "<dummy>", "eval")
582 code = compile(buffer("123\x00", 1, 2), "<dummy>", "eval")
584 code = compile(buffer("1234", 1, 2), "<dummy>", "eval")
586 code = compile(buffer("$23$", 1, 2), "<dummy>", "eval")
599 code = compile(code, "<foo>", "single")