Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: C strings, unescaping of

by daxim (Chaplain)
on Sep 30, 2013 at 14:05 UTC ( #1056363=note: print w/replies, xml ) Need Help??


in reply to C strings, unescaping of

Use Encode::Escape::ASCII. Under the hood it does the same, but your maintenance programmer gets a readable API and documentation.

Replies are listed 'Best First'.
Re^2: C strings, unescaping of
by Anonymous Monk on Sep 30, 2013 at 15:46 UTC
    That package does not implement C-style escapes. The \v is missing. Furthermore, it looks rather suspect. Observe:
    $ echo -n 'v\v\134aa' | perl -e 'use Encode::Escape::ASCII; print deco +de "ascii-escape", $_ for <>;' | hexdump -C 00000000 76 76 07 61 |vv.a| 00000004

    This does not look right to me at all!

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1056363]
help
Chatterbox?
[Lady_Aleena]: push @line, ref($list_addition ) eq 'ARRAY' ? @$list_addition : $list_addition if $list_addition; #trying again
[shmem]: Discipulus: yummy. I like those. Didn't have them for some time now, forgot the name. Should go get some...
[shmem]: Lasy_Aleena: correct, although for clarity I'd use an if() block, not a statement modifier
[shmem]: this allows you to add an else if maintainance makes it neccesary
[Lady_Aleena]: shmem, okeydokey.
[shmem]: ...or logging or debugging or such

How do I use this? | Other CB clients
Other Users?
Others surveying the Monastery: (8)
As of 2017-04-27 11:51 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    I'm a fool:











    Results (504 votes). Check out past polls.