Skip to content

Release destructuring temporaries after assignment - #4904

Open
fabpot wants to merge 1 commit into
twigphp:3.xfrom
fabpot:destructuring-temp-release
Open

Release destructuring temporaries after assignment#4904
fabpot wants to merge 1 commit into
twigphp:3.xfrom
fabpot:destructuring-temp-release

Conversation

@fabpot

@fabpot fabpot commented Aug 27, 2026

Copy link
Copy Markdown
Contributor

The compiled destructuring code kept the right-hand side alive in a hidden local until the end of rendering, wasting memory on large arrays and iterators. The temporary is now cleared as part of the compiled expression.

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

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant