Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re^3: Perl Windows vs Cygwin installs

by Eliya (Vicar)
on Mar 23, 2012 at 23:56 UTC ( #961335=note: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    #!/usr/local/perl/5.15.8/bin/perl -w
    
    ...
    
    open my $out, ">:crlf:encoding(UTF-16LE)", $fname or die;
    print $out "\x{feff}\x{1234}\n\x{5678}\n";
    
  2. or download this
    $ ./test-out.pl
    $ hexdump foo.utf16 
    0000000 feff 1234 0a0d 7800 0d56 000a          
    000000c
    
  3. or download this
    $ hexdump foo.utf16 
    0000000 feff 1234 000d 000a 5678 000d 000a     
    000000e
    
  4. or download this
    #!/usr/local/perl/5.15.8/bin/perl -w
    use Devel::Peek;
    ...
    open my $in, "<:crlf:encoding(UTF-16LE)", $fname or die;
    $/ = undef;
    Dump <$in>;
    
  5. or download this
    $ ./test-in.pl
    SV = PV(0x77dc60) at 0x953728
    ...
      PV = 0x829130 "\357\273\277\341\210\264\r\n\345\231\270\r\n"\0 [UTF8
    + "\x{feff}\x{1234}\r\n\x{5678}\r\n"]
      CUR = 13                                ^               ^
      LEN = 14
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (10)
As of 2014-07-31 12:31 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (248 votes), past polls