Daniel Bradburn
ca1679e636
Added support for support for Python 3.6 CALL_FUNCTION_KW
2017-05-10 21:49:42 +02:00
rocky
f8a40c1949
Reduce spurious "continue" statements
2017-05-07 13:15:26 -04:00
rocky
605721c995
Python 3.x control-flow bug...
...
"pass" statement inside "while True"
2017-05-07 09:10:05 -04:00
rocky
26e8de8532
Fix improper COME_FROM_EXCEPT in Python 3.3+
2017-05-07 03:19:53 -04:00
rocky
4e9555a7f6
Improve Python 3.2 decompilation ...
...
by removing a lot of the control-flow labels of 3.3+
2017-05-05 21:34:21 -04:00
rocky
84fd71b73b
Python 3.6 CALL_FUNCTION_EX first attempt
2017-04-25 07:31:01 -04:00
rocky
47dbc57f3d
Reduce adding RETURN_END_IF in 3.5+
...
The whole control flow determination has to be redone in a less
haphazard way using real flow-control analysis. Hopefully that's on the
way.
In the meantime we have this hack.
2017-04-14 06:57:25 -04:00
rocky
41343c27b7
Misc bugs
...
parse2.py: restore accidently-removed while1stmt rule
scanner27.py: grammar typo
check_ast: add while1else to list of looping constructs
pysource.py: CALL_FUNCTION_VAR_KW_ARGS with positional args rule is different?
2017-04-10 07:57:56 -04:00
rocky
fdcb90f661
Python 3.0 doesn't have POP_JUMP_IF...
2017-03-12 10:32:05 -04:00
rocky
5856802902
Small cleanup - remove POP_JUMP_TF
2017-03-07 22:07:29 -05:00
rocky
4f2ae2f603
More accurate ranges of try blocks in 3.x
2017-03-05 00:05:52 -05:00
rocky
160ec0d9cc
COME_FROM for 3.x POP_EXCEPT, DRY with op_name() ...
...
Start adding COME_FROMs for POP_EXCEPT in preparation for
getting tryelse blocks correct.
Simpler opname access functions:
- self.op_name(op) is self.opc.opname[op]
- self.op_name_from_offset(offset) is self.opc.opname[self.code[offset]]
verify.py: not all offsets are ints
2017-03-01 05:50:31 -05:00
rocky
493e4b14a1
Some Python 3.4 bugss fixed by using 3.5 rules
2017-02-20 08:17:17 -05:00
rocky
9491c67779
More COME_FROM's in Python 3...
...
Need this to find boundaries of simple if better
2017-02-20 04:17:46 -05:00
rocky
1cb2cd7a82
More 2.6, 2.7 control flow
...
Todo more COME_FROMs but now need to check targets better. In some cases
we're relying on grammar ambiguity to work out right and in 2.7 it doesn't
2017-01-24 01:21:28 -05:00
rocky
9ec312ba5e
More 2.6, 2.7 control-flow bugs
...
Wasn't limiting exception clause to try finally. Probably still has bugs
in try-finally nesting
Add another 2.6/2.7 COME_FROM to try to limit if/end scope better
2017-01-24 00:53:30 -05:00
rocky
597d51951e
Improve Python 2.6 & 2.7 verification
2017-01-23 02:32:09 -05:00
rocky
8333e4ae93
Handle BUILD_CONST_KEY_MAP as a varargs
...
custom rules with BUILD_CONST_KEY_MAP are pinned to the specific number
of args seen.
2017-01-20 20:41:10 -05:00
rocky
9c49b5d54b
Handle 3.6 BUILD_CONST_KEYMAP
2017-01-15 11:10:13 -05:00
rocky
8dc23e2cdc
Python 2.1 doesn't have FOR_ITER or GET_ITER...
...
adjust locgic for this fact
2017-01-15 09:50:38 -05:00
rocky
707770049f
Python 3.0 decompile bugs
2017-01-08 22:19:15 -05:00
rocky
ec0669367f
Towards better 3.0 decompilation
...
Sync scanner2 and scanner3 better
2017-01-08 17:40:57 -05:00
rocky
3f40c16587
Fix 3.5, 3.6 while true if/break bug
2017-01-08 15:54:49 -05:00
rocky
21023fea74
Add 3.5+ async with/for ..
...
scanner3.py: 3.6 bytecode vs wordcode fix
2017-01-08 08:54:03 -05:00
rocky
e4c0d56947
3.5 continue check is needed on 3.6
2017-01-03 07:22:25 -05:00
rocky
4827b1e994
Towards better 3.6 support
2017-01-03 00:44:07 -05:00
rocky
2b46e71264
Python 3.5 continue detection bug
2017-01-02 10:06:52 -05:00
rocky
84c2932bc5
add come_from for setup_finally and setup_except
2017-01-01 21:11:35 -05:00
rocky
874b3c9d31
Towards fixing Python 3.5 return bugs
2017-01-01 04:56:15 -05:00
rocky
2327f0fdfa
Towards fixing a Python 3.3 return/continue bug
2016-12-31 03:56:41 -05:00
rocky
6f097ff1ca
dectect_structure() -> detect_control_flow()
2016-12-29 07:32:36 -05:00
rocky
8eb1a16f5b
DRY code and emitted Python 3 source
...
* Python 3: break; continue -> break
* Use variable in detect_structure for pre[rtarget]
* Make Python 2 and Python 3 detect_structure more alie
2016-12-29 07:28:37 -05:00
rocky
ed9fb64e72
More if/then detection in Python 3.x
2016-12-29 03:56:39 -05:00
R. Bernstein
e56743cc14
Merge pull request #72 from rocky/master
...
THEN psuedo-ops for Python 2.x
2016-12-29 01:49:59 -05:00
rocky
39814fab8b
Misc bugs
2016-12-28 20:16:13 -05:00
rocky
6c546fe6e1
WIP : Add THEN to disambigute from "and"
2016-12-27 22:45:08 -05:00
rocky
9b1dd0f26c
Make 2.6 and 2.7 ingest more alike
2016-12-27 10:29:29 -05:00
rocky
2f51067a9d
Scanner call fixes. NAME_MODULE removal for <=2.4
2016-12-25 09:20:57 -05:00
rocky
e3f4beeb74
Lint
2016-12-24 07:45:02 -05:00
rocky
e6761e13bb
Python flake8 crap
...
Was testing realgud's C-x!8 (goto flake8 warning/error)
2016-12-18 20:18:19 -05:00
rocky
eebec48308
show-asm on python2.5 is optional
...
make scanner2 look a little more like scanner3
2016-12-17 08:01:25 -05:00
rocky
08dcc7d820
Start to handle 3.5 build_map_unpack_with_call
...
3.6 also started but needs even more work
2016-12-16 20:39:24 -05:00
rocky
7755563b65
Some Python 3.6 bytecode->wordcode fixes
2016-12-15 02:54:25 -05:00
rocky
38eed14b41
Another python 3 ELSE fixes and ...
...
Makefile:
- test python 3.0 bytecode
- turn full --verify back on Python 3.x
2016-12-10 06:36:22 -05:00
rocky
2c993f8c32
Another faulty Python3 ELSE tag remove
2016-12-10 00:43:55 -05:00
rocky
263c63e009
Back of some of the verification changes
2016-12-09 21:43:22 -05:00
rocky
813bce4697
Merge branch 'master' of github.com:rocky/python-uncompyle6
2016-12-09 21:13:31 -05:00
rocky
a5d2237435
Python 3.x else clause detection and..
...
- Strengthen verify check.
- weak verification on Python 3.5 for now
2016-12-09 21:10:10 -05:00
rocky
d22931cb49
Get ready for release 2.9.7
...
Some of the many lint things. Linting is kind of stupid though.
2016-12-04 09:36:30 -05:00
rocky
97576e473d
Python 3 while/else bug
2016-11-27 07:06:20 -05:00