3 ms·
> Which is the point TFA is making. Again, the point is wrong in more than one way. You don't simply add undefined behavior. It's wrong, and buggy code. Onboa
by chipdart 2y ago
> Which is the point TFA is making.
Again, the point is wrong in more than one way.
You don't simply add undefined behavior. It's wrong, and buggy code. Onboard a static code analysis tool like cppcheck to tell you when you messed up.
It takes far less work to onboard any of these tools than it takes to write a sentence in a blog post.
- throw_a_grenade 2y agoTFA argues developers add it left and right, unless someone memorised all the rules. Since reportedly it's not possible to memorise all the rules by a single human, then you either "simply add undefined behaviour", or limit yourself to a subset of C++ that programmers do actually understand. Which is a solution I see in many codebases: to limit a set of permissible constructs by a style manual.