This is the mail archive of the libc-alpha@sources.redhat.com mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFH] Trouble with mbsrtowcs and "\244" (Euro symbol)


On Mon, May 13, 2002 at 09:31:11AM +0200, Paolo Carlini wrote:
>   wstring result4 = oss.str();
>   assert( result4 == L"7.200.000.000,00 \244");
> }
> 
> I wrote the testcase dumbly copying it from the corresponding char case, 
> that is simply prepending L to the expected result4. But now I see that 
> this is incorrect since, according to Unicode Euro is 8364. Therefore, I 
> suppose, in preparing this kind of testcase, the last char should be 
> compared separately from the former.
> 
> Thoughts?

Err, why you cannot just:

  assert( result4 == L"7.200.000.000,00 \x20ac");

(the test works just fine then, provided the setlocale call is uncommented
(otherwise U20AC might not be in LC_CTYPE and as such not added at all)).

	Jakub


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]