3 ms·
djb, who is famous for being an exceptionally talented and careful C programmer, summarized these issues better than I ever could: https://groups.google.com/for
by ekidd 10y ago
djb, who is famous for being an exceptionally talented and careful C programmer, summarized these issues better than I ever could: https://groups.google.com/forum/m/#!msg/boring-crypto/48qa1kWignU/o8GGp2K1DAAJ https://groups.google.com/forum/m/#!msg/boring-crypto/48qa1k...
Yes, every time a C program relies on undefined behavior, it's a bug. And as djb observed, virtually all non-trivial C programs contain these bugs. This is the core of my argument.
Yes, we could rely on C programmers never making mistakes. But it would be better to design languages with no undefined behavior.
- RUG3Y 10y agoAs someone that doesn't HAVE to use C, this weirdness is one of the things that makes it interesting to me. I'm sure I'm the exception here, and if I were writing lots of C code for big projects I'd feel otherwise.
- ArkyBeagle 10y agoHis idea of flagging UB at compile-time is pretty obvious - I have to wonder what the economics are that it hasn't been an emphasis at all, all these years. I do get a facial tick when people say "all significant C programs use (or contain) UB." It's never been necessary and it's always been shameful.