diff options
author | Thomas Schwinge <thomas@codesourcery.com> | 2020-10-29 10:29:19 +0100 |
---|---|---|
committer | Thomas Schwinge <thomas@codesourcery.com> | 2020-11-02 14:14:43 +0100 |
commit | 528507fa0314c75d1105890e4781a475c8badd7c (patch) | |
tree | 4e9cdf1bfea3131d872a61a0cc92204af3b33ee4 | |
parent | b2a31e2c341d96520c5fb7c1e1f1c590eb182d7f (diff) | |
download | gcc-528507fa0314c75d1105890e4781a475c8badd7c.zip gcc-528507fa0314c75d1105890e4781a475c8badd7c.tar.gz gcc-528507fa0314c75d1105890e4781a475c8badd7c.tar.bz2 |
libgomp testsuite: tell warning from error diagnostics, etc. [PR80219, PR85303]
This changes makes 'dg-warning', 'dg-error', 'dg-bogus', 'dg-message' behave as
expected, and also enables use of relative line numbers as well as 'dg-line'.
libgomp/
PR testsuite/80219
PR testsuite/85303
* testsuite/lib/libgomp.exp (libgomp_init): Set
'gcc_warning_prefix', 'gcc_error_prefix'.
-rw-r--r-- | libgomp/testsuite/lib/libgomp.exp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/libgomp/testsuite/lib/libgomp.exp b/libgomp/testsuite/lib/libgomp.exp index 5d86e2a..72d0011 100644 --- a/libgomp/testsuite/lib/libgomp.exp +++ b/libgomp/testsuite/lib/libgomp.exp @@ -241,6 +241,12 @@ proc libgomp_init { args } { if { $offload_additional_options != "" } { lappend ALWAYS_CFLAGS "additional_flags=${offload_additional_options}" } + + # Tell warning from error diagnostics. This fits for C, C++, and Fortran. + global gcc_warning_prefix + set gcc_warning_prefix "\[Ww\]arning:" + global gcc_error_prefix + set gcc_error_prefix "(\[Ff\]atal )?\[Ee\]rror:" } # |