You've already forked python-uncompyle6
mirror of
https://github.com/rocky/python-uncompyle6.git
synced 2025-08-03 00:45:53 +08:00
BIN
test/bytecode_3.5/04_CALL_FUNCTION_VAR_KW.pyc
Normal file
BIN
test/bytecode_3.5/04_CALL_FUNCTION_VAR_KW.pyc
Normal file
Binary file not shown.
7
test/simple_source/bug35/04_CALL_FUNCTION_VAR_KW.py
Normal file
7
test/simple_source/bug35/04_CALL_FUNCTION_VAR_KW.py
Normal file
@@ -0,0 +1,7 @@
|
||||
# sql/schema.py
|
||||
def tometadata(self, metadata, schema, Table, args, name=None):
|
||||
table = Table(
|
||||
name, metadata, schema=schema,
|
||||
*args, **self.kwargs
|
||||
)
|
||||
return table
|
@@ -483,6 +483,8 @@ class Python3Parser(PythonParser):
|
||||
# high byte number of positional parameters
|
||||
args_pos = token.attr & 0xff
|
||||
args_kw = (token.attr >> 8) & 0xff
|
||||
args_kw = (token.attr >> 8) & 0xff
|
||||
# args_ann = (token.attr >> 16) & 0x7FFF
|
||||
|
||||
# Additional exprs for * and ** args:
|
||||
# 0 if neither
|
||||
@@ -498,7 +500,7 @@ class Python3Parser(PythonParser):
|
||||
# first LOAD_FAST, below are located.
|
||||
# Python 3.6+ replaces CALL_FUNCTION_VAR_KW with CALL_FUNCTION_EX
|
||||
if opname.endswith('KW'):
|
||||
kw = 'LOAD_FAST '
|
||||
kw = 'expr '
|
||||
else:
|
||||
kw = ''
|
||||
rule = ('call_function ::= expr expr ' +
|
||||
|
Reference in New Issue
Block a user