Skip to content

Clarify duplicate macro deprecation message - #4883

Merged
fabpot merged 1 commit into
twigphp:3.xfrom
fabpot:clarify-duplicate-macro-deprecation
Aug 3, 2026
Merged

Clarify duplicate macro deprecation message#4883
fabpot merged 1 commit into
twigphp:3.xfrom
fabpot:clarify-duplicate-macro-deprecation

Conversation

@fabpot

@fabpot fabpot commented Aug 3, 2026

Copy link
Copy Markdown
Contributor

No description provided.

@upsun-dispatch

upsun-dispatch Bot commented Aug 3, 2026

Copy link
Copy Markdown

📋 PR Summary

This PR appends a clarifying sentence to the duplicate-macro deprecation message in Twig's Parser, stating that the last definition is the one used in Twig 3, and updates the matching test fixture expectation.

Changes
Layer / File(s) Summary
deprecation message
src/Parser.php Extends the trigger_deprecation message in setMacro to note that the last macro definition is used in Twig 3.
tests/Fixtures/macros/duplicate_definition.legacy.test Updates the expected --DEPRECATION-- output to match the new message text.

@fabpot
fabpot merged commit 6fafa10 into twigphp:3.x Aug 3, 2026
54 checks passed
@fabpot
fabpot deleted the clarify-duplicate-macro-deprecation branch August 3, 2026 19:22
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