If you assume Annex F, floating division by zero is not undefined.
-
-
-
why does ubsan complain then?
-
It's a bug in UBSan.
-
is
@wdtz responsible for this? -
I did touch that code! Last time this came up: https://llvm.org/bugs/show_bug.cgi?id=19535 … -- have things changed?
-
Nothing changed; comment 1 is just wrong and ignores the fact that Annex F overrides the quoted passage.
-
F.3 ¶1: "The +, -, *, and / operators provide the IEC 60559 add, subtract, multiply, and divide operations."
-
the problem is C has F.3 p1: divide is IEC 60559, but in C++ [expr.mul]p4: div 0 is undefined
- 2 more replies
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.