#include "config.h"#include "system.h"#include "coretypes.h"#include "tm.h"#include "tree.h"#include "rtl.h"#include "expr.h"#include "flags.h"#include "cp-tree.h"#include "decl.h"#include "output.h"#include "except.h"#include "toplev.h"#include "timevar.h"#include "cpplib.h"#include "target.h"#include "c-common.h"#include "tree-mudflap.h"#include "cgraph.h"#include "tree-inline.h"#include "c-pragma.h"#include "gt-cp-decl2.h"

Go to the source code of this file.
| #define deferred_fns_used (deferred_fns ? deferred_fns->elements_used : 0) |
| #define pending_statics_used (pending_statics ? pending_statics->elements_used : 0) |
| #define SSDF_IDENTIFIER "__static_initialization_and_destruction" |
| typedef struct priority_info_s * priority_info |
Definition at line 517 of file decl2.c.
References args, CLASSTYPE_TEMPLATE_INFO, CLASSTYPE_TI_ARGS, i, TREE_CODE, TREE_TYPE, TREE_VEC_ELT, TREE_VEC_LENGTH, and TYPE_FOR_JAVA.
Definition at line 1094 of file decl2.c.
References ANON_AGGR_TYPE_P, base, build_anon_union_vars(), build_class_member_access_expr(), build_decl, build_min_nt(), cp_pedwarn_at(), DECL_ARTIFICIAL, DECL_EXTERNAL, DECL_NAME, DECL_VALUE_EXPR, error(), get_base_address(), NULL_TREE, processing_template_decl, pushdecl(), TREE_CHAIN, TREE_CODE, TREE_PRIVATE, TREE_PROTECTED, TREE_PUBLIC, TREE_STATIC, TREE_TYPE, and TYPE_FIELDS.
Definition at line 167 of file decl2.c.
References cp_build_parm_decl(), DECL_ARTIFICIAL, and TREE_READONLY.
Definition at line 1990 of file decl2.c.
References build1, build_delete(), build_pointer_type(), cxx_mark_addressable(), gcc_assert, LOOKUP_DESTRUCTOR, LOOKUP_NONVIRTUAL, LOOKUP_NORMAL, mark_used(), sfk_complete_destructor, TREE_CODE, TREE_TYPE, and TYPE_HAS_TRIVIAL_DESTRUCTOR.
Definition at line 3199 of file decl2.c.
References any_type_dependent_arguments_p(), build_function_call(), build_min_non_dep(), build_min_nt(), build_non_dependent_args(), build_non_dependent_expr(), build_unary_op(), error_mark_node, gcc_assert, get_member_function_from_ptrfunc(), NULL_TREE, processing_template_decl, TREE_CODE, tree_cons, TREE_OPERAND, and type_dependent_expression_p().
Definition at line 3252 of file decl2.c.
References cp_error_at(), i, TREE_CHAIN, TREE_CODE, TREE_PURPOSE, TREE_TYPE, TYPE_ARG_TYPES, and void_list_node.
Definition at line 552 of file decl2.c.
References acceptable_java_type(), arg_types, DECL_HAS_IN_CHARGE_PARM_P, DECL_HAS_VTT_PARM_P, error(), NULL_TREE, TREE_CHAIN, TREE_TYPE, TREE_VALUE, and TYPE_ARG_TYPES.
Definition at line 477 of file decl2.c.
References current_function_decl, DECL_IGNORED_P, DECL_TEMPLATE_RESULT, DECL_VIRTUAL_P, error(), gcc_assert, IS_AGGR_TYPE, TREE_CODE, and TREE_TYPE.
Definition at line 1256 of file decl2.c.
References args, build_exception_variant(), build_function_type(), error(), gcc_assert, NULL_TREE, ptr_type_node, same_type_p, TREE_CHAIN, TREE_CODE, tree_cons, TREE_TYPE, TREE_VALUE, TYPE_ARG_TYPES, TYPE_RAISES_EXCEPTIONS, void_list_node, and void_type_node.
Definition at line 1218 of file decl2.c.
References args, build_exception_variant(), build_function_type(), error(), gcc_assert, NULL_TREE, pedwarn(), ptr_type_node, same_type_p, size_type_node, TREE_CHAIN, TREE_CODE, tree_cons, TREE_TYPE, TREE_VALUE, TYPE_ARG_TYPES, TYPE_RAISES_EXCEPTIONS, and void_list_node.
Definition at line 1328 of file decl2.c.
References DECL_ARTIFICIAL, DECL_COMDAT, DECL_COMMON, DECL_EXPLICIT_INSTANTIATION, DECL_EXTERNAL, DECL_INITIAL, DECL_LANG_SPECIFIC, DECL_NOT_REALLY_EXTERN, EMPTY_CONSTRUCTOR_P, error_mark_node, flag_weak, make_decl_one_only(), TREE_CODE, and TREE_PUBLIC.
Definition at line 153 of file decl2.c.
References build_decl, DECL_ARG_TYPE, processing_template_decl, and type_passed_as().
Definition at line 1075 of file decl2.c.
References decl_attributes(), DECL_NAME, DECL_TEMPLATE_RESULT, NULL_TREE, SET_IDENTIFIER_TYPE_VALUE, TREE_CODE, TREE_TYPE, and void_type_node.
| tree cxx_callgraph_analyze_expr | ( | tree * | tp, | |
| int *walk_subtrees | ATTRIBUTE_UNUSED, | |||
| tree from | ATTRIBUTE_UNUSED | |||
| ) |
Definition at line 2744 of file decl2.c.
References BASELINK_FUNCTIONS, cgraph_mark_needed_node(), cgraph_node(), CLASSTYPE_VTABLES, DECL_CONTEXT, DECL_VTABLE_OR_VTT_P, mark_decl_referenced(), NULL, PTRMEM_CST_MEMBER, TREE_CHAIN, TREE_CODE, TREE_TYPE, and TYPE_PTRMEMFUNC_P.
Definition at line 411 of file decl2.c.
References build1, build_delete(), build_expr_type_conversion(), build_min(), build_vec_delete(), DELETE_EXPR_USE_GLOBAL, DELETE_EXPR_USE_VEC, error(), error_mark_node, integer_zerop(), LOOKUP_NORMAL, NULL_TREE, processing_template_decl, sfk_deleting_destructor, TREE_CODE, TREE_SIDE_EFFECTS, TREE_TYPE, void_type_node, WANT_POINTER, and warning.
Definition at line 2539 of file decl2.c.
References build_cleanup(), finish_expr_stmt(), finish_static_initialization_or_destruction(), flag_use_cxa_atexit, gcc_assert, start_static_initialization_or_destruction(), TREE_TYPE, and TYPE_HAS_TRIVIAL_DESTRUCTOR.
Definition at line 2511 of file decl2.c.
References finish_expr_stmt(), finish_static_initialization_or_destruction(), flag_use_cxa_atexit, register_dtor_fn(), and start_static_initialization_or_destruction().
Definition at line 1165 of file decl2.c.
References add_decl_expr(), at_function_scope_p(), build_anon_union_vars(), building_stmt_tree, DECL_CONTEXT, DECL_NAME, error(), error_mark_node, mangle_decl(), NULL_TREE, processing_template_decl, pushdecl(), rest_of_decl_compilation(), toplevel_bindings_p(), TREE_PUBLIC, TREE_TYPE, TYPE_FIELDS, TYPE_NAME, and warning.
Definition at line 2179 of file decl2.c.
References gcc_target::asm_out, gcc_target::asm_out::constructor, DECL_RTL, gcc_target::asm_out::destructor, expand_or_defer_fn(), finish_compound_stmt(), finish_function(), flag_syntax_only, gcc_target::have_ctors_dtors, targetm, and XEXP.
Definition at line 764 of file decl2.c.
References cp_finish_decl(), CP_TYPE_CONST_P, current_class_type, DECL_CONTEXT, DECL_IN_AGGR_P, DECL_INITIAL, error(), error_mark_node, gcc_assert, LOCAL_CLASS_P, my_friendly_assert, note_vague_linkage_var(), NULL_TREE, pedwarn(), processing_template_decl, TREE_PUBLIC, TREE_TYPE, TREE_USED, TYPE_NEEDS_CONSTRUCTING, VARRAY_PUSH_TREE, and VARRAY_TREE_INIT.
Definition at line 2496 of file decl2.c.
References current_function_decl, DECL_CONTEXT, DECL_STATIC_FUNCTION_P, finish_if_stmt(), finish_then_clause(), and NULL_TREE.
Definition at line 2334 of file decl2.c.
References expand_or_defer_fn(), finish_compound_stmt(), and finish_function().
| static int generate_ctor_and_dtor_functions_for_priority | ( | splay_tree_node | n, | |
| void * | data | |||
| ) | [static] |
Definition at line 2718 of file decl2.c.
References DEFAULT_INIT_PRIORITY, generate_ctor_or_dtor_function(), int, splay_tree_node_s::key, pi, and splay_tree_node_s::value.
| static void generate_ctor_or_dtor_function | ( | bool | constructor_p, | |
| int | priority, | |||
| location_t * | locus | |||
| ) | [static] |
Definition at line 2639 of file decl2.c.
References build_function_call(), build_int_cst(), DEFAULT_INIT_PRIORITY, ECF_CONST, ECF_PURE, finish_expr_stmt(), finish_objects(), flags_from_decl_or_type(), i, input_location, NULL_TREE, start_objects(), TREE_CHAIN, tree_cons, TREE_VALUE, and VARRAY_TREE.
Definition at line 2020 of file decl2.c.
References build_decl, gcc_target::cxx, DECL_ARTIFICIAL, DECL_COMMON, DECL_IGNORED_P, DECL_ONE_ONLY, DECL_WEAK, gcc_target::cxx::guard_type, IDENTIFIER_GLOBAL_VALUE, mangle_guard_variable(), NULL_TREE, pushdecl_top_level_and_finish(), targetm, TREE_PUBLIC, TREE_STATIC, and TREE_USED.
Definition at line 2056 of file decl2.c.
References build1, build_pointer_type(), char_type_node, gcc_target::cxx, gcc_target::cxx::guard_mask_bit, targetm, and TREE_TYPE.
Definition at line 2078 of file decl2.c.
References convert(), cp_build_binary_op, gcc_target::cxx, get_guard_bits(), gcc_target::cxx::guard_mask_bit, integer_one_node, integer_zero_node, same_type_p, targetm, and TREE_TYPE.
| static priority_info get_priority_info | ( | int | priority | ) | [static] |
Definition at line 2346 of file decl2.c.
References priority_info_s::destructions_p, priority_info_s::initializations_p, n, pi, splay_tree_insert(), splay_tree_lookup(), splay_tree_node_s::value, and xmalloc().
Definition at line 326 of file decl2.c.
References build_array_ref(), build_expr_type_conversion(), build_min_non_dep(), build_min_nt(), build_new_op(), build_non_dependent_expr(), error(), error_mark_node, error_operand_p, gcc_assert, i1, i2, IS_AGGR_TYPE, LOOKUP_NORMAL, non_reference(), NULL, NULL_TREE, p1, p2, processing_template_decl, TREE_CODE, TREE_TYPE, type_dependent_expression_p(), WANT_ENUM, WANT_INT, and WANT_POINTER.
| tree grokbitfield | ( | const cp_declarator * | declarator, | |
| cp_decl_specifier_seq * | declspecs, | |||
| tree | width | |||
| ) |
| void grokclassfn | ( | tree | ctype, | |
| tree | function, | |||
| enum overload_flags | flags, | |||
| cp_cv_quals | quals | |||
| ) |
Definition at line 274 of file decl2.c.
References build_artificial_parm(), cp_apply_type_quals_to_decl(), cp_build_qualified_type, DECL_ARGUMENTS, DECL_CONSTRUCTOR_P, DECL_CONTEXT, DECL_DESTRUCTOR_P, DECL_NAME, DTOR_FLAG, error(), get_identifier(), grok_method_quals(), lang_cplusplus, maybe_retrofit_in_chrg(), NULL_TREE, SET_DECL_LANGUAGE, this_identifier, TREE_CHAIN, TREE_CODE, TREE_TYPE, TREE_VALUE, TYPE_ARG_TYPES, TYPE_QUAL_CONST, and TYPE_UNQUALIFIED.
| tree grokfield | ( | const cp_declarator * | declarator, | |
| cp_decl_specifier_seq * | declspecs, | |||
| tree | init, | |||
| tree | asmspec_tree, | |||
| tree | attrlist | |||
| ) |
Definition at line 827 of file decl2.c.
References cp_decl_specifier_seq::any_specifiers_p, cdk_id, cp_finish_decl(), cplus_decl_attributes(), current_class_type, DECL_CONTEXT, DECL_EXTERNAL, DECL_FRIEND_P, DECL_IN_AGGR_P, DECL_INITIAL, DECL_NAME, DECL_NONLOCAL, DECL_P, DECL_PURE_VIRTUAL_P, digest_init(), do_class_using_decl(), error(), error_mark_node, error_operand_p, FIELD, finish_static_data_member_decl(), flags, gcc_assert, gcc_unreachable, grok_special_member_properties(), grokdeclarator(), cp_declarator::id, IDENTIFIER_POINTER, integer_zerop(), integral_constant_value(), cp_declarator::kind, LOOKUP_ONLYCONVERTING, NULL_TREE, pedantic, processing_template_decl, push_template_decl(), set_user_assembler_name(), sorry(), strcmp(), TREE_CHAIN, TREE_CODE, TREE_CONSTANT, TREE_STATIC, TREE_STRING_POINTER, TREE_TYPE, TREE_VALUE, cp_declarator::u, and void_type_node.
| static GTY | ( | () | ) | [static] |
Definition at line 96 of file decl2.c.
References at_eof, build_exception_variant(), build_method_type_directly(), cp_build_qualified_type, TREE_CHAIN, TREE_CODE, TREE_TYPE, TYPE_ARG_TYPES, TYPE_QUAL_RESTRICT, TYPE_RAISES_EXCEPTIONS, and TYPE_UNQUALIFIED.
Definition at line 1418 of file decl2.c.
References CLASSTYPE_IMPLICIT_INSTANTIATION, CLASSTYPE_INTERFACE_KNOWN, CLASSTYPE_INTERFACE_ONLY, CLASSTYPE_KEY_METHOD, gcc_target::cxx, DECL_DECLARED_INLINE_P, DECL_REALLY_EXTERN, flag_implicit_templates, flag_weak, gcc_assert, gcc_target::cxx::import_export_class, lookup_attribute(), MULTIPLE_SYMBOL_SPACES, repo_export_class_p(), SET_CLASSTYPE_INTERFACE_KNOWN, targetm, TYPE_ATTRIBUTES, and TYPE_POLYMORPHIC_P.
Definition at line 1744 of file decl2.c.
References CLASS_TYPE_P, CLASSTYPE_EXPLICIT_INSTANTIATION, CLASSTYPE_IMPLICIT_INSTANTIATION, CLASSTYPE_INTERFACE_KNOWN, CLASSTYPE_INTERFACE_ONLY, CLASSTYPE_KEY_METHOD, CLASSTYPE_USE_TEMPLATE, comdat_linkage(), DECL_ARTIFICIAL, DECL_CONTEXT, DECL_DECLARED_INLINE_P, DECL_EXTERNAL, DECL_FRIEND_PSEUDO_TEMPLATE_INSTANTIATION, DECL_FUNCTION_MEMBER_P, DECL_IMPLICIT_INSTANTIATION, DECL_INTERFACE_KNOWN, DECL_MAYBE_IN_CHARGE_CONSTRUCTOR_P, DECL_MAYBE_IN_CHARGE_DESTRUCTOR_P, DECL_NAME, DECL_NOT_REALLY_EXTERN, DECL_REALLY_EXTERN, DECL_TEMPLATE_INSTANTIATION, DECL_TINFO_P, DECL_VINDEX, DECL_VTABLE_OR_VTT_P, flag_implement_inlines, flag_implicit_inline_templates, flag_implicit_templates, flag_rtti, flag_weak, FOR_EACH_CLONE, gcc_assert, import_export_class(), mark_needed(), maybe_make_one_only(), repo_emit_p(), TARGET_WEAK_NOT_IN_ARCHIVE_TOC, TREE_CODE, TREE_PUBLIC, TREE_TYPE, TYPE_FOR_JAVA, and TYPE_POLYMORPHIC_P.
Definition at line 3274 of file decl2.c.
References assemble_external(), current_function_decl, DECL_ARTIFICIAL, DECL_CLASS_SCOPE_P, DECL_CONTEXT, DECL_DECLARED_INLINE_P, DECL_DEFERRED_FN, DECL_EXPLICIT_INSTANTIATION, DECL_INITIAL, DECL_INITIALIZED_BY_CONSTANT_EXPRESSION_P, DECL_INLINE, DECL_LANG_SPECIFIC, DECL_NON_THUNK_FUNCTION_P, DECL_NONSTATIC_MEMBER_FUNCTION_P, DECL_SOURCE_LOCATION, DECL_TEMPLATE_INFO, DECL_TEMPLATE_RESULT, DECL_THUNK_P, dependent_type_p(), HOST_WIDE_INT, input_location, instantiate_decl(), note_vague_linkage_fn(), processing_template_decl, skip_evaluation, synthesize_method(), template_for_substitution(), TREE_ASM_WRITTEN, TREE_CODE, and TREE_USED.
Definition at line 1295 of file decl2.c.
References CONSTRUCTOR_ELTS, DECL_INITIAL, DECL_THUNK_P, mark_used(), STRIP_NOPS, TREE_ADDRESSABLE, TREE_CHAIN, TREE_CODE, TREE_OPERAND, TREE_VALUE, and use_thunk().
Definition at line 1581 of file decl2.c.
References CLASSTYPE_DEBUG_REQUESTED, CLASSTYPE_VTABLES, gcc_target::cxx, DECL_COMDAT, DECL_EXTERNAL, DECL_INITIAL, decl_needed_p(), DECL_NOT_REALLY_EXTERN, determine_key_method(), flag_syntax_only, gcc_assert, import_export_decl(), gcc_target::cxx::key_method_may_be_inline, mark_vtable_entries(), note_debug_info_needed(), rest_of_decl_compilation(), store_init_value(), targetm, TREE_ASM_WRITTEN, TREE_CHAIN, TREE_TYPE, var_finalized_p(), and void_type_node.
Definition at line 1383 of file decl2.c.
References DECL_COMDAT, DECL_EXPLICIT_INSTANTIATION, DECL_TEMPLATE_SPECIALIZATION, flag_weak, make_decl_one_only(), mark_decl_referenced(), TARGET_WEAK_NOT_IN_ARCHIVE_TOC, and TREE_CODE.
Definition at line 191 of file decl2.c.
References arg_types, build_artificial_parm(), build_exception_variant(), build_method_type_directly(), CLASSTYPE_VBASECLASSES, DECL_ARGUMENTS, DECL_CONSTRUCTOR_P, DECL_CONTEXT, DECL_HAS_IN_CHARGE_PARM_P, DECL_HAS_VTT_PARM_P, hash_tree_chain(), in_charge_identifier, integer_type_node, processing_template_decl, TREE_CHAIN, TREE_TYPE, TREE_VALUE, TYPE_ARG_TYPES, TYPE_RAISES_EXCEPTIONS, vtt_parm_identifier, and vtt_parm_type.
Definition at line 751 of file decl2.c.
References VARRAY_PUSH_TREE, and VARRAY_TREE_INIT.
Referenced by finish_static_data_member_decl().
Definition at line 2567 of file decl2.c.
References DECL_EXTERNAL, error_mark_node, gcc_assert, NULL_TREE, result, TREE_CHAIN, TREE_CODE, TREE_PURPOSE, TREE_VALUE, and value_member().
Definition at line 2104 of file decl2.c.
References build_modify_expr(), convert(), get_guard_bits(), integer_one_node, same_type_p, and TREE_TYPE.
| static tree start_objects | ( | int | method_type, | |
| int | initp | |||
| ) | [static] |
Definition at line 2120 of file decl2.c.
References BCS_FN_BODY, begin_compound_stmt(), build_function_type(), build_lang_decl(), current_function_decl, DECL_GLOBAL_CTOR_P, DECL_GLOBAL_DTOR_P, DECL_INLINE, DECL_LANG_SPECIFIC, DECL_UNINLINABLE, DEFAULT_INIT_PRIORITY, get_file_function_name_long(), gcc_target::have_ctors_dtors, JOINER, NULL_TREE, SF_PRE_PARSED, sprintf(), start_preparsed_function(), targetm, TREE_PUBLIC, TREE_USED, void_list_node, and void_type_node.
Definition at line 2375 of file decl2.c.
References begin_if_stmt(), build_int_cst(), build_unary_op(), cond, cp_build_binary_op, current_function_decl, DECL_COMMON, DECL_CONTEXT, DECL_INIT_PRIORITY, DECL_ONE_ONLY, DECL_SOURCE_LOCATION, DECL_STATIC_FUNCTION_P, DECL_WEAK, DEFAULT_INIT_PRIORITY, priority_info_s::destructions_p, finish_expr_stmt(), finish_if_stmt_cond(), flag_use_cxa_atexit, gcc_assert, get_guard(), get_guard_cond(), get_priority_info(), priority_info_s::initializations_p, input_location, integer_one_node, integer_zero_node, member_p(), NULL_TREE, pi, set_guard(), and TREE_PUBLIC.
| static tree start_static_storage_duration_function | ( | unsigned | ) | [static] |
Referenced by cp_finish_file(), and finish_file().
Definition at line 1486 of file decl2.c.
References cgraph_varpool_node().
Referenced by cp_finish_file(), maybe_emit_vtables(), and write_out_vars().
Definition at line 2619 of file decl2.c.
References import_export_decl(), rest_of_decl_compilation(), TREE_CHAIN, TREE_VALUE, and var_finalized_p().
Definition at line 54 of file c-common.c.
1.5.6