Re: wcscoll bug?

Tech-Archive recommends: Fix windows errors by optimizing your registry



Thanks very much for your information. Very helpful.

Zhongchao

"Igor Tandetnik" <itandetnik@xxxxxxxx> wrote in message
news:uvV764cyFHA.720@xxxxxxxxxxxxxxxxxxxxxxx
> Zhongchao Yu <yuzc00@xxxxxxxxx> wrote:
> > I assume that wcscoll() is an ANSI function. So why does it behave
> > differently on different platforms? Is there any related standard
> > about English collation out there?
>
> Locale-specific information is (probably intentionally) underspecified
> in C and C++ standards. The standard simply says that strcoll and
> wcscoll compare two strings as appropriate for the currently selected
> locale, but does not say what "appropriate" means.
>
> The most relevant standards are:
>
> ISO 14651 "Information technology -- International string ordering and
> comparison -- Method for comparing character strings and description of
> the common template tailorable ordering"
>
> Unicode Collation Algorithm (UCA)
> http://www.unicode.org/reports/tr10/
>
> There exist fully conformant implementations of UCA (see e.g.
> http://icu.sourceforge.net/), but Windows collation support is not one
> of them. For more details, see
>
> http://blogs.msdn.com/michkap/archive/2004/11/28/271121.aspx
>
> --
> With best wishes,
> Igor Tandetnik
>
> With sufficient thrust, pigs fly just fine. However, this is not
> necessarily a good idea. It is hard to be sure where they are going to
> land, and it could be dangerous sitting under them as they fly
> overhead. -- RFC 1925
>
>


.



Relevant Pages

  • Re: wcscoll bug?
    ... Is there any related standard ... Locale-specific information is underspecified ... wcscoll compare two strings as appropriate for the currently selected ... Unicode Collation Algorithm ...
    (microsoft.public.vc.language)
  • Re: Requesting advice how to clean up C code for validating string represents integer
    ... Linkname: c standard - clc-wiki ... being able to compare unrelated pointers, ...
    (comp.lang.c)
  • Re: Versions
    ... CVersionTypeAlpha -- class for alpha comparation ... So make a special check in the Compare methods for this rule. ... Another way is via a mapping, where the CVersionTypeAlpha class converts all ... you'll never get a standard implementation for all cases.. ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: File-Compare "fc" falsely reports mismatch between identical files
    ... said to compare files as ascii text. ... Redmond is some variety of universal standard. ... mean that there is no benefit in making the distinction between ASCII ... it is now safe to turn your computer off. ...
    (microsoft.public.win2000.cmdprompt.admin)
  • Re: Requesting advice how to clean up C code for validating string represents integer
    ... The standard form is like this, ... 1108 The sizeof operator ... ... being able to compare unrelated pointers, ... So long as the pointers are of the same type, ...
    (comp.lang.c)