From 88d92ca5b290f6bd966ebfa9ca98652763f61b18 Mon Sep 17 00:00:00 2001 From: Richard Stallman Date: Fri, 22 May 1992 19:43:56 +0000 Subject: [PATCH] *** empty log message *** From-SVN: r1051 --- gcc/c-lex.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/gcc/c-lex.c b/gcc/c-lex.c index 34c83569505..95efad586bb 100644 --- a/gcc/c-lex.c +++ b/gcc/c-lex.c @@ -1446,10 +1446,10 @@ yylex () warn = 1; } if (warn) - warning ("integer constant out of range"); + pedwarn ("integer constant out of range"); } else if (overflow) - warning ("integer constant larger than compiler can handle"); + pedwarn ("integer constant larger than compiler can handle"); /* If it overflowed our internal buffer, then make it unsigned. We can't distinguish based on the tree node because @@ -1602,6 +1602,9 @@ yylex () } #endif + if (!int_fits_type_p (yylval.ttype, type)) + pedwarn ("integer constant out of range"); + TREE_TYPE (yylval.ttype) = type; *p = 0; } -- 2.30.2