Title: dis module: undocumented new bytecodes
Type: Stage:
Components: Documentation Versions: Python 3.0, Python 2.6
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: georg.brandl Nosy List: benjamin.peterson, georg.brandl, loewis, terry.reedy
Priority: normal Keywords:

Created on 2008-07-17 22:24 by terry.reedy, last changed 2008-07-20 21:39 by georg.brandl. This issue is now closed.

Messages (4)
msg69918 - (view) Author: Terry J. Reedy (terry.reedy) * (Python committer) Date: 2008-07-17 22:24
dis / Python Bytecode Instructions is missing
which appear in dis.opname (3.0 version).

Suggestion: After entry for UNPACK_SEQUENCE(count), add
Used for starred assignment.  Similar to UNPACK_SEQUENCE except 1) the
lo and hi bytes of the argument are the number of unstarred targets
before and after the starred target and 2) the values between the first
lo and last hi are collected into a list for the starred target.

I deduced this because *a,b; a,*b; *a,b,c; a,*b,c; and a,b,*c as targets
produce byte pairs of 0,1; 1,0; 0,2; 1,1; and 2,0 (arguments 256, 1,
512, 257, and 2).

The other three are new since 2.5 but do not make much sense to me.  I
will ask on pydev for clarification.  I do not have 2.6 to check its
version of .opname to determine which of these belong there too.
msg69919 - (view) Author: Benjamin Peterson (benjamin.peterson) * (Python committer) Date: 2008-07-17 22:26
LOAD_BUILD_CLASS is 3.0 only and I documented it.
msg69923 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2008-07-17 22:53
Terry, would you like to contribute a patch (even if only for the one
you understand)?
msg70092 - (view) Author: Georg Brandl (georg.brandl) * (Python committer) Date: 2008-07-20 21:39
MAKE_BYTES is no longer in opcode.h; removed it in r65160.
Documented the other three, which are new in 3k, in r65161. Thanks!
Date User Action Args
2008-07-20 21:39:33georg.brandlsetstatus: open -> closed
resolution: fixed
messages: + msg70092
2008-07-17 22:53:31loewissetnosy: + loewis
messages: + msg69923
2008-07-17 22:26:11benjamin.petersonsetnosy: + benjamin.peterson
messages: + msg69919
2008-07-17 22:24:17terry.reedycreate