dotgnu-pnet
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Pnet-developers] [bugs #7014] String.Compare() returns the wrong va


From: Rhys Weatherley
Subject: Re: [Pnet-developers] [bugs #7014] String.Compare() returns the wrong values when comparing n and N
Date: Tue, 30 Dec 2003 09:13:31 +1000
User-agent: KMail/1.4.3

On Tuesday 30 December 2003 03:00 am, Rainer Groesslinger wrote:

> It seems like if pnet compares the same characters but one is capitalized
> and one isn't, it returns the wrong value. e.g. if I am not mistaken in
> .NET it's supposed to be
> c > a
> C > a
> N > n
>
> pnet seems to interpret the last one the other way around (n > N)

If you look at the ordinal values, you will see that n (\u006E) is indeed 
greater than N (\u004E).  However, in Unicode collation order, capital 
letters are typically sorted as greater than lower case letters.

We currently support ordinal comparisons, but not Unicode collation yet, 
because Unicode collation is complicated and locale-specific.  I'm working on 
it, but it will probably be a while before it is ready.

Cheers,

Rhys.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]