C++ Logo

std-discussion

Advanced search

Re: Inconsistency in Examples

From: Bjorn Reese <breese_at_[hidden]>
Date: Fri, 24 Nov 2023 12:33:44 +0100
On 11/23/23 22:38, Jens Maurer via Std-Discussion wrote:

> You're looking at the declaration of "operator new", but you've
> written a new-expression in your example. It's not clear to me
> that [[nodiscard]] on the former has any effect on the latter.

Related to this, placement-new operators are marked nodiscard
[new.delete.placement], but the function construct_at() is not
[specialized.construct]. Is that deliberate or an oversight?

Received on 2023-11-24 11:33:47