5 ms·
That would neat, although I suspect most compilers/linters should already be able to warn you about potential overflows. If you want to boil down what devs are
by kmoser 2y ago
That would neat, although I suspect most compilers/linters should already be able to warn you about potential overflows.
If you want to boil down what devs are looking for in a diff tool to one thing, it would be "which change(s) between these two versions of code result in a different binary (or AST/opcodes/bytecode, depending on the language)?" All other changes, while certainly sometimes useful to know about, are just syntactic sugar.
- tsimionescu 2y agoLiterally every time you add/subtract/multiply two variables there is a potential overflow. In relatively rare cases, the compiler might be able to prove that they can't overflow, but in the general case it can't, and I doubt any actually do.