Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

xdis.std.Instruction should not take "has_arg" parameter #86 #32

Open
rocky opened this issue Mar 19, 2017 · 0 comments
Open

xdis.std.Instruction should not take "has_arg" parameter #86 #32

rocky opened this issue Mar 19, 2017 · 0 comments

Comments

@rocky
Copy link
Owner

rocky commented Mar 19, 2017

Although we want has_stdarg in the underlying bytecode instruction, in in std.Instruction() it shouldn't be passed as a parameter but computed based on the opc, e.g. has_arg = opname >= opc.HAVE_ARGUMENT.

In an ideal world, fields argrepr and opname wouldn't need to be passed in std.Instruction(). We could either create another function or have setting these to be None to mean that they get filled in. And opname probably should be checked against opcode.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant