Hello, On Mon, Jun 23 2025, David Malcolm wrote: > This patch adds various support for debugging diagnostic paths and > events, intended initially for myself to help with debugging -fanalyzer.
[...] > diff --git a/gcc/analyzer/sm.cc b/gcc/analyzer/sm.cc > index 0abbdd69adf..54bd92c31ab 100644 > --- a/gcc/analyzer/sm.cc > +++ b/gcc/analyzer/sm.cc > @@ -116,9 +116,11 @@ state_machine::get_state_by_name (const char *name) const > /* Base implementation of state_machine::on_leak. */ > > std::unique_ptr<pending_diagnostic> > -state_machine::on_leak (tree var ATTRIBUTE_UNUSED) const > +state_machine::on_leak (tree var ATTRIBUTE_UNUSED, > + const program_state *old_state ATTRIBUTE_UNUSED, > + const program_state *new_state ATTRIBUTE_UNUSED) const > { > - return NULL; > + return nullptr; > } > > /* Dump a multiline representation of this state machine to PP. */ > @@ -158,6 +160,21 @@ state_machine::to_json () const > return sm_obj; > } > > +void > +state_machine::add_state_to_xml (xml_state &out_xml, > + const svalue &sval, > + state_machine::state_t state) const > +{ > + // no-op > +} I am somewhat surprised this does not trigger a warning about unused parameters during bootstrap. It does when this is built with clang. Could we perhaps remove the names and leave just the types to indicate this is desirable? > + > +void > +state_machine::add_global_state_to_xml (xml_state &out_xml, > + state_machine::state_t state) const > +{ > + // no-op > +} Likewise here? I am also perfectly happy with filtering this out in contrib/filter-clang-warnings.py if we want to keep this as-is. Thanks, Martin