C++ Logo

sg15

Advanced search

Re: [isocpp-sg15] [isocpp-sg21] P3835 -- Different contract checking for different libraries

From: Herb Sutter <herb.sutter_at_[hidden]>
Date: Wed, 22 Oct 2025 16:16:52 -0700
John S wrote:

> That still fails to do what i want, which is to have the library provide know

> that the semantic they choose will be the one used when the program is linked.

 

Agreed that this is not directly supported in C++26.

 

John, just making sure I understand… I think (please correct!):

 

* we agree this will be supported post-C++26 with the labels feature, such as a “contract_assert<enforce>(cond)” or similar syntax to require a specific semantic, and

 

* you think C++26 should not be shipped without a way to express that as part of the first version

 

… did I get that right?

 

I just want to make sure I understand your view of this specific concern correctly (and of course I know you have other concerns too, just trying to focus on this one here).

 

Thanks,

 

Herb

 

 


Received on 2025-10-22 23:16:57