[cmake-developers] Questions about coding conventions
clinton at elemtech.com
clinton at elemtech.com
Tue Jun 14 11:28:25 EDT 2016
----- On Jun 14, 2016, at 8:09 AM, Daniel Pfeifer daniel at pfeifer-mail.de wrote:
> On Tue, Jun 14, 2016 at 3:14 PM, Brad King <brad.king at kitware.com> wrote:
>> On 06/13/2016 10:16 AM, Brad King wrote:
>>>> Can't `std::ifstream` and `std::ofstream` be used directly? It seams
>>>> that kwsys does some workarounds
>>>
>>> Yes, std::{o,f}stream can be used directly.
>>
>> On second thought, std::{i,o}fstream should not be used to open files.
>> The cmsys::{i,o}fstream interfaces are not about compatibility, they
>> are about opening files on Windows using the wide character APIs by
>> converting from UTF-8 to UCS-2.
>
> I see.
>
> There are a few uses of std::{i,o}fstream. I guess we should migrate
> them all to kwsys.
Yes. Thanks.
cmsys::{i,o}fstream is to support additional filenames on Windows by not using obsolete ANSI apis.
Clint
More information about the cmake-developers
mailing list