rocky
8663b4ca52
Fix bugs caused by last commit
2019-04-18 07:31:16 -04:00
rocky
b2dd58a85e
Hacky attemp to add more 3.x annotate information in
2019-04-18 02:26:50 -04:00
rocky
43646b3c71
Comma placement in 3.6 and 3.7 **kwargs
...
fixes #208
2019-01-14 17:41:54 -05:00
rocky
19ec52eb63
Change AST to SyntaxTree in many places
2018-07-15 12:37:50 -04:00
rocky
3ac4f1ee61
Had botched parameter order in 3.x. Sigh
2018-06-13 11:29:57 -04:00
rocky
e3d918df3d
Allow Python 3.0 and fix default param bug in 3.0
2018-06-11 11:33:50 -04:00
rocky
e7b62a722f
Fix more Python 3.0 parse bugs
2018-06-10 16:49:04 -04:00
rocky
189605ea2c
Adjust showtree() calls
2018-05-13 14:23:52 -04:00
rocky
5de8a33286
codeNode->code_node
2018-04-13 15:44:41 -04:00
rocky
61e2b3b635
Can run on 3.1. Fix some 3.1 function-call bugs
2018-04-08 04:11:01 -04:00
rocky
30ce3a8bea
Small tweaks
2018-04-04 22:36:26 -04:00
rocky
ca41ea99f2
Fix 3.2 to 3.3 make_function more properly
2018-04-04 14:30:34 -04:00
rocky
e3040c78a9
3.2-3.4 Functions cals/defininitions yet again
...
And we're still not out of the woods.
2018-04-03 21:27:31 -04:00
rocky
e9c0d03b8b
3.2 mk_func tweak...
...
...more is needed though
2018-04-03 17:57:37 -04:00
rocky
120412f5a8
Add Python 3.6 setcomp and another call bug
2018-04-01 07:09:24 -04:00
rocky
9be4908c9c
Python 3.6 MAKE_FUNCTION yet again...
...
And we'll eventually have to do more down the line
2018-03-29 22:04:46 -04:00
rocky
7d110f17bc
3.6 decompilation problems
2018-03-29 17:21:22 -04:00
rocky
35a60e0274
Fix parser slowness in decompiling 3.x locale.py..
...
And remove grammar inefficiency in adding extraneous kwargs in <= 3.2
kwargs was nullable so it might not have been wasn't wrong, just inefficient.
2018-03-23 11:59:04 -04:00
rocky
5c662b334e
Handle 3.x "nonlocal" statement
2018-03-19 07:57:25 -04:00
rocky
def9e1676b
look for "closure" node from the end...
...
Fix previous commit. Looking from the beginning fails because there are
a variable number of default values. From the end though seems fixed.
2018-03-04 19:28:51 -05:00
rocky
35fcb1edf1
Picking out 3.3 function default values
2018-03-04 18:40:08 -05:00
rocky
a8260edded
3.6 function/class prototype fixes..
...
Had got the order backwards in: class Foo(a=B.c)
String defaults in default parameter tuples need to be quoted
2018-03-03 09:12:02 -05:00
rocky
bb13988126
Instruction fixup broken 3.x make_func...
...
for handling default values
2018-03-02 08:03:51 -05:00
rocky
2edc757b6f
more deparse_code -> code_deparse API additions
2018-03-01 16:55:45 -05:00
rocky
f7439f506a
Fix 3.6 MAKE_FUNCTION for kw params...
...
and remove duplicated attributies in pattr of MAKE_FUNCITON token.
2018-03-01 07:14:46 -05:00
rocky
413df51dfa
Token.format(), shows CONST values better...
...
We were not showing the proper value for None, or False.
Start a unit test for Token().
I think this cleans the Token class up a little more.
More work is needed for MAKE_FUNCTION...
Note: Some debug stuff is commented out in make_funciton.py for upcoming work.
2018-02-28 22:05:12 -05:00
rocky
5c2d0484e5
3.6 MAKE_FUNCTION workarounds
...
Still wrong, but points to diretions for improvements
2018-02-26 09:10:00 -05:00
Yiming Wang
3545c7dc6f
Keep global statements in fixed order
2018-02-24 22:22:50 +08:00
rocky
09efb24a3e
Start distinguishing AST from grammar tree
2018-02-22 11:17:09 -05:00
rocky
bcf437deda
3.x bug in adding extra , in **kargs
2018-01-29 12:03:15 -05:00
rocky
a9df4e3a54
Fix 3.0 .. 3.2 kwargs bug
2018-01-29 09:40:38 -05:00
rocky
3b0eb017b6
Bang on Python 3.6 MAKE_FUNCTION
2017-12-15 07:35:58 -05:00
rocky
c5b8531ef1
Fix last-minute bug due to kwargs->kwargs1
2017-12-10 18:00:44 -05:00
rocky
bbaa3e6602
Fix bug in single param **arg
2017-12-05 07:50:22 -05:00
rocky
2d628acf60
Separate rules for set, tuple, dict from list...
...
Sync fragments.py with pysource
2017-12-05 00:13:17 -05:00
rocky
5fe8303184
Two bugs and a refactor ..
...
1. parse2.py: try except in a loop with a (virtual) continue
treat CONTINUE like JUMP_ABSOLUTE which it is
2. in taking methods off of constants, a parenthesis needs to be added
Some refactoring of global code done
2017-12-03 10:46:22 -05:00
rocky
5ae32de709
Add global statements even for read of globals
2017-12-02 19:13:11 -05:00
rocky
dad1b4780c
Fix bugs in 3.6 default parameter handling
...
Mentioned in Issue #139
2017-12-01 20:12:06 -05:00
rocky
af38064a1b
remove unpack_list rule and ...
...
tidy things a bit more
2017-11-25 00:32:13 -05:00
rocky
0c386d2c39
Fix bug where lambda has a yield in it
2017-11-24 08:55:26 -05:00
rocky
4f0a668b7c
Add flag to tolerate deparse errors...
...
and keep going. The fragment parser should ignore errors
in nested function definitions
2017-11-04 12:29:27 -04:00
rocky
1392b18bd7
Adjust for spark-parser 2.7.0 incompatabilities
2017-10-10 14:14:26 -04:00
rocky
4d58438515
Get ready for release 2.11.5
2017-08-31 09:42:14 -04:00
rocky
ee3202779a
A guard against badly formated bytecode
2017-06-28 18:39:05 -04:00
rocky
9c072a6a42
3.x funciton and annotation bug fixes
2017-06-25 18:46:03 -04:00
rocky
daea3c348c
Fragment tag more expressions
...
Revise make_function3 comment wrt args and kwargs
2017-06-10 16:31:56 -04:00
rocky
267ecda070
Python 3.2 MAKE_FUNCTION again..
...
Was handling bug32/01_named_and_kwargs.py wrong again
2017-06-10 01:42:50 -04:00
rocky
6a991833a3
Attempt to document the MAKE_FUNCTION/MAKE_LAMBDA mess...
...
in Python 3.0+
2017-06-09 06:52:14 -04:00
rocky
28ee3f1257
Correct make_function3 for Pytohn 3.2
2017-06-08 21:49:13 -04:00
rocky
d540146d5a
WIP: start 3.6 MAKE_FUNCTION handling
2017-05-11 07:00:46 -04:00