(self)
| 1119 | yield from do(ast.AST) |
| 1120 | |
| 1121 | def test_pickling(self): |
| 1122 | import pickle |
| 1123 | |
| 1124 | for protocol in range(pickle.HIGHEST_PROTOCOL + 1): |
| 1125 | for code in exec_tests: |
| 1126 | with self.subTest(code=code, protocol=protocol): |
| 1127 | tree = compile(code, "?", "exec", 0x400) |
| 1128 | ast2 = pickle.loads(pickle.dumps(tree, protocol)) |
| 1129 | self.assertEqual(to_tuple(ast2), to_tuple(tree)) |
| 1130 | |
| 1131 | @skip_if_unlimited_stack_size |
| 1132 | def test_copy_with_parents(self): |