diff options
author | David Malcolm <dmalcolm@redhat.com> | 2023-11-14 14:01:55 -0500 |
---|---|---|
committer | David Malcolm <dmalcolm@redhat.com> | 2023-11-14 14:01:55 -0500 |
commit | 07e568d77f364e833193dd6f7b3170b28b1e52db (patch) | |
tree | b2ab11ae4ae0a38d4f5740aa0c55ef9e9c554b1e /gcc/tree-diagnostic-path.cc | |
parent | d0bfd6ba3ba77fd372c1d3621521693b653cf8b1 (diff) | |
download | gcc-07e568d77f364e833193dd6f7b3170b28b1e52db.zip gcc-07e568d77f364e833193dd6f7b3170b28b1e52db.tar.gz gcc-07e568d77f364e833193dd6f7b3170b28b1e52db.tar.bz2 |
diagnostics: make m_text_callbacks private
No functional change intended.
gcc/ChangeLog:
* diagnostic-show-locus.cc (diagnostic_context::show_locus):
Update for renaming of text callbacks fields.
* diagnostic.cc (diagnostic_context::initialize): Likewise.
* diagnostic.h (class diagnostic_context): Add "friend" for
accessors to m_text_callbacks.
(diagnostic_context::m_text_callbacks): Make private, and add an
"m_" prefix to field names.
(diagnostic_starter): Convert from macro to inline function.
(diagnostic_start_span): New.
(diagnostic_finalizer): Convert from macro to inline function.
gcc/fortran/ChangeLog:
* error.cc (gfc_diagnostics_init): Use diagnostic_start_span.
gcc/ChangeLog:
* selftest-diagnostic.cc
(test_diagnostic_context::test_diagnostic_context): Use
diagnostic_start_span.
* tree-diagnostic-path.cc (struct event_range): Likewise.
gcc/testsuite:
* gcc.dg/plugin/diagnostic_group_plugin.c: Use
diagnostic_start_span.
Signed-off-by: David Malcolm <dmalcolm@redhat.com>
Diffstat (limited to 'gcc/tree-diagnostic-path.cc')
-rw-r--r-- | gcc/tree-diagnostic-path.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/tree-diagnostic-path.cc b/gcc/tree-diagnostic-path.cc index d2345c8..3cd9c21 100644 --- a/gcc/tree-diagnostic-path.cc +++ b/gcc/tree-diagnostic-path.cc @@ -206,7 +206,7 @@ struct event_range = linemap_client_expand_location_to_spelling_point (line_table, initial_loc, LOCATION_ASPECT_CARET); if (exploc.file != LOCATION_FILE (dc->m_last_location)) - dc->m_text_callbacks.start_span (dc, exploc); + diagnostic_start_span (dc) (dc, exploc); } /* If we have an UNKNOWN_LOCATION (or BUILTINS_LOCATION) as the |