Giter VIP home page Giter VIP logo

Comments (6)

rocky avatar rocky commented on August 11, 2024

Hello,

Seems easy enough to do. What is the motivation for this?

from python-uncompyle6.

Nothing4You avatar Nothing4You commented on August 11, 2024

from python-uncompyle6.

rocky avatar rocky commented on August 11, 2024

Ok. Thanks for the information. Right now performance if anything has gotten worse on 2.7 since we are more focused on accuracy and handling Python bytecode other than 2.7.

So if all you care about is decompiling 2.7 using a 2.7ish compiler, then I'd stick with wibiti's uncompyle6. (There have been a couple of bugs found in that like escaping triple-quoted strings, and handling complex number constants, some control flow and function prototypes, and handling if == precedence; but all of these tend to be arcane situations. Someone could probably take the code in uncompyle6 and back port it to wibiti uncompyle2.)

While doing some testing and comparing the outputs I have also found that this project adds quite a few redundant return statements, is that intended behavior?

While it isn't intended, it isn't unintended either. The code works simply by following grammar patterns it detects in the code. Possibly it is matching more return statements than the grammar used previously.

In both, there's a special case hack to check to see if the last statement is a return statement https://github.com/rocky/python-uncompyle6/blob/master/uncompyle6/semantics/pysource.py#L1959-L1963

This test probably used to come out True more often. If this is important to fix, find a small test case that exhibits the problem and file an issue for that.

Oh, and if you file a pull request for an option to disable outputting headers, this will probably get done sooner.

from python-uncompyle6.

rocky avatar rocky commented on August 11, 2024

Closed because of lack of interest. In fact, it might not be a bad idea to go the other way. Maybe I should add my name in the meta comments.

from python-uncompyle6.

Nothing4You avatar Nothing4You commented on August 11, 2024

Why don't you just leave it open as a feature request? You don't have to implement it but you can keep it tracked.

from python-uncompyle6.

rocky avatar rocky commented on August 11, 2024

Nah - Nothing4You ;-)

from python-uncompyle6.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.