C++ Logo

std-proposals

Advanced search

Re: [std-proposals] "shared libraries are outside the scope of the C++ standard"

From: Timur Doumler <cpp_at_[hidden]>
Date: Tue, 18 Jul 2023 04:37:09 -0400
> On 18 Jul 2023, at 04:08, Lénárd Szolnoki via Std-Proposals <std-proposals_at_[hidden]> wrote:
> AFAIK one of the design goals of contracts is to allow companies to
> still only release two builds: one debug and one release build, and
> allow users the replace the contract violation handler for the debug
> library if they want to do so. I don't know if this is possible with
> replaceable functions within DLLs on Windows.

That's a good question, but it is the responsibility of Windows & the Microsoft compiler and toolchain to figure out whether it's possible and how that would work — not the responsibility of the Standard.

Is it possible for operator new/delete? If yes, it should in principle be possible for the Contract violation handler, too.

Cheers,
Timur

Received on 2023-07-18 08:37:22