Re: [RFC] Unicode Escape Syntax

From: Date: Tue, 25 Nov 2014 11:37:19 +0000
Subject: Re: [RFC] Unicode Escape Syntax
References: 1 2  Groups: php.internals 
Request: Send a blank email to internals+get-79161@lists.php.net to get a copy of this message
Ivan Enderlin @ Hoa wrote: > Le 24/11/2014 23:09, Andrea Faulds a écrit : >> Good evening, >> >> Here’s a new RFC: https://wiki.php.net/rfc/unicode_escape >> >> It has a rationale section explaining why certain decisions were made, >> that I’d recommend you read in full. > Excellent RFC, thank you for this proposal. > I would suggest this talk > https://speakerdeck.com/mathiasbynens/hacking-with-unicode (you > might > already know) but interesting concepts and limitations of current > Unicode implementations are mentioned. > The usage of \u{…} fixes most limitations and I could not be > more > agree with that notation! I don't see that the proposed \u{...} notation fixes any limitation. Its only advantage would be slightly better readability opposed to inserting the desired UTF-8 byte sequences as octal or hexadecimal escapes. For instance, all of the following would print Ä (in an UTF-8 context): echo "\u{00C4}"; echo "\xC3\x84"; echo "\303\204"; -- Christoph M. Becker

« previous php.internals (#79161) next »