You've already forked python-uncompyle6
mirror of
https://github.com/rocky/python-uncompyle6.git
synced 2025-08-04 01:09:52 +08:00
Start custom grammar for 2.6 and ...
fix a python 2.6.9 deparse with lc if+and+not
This commit is contained in:
23
uncompyle6/parsers/parse26.py
Normal file
23
uncompyle6/parsers/parse26.py
Normal file
@@ -0,0 +1,23 @@
|
||||
# Copyright (c) 2016 Rocky Bernstein
|
||||
"""
|
||||
spark grammar differences over Python2 for Python 2.6.
|
||||
"""
|
||||
|
||||
from uncompyle6.parser import PythonParserSingle
|
||||
from spark_parser import DEFAULT_DEBUG as PARSER_DEFAULT_DEBUG
|
||||
from uncompyle6.parsers.parse2 import Python2Parser
|
||||
|
||||
class Python26Parser(Python2Parser):
|
||||
|
||||
def __init__(self, debug_parser=PARSER_DEFAULT_DEBUG):
|
||||
super(Python26Parser, self).__init__(debug_parser)
|
||||
self.customized = {}
|
||||
|
||||
|
||||
def p_lis_iter(self, args):
|
||||
'''
|
||||
list_iter ::= list_if JUMP_BACK
|
||||
'''
|
||||
|
||||
class Python26ParserSingle(Python2Parser, PythonParserSingle):
|
||||
pass
|
Reference in New Issue
Block a user