You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: clang/test/C/drs/dr0xx.c
+2-1Lines changed: 2 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -430,7 +430,8 @@ void dr081(void) {
430
430
/* Demonstrate that we don't crash when left shifting a signed value; that's
431
431
* implementation defined behavior.
432
432
*/
433
-
_Static_assert(-1 << 1==-2, "fail"); /* Didn't shift a zero into the "sign bit". */
433
+
_Static_assert(-1 << 1==-2, "fail"); /* expected-warning {{expression is not an integer constant expression; folding it to a constant is a GNU extension}}
434
+
expected-note {{left shift of negative value -1}} */
434
435
_Static_assert(1 << 3==1u << 3u, "fail"); /* Shift of a positive signed value does sensible things. */
0 commit comments