gcc/
authorrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 25 Jun 2015 17:07:16 +0000 (17:07 +0000)
committerrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 25 Jun 2015 17:07:16 +0000 (17:07 +0000)
* hash-traits.h (typed_noop_remove): Don't require a pointer type.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@224963 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/hash-traits.h

index 3a7e1b0..5bd35bd 100644 (file)
@@ -1,5 +1,9 @@
 2015-06-25  Richard Sandiford  <richard.sandiford@arm.com>
 
+       * hash-traits.h (typed_noop_remove): Don't require a pointer type.
+
+2015-06-25  Richard Sandiford  <richard.sandiford@arm.com>
+
        * hash-table.h (has_is_deleted, is_deleted_helper): Delete.
        (has_is_empty, is_empty_helper): Delete.
        (has_mark_deleted, mark_deleted_helper): Delete.
index 5fd43f1..c8314e5 100644 (file)
@@ -44,7 +44,7 @@ typed_free_remove <Type>::remove (Type *p)
 template <typename Type>
 struct typed_noop_remove
 {
-  static inline void remove (Type *p);
+  static inline void remove (Type &);
 };
 
 
@@ -52,7 +52,7 @@ struct typed_noop_remove
 
 template <typename Type>
 inline void
-typed_noop_remove <Type>::remove (Type *p ATTRIBUTE_UNUSED)
+typed_noop_remove <Type>::remove (Type &)
 {
 }
 
@@ -169,7 +169,7 @@ struct ggc_cache_remove : ggc_remove<T>
    is deleted.  */
 
 template <typename T>
-struct nofree_ptr_hash : pointer_hash <T>, typed_noop_remove <T> {};
+struct nofree_ptr_hash : pointer_hash <T>, typed_noop_remove <T *> {};
 
 /* Traits for pointer elements that should be freed via free() when an
    element is deleted.  */