> we already have memcpy, but bit_cast is safer and also can run at compile time.
Can someone smarter than I am explain the significance about bit_cast running at compile time?
Can someone smarter than I am explain the significance about bit_cast running at compile time?
Mostly though, this is fairly unimportant and tedious spec-manship, filling in some obvious gaps.
We had a version of this in chromium a few years ago. This is a proposal just picking that up from what I can tell.
Here are some videos on the topic: https://www.youtube.com/watch?v=PJwd4JLYJJY https://www.youtube.com/watch?v=rpn_5Mrrxf8