Yes I'd bet big this technique is an often reinvented wheel.
Why do you prefer two static casts involving void * over a reinterpret cast? Also, your C style cast is really a reinterpret cast. I think the reason for having reinterpret cast is that it's a (greppable) warning that something is dangerous. And this technique is fairly dangerous, mistakes can elude static checking.
Yeah I just got the habit of not using any reinterpret_casts from
the Boost community standards, so it's just another way of writing
them down.
And I wasn't sure how alignments and little to big endian
machines would convert them.
On Sun, Aug 21, 2022 at 4:38 PM, Phil Bouchard via Std-Proposals--
Std-Proposals mailing list
Std-Proposals@lists.isocpp.org
https://lists.isocpp.org/mailman/listinfo.cgi/std-proposals
|
|
|||||||
Le message ci-dessus,
ainsi que les documents l'accompagnant, sont destinés
uniquement aux personnes identifiées et peuvent contenir
des informations privilégiées, confidentielles ou ne
pouvant être divulguées. Si vous avez reçu ce message par
erreur, veuillez le détruire.This communication (and/or the attachments) is intended for named recipients only and may contain privileged or confidential information which is not to be disclosed. If you received this communication by mistake please destroy all copies. |
||||||||