diff options
author | Nathan Sidwell <nathan@gcc.gnu.org> | 2004-08-24 16:39:43 +0000 |
---|---|---|
committer | Nathan Sidwell <nathan@gcc.gnu.org> | 2004-08-24 16:39:43 +0000 |
commit | 8c1d6d62a680bf67cb921c550662306b4cb3a67b (patch) | |
tree | 68fa8feee0d0759d7e8c1a8d496ea0bff1000fc3 /gcc/tree.c | |
parent | 436529eae35b089720e402b3e9354b7786ea2c38 (diff) | |
download | gcc-8c1d6d62a680bf67cb921c550662306b4cb3a67b.zip gcc-8c1d6d62a680bf67cb921c550662306b4cb3a67b.tar.gz gcc-8c1d6d62a680bf67cb921c550662306b4cb3a67b.tar.bz2 |
c-decl.c (c_init_decl_processing): Adjust build_common_tree_nodes call.
* c-decl.c (c_init_decl_processing): Adjust
build_common_tree_nodes call.
* expmed.c (const_mult_add_overflow_p): Use
build_distinct_type_copy.
* stor-layout.c (early_type_list): Remove.
(layout_type): Don't append to early_type_list.
(initialize_sizetypes): Add signed_p argument.
(set_sizetype): Overwrite the stub type nodes directly.
* tree.c (copy_node_stat): Clear a type's value cache here ...
(build_distinct_type): ... not here.
(build_common_tree_nodes): Add signed_sizetype argument. Adjust.
* tree.h (initialize_sizetypes): Add signed_p argument.
(build_common_tree_nodes): Likewise.
* ada/utils.c (gnat_init_decl_processing): Adjust
build_common_tree_nodes call.
* cp/decl.c (cxx_init_decl_processing): Adjust
build_common_tree_nodes call.
* fortran/f95-lang.c (gfc_init_decl_processing): Adjust
build_common_tree_nodes call.
* java/decl.c (java_init_decl_processing): Adjust
initialize_sizetypes call.
* objc/objc-act.c (get_static_reference): Use
build_variant_type_copy.
(get_protocol_reference): Likewise.
* objc/objc-act.h (TREE_STATIC_TEMPLATE): Use TREE_PRIVATE.
* treelang/treetree.c (treelang_init_decl_processing): Adjust
build_common_tree_nodes call.
From-SVN: r86493
Diffstat (limited to 'gcc/tree.c')
-rw-r--r-- | gcc/tree.c | 20 |
1 files changed, 9 insertions, 11 deletions
@@ -392,6 +392,13 @@ copy_node_stat (tree node MEM_STAT_DECL) but the optimizer should catch that. */ TYPE_SYMTAB_POINTER (t) = 0; TYPE_SYMTAB_ADDRESS (t) = 0; + + /* Do not copy the values cache. */ + if (TYPE_CACHED_VALUES_P(t)) + { + TYPE_CACHED_VALUES_P (t) = 0; + TYPE_CACHED_VALUES (t) = NULL_TREE; + } } return t; @@ -3141,15 +3148,6 @@ build_distinct_type_copy (tree type) { tree t = copy_node (type); - if (TYPE_CACHED_VALUES_P(t)) - { - /* Do not copy the values cache. */ - if (TREE_CODE (t) == INTEGER_TYPE && TYPE_IS_SIZETYPE (t)) - abort (); - TYPE_CACHED_VALUES_P (t) = 0; - TYPE_CACHED_VALUES (t) = NULL_TREE; - } - TYPE_POINTER_TO (t) = 0; TYPE_REFERENCE_TO (t) = 0; @@ -5374,12 +5372,12 @@ make_or_reuse_type (unsigned size, int unsignedp) this function to select one of the types as sizetype. */ void -build_common_tree_nodes (int signed_char) +build_common_tree_nodes (bool signed_char, bool signed_sizetype) { error_mark_node = make_node (ERROR_MARK); TREE_TYPE (error_mark_node) = error_mark_node; - initialize_sizetypes (); + initialize_sizetypes (signed_sizetype); /* Define both `signed char' and `unsigned char'. */ signed_char_type_node = make_signed_type (CHAR_TYPE_SIZE); |