This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: [RFC] collate_members_wchar_t.cc
- From: Philip Martin <philip at codematters dot co dot uk>
- To: Peter Schmid <schmid at snake dot iap dot physik dot tu-darmstadt dot de>
- Cc: Paolo Carlini <pcarlini at unitus dot it>, Ulrich Drepper <drepper at redhat dot com>, <libstdc++ at gcc dot gnu dot org>, <bkoz at redhat dot com>
- Date: 09 Mar 2002 22:21:12 +0000
- Subject: Re: [RFC] collate_members_wchar_t.cc
- References: <Pine.LNX.4.30.0203092359270.20940-100000@snake.iap.physik.tu-darmstadt.de>
Peter Schmid <schmid@snake.iap.physik.tu-darmstadt.de> writes:
> When I compile the following test case by gcc 3.1 20020306 and run the
> executable on my system, i686-pc-linux-gnu, glibc 2.2.4 + patches
> (glibc-2.2.4-65), SuSE 7.3
>
> #include <wchar.h>
> #include <locale.h>
> #include <stdio.h>
> #include <string.h>
>
> int main()
> {
> setlocale(LC_ALL, "de_DE");
> int i = wcscoll (L"Äuglein", L"Augment");
> printf("result of the wide string comparison: %i\n", i);
> i = strcoll ("Äuglein", "Augment");
> printf("result of the string comparison: %i\n", i);
> return 0;
> }
>
> the output is:
>
> result of the wide string comparison: 20
> result of the string comparison: -1
I get the same result on a Debian 'testing' machine with gcc 3.0.3 and
glibc 2.2.5
$ dpkg -s gcc-3.0 | grep Version
Version: 1:3.0.3-1
$ dpkg -s libc6 | grep Version
Version: 2.2.5-3
$ dpkg -s locales | grep Version
Version: 2.2.5-3
--
Philip