This is the mail archive of the
libstdc++@sources.redhat.com
mailing list for the libstdc++ project.
[patch] testsuite patch -- to use VERIFY macro
- To: stdc++ <libstdc++ at sourceware dot cygnus dot com>
- Subject: [patch] testsuite patch -- to use VERIFY macro
- From: brent verner <brent at rcfile dot org>
- Date: Sat, 12 Aug 2000 01:57:01 -0400
Hi,
The patch linked below is against cvs libstdc++-v3 (current as
of this email being sent). It changes each instance of 'test &= TEST'
to VERIFY(TEST) -- which is either defined as 'assert(TEST)' or
'test &= TEST'. I originally did this so I could see quicker _exactly_
where a test prog was failing (of course, I've recently learned about
hardware assisted breakpoints :), so I can get by without the
VERIFY(...) macro, but it may help others who decide its a fun thing
to hack on the library. The VERIFY macro is defined in a header file
testsuite/debug_assert.h which has been added to the -I for the
testsuite. If anyone can recommend a better place/name for the file,
I'm open to suggestions.
I'll also be going through the testsuite and changing the
definition of all functions (where appropriate) to ...
int
test0N(){
//stuff
return 0;
}
... but I won't get to tackle that for a couple of weekends (crosstown
relocation), so if there is any reason a different standard function
signature for the testsuite would be better, let me know -- I noticed
that a few are 'bool test0N(){ //...; return test; }'.
btw, I'm seeing failures at
- - 27_io/stringstream.cc
- + 27_io/wide_stream_objects.cc
in the testsuite since yesterday. I'm quite sure they aren't related
to the testsuite's new hack. I have no clue about the wide_stream..
failure, but the stringstream.cc test is bailing on strlen(NULL)...
how/why it got there, idunno, but I'm looking into that as soon as
I fire this mail off.
cheers.
Brent
====================================================================
patch: http://rcfile.org/misc/testsuite.diff.gz [40k]
(apply with -p1 from within the libstdc++-v3 dir)
Changelog:
2000-08-11 Brent Verner <brent@rcfile.org>
* testsuite/debug_assert.h: new file
* testsuite/*/*.cc: s/test\s*&=([^;]+);/VERIFY($1);/g
changed conditional #include <c?assert.?h?> to
unconditional #include <debug_assert.h>
* mkcheck.in: added $SRC_DIR/testsuite to include search path
for testsuite compile command.