[SG16-Unicode] P1689: Encoding of filenames for interchange

Tom Honermann tom at honermann.net
Fri Sep 6 08:35:27 CEST 2019


On 9/5/19 11:57 PM, Thiago Macieira wrote:
> On Thursday, 5 September 2019 10:53:54 PDT Tom Honermann wrote:
>>> Future modern i/o in C++ may support byte-multiple filenames on Windows.
>>> For example, UTF-8, with a direct unreencoded path between userspace and
>>> the filing system. No need to hardcode the assumption that all of
>>> Windows will always be wchar_t based forever if unnecessary. Indeed,
>>> given the ever closer integration of the Linux and Windows kernels,
>>> efficiency would demand that much more of the NT kernel works natively
>>> in UTF-8, which it is designed to do just fine.
>> I agree with this.  This is why I support a handle approach rather than
>> a byte based approach.
> I was very clear in the subject of the email: filenames for interchange. I
> knew the discussion of handles would come about.

Yes you were, and rightfully so.  My bad, I took a tangent based on 
prior discussions of path_view.

> You can't store a handle in a file, not in any OS I am familiar with.
>
> This discussion is how one process communicates to another the name of a file.
> By necessity, this can't use a handle, which would uniquely identify the file.
> This also means it's subject to all of the race condition attacks and issues
> with views of filesystem.
>
Well, there are ways to pass handles between processes, but lets not go 
down this rabbit hole further :)

Tom.



More information about the Unicode mailing list