Bug 21496 - more flexible dg-error
Summary: more flexible dg-error
Status: NEW
Alias: None
Product: gcc
Classification: Unclassified
Component: testsuite (show other bugs)
Version: 4.1.0
: P2 enhancement
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-05-10 16:04 UTC by Benjamin Kosnik
Modified: 2024-08-04 19:10 UTC (History)
4 users (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed: 2005-10-30 17:28:08


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Benjamin Kosnik 2005-05-10 16:04:19 UTC
http://gcc.gnu.org/ml/libstdc++/2005-05/msg00098.html

In general, what happens is that current negative compile tests have different
line numbers and or message text, depending on various command line defines.

Ie, 23_containers/map/operators/1_neg.cc when run in normal mode (-g -O2) and in
debug mode (-g -O2 -D_GLIBCXX_DEBUG).

This is also an issue with different versions of compilers, and or different
(non FSF) compilers. For instance, older compilers may have different warning text.

I think everybody would be happy as long as the test file in question could be
marked up so dejagnu could pass/fail/be skipped with the changed constraint.
Comment 1 Andrew Pinski 2005-05-10 17:54:21 UTC
Confirmed.
Comment 2 Andrew Pinski 2021-09-14 04:18:47 UTC
So I think this testcase was fixed in two different ways.

First was by using dg-excess-errors for the testcase which was introduced by r0-98409 to testcase.

And then fixed with r0-109419 for GCC 4.7.0 where the libstdc++ testsuite will prune all of "notes:" now unless you use dg-prune-output.

Also it looks like a linenum of 0 will match all lines num now too.


Also in the main GCC testsuite (I don't know if it applies to the libstdc++ testsuite) you can use relative line numbers now too.