Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re^2: A sub named ∃

by ikegami (Patriarch)
on Nov 30, 2006 at 16:36 UTC ( [id://586993]=note: print w/replies, xml ) Need Help??


in reply to Re: A sub named ∃
in thread A sub named ∃

Note: In the following source code,
replace "∃" with the UTF-8 representation of "∃", and
replace "трщь" with the UTF-8 representation of "трщь".

use strict; use warnings; no warnings 'redefine'; for ( [ "Symbol, use utf8: " => "use utf8; sub ∃ {}" ], [ "Symbol, no utf8: " => "no utf8; sub ∃ {}" ], [ "Russian, use utf8: " => "use utf8; sub трщ&#11 +00; {}" ], [ "Russian, no utf8: " => "no utf8; sub трщ&#11 +00; {}" ], ) { print $_->[0], eval "$_->[1]; 1" ? "Success\n" : $@; }
outputs
Symbol, use utf8: Illegal declaration of anonymous subroutine at (eva +l 1) line 1. Symbol, no utf8: Illegal declaration of anonymous subroutine at (eva +l 2) line 1. Russian, use utf8: Success Russian, no utf8: Illegal declaration of anonymous subroutine at (eva +l 4) line 1.

If the problem is what you say it is, wouldn't use utf8 have no effect on the error?

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others chanting in the Monastery: (7)
As of 2024-04-18 07:56 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found