Doc #67041 [Opn->Ana]: POSIX character classes and UTF-8

From: Date: Tue, 15 Apr 2014 22:51:58 +0000
Subject: Doc #67041 [Opn->Ana]: POSIX character classes and UTF-8
References: 1  Groups: php.doc.bugs 
Request: Send a blank email to doc-bugs+get-11146@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=67041&edit=1 ID: 67041 Updated by: dm@php.net Reported by: cmbecker69 at gmx dot de Summary: POSIX character classes and UTF-8 -Status: Open +Status: Analyzed Type: Documentation Problem Package: PCRE related Operating System: * PHP Version: 5.5.11 Block user comment: N Private report: N New Comment: It seems that behavior changed in 5.3.4 (PCRE updated to 8.10). However, I couldn't see relevant changes that cause this. Will look further, if anything, docs can be updated to reflect it. Thanks for report. Previous Comments: ------------------------------------------------------------------------ [2014-04-08 14:37:32] trainmaster at gmx dot net Introduced with 5.3.4? http://3v4l.org/RNhTU ------------------------------------------------------------------------ [2014-04-07 21:48:02] cmbecker69 at gmx dot de Description: ------------ The PREG manual states[1]: | In UTF-8 mode, characters with values greater than 128 do not | match any of the POSIX character classes. However, that is not necessarily true, so the statement should be changed appropriately. Test script: --------------- var_dump(preg_match('/^[[:alnum:]]$/u', "\xc3\x84")); Expected result: ---------------- int(0) // expected according to the current documentation Actual result: -------------- int(1) ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=67041&edit=1

« previous php.doc.bugs (#11146) next »