[llvm-bugs] [Bug 32470] New: Add a warning about sequence points
llvm-bugs at lists.llvm.org
Thu Mar 30 07:04:38 PDT 2017
Bug ID: 32470
Summary: Add a warning about sequence points
Component: -New Bugs
Assignee: unassignedclangbugs at nondot.org
Reporter: lebedev.ri at gmail.com
CC: llvm-bugs at lists.llvm.org
Created attachment 18199
I have experienced an issue, when the same code would result in different
behavior with clang and gcc.
I was able to reduce the testcase.
The attached testcase was minimized.
With gcc (6), the exit code is 10.
With clang (tried with current svn version), the exit code is 0.
0 is the 'expected' answer.
As i was told in Debian Bug#859116, "This is unspecified, there are no sequence
points between the two."
Perhaps clang or clang-tidy can learn to warn about code like this?
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the llvm-bugs