"Peter Dembinski" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > "Terry Reedy" <[EMAIL PROTECTED]> writes: >> I believe the top-level production is something like >> BYTECODE := (OPCODE ARGS)* > > ROTFL :)
Glad to make your day ;-) I am aware that since ARGS depends on OPCODE, the above would lead to context-dependent productions for ARGS. Upon thoroughly perusing http://docs.python.org/lib/bytecodes.html 18.10.1 Python Byte Code Instructions I discovered that there is at most one (non-stack) argument in the byte stream (contrary to the possibly plural implication of "All of the following opcodes expect arguments"). So the above could be written context-freely as BYTECODE := (NO_ARG_CODE | ARG_CODE TWO_BYTE_ARG)* where the symbolic expansions of NO_ARG_CODE and ARG_CODE, with semantic explanations, constitute the contents of the doc above. Terry J. Reedy -- http://mail.python.org/mailman/listinfo/python-list