* Karl Williamson <public@khwilliamson.com> [2011-12-17 01:35]:
> I've mostly implemented this, but based on Aristotle's feedback and
> the fact that I can't see any reason to ever have just one of CTYPE
> or COLLATE, I would like to change the pragma's argument to 'unicode'
> unless someone has a better name for it.
If I may join this (round of the) party fashionably late and just to
bikeshed for a few strokes, I’d like to suggest it be called :unicode
rather than just unicode unadorned. I can’t explain quite exactly why
I like this better, but consider how it looks adjacent to open.pm:
use open ':locale';
use locale ':unicode';
* Karl Williamson <public@khwilliamson.com> [2011-12-22 17:40]:
> I have been thinking of a better argument name, and at this point I like
> use locale 'uni_chars';
> better.
>
> This means in effect "Use locale settings, except the program has
> arranged by other means to make the character set be Unicode"
I believe that’s not pedantically correct. Characters are Unicode in
Perl any way and how. (And where they aren’t yet you have been working
tirelessly to make it so – a tip of the hat to you. :-) )
What you actually did was to ask for the strings to be compared and
sorted according to the rules of Unicode rather than the locale’s. But
by the time they get to be compared or sorted, they have long been
decoded – possibly even according to the locale! So what you are asking
for could mayhap be called Unicode semantics… but sure is not that you
want the Unicode character set.
That’s according to my understanding of the various terms, anyway.
As a parenthetical note, I really dislike the æsthetics of abbreviating
“Unicode” there and would much prefer `unicode_chars`. Shortening it to
“uni” makes the code read cramped and jargony to me, all for the sake of
4 characters saved.
And with that, I’m returning the brush.
Regards,
--
Aristotle Pagaltzis // <http://plasmasturm.org/>
Thread Previous
|
Thread Next