◐ Shell
reader mode source ↗
Skip to content

gh-95913: Edit, expand & format Bytecode sect in 3.11 WhatsNew#98559

Merged
iritkatriel merged 13 commits into
python:mainfrom
CAM-Gerlach:whatsnew-bytecode
Oct 24, 2022
Merged

gh-95913: Edit, expand & format Bytecode sect in 3.11 WhatsNew#98559
iritkatriel merged 13 commits into
python:mainfrom
CAM-Gerlach:whatsnew-bytecode

Conversation

@CAM-Gerlach

@CAM-Gerlach CAM-Gerlach commented Oct 22, 2022

Copy link
Copy Markdown
Member

Part of #95913

This PR expands, edits and formats the CPython Bytecode Changes section in the What's New in Python 3.11 document.

On the editing side, like with the other PRs, it:

  • Uses clear, consistent phrasing on all bytecode entries, making them easier to scan and read
  • Orders them more consistently (Added, Replaced, Removed, Changed, roughly alphabetical by opcode name within each, aside from special cases), for the same reasons
  • Fixes and improves the Sphinx syntax and semantics

Likewise, it adds some missing additional opcodes that were added, replaced or removed in 3.11:

  • Added COPY_FREE_VARS, MAKE_CELL, PUSH_EXC_INFO, PREP_RE_RAISE_STAR, RETURN_GENERATOR, SEND and ASYNC_GEN_WRAP
  • Replaced SETUP_WITH and SETUP_ASYNC_WITH with BEFORE_WITH
  • Removed POP_BLOCK, SETUP_FINALLY and YIELD_FROM

Finally, it consolidates the sets of replaced opcodes into a much quicker and easier to navigate table.

Rendered Preview

--> Rendered Preview (click to expand) <---

image

@CAM-Gerlach CAM-Gerlach mentioned this pull request Oct 22, 2022
33 tasks
@pablogsal

Copy link
Copy Markdown
Member

This should be also checked with @markshannon, @brandtbucher, @iritkatriel and @ericsnowcurrently.

If this doesn't land today, it won't be included in 3.11.0

@CAM-Gerlach CAM-Gerlach requested review from ericsnowcurrently, iritkatriel and markshannon and removed request for JelleZijlstra October 23, 2022 03:25
@iritkatriel

Copy link
Copy Markdown
Member

Yeah this is better! Just CHECK_EG_MATCH is also new for PEP 654.

@pablogsal

Copy link
Copy Markdown
Member

Heads up: please land this before 3Pm GMT+0 if you want it to be in 3.11.0

@miss-islington

Copy link
Copy Markdown
Contributor

Thanks @CAM-Gerlach for the PR, and @iritkatriel for merging it 🌮🎉.. I'm working now to backport this PR to: 3.11.
🐍🍒⛏🤖

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Oct 24, 2022
…ythonGH-98559)

(cherry picked from commit 22739a0)

Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
@bedevere-bot

Copy link
Copy Markdown

GH-98597 is a backport of this pull request to the 3.11 branch.

@bedevere-bot bedevere-bot removed the needs backport to 3.11 only security fixes label Oct 24, 2022
miss-islington added a commit that referenced this pull request Oct 24, 2022
)

(cherry picked from commit 22739a0)

Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
@iritkatriel

Copy link
Copy Markdown
Member

Heads up: please land this before 3Pm GMT+0 if you want it to be in 3.11.0

It's merged and backported.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3.11 only security fixes docs Documentation in the Doc dir skip news

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants