Skip to content

[Sync-En] Document that readonly properties cannot be initialized by reference - #1167

Merged
julionc merged 1 commit into
php:masterfrom
lacatoire:sync-en/1159-readonly-no-ref
Aug 31, 2026
Merged

julionc merged 1 commit into
php:masterfrom
lacatoire:sync-en/1159-readonly-no-ref

Conversation

@lacatoire

Copy link
Copy Markdown
Member

Sync with EN commit 4e77868e15fea65175b87a38d6d31b61d63f7f8e.

Adds a note explaining that an uninitialized readonly property cannot be initialized by reference (passing it to a by-reference parameter or assigning it by reference results in an Error exception), with a code example.

Fixes: #1159

@julionc
julionc merged commit c9637ea into php:master Aug 31, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Sync EN] Document that readonly properties cannot be initialized by reference (#5226)

2 participants