Hi.

It's a small refactoring patch that I've just tested.

Patch can bootstrap on x86_64-linux-gnu and survives regression tests.

I'm going to install the patch.
Thanks,
Martin

gcc/ChangeLog:

2019-11-05  Martin Liska  <mli...@suse.cz>

        * symbol-summary.h: Use ggc_delete.
---
 gcc/symbol-summary.h | 10 ++--------
 1 file changed, 2 insertions(+), 8 deletions(-)


diff --git a/gcc/symbol-summary.h b/gcc/symbol-summary.h
index 8aedcfe9143..a5e20e547a1 100644
--- a/gcc/symbol-summary.h
+++ b/gcc/symbol-summary.h
@@ -69,10 +69,7 @@ protected:
   void release (T *item)
   {
     if (is_ggc ())
-      {
-	item->~T ();
-	ggc_free (item);
-      }
+      ggc_delete (item);
     else
       m_allocator.remove (item);
   }
@@ -562,10 +559,7 @@ protected:
   void release (T *item)
   {
     if (is_ggc ())
-      {
-	item->~T ();
-	ggc_free (item);
-      }
+      ggc_delete (item);
     else
       m_allocator.remove (item);
   }

Reply via email to