2821. std::launder() should be marked as [[nodiscard]]

Section: 21.6.4 [ptr.launder] Status: New Submitter: Tony van Eerd Opened: 2016-11-13 Last modified: 2017-03-19

Priority: 3

View other active issues in [ptr.launder].

View all other issues in [ptr.launder].

View all issues with New status.

Discussion:

As pointed out by Nevin: A use of std::launder that does not make use of its return value is always pointless; the function has no side effects.

[2017-01-27 Telecon]

Priority 3; Nico's upcoming paper P0532 should address this and other issues around launder.

[2017-03-04, Kona]

This should be handled post-C++17 by Nico's paper P0600.

Proposed resolution: