C++ Logo

sg5

Advanced search

Re: [SG5] P2066 question

From: Jens Maurer <Jens.Maurer_at_[hidden]>
Date: Tue, 20 Oct 2020 11:28:19 +0200
On 20/10/2020 03.52, Hans Boehm via SG5 wrote:
> Would we get ourselves into any trouble if we required that const operations on vector and list also be supported? What about the same question for other standard containers and strings?

std::vector::at may throw an exception.

> I think currently vector::size() is not allowed in transactions. My goal would be to fix that along with as many similar anomalies as possible.

I can only repeat what I said earlier: There is no question we will find a
gazillion of functions in the standard library that could be used inside a
transaction. Procedurally, we need to go back to SG5 -> LEWG -> LWG for
each of them, and it's going to hurt every single time.

Plus, until the audience (e.g. library implementers) are comfortable with
what it means to make a function fit for transactions, this will need
convincing and/or providing an implementation every time. I'd strongly
suggest to move the TS as-is and consider any additions as post-TS feedback.

(I probably won't be able to join the SG5 meeting today.)

Jens

Received on 2020-10-20 04:28:28