The ..._DECL node is returned as the value.
Exception: for arrays where the length is not specified,
- the type is left null, to be filled in by `finish_decl'.
+ the type is left null, to be filled in by `cp_finish_decl'.
Function definitions do not come here; they go to start_function
instead. However, external and forward declarations of functions
pop_obstacks ();
}
- /* Corresponding pop_obstacks is done in `finish_decl'. */
+ /* Corresponding pop_obstacks is done in `cp_finish_decl'. */
push_obstacks_nochange ();
context
if (initialized)
/* Is it valid for this decl to have an initializer at all?
If not, set INITIALIZED to zero, which will indirectly
- tell `finish_decl' to ignore the initializer once it is parsed. */
+ tell `cp_finish_decl' to ignore the initializer once it is parsed. */
switch (TREE_CODE (decl))
{
case TYPE_DECL:
/* typedef foo = bar means give foo the same type as bar.
- We haven't parsed bar yet, so `finish_decl' will fix that up.
+ We haven't parsed bar yet, so `cp_finish_decl' will fix that up.
Any other case of an initialization in a TYPE_DECL is an error. */
if (pedantic || list_length (declspecs) > 1)
{
/* Tell `pushdecl' this is an initialized decl
even though we don't yet have the initializer expression.
- Also tell `finish_decl' it may store the real initializer. */
+ Also tell `cp_finish_decl' it may store the real initializer. */
DECL_INITIAL (decl) = error_mark_node;
}
{
DECL_INITIAL (tmp) = init;
TREE_STATIC (tmp) = toplevel_bindings_p ();
- finish_decl (tmp, init, NULL_TREE, 0, LOOKUP_ONLYCONVERTING);
+ cp_finish_decl (tmp, init, NULL_TREE, 0, LOOKUP_ONLYCONVERTING);
}
if (TREE_STATIC (tmp))
preserve_initializer ();
#endif
/* Handle initialization of references.
- These three arguments from from `finish_decl', and have the
+ These three arguments from from `cp_finish_decl', and have the
same meaning here that they do there. */
/* quotes on semantics can be found in ARM 8.4.3. */
static void
Call `pop_obstacks' iff NEED_POP is nonzero.
- For C++, `finish_decl' must be fairly evasive: it must keep initializers
+ For C++, `cp_finish_decl' must be fairly evasive: it must keep initializers
for aggregates that have constructors alive on the permanent obstack,
so that the global initializing functions can be written at the end.
if the (init) syntax was used.
For functions that take default parameters, DECL points to its
- "maximal" instantiation. `finish_decl' must then also declared its
+ "maximal" instantiation. `cp_finish_decl' must then also declared its
subsequently lower and lower forms of instantiation, checking for
ambiguity as it goes. This can be sped up later. */
void
-finish_decl (decl, init, asmspec_tree, need_pop, flags)
+cp_finish_decl (decl, init, asmspec_tree, need_pop, flags)
tree decl, init;
tree asmspec_tree;
int need_pop;
cadillac_finish_decl (decl);
}
+/* This is here for a midend callback from c-common.c */
+void
+finish_decl (decl, init, asmspec_tree)
+ tree decl, init;
+ tree asmspec_tree;
+{
+ cp_finish_decl (decl, init, asmspec_tree, 1, 0);
+}
+
void
expand_static_init (decl, init)
tree decl;
if (parmlist_is_exprlist (TREE_OPERAND (decl, 1)))
{
/* This is actually a variable declaration using constructor
- syntax. We need to call start_decl and finish_decl so we
+ syntax. We need to call start_decl and cp_finish_decl so we
can get the variable initialized... */
if (last)
init = TREE_OPERAND (decl, 1);
decl = start_decl (declarator, declspecs, 1, NULL_TREE);
- finish_decl (decl, init, NULL_TREE, 1, 0);
+ finish_decl (decl, init, NULL_TREE);
return 0;
}
innermost_code = TREE_CODE (decl);
DECL_RTL (decl) = gen_reg_rtx (DECL_MODE (decl));
}
- /* Let `finish_decl' know that this initializer is ok. */
+ /* Let `cp_finish_decl' know that this initializer is ok. */
DECL_INITIAL (decl) = init;
pushdecl (decl);
- finish_decl (decl, init, NULL_TREE, 0, LOOKUP_ONLYCONVERTING);
+ cp_finish_decl (decl, init, NULL_TREE, 0, LOOKUP_ONLYCONVERTING);
}
}
grok_op_properties (fndecl, DECL_VIRTUAL_P (fndecl), 0);
}
- finish_decl (fndecl, NULL_TREE, NULL_TREE, 0, 0);
+ cp_finish_decl (fndecl, NULL_TREE, NULL_TREE, 0, 0);
/* Make a place for the parms */
pushlevel (0);