]> gcc.gnu.org Git - gcc.git/commit
diagnostics: make m_text_callbacks private
authorDavid Malcolm <dmalcolm@redhat.com>
Tue, 14 Nov 2023 19:01:55 +0000 (14:01 -0500)
committerDavid Malcolm <dmalcolm@redhat.com>
Tue, 14 Nov 2023 19:01:55 +0000 (14:01 -0500)
commit07e568d77f364e833193dd6f7b3170b28b1e52db
treeb2ab11ae4ae0a38d4f5740aa0c55ef9e9c554b1e
parentd0bfd6ba3ba77fd372c1d3621521693b653cf8b1
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>
gcc/diagnostic-show-locus.cc
gcc/diagnostic.cc
gcc/diagnostic.h
gcc/fortran/error.cc
gcc/selftest-diagnostic.cc
gcc/testsuite/gcc.dg/plugin/diagnostic_group_plugin.c
gcc/tree-diagnostic-path.cc
This page took 0.067585 seconds and 5 git commands to generate.