mirror of
https://github.com/RustPython/RustPython.git
synced 2026-10-28 10:44:36 +08:00
Retain direct IR coverage for constant-pool representations, malformed append-sequence rejection, and vacated instruction-slot metadata reuse. Reject non-unit terminal append depths at the private folding helper. Existing production callers already require depth one; this is defensive contract hardening, not a newly fixed reachable interpreter bug. Preserve the existing helper structure and all pre-existing tests. The three added native tests are unchanged from the Python 3.15 upgrade work. Validation: codegen check and strict Clippy with --tests, a --lib --no-run build, and exactly three bounded native IR tests (one pass, zero ignored each). No Python, parser, VM or lifecycle payload was executed. The symmetric SetAdd guard has no dedicated depth-two assertion. Assisted-by: OpenAI Codex:model version unavailable