|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2015-07-10 01:47 UTC] keithm at aoeex dot com
[2015-07-10 03:46 UTC] requinix@php.net
-Status: Open
+Status: Not a bug
[2015-07-10 03:46 UTC] requinix@php.net
[2015-07-10 04:23 UTC] chrisdmiddleton at gmail dot com
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Dec 16 06:00:02 2025 UTC |
Description: ------------ When trying to match newlines with the PCRE_DOLLAR_ENDONLY modifier in conjunction with the "|" operator, it matches more than it should. My original test case was using a regex of '/^\n|\r\n|\r$/D' against a string containing other characters. I've simplified the test below. Test script: --------------- echo preg_match('/^\n|\n$/D', "\nasdf", $matches); Expected result: ---------------- 0 Actual result: -------------- 1