aboutsummaryrefslogtreecommitdiff
path: root/gcc/opts-common.c
diff options
context:
space:
mode:
authorDavid Malcolm <dmalcolm@redhat.com>2020-10-06 16:58:00 -0400
committerDavid Malcolm <dmalcolm@redhat.com>2020-10-07 09:37:11 -0400
commit7345c89ecb1a31ce96c6789bffc7183268a040b3 (patch)
tree6c67bc927dfe4ce2b2dcc7ef73045744d6956e3d /gcc/opts-common.c
parent4e62aca0e0520e4ed2532f2d8153581190621c1a (diff)
downloadgcc-7345c89ecb1a31ce96c6789bffc7183268a040b3.zip
gcc-7345c89ecb1a31ce96c6789bffc7183268a040b3.tar.gz
gcc-7345c89ecb1a31ce96c6789bffc7183268a040b3.tar.bz2
Add -fdiagnostics-path-format=separate-events to -fdiagnostics-plain-output
The path-printing default of -fdiagnostics-path-format=inline-events interacted poorly with -fdiagnostics-plain-output, so it makes most sense to add -fdiagnostics-path-format=separate-events to -fdiagnostics-plain-output. Seen when adding an experimental analyzer plugin to gcc.dg/plugin.exp. gcc/ChangeLog: * doc/invoke.texi (-fdiagnostics-plain-output): Add -fdiagnostics-path-format=separate-events to list of options injected by -fdiagnostics-plain-output. * opts-common.c (decode_cmdline_options_to_array): Likewise. gcc/testsuite/ChangeLog: * g++.dg/analyzer/analyzer.exp (DEFAULT_CXXFLAGS): Remove -fdiagnostics-path-format=separate-events. * gcc.dg/analyzer/analyzer.exp (DEFAULT_CFLAGS): Likewise. * gcc.dg/plugin/diagnostic-path-format-default.c: Rename to... * gcc.dg/plugin/diagnostic-path-format-plain.c: ...this. Remove dg-options directive. Copy remainder of test from diagnostic-path-format-separate-events.c. * gcc.dg/plugin/diagnostic-test-paths-2.c: Add -fdiagnostics-path-format=inline-events to options. Fix expected output for location of conditional within "for" loop. * gcc.dg/plugin/plugin.exp (plugin_test_list): Update for renaming. * gfortran.dg/analyzer/analyzer.exp (DEFAULT_FFLAGS): Remove -fdiagnostics-path-format=separate-events.
Diffstat (limited to 'gcc/opts-common.c')
-rw-r--r--gcc/opts-common.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/gcc/opts-common.c b/gcc/opts-common.c
index 237e4ce..8ec8c1e 100644
--- a/gcc/opts-common.c
+++ b/gcc/opts-common.c
@@ -1000,6 +1000,7 @@ decode_cmdline_options_to_array (unsigned int argc, const char **argv,
"-fno-diagnostics-show-line-numbers",
"-fdiagnostics-color=never",
"-fdiagnostics-urls=never",
+ "-fdiagnostics-path-format=separate-events",
};
const int num_expanded = ARRAY_SIZE (expanded_args);
opt_array_len += num_expanded - 1;