Skip to content
Commit 7e61ac5a authored by Chris Lattner's avatar Chris Lattner
Browse files

Catch overflow of negate. This allows us to emit:

t.c:2:17: warning: integer overflow in preprocessor expression
#if -(INTMAX_MAX+1)
                ^
t.c:2:5: warning: integer overflow in preprocessor expression
#if -(INTMAX_MAX+1)
    ^

GCC has some seriously confused source locations in this case:
t.c:2:19: warning: integer overflow in preprocessor expression
t.c:2:20: warning: integer overflow in preprocessor expression

column 19/20 are off the end of the line.

llvm-svn: 39404
parent 028c7dec
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment