[Mono-devel-list] Patch idea for previous message
Atsushi Eno
atsushi at ximian.com
Tue Jun 7 05:53:34 EDT 2005
Hi,
>> String comparison with
>> invariant culture does not mean that it has no other side effect
>> than case insensitivity. With CultureInfo dependent (including
>> InvariantCulture) there are some characters that are ignored in the
>> comparison (and sometimes culture-sensitive comparison is buggy, at
>> least with MS.NET) or regarded equivalent to other character
>> sequences.
>
> It's true but I don't treat this as a bug I think it is the expected
> behaviour.
>> From String.Compare documentation in .NET Framework SDK:
Well, I don't think that regarding "AE" and "\u006C" as equivalent
is a bug. What I have in mind is other cases such as
String.Compare ("\u00E6\u0304", "\u01E3")
There are many cases that diacritical characters results in
incorrect equality.
> And even InvarianCulture can have such rules the only thing is guaranted
> that it allways has the same rules.
>
> .NET Framework 2.0 has a new option: OrdinalIgnoreCase
> http://msdn2.microsoft.com/library/8d9k4871(en-us,vs.80).aspx
> It does exactly what you want.
Yeah, that's the thing we can use after .NET 2.0 support ;-)
Michael Kaplan (MSFT) recently wrote about that:
http://blogs.msdn.com/michkap/archive/2005/06/02/424128.aspx
Atsushi Eno
More information about the Mono-devel-list
mailing list