diff options
author | Gavin Romig-Koch <gavin@cygnus.com> | 1999-07-01 08:08:42 +0000 |
---|---|---|
committer | Gavin Romig-Koch <gavin@gcc.gnu.org> | 1999-07-01 08:08:42 +0000 |
commit | ed534bdd3753683d7bb4fa1d6b5f1e8760ad7342 (patch) | |
tree | 896e2f2586bef58e47eb7b54e41c969ea83538fc /gcc/c-lex.c | |
parent | ac8f5d48cba9387f8ccb22bb91786805a213bf5a (diff) | |
download | gcc-ed534bdd3753683d7bb4fa1d6b5f1e8760ad7342.zip gcc-ed534bdd3753683d7bb4fa1d6b5f1e8760ad7342.tar.gz gcc-ed534bdd3753683d7bb4fa1d6b5f1e8760ad7342.tar.bz2 |
For gcc:
* c-lex.c (yylex): Improve 'integer constant out of range' messages.
For gcc/cp:
* lex.c (real_yylex): Improve 'integer constant out of range' messages.
From-SVN: r27873
Diffstat (limited to 'gcc/c-lex.c')
-rw-r--r-- | gcc/c-lex.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/gcc/c-lex.c b/gcc/c-lex.c index 96ca224..214bcd1 100644 --- a/gcc/c-lex.c +++ b/gcc/c-lex.c @@ -1775,7 +1775,7 @@ yylex () warn = overflow; if (warn) - pedwarn ("integer constant out of range"); + pedwarn ("integer constant is too large for this configuration of the compiler - truncated to %d bits", HOST_BITS_PER_WIDE_INT * 2); /* This is simplified by the fact that our constant is always positive. */ @@ -1866,7 +1866,7 @@ yylex () < TYPE_PRECISION (type))) { warn = 1; - pedwarn ("integer constant out of range"); + pedwarn ("integer constant larger than the maximum value of an unsigned long int"); } if (base == 10 && ! spec_unsigned && TREE_UNSIGNED (type)) @@ -1903,7 +1903,7 @@ yylex () if (! warn && TREE_CODE (TREE_TYPE (yylval.ttype)) == INTEGER_TYPE && ! int_fits_type_p (yylval.ttype, TREE_TYPE (yylval.ttype))) - pedwarn ("integer constant out of range"); + pedwarn ("integer constant is larger than the maximum value for its type"); } UNGETC (c); |