3 ms·
> On the other hand, there seem to be so many cases like this one where the “undefined behavior code deleter goes brrrrrr” really overextends its usefulness. I
by oxff 4y ago
> On the other hand, there seem to be so many cases like this one where the “undefined behavior code deleter goes brrrrrr” really overextends its usefulness.
I would simply not depend on invoking UB as part of my program's behavior (?).
- masklinn 4y agoAlternatively I would not trust myself with not doing that, which is why I don’t use C.
- eru 4y agoThat's the only way to use C correctly. Alas, it's nearly impossible for a mere mortal to write any non-trivial C code that doesn't have UB.
- pjc50 4y ago"a+b" for signed integer types potentially invokes undefined behavior (overflow). It's a horrendous situation.
- vgatherps 4y agoI don't think I ever claimed that one would or should intentionally invoke UB as part of their program's behavior?