Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 6a4e3c5

Browse files
committed
Make Demo/parser/test_parser.py run.
1 parent feb3b75 commit 6a4e3c5

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

Demo/parser/test_parser.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,19 +11,19 @@ def testChunk(t, fileName):
1111
global _numFailed
1212
print('----', fileName, end=' ')
1313
try:
14-
ast = parser.suite(t)
15-
tup = parser.ast2tuple(ast)
16-
# this discards the first AST; a huge memory savings when running
14+
st = parser.suite(t)
15+
tup = parser.st2tuple(st)
16+
# this discards the first ST; a huge memory savings when running
1717
# against a large source file like Tkinter.py.
18-
ast = None
19-
new = parser.tuple2ast(tup)
18+
st = None
19+
new = parser.tuple2st(tup)
2020
except parser.ParserError as err:
2121
print()
2222
print('parser module raised exception on input file', fileName + ':')
2323
traceback.print_exc()
2424
_numFailed = _numFailed + 1
2525
else:
26-
if tup != parser.ast2tuple(new):
26+
if tup != parser.st2tuple(new):
2727
print()
2828
print('parser module failed on input file', fileName)
2929
_numFailed = _numFailed + 1

0 commit comments

Comments
 (0)