Beefy Boxes and Bandwidth Generously Provided by pair Networks vroom
Clear questions and runnable code
get the best and fastest answer

Re^12: any use of 'use locale'? (source encoding)

by wanradt (Scribe)
on Nov 30, 2009 at 19:56 UTC ( #810262=note: print w/ replies, xml ) Need Help??

in reply to Re^11: any use of 'use locale'? (source encoding)
in thread any use of 'use locale'?

I have more thinking to do with your answer, but main (for me) questions i can review.

Pretending it would currently be possible to implement "use utf8_everywhere", it would break every single piece of code that assumes characters are bytes.

Do you mean, that would break any code, which i incorporate to my project if i declare "use utf8_everywhere"? Then, why it does not break now when i use same things (like "use utf8", "use open", binmode...) separately?

Or do you mean, it will break "characters are bytes"-code, if they use "use uf8_everywhere"? Then i agree, but why they need such declaration?

Assume you read four bytes 0x42 0xC3 0x84 0x48, e.g. from STDIN, a file you opened, an inherited file handle, a command line argument or an environment variable. How many characters do these bytes represent? Explain why

If i am declared fully utf8 environment, i treat them being 3 utf8 characters. If i need some other behaviour, i ask it explicitly to handle the source which from those bytes are coming. Where is the problem?

Nġnda, WK

Comment on Re^12: any use of 'use locale'? (source encoding)

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (12)
As of 2014-04-17 15:38 GMT
Find Nodes?
    Voting Booth?

    April first is:

    Results (453 votes), past polls