When compiling diagnostic-path-output.cc with clang, it warns that
path_label::get_effects should be marked as override. That looks like
a good idea and from a brief look I also believe it should be marked
as final (the other override in the class is marked as both), so this
patch does that.
Likewise for html_output_format::after_diagnostic in
diagnostic-format-html.cc which also already has quite a few member
functions marked as final override.
gcc/ChangeLog:
2025-06-24 Martin Jambor <mjambor@suse.cz>
* diagnostic-path-output.cc (path_label::get_effects): Mark as
final override.
* diagnostic-format-html.cc
(html_output_format::after_diagnostic): Likewise.
{
m_builder.emit_diagram (diagram);
}
- void after_diagnostic (const diagnostic_info &)
+ void after_diagnostic (const diagnostic_info &) final override
{
/* No-op, but perhaps could show paths here. */
}
return result;
}
- const label_effects *get_effects (unsigned /*range_idx*/) const
+ const label_effects *get_effects (unsigned /*range_idx*/) const final override
{
return &m_effects;
}