From: Fred Drake Date: Tue, 17 Jul 2001 19:33:25 +0000 (+0000) Subject: Use the "st" versions of the "ast" calls in the parser module -- there is X-Git-Tag: v2.2a3~1098 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=6e4f2c09dfc7f6c63c86bf795004f7bba9eef2ac;p=thirdparty%2FPython%2Fcpython.git Use the "st" versions of the "ast" calls in the parser module -- there is no reason to pretend the syntax trees we're dealing with are abstract. --- diff --git a/Lib/test/test_parser.py b/Lib/test/test_parser.py index 8955bf8dfabc..9e994750c916 100644 --- a/Lib/test/test_parser.py +++ b/Lib/test/test_parser.py @@ -13,7 +13,7 @@ class RoundtripLegalSyntaxTestCase(unittest.TestCase): st1 = f(s) t = st1.totuple() try: - st2 = parser.sequence2ast(t) + st2 = parser.sequence2st(t) except parser.ParserError: self.fail("could not roundtrip %r" % s) @@ -140,7 +140,7 @@ class RoundtripLegalSyntaxTestCase(unittest.TestCase): class IllegalSyntaxTestCase(unittest.TestCase): def check_bad_tree(self, tree, label): try: - parser.sequence2ast(tree) + parser.sequence2st(tree) except parser.ParserError: pass else: