mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-04-23 00:51:00 +08:00
decl2.c (lang_f_options): Const-ification.
* decl2.c (lang_f_options): Const-ification. * lex.c (cplus_tree_code_name): Likewise. * spew.c (yyerror): Likewise. From-SVN: r45565
This commit is contained in:
parent
fd033052f9
commit
40008eda37
@ -1,3 +1,9 @@
|
||||
2001-09-12 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
|
||||
|
||||
* decl2.c (lang_f_options): Const-ification.
|
||||
* lex.c (cplus_tree_code_name): Likewise.
|
||||
* spew.c (yyerror): Likewise.
|
||||
|
||||
2001-09-06 Nathan Sidwell <nathan@codesourcery.com>
|
||||
|
||||
PR c++/3986
|
||||
|
@ -417,7 +417,7 @@ c_language_kind c_language = clk_cplusplus;
|
||||
if `-fSTRING' is seen as an option.
|
||||
(If `-fno-STRING' is seen as an option, the opposite value is stored.) */
|
||||
|
||||
static struct { const char *string; int *variable; int on_value;}
|
||||
static struct { const char *const string; int *variable; int on_value;}
|
||||
lang_f_options[] =
|
||||
{
|
||||
/* C/C++ options. */
|
||||
|
@ -235,7 +235,7 @@ static int cplus_tree_code_length[] = {
|
||||
Used for printing out the tree and error messages. */
|
||||
#define DEFTREECODE(SYM, NAME, TYPE, LEN) NAME,
|
||||
|
||||
static const char *cplus_tree_code_name[] = {
|
||||
static const char *const cplus_tree_code_name[] = {
|
||||
"@@dummy",
|
||||
#include "cp-tree.def"
|
||||
};
|
||||
|
@ -1482,7 +1482,7 @@ yyerror (msgid)
|
||||
else if (last_token == CPP_CHAR || last_token == CPP_WCHAR)
|
||||
{
|
||||
unsigned int val = TREE_INT_CST_LOW (yylval.ttype);
|
||||
const char *ell = (last_token == CPP_CHAR) ? "" : "L";
|
||||
const char *const ell = (last_token == CPP_CHAR) ? "" : "L";
|
||||
if (val <= UCHAR_MAX && ISGRAPH (val))
|
||||
error ("%s before %s'%c'", string, ell, val);
|
||||
else
|
||||
|
Loading…
x
Reference in New Issue
Block a user