On Oct 18, 2008, at 8:32 AM, Yukihiro Matsumoto wrote:

> Basically Ruby's case sensitivity (except for regular expressions)
> works on ASCII region only, mostly because we've followed Tim Bray's
> advice at the past RubyConf (2006?).  I was told that case sensitivity
> is sometimes locale dependent.  I don't think the semantics of a
> program should depend on locale.  Tell me if I'm wrong.

I think this is correct.

However, in Unicode, it's not ambiguous whether a character has the  
upper-case or lower-case property.  What's ambiguous and locale- 
dependent and not even one-to-one is the mapping between the cases.   
If Ruby program text were defined as unicode, I suppose you could  
allow anything with the "Lu" property.

Since Ruby is not limited to Unicode, and we don't know if Unicode and  
other character sets agree on the semantics of upper-case (I suspect  
not) it seems to me that only safe/portable definition of "upper-case"  
is [A-Z].

  -Tim