* g++.old-dega/g++.pt/ttp62.C: Call abort() on failure.

From-SVN: r37728
This commit is contained in:
Kriang Lerdsuwanakij 2000-11-25 02:40:00 +00:00 committed by Kriang Lerdsuwanakij
parent c3edd394bb
commit 3a163b1a99
2 changed files with 9 additions and 3 deletions

View File

@ -1,3 +1,7 @@
2000-11-24 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
* g++.old-dega/g++.pt/ttp62.C: Call abort() on failure.
2000-11-24 Bernd Schmidt <bernds@redhat.co.uk>
* gcc.dg/sequence-point-1.c: Add some new tests.

View File

@ -1,6 +1,6 @@
// Origin: Ewgenij Gawrilow <gawrilow@math.TU-Berlin.DE>
#include <iostream>
extern "C" void abort ();
template <template <class X> class B, class A>
struct is_instance_of {
@ -21,7 +21,9 @@ bool is_C (const T&) {
};
int main() {
std::cout << "should be true: " << is_C(C<int>()) << std::endl;
std::cout << "should be false: " << is_C(D<int>()) << std::endl;
if (!is_C(C<int>()))
abort ();
if (is_C(D<int>()))
abort ();
return 0;
}