C++ Logo

liaison

Advanced search

Re: [wg14/wg21 liaison] #once proposal

From: Miguel Ojeda <miguel.ojeda.sandonis_at_[hidden]>
Date: Thu, 3 Feb 2022 22:11:23 +0100
On Thu, Feb 3, 2022 at 9:08 PM Christof Meerwald <cmeerw_at_[hidden]> wrote:
>
> Existing practice is to use "#pragma once" which already has
> implementation defined behavior - the paper proposes to change
> "#pragma once" to "#once" with implementation defined behavior.
> Doesn't really look like much of an improvement to me.

It is standardizing that existing practice. The advantage is that all
implementations have to """support""" it in some way and document what
they will do with it. So far, an implementation that currently ignores
it does not need to say anything about it.

Cheers,
Miguel

Received on 2022-02-03 21:11:34