From 7700446bb12ce4fc7f81ec9ebc586663847d1532 Mon Sep 17 00:00:00 2001 From: rocky Date: Sun, 30 Oct 2016 21:16:33 -0400 Subject: [PATCH] Note github unpyc3 and.. - Add source to bytecode_2.2/03_class_method.pyc - more ignore --- .gitignore | 3 ++- README.rst | 1 + test/bytecode_2.2/03_class_method.pyc | Bin 570 -> 570 bytes test/simple_source/def/03_class_method.py | 13 +++++++++++++ 4 files changed, 16 insertions(+), 1 deletion(-) create mode 100644 test/simple_source/def/03_class_method.py diff --git a/.gitignore b/.gitignore index 88363be6..76e99b32 100644 --- a/.gitignore +++ b/.gitignore @@ -1,7 +1,7 @@ +*.pyo *.pyc *_dis *~ -*.pyc /.cache /.eggs /.python-version @@ -13,5 +13,6 @@ /nose-*.egg /tmp /uncompyle6.egg-info +/unpyc __pycache__ build diff --git a/README.rst b/README.rst index 46c1eb08..60b654f6 100644 --- a/README.rst +++ b/README.rst @@ -132,6 +132,7 @@ See Also * https://github.com/zrax/pycdc : supports all versions of Python and is written in C++ * https://code.google.com/archive/p/unpyc3/ : supports Python 3.2 only. The above projects use a different decompiling technique what is used here. +* https://github.com/figment/unpyc3/ : fork of above, but supports Python 3.2 only. Include some fixes like supporting function annotations * The HISTORY_ file. .. |downloads| image:: https://img.shields.io/pypi/dd/uncompyle6.svg diff --git a/test/bytecode_2.2/03_class_method.pyc b/test/bytecode_2.2/03_class_method.pyc index 0304456719ac94b4c94fb26af0e994e7952a63b9..08f9ed7777fbf951f0cf981c363195e09de38945 100644 GIT binary patch delta 17 YcmdnRvWta7_bo5i^BH0h8##=a05&!SkN^Mx delta 17 ZcmdnRvWta7_bo5i@_*~XH*y#;0RTFS22B6} diff --git a/test/simple_source/def/03_class_method.py b/test/simple_source/def/03_class_method.py new file mode 100644 index 00000000..47d635d9 --- /dev/null +++ b/test/simple_source/def/03_class_method.py @@ -0,0 +1,13 @@ +# From Decompyle++ +# File: 22_class_method.pyc (Python 2.2) +# An old-style Python class. + +class MyClass: + + def method(self, i): + if i is 5: + print 'five' + elif not (i is 2): + print 'not two' + else: + print '2'