Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: UU-decode unpack of empty string yields undefined value

by december (Pilgrim)
on May 13, 2009 at 06:42 UTC ( #763683=note: print w/replies, xml ) Need Help??


in reply to UU-decode unpack of empty string yields undefined value

I'm running Perl v5.10.0 on Linux and I get the exact same output. I would assume, in a string context, an empty string to remain an empty string and not to become an "undefined value". An empty string is valid unicode (or indeed should be valid in any and every encoding) after all. I too am curious about the reason for this "feature", as I do a lot of unicode handling in my code I've never noticed this before...
  • Comment on Re: UU-decode unpack of empty string yields undefined value

Replies are listed 'Best First'.
Re^2: UU-decode unpack of empty string yields undefined value
by almut (Canon) on May 13, 2009 at 07:05 UTC
    ...as I do a lot of unicode handling in my code

    Just to avoid confusion:  uuencoding has nothing directly to do with Unicode.

    Note the difference between upper and lower case U. From pack:

    u A uuencoded string. U A Unicode character number. Encodes to UTF-8 inter +nally (or UTF-EBCDIC in EBCDIC platforms).

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://763683]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (6)
As of 2022-01-21 09:13 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    In 2022, my preferred method to securely store passwords is:












    Results (57 votes). Check out past polls.

    Notices?