C++ Logo


Advanced search

Re: [std-proposals] Alteration of elements in a set (non-const iterator)

From: Thiago Macieira <thiago_at_[hidden]>
Date: Mon, 22 May 2023 10:12:53 -0700
On Monday, 22 May 2023 04:22:18 PDT Edward Catmur via Std-Proposals wrote:
> The abstract machine is perfectly capable of doing that. A picky
> implementation could place such a class instance across a page boundary, if
> it wanted.

A much more likely, though still currently non-existent, implementation could
have a byte-level management of memory protection. The implementation could
easily apply the constness to each sub-object on construction.

If nothing else, sanitisers can do that.

Thiago Macieira - thiago (AT) macieira.info - thiago (AT) kde.org
   Software Architect - Intel DCAI Cloud Engineering

Received on 2023-05-22 17:12:55