annotate gcc/diagnostic.def @ 158:494b0b89df80 default tip

...
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Mon, 25 May 2020 18:13:55 +0900
parents 1830386684a0
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
145
1830386684a0 gcc-9.2.0
anatofuz
parents: 131
diff changeset
1 /* Copyright (C) 2001-2020 Free Software Foundation, Inc.
55
77e2b8dfacca update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
2
77e2b8dfacca update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
3 This file is part of GCC.
77e2b8dfacca update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
4
77e2b8dfacca update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
5 GCC is free software; you can redistribute it and/or modify it under
77e2b8dfacca update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
6 the terms of the GNU General Public License as published by the Free
77e2b8dfacca update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
7 Software Foundation; either version 3, or (at your option) any later
77e2b8dfacca update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
8 version.
77e2b8dfacca update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
9
77e2b8dfacca update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
10 GCC is distributed in the hope that it will be useful, but WITHOUT ANY
77e2b8dfacca update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
11 WARRANTY; without even the implied warranty of MERCHANTABILITY or
77e2b8dfacca update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
12 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
77e2b8dfacca update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
13 for more details.
77e2b8dfacca update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
14
77e2b8dfacca update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
15 You should have received a copy of the GNU General Public License
77e2b8dfacca update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
16 along with GCC; see the file COPYING3. If not see
77e2b8dfacca update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
17 <http://www.gnu.org/licenses/>. */
77e2b8dfacca update it from 4.4.3 to 4.5.0
ryoma <e075725@ie.u-ryukyu.ac.jp>
parents: 0
diff changeset
18
0
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
19 /* DK_UNSPECIFIED must be first so it has a value of zero. We never
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
20 assign this kind to an actual diagnostic, we only use this in
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
21 variables that can hold a kind, to mean they have yet to have a
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
22 kind specified. I.e. they're uninitialized. Within the diagnostic
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
23 machinery, this kind also means "don't change the existing kind",
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
24 meaning "no change is specified". */
111
kono
parents: 55
diff changeset
25 DEFINE_DIAGNOSTIC_KIND (DK_UNSPECIFIED, "", NULL)
0
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
26
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
27 /* If a diagnostic is set to DK_IGNORED, it won't get reported at all.
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
28 This is used by the diagnostic machinery when it wants to disable a
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
29 diagnostic without disabling the option which causes it. */
111
kono
parents: 55
diff changeset
30 DEFINE_DIAGNOSTIC_KIND (DK_IGNORED, "", NULL)
0
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
31
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
32 /* The remainder are real diagnostic types. */
111
kono
parents: 55
diff changeset
33 DEFINE_DIAGNOSTIC_KIND (DK_FATAL, "fatal error: ", "error")
kono
parents: 55
diff changeset
34 DEFINE_DIAGNOSTIC_KIND (DK_ICE, "internal compiler error: ", "error")
kono
parents: 55
diff changeset
35 DEFINE_DIAGNOSTIC_KIND (DK_ERROR, "error: ", "error")
kono
parents: 55
diff changeset
36 DEFINE_DIAGNOSTIC_KIND (DK_SORRY, "sorry, unimplemented: ", "error")
kono
parents: 55
diff changeset
37 DEFINE_DIAGNOSTIC_KIND (DK_WARNING, "warning: ", "warning")
kono
parents: 55
diff changeset
38 DEFINE_DIAGNOSTIC_KIND (DK_ANACHRONISM, "anachronism: ", "warning")
kono
parents: 55
diff changeset
39 DEFINE_DIAGNOSTIC_KIND (DK_NOTE, "note: ", "note")
kono
parents: 55
diff changeset
40 DEFINE_DIAGNOSTIC_KIND (DK_DEBUG, "debug: ", "note")
145
1830386684a0 gcc-9.2.0
anatofuz
parents: 131
diff changeset
41
1830386684a0 gcc-9.2.0
anatofuz
parents: 131
diff changeset
42 /* For use when using the diagnostic_show_locus machinery to show
1830386684a0 gcc-9.2.0
anatofuz
parents: 131
diff changeset
43 a range of events within a path. */
1830386684a0 gcc-9.2.0
anatofuz
parents: 131
diff changeset
44 DEFINE_DIAGNOSTIC_KIND (DK_DIAGNOSTIC_PATH, "path: ", "path")
1830386684a0 gcc-9.2.0
anatofuz
parents: 131
diff changeset
45
0
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
46 /* These two would be re-classified as DK_WARNING or DK_ERROR, so the
a06113de4d67 first commit
kent <kent@cr.ie.u-ryukyu.ac.jp>
parents:
diff changeset
47 prefix does not matter. */
111
kono
parents: 55
diff changeset
48 DEFINE_DIAGNOSTIC_KIND (DK_PEDWARN, "pedwarn: ", NULL)
kono
parents: 55
diff changeset
49 DEFINE_DIAGNOSTIC_KIND (DK_PERMERROR, "permerror: ", NULL)
kono
parents: 55
diff changeset
50 /* This one is just for counting DK_WARNING promoted to DK_ERROR
kono
parents: 55
diff changeset
51 due to -Werror and -Werror=warning. */
kono
parents: 55
diff changeset
52 DEFINE_DIAGNOSTIC_KIND (DK_WERROR, "error: ", NULL)
kono
parents: 55
diff changeset
53 /* This is like DK_ICE, but backtrace is not printed. Used in the driver
kono
parents: 55
diff changeset
54 when reporting fatal signal in the compiler. */
kono
parents: 55
diff changeset
55 DEFINE_DIAGNOSTIC_KIND (DK_ICE_NOBT, "internal compiler error: ", "error")