C++ Logo

liaison

Advanced search

Re: [wg14/wg21 liaison] Fwd: native_handle_type

From: <pete_at_[hidden]>
Date: Mon, 19 Aug 2019 12:58:47 -0400
On Aug 19, 2019, at 12:08 PM, Niall Douglas via Liaison <liaison_at_[hidden]> wrote:
>
> There is precedent here. You can ask POSIX what kind of inode a file
> descriptor refers to. Same goes here for native handle type, which
> similarly refers to some implementation-defined-structure-elsewhere.
> Indeed, as you may have noticed in my forwarded message to WG14, one
> could even use mode_t as the union discriminant on POSIX platforms.
>

Let me ask you again a question that you elided when you quoted me:

If the standard adds support for determining the type (for whatever meaning of “type” is involved here), what then? What can you do **portably** that you can’t do **portably** without that information?

  -- Pete
Roundhouse Consulting, Ltd.

Received on 2019-08-19 12:00:52