]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
analyzer: remove redundant 'pp' [PR116613]
authorDavid Malcolm <dmalcolm@redhat.com>
Fri, 20 Sep 2024 22:51:55 +0000 (18:51 -0400)
committerDavid Malcolm <dmalcolm@redhat.com>
Fri, 20 Sep 2024 22:51:55 +0000 (18:51 -0400)
diagnostic_manager::emit_saved_diagnostic makes a useless clone
of global_dc->m_printer; remove it.

No functional change intended.

gcc/analyzer/ChangeLog:
PR other/116613
* diagnostic-manager.cc (diagnostic_manager::emit_saved_diagnostic):
Remove remove redundant 'pp'.

Signed-off-by: David Malcolm <dmalcolm@redhat.com>
gcc/analyzer/diagnostic-manager.cc

index 4a5a95136156884330a2cbdf84a560df126726e3..2363ae5df19c9d9053001f86ea081a8f8564f0fc 100644 (file)
@@ -1561,8 +1561,6 @@ diagnostic_manager::emit_saved_diagnostic (const exploded_graph &eg,
        sd.get_index (), sd.m_d->get_kind (), sd.m_snode->m_index);
   log ("num dupes: %i", sd.get_num_dupes ());
 
-  pretty_printer *pp = global_dc->m_printer->clone ();
-
   const exploded_path *epath = sd.get_best_epath ();
   gcc_assert (epath);
 
@@ -1645,7 +1643,6 @@ diagnostic_manager::emit_saved_diagnostic (const exploded_graph &eg,
          free (filename);
        }
     }
-  delete pp;
 }
 
 /* Emit a "path" of events to EMISSION_PATH describing the exploded path