C++ Logo


Advanced search

Re: [wg14/wg21 liaison] [isocpp-sg21] Telecon to review P2388R1 Minimum Contract Support: either Ignore or Check_and_abort

From: Jens Maurer <Jens.Maurer_at_[hidden]>
Date: Mon, 20 Sep 2021 22:28:58 +0200
On 20/09/2021 22.17, Ville Voutilainen via SG21 wrote:
> I wonder whether we have considered allowing the contract declaration
> to precede the function-declarator but
> allow it to refer to the parameters anyway.

Parsing in C++ is quite dependent on prior name lookup results.
The scenario you describes seems novel for C++ (at least in a
declaration context), and I'd like to see an actual implementation
for that idea before I'd like to go down that path.

Beyond that, due to the novelty in a core part of parsers,
it would probably cause substantial changes (= effort) to
any compiler.


Received on 2021-09-20 15:29:02