3 ms·
This is an April folks joke
by CraigRo 3y ago
This is an April folks joke
- hifromwork 3y agoI don't think this is true
- dgfitz 3y agoIs it? https://news.ycombinator.com/item?id=30017204 https://news.ycombinator.com/item?id=30017204
- perihelions 3y agoThe C++ language standard is not a funny joke.
- MaxBarraclough 3y agoAgreed. Brevity is the soul of wit, and all that.
- 1letterunixname 3y agoIt's the art of making the juggling with swords seem safe and easy while making a daily commute through a minefield of UB seem routine.
- MaxBarraclough 3y agoAnd there's a second minefield called the portable build solution, but we don't talk about it much.
- avidphantasm 3y ago> Don’t ask. If you’re not one of the 5 or so people in the world who already know what this is, you don’t want or need to know. The attitude rings true though. I am convinced that C++ is proof that we have discovered alien technology, and it is awful.
- ericdfoley 3y agoThe thing is that there is probably a lot of existing C++ code that is UB without std::launder (similarly to aliasing rules.) The main problem is that the C++ object lifetime rules are not well understood by most people writing C++ code.
- sqeaky 3y agoI hadn't even considered the task of going through old code and using this to make it more compliant, this is a great use case for this feature.
- MaxBarraclough 3y agoIt is not. It links to a lengthy StackOverflow thread about std::launder. https://stackoverflow.com/questions/39382501/ https://stackoverflow.com/questions/39382501/
- avrionov 3y agoIt is a feature: https://en.cppreference.com/w/cpp/utility/launder https://en.cppreference.com/w/cpp/utility/launder