C++ Logo

std-proposals

Advanced search

Re: [std-proposals] constexpr support in std::filesystem API

From: Jonathan Wakely <cxx_at_[hidden]>
Date: Tue, 12 Mar 2024 13:54:50 +0000
On Tue, 12 Mar 2024 at 13:53, Jonathan Wakely <cxx_at_[hidden]> wrote:
>
> On Tue, 12 Mar 2024 at 13:47, Andrei Grosu <andrei_dg_at_[hidden]> wrote:
> >
> > OK,
> > First I am just arguing here for the sake of the discussion, just to make it clear.
> >
> > 1. One would think that reproduciblr builds are something everyone should strive for.
> >
> > 2. Regarding the optionally enabled stuff in the standard, there is a giant, gaping precedence for this: exceptions. RTTI can be conditionally disabled at compile time. I have a compiler flag that disables parts of the standard c++ . Why would it be oknfor exeptions/rtti but not for something like constexpr filesystem ? ( or anything else for that matter ).
>
> Standard C++ does not allow disabling exceptions or RTTI, they are
> required even for freestanding environments.
>
> And you're not talking about a standard feature that could probably be
> disabled by non-standard flags in compilers, you're suggesting it
> should be off by default and enabled by a flag. That's not the same
> thing as exceptions and RTTI at all.

If it needs to be off by default, it probably shouldn't be in the standard.

Maybe try implementing it in one of the open source compilers to
demonstrate it's doable and useful, and to get experience with the
feature and the problems it can create.

Received on 2024-03-12 13:56:07