Commit 89658955 by Bernardo Innocenti Committed by Bernardo Innocenti

c-decl.c (groktypename, [...]): Rename variable typename to type_name.

	* c-decl.c (groktypename, groktypename_in_param_context): Rename
	variable typename to type_name.
	* c-lex.c (interpret_float): Likewise.

From-SVN: r85161
parent 3244e67d
2004-07-25 Bernardo Innocenti <bernie@develer.com>
* c-decl.c (groktypename, groktypename_in_param_context): Rename
variable typename to type_name.
* c-lex.c (interpret_float): Likewise.
2004-07-25 Roger Sayle <roger@eyesopen.com> 2004-07-25 Roger Sayle <roger@eyesopen.com>
* convert.c (convert_to_real, convert_to_integer, * convert.c (convert_to_real, convert_to_integer,
......
...@@ -2646,33 +2646,33 @@ set_array_declarator_type (tree decl, tree type, int abstract_p) ...@@ -2646,33 +2646,33 @@ set_array_declarator_type (tree decl, tree type, int abstract_p)
/* Decode a "typename", such as "int **", returning a ..._TYPE node. */ /* Decode a "typename", such as "int **", returning a ..._TYPE node. */
tree tree
groktypename (tree typename) groktypename (tree type_name)
{ {
tree specs, attrs; tree specs, attrs;
if (TREE_CODE (typename) != TREE_LIST) if (TREE_CODE (type_name) != TREE_LIST)
return typename; return type_name;
split_specs_attrs (TREE_PURPOSE (typename), &specs, &attrs); split_specs_attrs (TREE_PURPOSE (type_name), &specs, &attrs);
typename = grokdeclarator (TREE_VALUE (typename), specs, TYPENAME, 0, type_name = grokdeclarator (TREE_VALUE (type_name), specs, TYPENAME, 0,
NULL); NULL);
/* Apply attributes. */ /* Apply attributes. */
decl_attributes (&typename, attrs, 0); decl_attributes (&type_name, attrs, 0);
return typename; return type_name;
} }
/* Return a PARM_DECL node for a given pair of specs and declarator. */ /* Return a PARM_DECL node for a given pair of specs and declarator. */
tree tree
groktypename_in_parm_context (tree typename) groktypename_in_parm_context (tree type_name)
{ {
if (TREE_CODE (typename) != TREE_LIST) if (TREE_CODE (type_name) != TREE_LIST)
return typename; return type_name;
return grokdeclarator (TREE_VALUE (typename), return grokdeclarator (TREE_VALUE (type_name),
TREE_PURPOSE (typename), TREE_PURPOSE (type_name),
PARM, 0, NULL); PARM, 0, NULL);
} }
......
...@@ -597,24 +597,24 @@ interpret_float (const cpp_token *token, unsigned int flags) ...@@ -597,24 +597,24 @@ interpret_float (const cpp_token *token, unsigned int flags)
REAL_VALUE_TYPE real; REAL_VALUE_TYPE real;
char *copy; char *copy;
size_t copylen; size_t copylen;
const char *typename; const char *type_name;
/* FIXME: make %T work in error/warning, then we don't need typename. */ /* FIXME: make %T work in error/warning, then we don't need type_name. */
if ((flags & CPP_N_WIDTH) == CPP_N_LARGE) if ((flags & CPP_N_WIDTH) == CPP_N_LARGE)
{ {
type = long_double_type_node; type = long_double_type_node;
typename = "long double"; type_name = "long double";
} }
else if ((flags & CPP_N_WIDTH) == CPP_N_SMALL else if ((flags & CPP_N_WIDTH) == CPP_N_SMALL
|| flag_single_precision_constant) || flag_single_precision_constant)
{ {
type = float_type_node; type = float_type_node;
typename = "float"; type_name = "float";
} }
else else
{ {
type = double_type_node; type = double_type_node;
typename = "double"; type_name = "double";
} }
/* Copy the constant to a nul-terminated buffer. If the constant /* Copy the constant to a nul-terminated buffer. If the constant
...@@ -641,7 +641,7 @@ interpret_float (const cpp_token *token, unsigned int flags) ...@@ -641,7 +641,7 @@ interpret_float (const cpp_token *token, unsigned int flags)
??? That's a dubious reason... is this a mandatory diagnostic or ??? That's a dubious reason... is this a mandatory diagnostic or
isn't it? -- zw, 2001-08-21. */ isn't it? -- zw, 2001-08-21. */
if (REAL_VALUE_ISINF (real) && pedantic) if (REAL_VALUE_ISINF (real) && pedantic)
warning ("floating constant exceeds range of \"%s\"", typename); warning ("floating constant exceeds range of \"%s\"", type_name);
/* Create a node with determined type and value. */ /* Create a node with determined type and value. */
value = build_real (type, real); value = build_real (type, real);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment