diff options
author | Jan Hubicka <hubicka@ucw.cz> | 2014-06-25 01:14:26 +0200 |
---|---|---|
committer | Jan Hubicka <hubicka@gcc.gnu.org> | 2014-06-24 23:14:26 +0000 |
commit | aaf8a23ef3ff2055dde65871b438883ecc067bb0 (patch) | |
tree | 4eb562a7b31cab4e4e7d8a28aa86e3deca8f76e5 /gcc/tree.h | |
parent | ecc6304308f19c159a9df27d0bd5a66f5acbba83 (diff) | |
download | gcc-aaf8a23ef3ff2055dde65871b438883ecc067bb0.zip gcc-aaf8a23ef3ff2055dde65871b438883ecc067bb0.tar.gz gcc-aaf8a23ef3ff2055dde65871b438883ecc067bb0.tar.bz2 |
class.c (check_methods, [...]): Guard VINDEX checks by FUNCTION_DECL check.
* class.c (check_methods, create_vtable_ptr, determine_key_method,
add_vcall_offset_vtbl_entries_1): Guard VINDEX checks by FUNCTION_DECL check.
* cp-tree.h (lang_decl_ns): Add ns_using and ns_users.
(DECL_NAMESPACE_USING, DECL_NAMESPACE_USERS): Use lang_decl_ns.
(DECL_NAMESPACE_ASSOCIATIONS): Use DECL_INITIAL.
(DECL_TEMPLATE_INSTANTIATIONS): Use DECL_SIZE_UNIT.
* tree.c (find_decls_types_r): Do not check DECL_VINDEX for TYPE_DECL.
* tree.h (DECL_VINDEX, DECL_SAVED_TREE): Restrict to DECL_FUNCTION.
* tree-core.h (tree_decl_non_common): Move saved_tree and vindex...
(tree_function_decl): ... here.
* tree-streamer-out.c (write_ts_decl_non_common_tree_pointers): Move
streaming of vindex to ...
(write_ts_function_decl_tree_pointers): ... here.
* tree-streamer-in.c (lto_input_ts_decl_non_common_tree_pointers):
Do not stream DECL_VINDEX.
(lto_input_ts_function_decl_tree_pointers): Stream it here.
* lto.c (mentions_vars_p_decl_non_common): Move DECL_VINDEX check to ..
(mentions_vars_p_function): ... here.
(compare_tree_sccs_1): Update VINDEX checks.
(lto_fixup_prevailing_decls): Likewise.
From-SVN: r211960
Diffstat (limited to 'gcc/tree.h')
-rw-r--r-- | gcc/tree.h | 7 |
1 files changed, 3 insertions, 4 deletions
@@ -2470,10 +2470,9 @@ extern void decl_fini_priority_insert (tree, priority_type); is the FUNCTION_DECL which this FUNCTION_DECL will replace as a virtual function. When the class is laid out, this pointer is changed to an INTEGER_CST node which is suitable for use as an index - into the virtual function table. - C++ also uses this field in namespaces, hence the DECL_NON_COMMON_CHECK. */ + into the virtual function table. */ #define DECL_VINDEX(NODE) \ - (DECL_NON_COMMON_CHECK (NODE)->decl_non_common.vindex) + (FUNCTION_DECL_CHECK (NODE)->function_decl.vindex) /* In FUNCTION_DECL, holds the decl for the return value. */ #define DECL_RESULT(NODE) (FUNCTION_DECL_CHECK (NODE)->decl_non_common.result) @@ -2485,7 +2484,7 @@ extern void decl_fini_priority_insert (tree, priority_type); /* In a FUNCTION_DECL, the saved representation of the body of the entire function. */ #define DECL_SAVED_TREE(NODE) \ - (FUNCTION_DECL_CHECK (NODE)->decl_non_common.saved_tree) + (FUNCTION_DECL_CHECK (NODE)->function_decl.saved_tree) /* Nonzero in a FUNCTION_DECL means this function should be treated as if it were a malloc, meaning it returns a pointer that is |