diff options
author | Daniel Jacobowitz <drow@false.org> | 2010-08-30 17:38:10 +0000 |
---|---|---|
committer | Daniel Jacobowitz <drow@false.org> | 2010-08-30 17:38:10 +0000 |
commit | 640617ad17a526e78796054d1da3d652ae5c8dc9 (patch) | |
tree | 07c3c7700563fb65d76326cecf2a34c31c6444e5 /gdb/testsuite/gdb.cp/cpexprs.cc | |
parent | 25b41d01eaa6f8f68491ef2eb65ca403907269f7 (diff) | |
download | gdb-640617ad17a526e78796054d1da3d652ae5c8dc9.zip gdb-640617ad17a526e78796054d1da3d652ae5c8dc9.tar.gz gdb-640617ad17a526e78796054d1da3d652ae5c8dc9.tar.bz2 |
* gdb.cp/cpexprs.exp (test_breakpoint): Continue to test_function
instead of running to main. Do not test the main function.
* gdb/testsuite/gdb.cp/cpexprs.cc (main): Rename to test_function.
Add new main.
Diffstat (limited to 'gdb/testsuite/gdb.cp/cpexprs.cc')
-rw-r--r-- | gdb/testsuite/gdb.cp/cpexprs.cc | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/gdb/testsuite/gdb.cp/cpexprs.cc b/gdb/testsuite/gdb.cp/cpexprs.cc index 2bca4cd..ac79666 100644 --- a/gdb/testsuite/gdb.cp/cpexprs.cc +++ b/gdb/testsuite/gdb.cp/cpexprs.cc @@ -309,8 +309,8 @@ class derived : public base1, public base2 }; int -main (int argc, char* argv[]) // main -{ // main +test_function (int argc, char* argv[]) // test_function +{ // test_function derived d; void (derived::*pfunc) (void) const = &derived::a_function; (d.*pfunc) (); @@ -427,5 +427,19 @@ main (int argc, char* argv[]) // main char* str = a; fluff* flp = a; fluff** flpp = a; + + return 0; } +int +main (int argc, char* argv[]) +{ + int i; + + /* Call the test function repeatedly, enough times for all our tests + without running forever if something goes wrong. */ + for (i = 0; i < 1000; i++) + test_function (argc, argv); + + return 0; +} |