diff options
author | Trevor Saunders <tsaunders@mozilla.com> | 2014-08-02 11:23:49 +0000 |
---|---|---|
committer | Trevor Saunders <tbsaunde@gcc.gnu.org> | 2014-08-02 11:23:49 +0000 |
commit | 6e2830c3dbe0d4972519ddd44bd1b15b2b274ba2 (patch) | |
tree | f0fb192e856fa98b7d91e225ff958dfcc1f602df /gcc/fortran/trans-decl.c | |
parent | 2df06cec0a2fe611c5487bf54c4ef8e3b2b30543 (diff) | |
download | gcc-6e2830c3dbe0d4972519ddd44bd1b15b2b274ba2.zip gcc-6e2830c3dbe0d4972519ddd44bd1b15b2b274ba2.tar.gz gcc-6e2830c3dbe0d4972519ddd44bd1b15b2b274ba2.tar.bz2 |
add a hash_set based on hash_table
This allows us to replace the usage of pointer_set outside of
pointer_map with a nicer interface.
gcc/ada/
* gcc-interface/trans.c: Use hash_set instead of pointer_set.
gcc/c-family/
* c-gimplify.c: Use hash_set instead of pointer_set.
gcc/c/
* c-decl.c: Use hash_set instead of pointer_set.
gcc/cp/
* class.c, cp-gimplify.c, cp-tree.h, decl.c, decl2.c, error.c,
method.c, name-lookup.c, pt.c, semantics.c, tree.c: Use hash_set
instead of pointer_set.
gcc/fortran/
* openmp.c, trans-decl.c: Use hash_set instead of pointer_set.
gcc/
* hash-set.h: new File.
* cfgexpand.c, cfgloop.c, cgraph.c, cgraphbuild.c, cgraphunit.c,
cprop.c, cse.c, gimple-walk.c, gimple-walk.h, gimplify.c, godump.c,
ipa-devirt.c, ipa-pure-const.c, ipa-visibility.c, ipa.c, lto-cgraph.c,
lto-streamer-out.c, stmt.c, tree-cfg.c, tree-core.h, tree-eh.c,
tree-inline.c, tree-inline.h, tree-nested.c, tree-pretty-print.c,
tree-ssa-loop-niter.c, tree-ssa-phiopt.c, tree-ssa-threadedge.c,
tree-ssa-uninit.c, tree.c, tree.h, value-prof.c, varasm.c,
varpool.c: Use hash_set instead of pointer_set.
gcc/lto/
* lto-partition.c, lto-partition.h: Use hash_set instead of
pointer_set.
From-SVN: r213516
Diffstat (limited to 'gcc/fortran/trans-decl.c')
-rw-r--r-- | gcc/fortran/trans-decl.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/gcc/fortran/trans-decl.c b/gcc/fortran/trans-decl.c index 8b56151..babe48f 100644 --- a/gcc/fortran/trans-decl.c +++ b/gcc/fortran/trans-decl.c @@ -40,7 +40,7 @@ along with GCC; see the file COPYING3. If not see #include "cgraph.h" #include "debug.h" #include "gfortran.h" -#include "pointer-set.h" +#include "hash-set.h" #include "constructor.h" #include "trans.h" #include "trans-types.h" @@ -63,7 +63,7 @@ static GTY(()) tree parent_fake_result_decl; static GTY(()) tree saved_function_decls; static GTY(()) tree saved_parent_function_decls; -static struct pointer_set_t *nonlocal_dummy_decl_pset; +static hash_set<tree> *nonlocal_dummy_decl_pset; static GTY(()) tree nonlocal_dummy_decls; /* Holds the variable DECLs that are locals. */ @@ -1094,9 +1094,9 @@ gfc_nonlocal_dummy_array_decl (gfc_symbol *sym) tree decl, dummy; if (! nonlocal_dummy_decl_pset) - nonlocal_dummy_decl_pset = pointer_set_create (); + nonlocal_dummy_decl_pset = new hash_set<tree>; - if (pointer_set_insert (nonlocal_dummy_decl_pset, sym->backend_decl)) + if (nonlocal_dummy_decl_pset->add (sym->backend_decl)) return; dummy = GFC_DECL_SAVED_DESCRIPTOR (sym->backend_decl); @@ -5861,7 +5861,7 @@ gfc_generate_function_code (gfc_namespace * ns) { BLOCK_VARS (DECL_INITIAL (fndecl)) = chainon (BLOCK_VARS (DECL_INITIAL (fndecl)), nonlocal_dummy_decls); - pointer_set_destroy (nonlocal_dummy_decl_pset); + delete nonlocal_dummy_decl_pset; nonlocal_dummy_decls = NULL; nonlocal_dummy_decl_pset = NULL; } |