On 09/16/2015 11:54 AM, Manuel López-Ibáñez wrote:
Unfortunately, toplev.c is a kitchen sink of things that do not belong
anywhere in particular.
For example, check_global_declarations is only used in cgraphunit.c.
Moving it there allows us to make it static and remove one call to
symtab_node::get.
Bootstrapped & regtested on x86_64-linux-gnu.
OK?
gcc/ChangeLog:
2015-09-15 Manuel López-Ibáñez <m...@gcc.gnu.org>
* toplev.h (check_global_declaration): Remove declaration.
* toplev.c (check_global_declaration): Move to ...
* cgraphunit.c: ... here. Make it static and pass a symtab_node *.
(analyze_functions): Update call.
I'm not really sure that passing in the symtab node is better than the
underlying decl. But I doubt it really matters in practice.
Ok for the trunk.
jeff