[issue17916] Provide dis.Bytecode based equivalent of dis.distb

2013-11-22 Thread Nick Coghlan
Nick Coghlan added the comment: Thank you for the patch! It's nice to have this included for the initial general availability of the new disassembly API :) -- ___ Python tracker ___

[issue17916] Provide dis.Bytecode based equivalent of dis.distb

2013-11-22 Thread Roundup Robot
Roundup Robot added the comment: New changeset d71251d9fbbe by Nick Coghlan in branch 'default': Close #17916: dis.Bytecode based replacement for distb http://hg.python.org/cpython/rev/d71251d9fbbe -- nosy: +python-dev resolution: -> fixed stage: needs patch -> committed/rejected status

[issue17916] Provide dis.Bytecode based equivalent of dis.distb

2013-11-22 Thread Nick Coghlan
Changes by Nick Coghlan : -- assignee: -> ncoghlan ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mai

[issue17916] Provide dis.Bytecode based equivalent of dis.distb

2013-11-21 Thread Claudiu.Popa
Claudiu.Popa added the comment: Thanks, Nick! Attached the new version, I hope that I did it right this time. -- Added file: http://bugs.python.org/file32762/dis_tb_3.patch ___ Python tracker __

[issue17916] Provide dis.Bytecode based equivalent of dis.distb

2013-11-21 Thread Nick Coghlan
Nick Coghlan added the comment: My apologies for not reviewing this earlier, it's been a somewhat hectic month. Thanks for pinging the ticket while there's still a chance to get this into 3.4 :) After my last round of updates to dis.Bytecode removed the potential for confusion between line_of

[issue17916] Provide dis.Bytecode based equivalent of dis.distb

2013-11-21 Thread Claudiu.Popa
Claudiu.Popa added the comment: Nick, what's your opinion on my latest patch? -- ___ Python tracker ___ ___ Python-bugs-list mailing l

[issue17916] Provide dis.Bytecode based equivalent of dis.distb

2013-10-24 Thread Claudiu.Popa
Claudiu.Popa added the comment: Here's the updated version according to your comments. Because there is no need for show_info() and info(), the current class is not a subclass of Bytecode (as I implied from your first message). After issue19378 is fixed, we could change the line_offset with so

[issue17916] Provide dis.Bytecode based equivalent of dis.distb

2013-10-24 Thread Nick Coghlan
Nick Coghlan added the comment: It's not quite that simple - the instruction responsible for the exception also needs to be recorded, and Bytecode doesn't currently allow for that (look at the way the "lasti" arg to disassemble is used in disttb, and then how that gets passed to the "mark_as_c

[issue17916] Provide dis.Bytecode based equivalent of dis.distb

2013-10-24 Thread Claudiu.Popa
Claudiu.Popa added the comment: Nick, could you review this, please? It would be nice if we can flesh it out and add it to 3.4. -- ___ Python tracker ___ ___

[issue17916] Provide dis.Bytecode based equivalent of dis.distb

2013-08-21 Thread Claudiu.Popa
Claudiu.Popa added the comment: Here's a basic patch, using a classmethod. It doesn't support the full distb API (if the traceback is not given, try to retrieve the last one), because Bytecode.from_tb() looks pretty weird. -- keywords: +patch nosy: +Claudiu.Popa Added file: http://bugs

[issue17916] Provide dis.Bytecode based equivalent of dis.distb

2013-05-06 Thread Nick Coghlan
Changes by Nick Coghlan : -- dependencies: +Refactor the dis module to provide better building blocks for bytecode analysis ___ Python tracker ___ __

[issue17916] Provide dis.Bytecode based equivalent of dis.distb

2013-05-06 Thread Nick Coghlan
New submission from Nick Coghlan: Issue 11816 adds a new dis.Bytecode API that replaces most of the dis functions, but doesn't cover dis.distb. A dis.Bytecode.from_tb class method, or a TracebackBytecode subclass to handle that use case may be desirable. -- messages: 188528 nosy: ncog