This is an unofficial snapshot of the ISO/IEC JTC1 SC22 WG21 Core Issues List revision 117b. See http://www.open-std.org/jtc1/sc22/wg21/ for the official list.
2025-08-11
944. reinterpret_cast for all types with the same size and alignmentSection: 7.6.1.10 [expr.reinterpret.cast] Status: NAD Submitter: Miller Date: 15 July, 2009During the discussion of issue 799, which specified the result of using reinterpret_cast to convert an operand to its own type, it was observed that it is probably reasonable to allow reinterpret_cast between any two types that have the same size and alignment.
Additional note, April, 2015:
It has been suggested that this question may more properly be the province of EWG, especially in light of discussions during the resolution of issue 330.
Rationale (May, 2015):
CWG agreed that this question should be considered from a language design perspective and is thus being referred to EWG.
Rationale (June, 2021):
EWG resolved to close this issue. The bit_cast function addresses some of the use-cases. Supporting other use-cases would need a paper. See vote.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4