Boost logo

Boost Users :

From: Gennadiy Rozental (gennadiy.rozental_at_[hidden])
Date: 2006-07-30 21:22:39


"Felipe Magno de Almeida" <felipe.m.almeida_at_[hidden]> wrote in message
news:a2b17b60607301016y69e3ffdew3525f1449893e28d_at_mail.gmail.com...
> On 7/30/06, Gennadiy Rozental <gennadiy.rozental_at_[hidden]> wrote:
>>
>
> [snipped]
>
>
>> > Interestingly, the first two tests fail, while the last two pass.
>> >
>> > BOOST_CHECK(L"A" == m_mmf.SetLngGetString(1033, 1));
>> >
>> > BOOST_CHECK(m_mmf.SetLngGetString(1033, 1) == L"A" );
>>
>> This actually perform pointers comparizons and almost never produce true.
>
> I dont think you can actually be sure about this, since we can't know
> if SetLngGetString doesnt return a std::wstring or some other type
> that has implicit conversion from wchar_t.

Wouldn't you remove the rest of the original message, you would see that it
does return wchar_t const*.

>>> where m_mmf.SetLngGetString(1033, 1) returns a const wchar_t* type.

Gennaadiy


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net