Boost logo

Boost :

From: Alexei Alexandrov (alexei.alexandrov_at_[hidden])
Date: 2008-01-29 01:01:35


Beman Dawes wrote:
> Alexei Alexandrov wrote:
>> Beman Dawes wrote:
>
> One possible way to isolate the problem is to try a codecvt operation on
> the locale of interest without involving any boost code at all. If that
> works, the problem is likely within Boost.Filesystem. But if that fails,
> the problem is with the locale or use of it, not with Boost.Filesystem.
>

This is what I did. It was something like

int main()
{
     std::wofstream of("test.txt");
     of.imbue(std::locale(""));

     of << utf8_to_wide("Some Russian string in UTF-8") << std::endl;
}

and the data in the output file appeared correctly as UTF-8.

-- 
Alexei Alexandrov

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk