You've already forked python-uncompyle6
mirror of
https://github.com/rocky/python-uncompyle6.git
synced 2025-08-04 09:22:40 +08:00
Add Python 2.3 rule for "if 1: ..."
Fully fixes #97 for Python 2.3. Python 2.4 was fixed in a previous commit.
This commit is contained in:
@@ -218,6 +218,11 @@ class SourceWalker(GenericASTTraversal, object):
|
||||
'importlist2': ( '%C', (0, maxint, ', ') ),
|
||||
})
|
||||
if version <= 2.4:
|
||||
if version == 2.3:
|
||||
TABLE_DIRECT.update({
|
||||
'if1_stmt': ( '%|if 1\n%+%c%-', 5 )
|
||||
})
|
||||
|
||||
global NAME_MODULE
|
||||
NAME_MODULE = AST('stmt',
|
||||
[ AST('assign',
|
||||
|
Reference in New Issue
Block a user