21#ifndef GCC_DIAGNOSTIC_H
22#define GCC_DIAGNOSTIC_H
25#include "rich-location.h"
234 void init (
int n_opts);
242 void pop (location_t where);
366 bool colorize)
const;
408 const rich_location &richloc,
459 void dump (FILE *out,
int indent)
const;
529 void dump (FILE *out)
const;
547 bool should_skip_bom);
563 rich_location &richloc,
566 const char *gmsgid, ...)
569 rich_location &richloc,
572 const
char *gmsgid, va_list *
ap)
606 void set_output_format (std::unique_ptr<diagnostic_output_format> output_format);
720 const char *,
const char *, va_list *,
762 add_sink (std::unique_ptr<diagnostic_output_format>);
1028#define diagnostic_context_auxiliary_data(DC) (DC)->m_client_aux_data
1029#define diagnostic_info_auxiliary_data(DI) (DI)->x_data
1045#define errorcount global_dc->diagnostic_count (DK_ERROR)
1047#define warningcount global_dc->diagnostic_count (DK_WARNING)
1049#define werrorcount global_dc->diagnostic_count (DK_WERROR)
1051#define sorrycount global_dc->diagnostic_count (DK_SORRY)
1054#define diagnostic_report_warnings_p(DC, LOC) \
1055 (!(DC)->m_inhibit_warnings \
1056 && !(in_system_header_at (LOC) && !(DC)->m_warn_system_headers))
1096 rich_location *richloc,
1125 bool should_skip_bom)
1170#ifdef ATTRIBUTE_GCC_DIAG
1174 va_list *, rich_location *,
1196 return diagnostic->message.get_location (which);
1204 return diagnostic->message.m_richloc->get_num_locations ();
1211inline expanded_location
1214 return diagnostic->richloc->get_expanded_location (which);
1228 expanded_location s1, expanded_location s2)
1230 return (s2.column && s1.line == s2.line
1232 > abs (s1.column - s2.column)));
Definition diagnostic-buffer.h:57
Definition diagnostic-client-data-hooks.h:31
Definition diagnostic.h:358
label_text get_location_text(const expanded_location &s, bool show_column, bool colorize) const
Definition diagnostic.cc:705
enum diagnostics_column_unit m_column_unit
Definition diagnostic.h:372
int m_column_origin
Definition diagnostic.h:373
diagnostic_column_policy(const diagnostic_context &dc)
Definition diagnostic.cc:681
int converted_column(expanded_location s) const
Definition diagnostic.cc:693
int m_tabstop
Definition diagnostic.h:374
int get_tabstop() const
Definition diagnostic.h:368
file_cache & m_file_cache
Definition diagnostic.h:371
Definition diagnostic.h:504
void action_after_output(diagnostic_t diag_kind)
Definition diagnostic.cc:877
int diagnostic_count(diagnostic_t kind) const
Definition diagnostic.h:675
bool bool emit_diagnostic_with_group_va(diagnostic_t kind, rich_location &richloc, const diagnostic_metadata *metadata, diagnostic_option_id option_id, const char *gmsgid, va_list *ap) ATTRIBUTE_GCC_DIAG(6
Definition diagnostic.cc:1303
int m_tabstop
Definition diagnostic.h:924
void initialize(int n_opts)
Definition diagnostic.cc:222
file_cache * m_file_cache
Definition diagnostic.h:790
bool execution_failed_p() const
Definition diagnostic.cc:458
void set_show_rules(bool val)
Definition diagnostic.h:622
void get_any_inlining_info(diagnostic_info *diagnostic)
Definition diagnostic.cc:1133
enum diagnostic_path_format m_path_format
Definition diagnostic.h:813
void finish()
Definition diagnostic.cc:382
void set_urlifier(std::unique_ptr< urlifier >)
Definition diagnostic.cc:534
pretty_printer * get_reference_printer() const
Definition diagnostic.h:756
void end_group()
Definition diagnostic.cc:1716
void error_recursion() ATTRIBUTE_NORETURN
Definition diagnostic.cc:1648
int m_diagnostic_nesting_level
Definition diagnostic.h:943
void set_escape_format(enum diagnostics_escape_format val)
Definition diagnostic.h:631
bool diagnostic_enabled(diagnostic_info *diagnostic)
Definition diagnostic.cc:1217
bool m_show_option_requested
Definition diagnostic.h:820
void set_set_locations_callback(set_locations_callback_t cb)
Definition diagnostic.h:540
void DEBUG_FUNCTION dump() const
Definition diagnostic.h:530
bool m_report_bug
Definition diagnostic.h:909
void refresh_output_sinks()
Definition diagnostic.cc:555
edit_context * get_edit_context() const
Definition diagnostic.h:659
void push_nesting_level()
Definition diagnostic.cc:1731
void set_format_decoder(printer_fn format_decoder)
Definition diagnostic.cc:565
void set_path_format(enum diagnostic_path_format val)
Definition diagnostic.h:624
friend diagnostic_text_starter_fn & diagnostic_text_starter(diagnostic_context *context)
Definition diagnostic.h:1005
void set_diagnostic_buffer(diagnostic_buffer *)
Definition diagnostic.cc:1842
void set_max_errors(int val)
Definition diagnostic.h:630
diagnostic_start_span_fn m_start_span
Definition diagnostic.h:866
int pch_restore(FILE *f)
Definition diagnostic.h:737
void set_option_manager(std::unique_ptr< diagnostic_option_manager > mgr, unsigned lang_mask)
Definition diagnostic.cc:525
enum diagnostics_extra_output_kind m_extra_output_kind
Definition diagnostic.h:914
bool m_inhibit_warnings
Definition diagnostic.h:843
int m_emission_count
Definition diagnostic.h:947
friend diagnostic_text_finalizer_fn & diagnostic_text_finalizer(diagnostic_context *context)
Definition diagnostic.h:1022
diagnostic_output_format & get_output_format(size_t idx) const
Definition diagnostic.cc:477
bool m_show_column
Definition diagnostic.h:827
void add_sink(std::unique_ptr< diagnostic_output_format >)
Definition diagnostic.cc:485
bool bool diagnostic_n_impl(rich_location *, const diagnostic_metadata *, diagnostic_option_id, unsigned HOST_WIDE_INT, const char *, const char *, va_list *, diagnostic_t) ATTRIBUTE_GCC_DIAG(7
Definition diagnostic.cc:1602
diagnostic_option_classifier m_option_classifier
Definition diagnostic.h:803
void report_verbatim(text_info &)
Definition diagnostic.cc:1508
bool m_show_path_depths
Definition diagnostic.h:816
int & diagnostic_count(diagnostic_t kind)
Definition diagnostic.h:671
struct diagnostic_context::@18 m_diagrams
char * make_option_url(diagnostic_option_id option_id) const
Definition diagnostic.h:699
void push_diagnostics(location_t where)
Definition diagnostic.h:589
void begin_group()
Definition diagnostic.cc:1710
enum diagnostics_escape_format m_escape_format
Definition diagnostic.h:929
set_locations_callback_t m_set_locations_cb
Definition diagnostic.h:961
void set_output_format(std::unique_ptr< diagnostic_output_format > output_format)
Definition diagnostic.cc:469
void set_show_path_depths(bool val)
Definition diagnostic.h:628
char * make_option_name(diagnostic_option_id option_id, diagnostic_t orig_diag_kind, diagnostic_t diag_kind) const
Definition diagnostic.h:688
diagnostic_counters m_diagnostic_counters
Definition diagnostic.h:793
std::unique_ptr< pretty_printer > clone_printer() const
Definition diagnostic.h:751
const char *const * get_original_argv()
Definition diagnostic.h:535
urlifier * get_urlifier() const
Definition diagnostic.h:667
void set_pretty_printer(std::unique_ptr< pretty_printer > pp)
Definition diagnostic.cc:545
urlifier * m_urlifier
Definition diagnostic.h:890
bool m_warn_system_headers
Definition diagnostic.h:846
struct diagnostic_context::@17 m_diagnostic_groups
char * build_indent_prefix() const
void flush_diagnostic_buffer(diagnostic_buffer &)
Definition diagnostic.cc:1892
diagnostic_text_starter_fn m_begin_diagnostic
Definition diagnostic.h:861
enum diagnostic_path_format get_path_format() const
Definition diagnostic.h:646
int pch_save(FILE *f)
Definition diagnostic.h:731
pretty_printer * m_reference_printer
Definition diagnostic.h:785
char ** m_original_argv
Definition diagnostic.h:983
diagnostic_client_data_hooks * m_client_data_hooks
Definition diagnostic.h:969
void(* m_internal_error)(diagnostic_context *, const char *, va_list *)
Definition diagnostic.h:874
bool warning_enabled_at(location_t loc, diagnostic_option_id option_id)
Definition diagnostic.cc:1261
bool m_show_cwe
Definition diagnostic.h:807
diagnostic_text_finalizer_fn m_end_diagnostic
Definition diagnostic.h:869
void * m_client_aux_data
Definition diagnostic.h:894
void set_client_data_hooks(std::unique_ptr< diagnostic_client_data_hooks > hooks)
Definition diagnostic.cc:503
diagnostic_option_manager * m_option_mgr
Definition diagnostic.h:883
void set_prefixing_rule(diagnostic_prefixing_rule_t rule)
Definition diagnostic.cc:582
void set_warning_as_error_requested(bool val)
Definition diagnostic.h:612
location_t m_last_location
Definition diagnostic.h:897
void check_max_errors(bool flush)
Definition diagnostic.cc:854
friend diagnostic_start_span_fn & diagnostic_start_span(diagnostic_context *context)
Definition diagnostic.h:1014
unsigned get_lang_mask() const
Definition diagnostic.h:710
void pop_nesting_level()
Definition diagnostic.cc:1737
enum diagnostics_escape_format get_escape_format() const
Definition diagnostic.h:647
bool emit_diagnostic_with_group(diagnostic_t kind, rich_location &richloc, const diagnostic_metadata *metadata, diagnostic_option_id option_id, const char *gmsgid,...) ATTRIBUTE_GCC_DIAG(6
Definition diagnostic.cc:1280
void set_text_art_charset(enum diagnostic_text_art_charset charset)
Definition diagnostic.cc:1809
auto_vec< diagnostic_output_format * > m_output_sinks
Definition diagnostic.h:955
text_art::theme * m_theme
Definition diagnostic.h:978
bool m_inhibit_notes_p
Definition diagnostic.h:903
bool show_path_depths_p() const
Definition diagnostic.h:644
bool supports_fnotice_on_stderr_p() const
Definition diagnostic.cc:493
void color_init(int value)
Definition diagnostic.cc:310
bool m_warning_as_error_requested
Definition diagnostic.h:796
const diagnostic_client_data_hooks * get_client_data_hooks() const
Definition diagnostic.h:663
void set_show_option_requested(bool val)
Definition diagnostic.h:629
void set_original_argv(unique_argv original_argv)
Definition diagnostic.cc:511
void urls_init(int value)
Definition diagnostic.cc:341
bool bool bool report_diagnostic(diagnostic_info *)
Definition diagnostic.cc:1326
int m_n_opts
Definition diagnostic.h:800
bool diagnostic_impl(rich_location *, const diagnostic_metadata *, diagnostic_option_id, const char *, va_list *, diagnostic_t) ATTRIBUTE_GCC_DIAG(5
Definition diagnostic.cc:1576
bool option_unspecified_p(diagnostic_option_id option_id) const
Definition diagnostic.h:557
diagnostic_t classify_diagnostic(diagnostic_option_id option_id, diagnostic_t new_kind, location_t where)
Definition diagnostic.h:579
file_cache & get_file_cache() const
Definition diagnostic.h:653
bool option_enabled_p(diagnostic_option_id option_id) const
Definition diagnostic.h:681
void pop_diagnostics(location_t where)
Definition diagnostic.h:593
bool m_pedantic_errors
Definition diagnostic.h:830
text_art::theme * get_diagram_theme() const
Definition diagnostic.h:669
int m_column_origin
Definition diagnostic.h:921
bool m_fatal_errors
Definition diagnostic.h:840
bool m_permissive
Definition diagnostic.h:833
struct diagnostic_context::@16 m_text_callbacks
void(* m_adjust_diagnostic_info)(diagnostic_context *, diagnostic_info *)
Definition diagnostic.h:878
unsigned m_lang_mask
Definition diagnostic.h:884
void create_edit_context()
Definition diagnostic.cc:599
void override_urlifier(urlifier *)
Definition diagnostic.cc:593
diagnostic_buffer * get_diagnostic_buffer() const
Definition diagnostic.h:744
enum diagnostics_column_unit m_column_unit
Definition diagnostic.h:918
void emit_diagram(const diagnostic_diagram &diagram)
Definition diagnostic.cc:1633
int m_lock
Definition diagnostic.h:900
void set_report_bug(bool val)
Definition diagnostic.h:616
bool m_show_rules
Definition diagnostic.h:810
void set_show_cwe(bool val)
Definition diagnostic.h:621
void clear_diagnostic_buffer(diagnostic_buffer &)
Definition diagnostic.cc:1876
bool bool int get_diagnostic_nesting_level() const
Definition diagnostic.h:723
int m_max_errors
Definition diagnostic.h:850
bool m_abort_on_error
Definition diagnostic.h:824
void maybe_show_locus(const rich_location &richloc, diagnostic_t diagnostic_kind, pretty_printer &pp, diagnostic_source_effect_info *effect_info)
Definition diagnostic-show-locus.cc:3266
edit_context * m_edit_context_ptr
Definition diagnostic.h:935
diagnostic_source_printing_options m_source_printing
Definition diagnostic.h:905
int m_opt_permissive
Definition diagnostic.h:837
bool warning_as_error_requested_p() const
Definition diagnostic.h:640
void(*) set_locations_callback_t(diagnostic_context *, diagnostic_info *)
Definition diagnostic.h:518
void set_extra_output_kind(enum diagnostics_extra_output_kind kind)
Definition diagnostic.h:617
int m_group_nesting_depth
Definition diagnostic.h:940
void set_show_highlight_colors(bool val)
Definition diagnostic.cc:573
diagnostic_buffer * m_diagnostic_buffer
Definition diagnostic.h:992
void initialize_input_context(diagnostic_input_charset_callback ccb, bool should_skip_bom)
Definition diagnostic.cc:373
Definition diagnostic-diagram.h:33
Definition diagnostic.h:382
diagnostic_location_print_policy(const diagnostic_context &dc)
Definition diagnostic.cc:727
bool m_show_column
Definition diagnostic.h:394
bool show_column_p() const
Definition diagnostic.h:387
const diagnostic_column_policy & get_column_policy() const
Definition diagnostic.h:390
diagnostic_column_policy m_column_policy
Definition diagnostic.h:393
Definition diagnostic.h:232
void push()
Definition diagnostic.cc:197
diagnostic_t update_effective_level_from_pragmas(diagnostic_info *diagnostic) const
Definition diagnostic.cc:1162
vec< int > m_push_list
Definition diagnostic.h:301
void fini()
Definition diagnostic.cc:142
int m_n_opts
Definition diagnostic.h:283
vec< diagnostic_classification_change_t > m_classification_history
Definition diagnostic.h:298
void pop(location_t where)
Definition diagnostic.cc:206
diagnostic_t classify_diagnostic(const diagnostic_context *context, diagnostic_option_id option_id, diagnostic_t new_kind, location_t where)
Definition diagnostic.cc:997
diagnostic_t * m_classify_diagnostic
Definition diagnostic.h:291
int pch_restore(FILE *)
Definition diagnostic.cc:174
diagnostic_t get_current_override(diagnostic_option_id option_id) const
Definition diagnostic.h:249
void init(int n_opts)
Definition diagnostic.cc:131
int pch_save(FILE *)
Definition diagnostic.cc:154
bool option_unspecified_p(diagnostic_option_id option_id) const
Definition diagnostic.h:244
Definition diagnostic.h:193
virtual ~diagnostic_option_manager()
Definition diagnostic.h:195
virtual int option_enabled_p(diagnostic_option_id option_id) const =0
virtual char * make_option_name(diagnostic_option_id option_id, diagnostic_t orig_diag_kind, diagnostic_t diag_kind) const =0
virtual char * make_option_url(diagnostic_option_id option_id) const =0
Definition diagnostic-label-effects.h:41
Definition diagnostic.h:402
text_art::theme * m_diagram_theme
Definition diagnostic.h:447
void print(pretty_printer &pp, const rich_location &richloc, diagnostic_t diagnostic_kind, diagnostic_source_effect_info *effect_info) const
Definition diagnostic-show-locus.cc:3311
file_cache & m_file_cache
Definition diagnostic.h:444
diagnostic_start_span_fn m_start_span_cb
Definition diagnostic.h:443
file_cache & get_file_cache() const
Definition diagnostic.h:419
text_art::theme * get_diagram_theme() const
Definition diagnostic.h:428
diagnostic_source_print_policy(const diagnostic_context &)
Definition diagnostic-show-locus.cc:3295
enum diagnostics_escape_format m_escape_format
Definition diagnostic.h:448
class diagnostic_location_print_policy m_location_policy
Definition diagnostic.h:442
const diagnostic_source_printing_options & get_options() const
Definition diagnostic.h:413
diagnostic_start_span_fn get_start_span_fn() const
Definition diagnostic.h:416
const diagnostic_source_printing_options & m_options
Definition diagnostic.h:441
const diagnostic_location_print_policy & get_location_policy() const
Definition diagnostic.h:435
enum diagnostics_escape_format get_escape_format() const
Definition diagnostic.h:422
const diagnostic_column_policy & get_column_policy() const
Definition diagnostic.h:430
Definition diagnostic-format-text.h:33
Definition edit-context.h:44
Definition logical-location.h:55
Definition pretty-print.h:241
virtual std::unique_ptr< pretty_printer > clone() const
Definition pretty-print.cc:2522
Definition pretty-print-urlifier.h:27
const char *(* diagnostic_input_charset_callback)(const char *)
Definition coretypes.h:171
void ATTRIBUTE_NORETURN
Definition diagnostic-core.h:105
diagnostic_t
Definition diagnostic-core.h:29
@ DK_LAST_DIAGNOSTIC_KIND
Definition diagnostic-core.h:90
#define ATTRIBUTE_GCC_DIAG(m, n)
Definition diagnostic-core.h:100
void diagnostic_set_caret_max_width(diagnostic_context *context, int value)
Definition diagnostic.cc:117
void diagnostic_set_info(diagnostic_info *, const char *, va_list *, rich_location *, diagnostic_t) ATTRIBUTE_GCC_DIAG(2
char * get_cwe_url(int cwe)
Definition diagnostic.cc:1208
location_t diagnostic_location(const diagnostic_info *diagnostic, int which=0)
Definition diagnostic.h:1194
const int CARET_LINE_MARGIN
Definition diagnostic.h:1220
diagnostics_escape_format
Definition diagnostic.h:52
@ DIAGNOSTICS_ESCAPE_FORMAT_BYTES
Definition diagnostic.h:59
@ DIAGNOSTICS_ESCAPE_FORMAT_UNICODE
Definition diagnostic.h:55
diagnostic_text_art_charset
Definition diagnostic.h:118
@ DIAGNOSTICS_TEXT_ART_CHARSET_ASCII
Definition diagnostic.h:123
@ DIAGNOSTICS_TEXT_ART_CHARSET_NONE
Definition diagnostic.h:120
@ DIAGNOSTICS_TEXT_ART_CHARSET_UNICODE
Definition diagnostic.h:127
@ DIAGNOSTICS_TEXT_ART_CHARSET_EMOJI
Definition diagnostic.h:130
const char * maybe_line_and_column(int line, int col)
Definition diagnostic-format-text.cc:620
diagnostic_t diagnostic_classify_diagnostic(diagnostic_context *context, diagnostic_option_id option_id, diagnostic_t kind, location_t where)
Definition diagnostic.h:1132
void(* diagnostic_text_finalizer_fn)(diagnostic_text_output_format &, const diagnostic_info *, diagnostic_t)
Definition diagnostic.h:185
diagnostic_path_format
Definition diagnostic.h:84
@ DPF_NONE
Definition diagnostic.h:86
@ DPF_SEPARATE_EVENTS
Definition diagnostic.h:90
@ DPF_INLINE_EVENTS
Definition diagnostic.h:96
void diagnostic_initialize_input_context(diagnostic_context *context, diagnostic_input_charset_callback ccb, bool should_skip_bom)
Definition diagnostic.h:1123
diagnostic_text_starter_fn & diagnostic_text_starter(diagnostic_context *context)
Definition diagnostic.h:1005
diagnostics_extra_output_kind
Definition diagnostic.h:103
@ EXTRA_DIAGNOSTIC_OUTPUT_none
Definition diagnostic.h:105
@ EXTRA_DIAGNOSTIC_OUTPUT_fixits_v2
Definition diagnostic.h:112
@ EXTRA_DIAGNOSTIC_OUTPUT_fixits_v1
Definition diagnostic.h:109
diagnostics_output_format
Definition diagnostic.h:65
@ DIAGNOSTICS_OUTPUT_FORMAT_SARIF_FILE
Definition diagnostic.h:79
@ DIAGNOSTICS_OUTPUT_FORMAT_JSON_STDERR
Definition diagnostic.h:70
@ DIAGNOSTICS_OUTPUT_FORMAT_TEXT
Definition diagnostic.h:67
@ DIAGNOSTICS_OUTPUT_FORMAT_SARIF_STDERR
Definition diagnostic.h:76
@ DIAGNOSTICS_OUTPUT_FORMAT_JSON_FILE
Definition diagnostic.h:73
void diagnostic_urls_init(diagnostic_context *context, int value=-1)
Definition diagnostic.h:1083
void diagnostic_abort_on_error(diagnostic_context *context)
Definition diagnostic.h:1033
void diagnostic_show_locus(diagnostic_context *context, rich_location *richloc, diagnostic_t diagnostic_kind, pretty_printer *pp, diagnostic_source_effect_info *effect_info=nullptr)
Definition diagnostic.h:1095
diagnostic_text_finalizer_fn & diagnostic_text_finalizer(diagnostic_context *context)
Definition diagnostic.h:1022
void diagnostic_inhibit_notes(diagnostic_context *context)
Definition diagnostic.h:996
int get_terminal_width(void)
Definition diagnostic.cc:96
const char * diagnostic_get_color_for_kind(diagnostic_t kind)
Definition diagnostic.cc:646
void default_diagnostic_text_finalizer(diagnostic_text_output_format &, const diagnostic_info *, diagnostic_t)
Definition diagnostic-format-text.cc:714
void default_diagnostic_start_span_fn(const diagnostic_location_print_policy &, pretty_printer *, expanded_location)
Definition diagnostic.cc:977
diagnostics_column_unit
Definition diagnostic.h:40
@ DIAGNOSTICS_COLUMN_UNIT_BYTE
Definition diagnostic.h:45
@ DIAGNOSTICS_COLUMN_UNIT_DISPLAY
Definition diagnostic.h:42
expanded_location diagnostic_expand_location(const diagnostic_info *diagnostic, int which=0)
Definition diagnostic.h:1212
diagnostic_start_span_fn & diagnostic_start_span(diagnostic_context *context)
Definition diagnostic.h:1014
const char * get_diagnostic_kind_text(diagnostic_t kind)
Definition diagnostic.cc:751
int num_digits(int)
Definition diagnostic.cc:1524
void(* diagnostic_text_starter_fn)(diagnostic_text_output_format &, const diagnostic_info *)
Definition diagnostic.h:177
bool option_unspecified_p(diagnostic_option_id option_id)
Definition diagnostic.h:1251
void(* diagnostic_start_span_fn)(const diagnostic_location_print_policy &, pretty_printer *, expanded_location)
Definition diagnostic.h:181
char * build_message_string(const char *,...) ATTRIBUTE_PRINTF_1
Definition diagnostic.cc:79
void diagnostic_finish(diagnostic_context *context)
Definition diagnostic.h:1089
bool warning_enabled_at(location_t loc, diagnostic_option_id option_id)
Definition diagnostic.h:1245
diagnostic_context * global_dc
Definition diagnostic-global-context.cc:34
unsigned int diagnostic_num_locations(const diagnostic_info *diagnostic)
Definition diagnostic.h:1202
void diagnostic_initialize(diagnostic_context *context, int n_opts)
Definition diagnostic.h:1071
void diagnostic_set_option_id(diagnostic_info *info, diagnostic_option_id option_id)
Definition diagnostic.h:1062
void diagnostic_color_init(diagnostic_context *context, int value=-1)
Definition diagnostic.h:1077
void void diagnostic_set_info_translated(diagnostic_info *, const char *, va_list *, rich_location *, diagnostic_t) ATTRIBUTE_GCC_DIAG(2
void diagnostic_pop_diagnostics(diagnostic_context *context, location_t where)
Definition diagnostic.h:1147
void diagnostic_push_diagnostics(diagnostic_context *context, location_t where)
Definition diagnostic.h:1141
bool diagnostic_same_line(const diagnostic_context *context, expanded_location s1, expanded_location s2)
Definition diagnostic.h:1227
bool diagnostic_report_diagnostic(diagnostic_context *context, diagnostic_info *diagnostic)
Definition diagnostic.h:1161
void void void default_diagnostic_text_starter(diagnostic_text_output_format &, const diagnostic_info *)
Definition diagnostic-format-text.cc:705
Definition diagnostic-diagram.h:25
bool(* printer_fn)(pretty_printer *, text_info *, const char *, int, bool, bool, bool, bool *, pp_token_list &)
Definition pretty-print.h:190
diagnostic_prefixing_rule_t
Definition pretty-print.h:66
static void const char va_list ap
Definition read-md.cc:205
Definition diagnostic.h:456
void clear()
Definition diagnostic.cc:1940
diagnostic_counters()
Definition diagnostic.cc:1908
void move_to(diagnostic_counters &dest)
Definition diagnostic.cc:1932
int get_count(diagnostic_t kind) const
Definition diagnostic.h:462
int m_count_for_kind[DK_LAST_DIAGNOSTIC_KIND]
Definition diagnostic.h:467
void DEBUG_FUNCTION dump() const
Definition diagnostic.h:460
Definition diagnostic.h:163
void * m_ao
Definition diagnostic.h:167
auto_vec< location_t, 8 > m_ilocs
Definition diagnostic.h:165
bool m_allsyslocs
Definition diagnostic.h:169
Definition diagnostic.h:137
const diagnostic_metadata * metadata
Definition diagnostic.h:151
diagnostic_info()
Definition diagnostic.h:138
void * x_data
Definition diagnostic.h:154
diagnostic_t kind
Definition diagnostic.h:156
struct diagnostic_info::inlining_info m_iinfo
text_info message
Definition diagnostic.h:144
rich_location * richloc
Definition diagnostic.h:147
diagnostic_option_id option_id
Definition diagnostic.h:158
Definition diagnostic.h:272
diagnostic_t kind
Definition diagnostic.h:280
int option
Definition diagnostic.h:278
location_t location
Definition diagnostic.h:273
Definition diagnostic-core.h:72
int m_idx
Definition diagnostic-core.h:84
Definition diagnostic.h:308
bool enabled
Definition diagnostic.h:312
bool show_line_numbers_p
Definition diagnostic.h:336
bool show_event_links_p
Definition diagnostic.h:350
int max_width
Definition diagnostic.h:315
char caret_chars[rich_location::STATICALLY_ALLOCATED_RANGES]
Definition diagnostic.h:318
bool show_ruler_p
Definition diagnostic.h:345
bool show_labels_p
Definition diagnostic.h:331
bool colorize_source_p
Definition diagnostic.h:327
int min_margin_width
Definition diagnostic.h:341
Definition libgdiagnostics.cc:723
Definition pretty-print.h:34
Definition unique-argv.h:28
#define gcc_assert(EXPR)
Definition system.h:814
#define DEBUG_FUNCTION
Definition system.h:1236