Skip to content

Update preg-match.xml to clarify language around when using offset making \A and ^ inoperable - #5652

Merged
jordikroon merged 2 commits into
php:masterfrom
rbairwell:patch-1
Aug 18, 2026
Merged

jordikroon merged 2 commits into
php:masterfrom
rbairwell:patch-1

Conversation

@rbairwell

Copy link
Copy Markdown
Contributor

Try to clarify the language around using \G instead of substr. It read as if ^ and \A both worked with offset and to use use \A instead of ^.

Try to clarify the language around using \G instead of substr. It read as if ^ and \A both worked with offset and to use use \A instead of ^.
@rbairwell rbairwell changed the title Update preg-match.xml Update preg-match.xml to clarify language around when using offset making \A and ^ inoperable Jul 4, 2026

@jordikroon jordikroon left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Styling nits

Comment thread reference/pcre/functions/preg-match.xml Outdated
Comment thread reference/pcre/functions/preg-match.xml Outdated
Comment thread reference/pcre/functions/preg-match.xml Outdated
Co-authored-by: Jordi Kroon <jordi@jordikroon.nl>
@jordikroon
jordikroon merged commit aa5a948 into php:master Aug 18, 2026
1 of 2 checks passed
KentarouTakeda added a commit to php/doc-ja that referenced this pull request Oct 4, 2026
php/doc-en@aa5a948a11 (php/doc-en#5652)、php/doc-en@cdbe6f9826 (php/doc-en#5272)、
php/doc-en@f88f34ad2f (php/doc-en#5887) に追従します。

PREG_UNMATCHED_AS_NULL の説明に、末尾のマッチしなかったサブパターンの扱い
(フラグなしでは結果に含まれず、フラグありでは &null; として含まれる) を追加し、
その例と出力、7.4.0 の変更履歴を加えました。

offset の注記の文言は php/doc-en@aa5a948a11 で変更され、php/doc-en@f88f34ad2f で
元に戻されているため、該当文はタグの変更のみです。

## 対象ファイル (1件)

- reference/pcre/functions/preg-match.xml
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.

2 participants