Re: [RFC] Deprecate and Remove utf8_encode and utf8_decode
| From: | Rowan Tommins | Date: | Mon, 21 Feb 2022 17:35:40 +0000 |
| Subject: | Re: [RFC] Deprecate and Remove utf8_encode and utf8_decode | ||
| References: | 1 2 3 4 5 6 7 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-117106@lists.php.net to get a copy of this message | ||
On 21/02/2022 16:29, Alain D D Williams wrote:
Looking at the description of grapheme_strlen() I note that it can return null. However it does not say why.Huh, that feels like a bug to me, since it can also return false, which is the more standard way of indicating failure. The obvious failure case is an input string that's not valid UTF-8, e.g. grapheme_strlen("\xFF"). It appears that currently returns null; so I'm not actually sure how you'd trigger the false case. Regards, -- Rowan Tommins [IMSoP]