2 ms·
I agree there should be a warning. But it is not trivial to teach a compiler when to warn or not to not generate too many false positives. Not as good as warni
by uecker 3y ago
I agree there should be a warning. But it is not trivial to teach a compiler when to warn or not to not generate too many false positives.
Not as good as warning, but UBSan catches this at run-time:
https://godbolt.org/z/Mdjn7h8dj https://godbolt.org/z/Mdjn7h8dj