Do you know where your variables are? | |
PerlMonks |
Re: Decoding @ARGV [Was: uparse - Parse Unicode strings]by kcott (Archbishop) |
on Nov 24, 2023 at 23:45 UTC ( [id://11155808]=note: print w/replies, xml ) | Need Help?? |
[A follow-up to "Re: Decoding @ARGV [Was: uparse - Parse Unicode strings]".] I'm not going to have sufficient spare time to do all that I wanted this weekend. I have managed to incorporate your changes and do a couple of other minor things. When prefixing the uparse command with PERL_UNICODE=A or PERL_UNICODE=SDAL, I just get "Wide character at ..." and no other output. I made these changes:
Here's the new code:
Here's a test run with just uparse: $ uparse 👮🏼 👮🏼♀️ 👮🏼♂️ ============================================================ String: '👮🏼' ============================================================ 👮 U+1F46E POLICE OFFICER 🏼 U+1F3FC EMOJI MODIFIER FITZPATRICK TYPE-3 ------------------------------------------------------------ ============================================================ String: '👮🏼♀️' ============================================================ 👮 U+1F46E POLICE OFFICER 🏼 U+1F3FC EMOJI MODIFIER FITZPATRICK TYPE-3 U+200D ZERO WIDTH JOINER ♀ U+2640 FEMALE SIGN U+FE0F VARIATION SELECTOR-16 ------------------------------------------------------------ ============================================================ String: '👮🏼♂️' ============================================================ 👮 U+1F46E POLICE OFFICER 🏼 U+1F3FC EMOJI MODIFIER FITZPATRICK TYPE-3 U+200D ZERO WIDTH JOINER ♂ U+2642 MALE SIGN U+FE0F VARIATION SELECTOR-16 ------------------------------------------------------------ And again, this time with PERL_UNICODE=A: $ PERL_UNICODE=A uparse 👮🏼 👮🏼♀️ 👮🏼♂️ ============================================================ String: '👮🏼' ============================================================ 👮 U+1F46E POLICE OFFICER 🏼 U+1F3FC EMOJI MODIFIER FITZPATRICK TYPE-3 ------------------------------------------------------------ ============================================================ String: '👮🏼♀️' ============================================================ 👮 U+1F46E POLICE OFFICER 🏼 U+1F3FC EMOJI MODIFIER FITZPATRICK TYPE-3 U+200D ZERO WIDTH JOINER ♀ U+2640 FEMALE SIGN U+FE0F VARIATION SELECTOR-16 ------------------------------------------------------------ ============================================================ String: '👮🏼♂️' ============================================================ 👮 U+1F46E POLICE OFFICER 🏼 U+1F3FC EMOJI MODIFIER FITZPATRICK TYPE-3 U+200D ZERO WIDTH JOINER ♂ U+2642 MALE SIGN U+FE0F VARIATION SELECTOR-16 ------------------------------------------------------------ Using "PERL_UNICODE=SDAL" gives the same output as "PERL_UNICODE=A". — Ken
In Section
Cool Uses for Perl
|
|