cp-tree.h (build_shared_int_cst): Remove.
authorNathan Sidwell <nathan@codesourcery.com>
Thu, 19 Aug 2004 11:17:01 +0000 (11:17 +0000)
committerNathan Sidwell <nathan@gcc.gnu.org>
Thu, 19 Aug 2004 11:17:01 +0000 (11:17 +0000)
* cp-tree.h (build_shared_int_cst): Remove.
* tree.c (shared_int_cache): Remove.
(build_shared_int_cst): Remove.
* class.c (finish_struct_1): Use build_int_cst.

From-SVN: r86249

gcc/cp/ChangeLog
gcc/cp/class.c
gcc/cp/cp-tree.h
gcc/cp/tree.c

index 0cd1b21d32ec66a6815f34aaeef84c65f963acda..85d5038ae54d85d8c09b3a2a2690591ae11adb58 100644 (file)
@@ -1,3 +1,10 @@
+2004-08-19  Nathan Sidwell  <nathan@codesourcery.com>
+
+       * cp-tree.h (build_shared_int_cst): Remove.
+       * tree.c (shared_int_cache): Remove.
+       (build_shared_int_cst): Remove.
+       * class.c (finish_struct_1): Use build_int_cst.
+
 2004-08-19  Nathan Sidwell  <nathan@codesourcery.com>
 
        * decl.c (finish_enum): Do not copy value node early, copy
index 7c16791d25851bcc42b63ffaa0d1be097173ff8d..1989dca91af04dd4ef9d98cd372928c28e7d3909 100644 (file)
@@ -5085,7 +5085,7 @@ finish_struct_1 (tree t)
               thunk base function.  */
            DECL_VINDEX (fndecl) = NULL_TREE;
          else if (TREE_CODE (DECL_VINDEX (fndecl)) != INTEGER_CST)
-           DECL_VINDEX (fndecl) = build_shared_int_cst (vindex);
+           DECL_VINDEX (fndecl) = build_int_cst (NULL_TREE, vindex, 0);
        }
     }
 
index 04a39b7d08b81575d4037600435bc577388b485b..b0f2697d781b6adeaf6b491d47be9ce5657466c7 100644 (file)
@@ -4246,7 +4246,6 @@ extern tree cp_build_type_attribute_variant     (tree, tree);
 extern tree cp_build_qualified_type_real        (tree, int, tsubst_flags_t);
 #define cp_build_qualified_type(TYPE, QUALS) \
   cp_build_qualified_type_real ((TYPE), (QUALS), tf_error | tf_warning)
-extern tree build_shared_int_cst                (int);
 extern special_function_kind special_function_p (tree);
 extern bool name_p                              (tree);
 extern int count_trees                          (tree);
index aede4a6ccf73c8d04044a0f54ed32310a4b97f6e..a7309dd0b80f3c7b0f737b13af882b464ebaede0 100644 (file)
@@ -1366,25 +1366,6 @@ build_min_non_dep (enum tree_code code, tree non_dep, ...)
   return t;
 }
 
-/* Returns an INTEGER_CST (of type `int') corresponding to I.
-   Multiple calls with the same value of I may or may not yield the
-   same node; therefore, callers should never modify the node
-   returned.  */
-
-static GTY(()) tree shared_int_cache[256];
-
-tree
-build_shared_int_cst (int i)
-{
-  if (i >= 256)
-    return build_int_cst (NULL_TREE, i, 0);
-
-  if (!shared_int_cache[i])
-    shared_int_cache[i] = build_int_cst (NULL_TREE, i, 0);
-
-  return shared_int_cache[i];
-}
-
 tree
 get_type_decl (tree t)
 {