aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite/gdb.base/break.c
diff options
context:
space:
mode:
authorAndreas Arnez <arnez@linux.vnet.ibm.com>2014-10-22 09:24:25 +0000
committerAndreas Krebbel <krebbel@linux.vnet.ibm.com>2014-11-13 10:20:42 +0100
commit3b377a3aa772bf1214efba8a98cec59e2d7ad734 (patch)
treed0934a1fdfebc00706cb1e04ecbf4b54a3e7230a /gdb/testsuite/gdb.base/break.c
parente444df73e954bf24d9dc6a4eaeb5153b3faee973 (diff)
downloadgdb-3b377a3aa772bf1214efba8a98cec59e2d7ad734.zip
gdb-3b377a3aa772bf1214efba8a98cec59e2d7ad734.tar.gz
gdb-3b377a3aa772bf1214efba8a98cec59e2d7ad734.tar.bz2
Drop non-prototype C function header variants: 'break' test case
Remove old-style function headers from break.c and break1.c. Adjust break.exp accordingly; in particular eliminate references to the removed locations "breakpoint 9, 13, and 16" from break.exp. gdb/testsuite/ChangeLog: * gdb.base/break.c: Remove #ifdef PROTOTYPES, keep prototyped variant. * gdb.base/break1.c: Likewise. * gdb.base/break.exp: Drop references to removed code.
Diffstat (limited to 'gdb/testsuite/gdb.base/break.c')
-rw-r--r--gdb/testsuite/gdb.base/break.c29
1 files changed, 0 insertions, 29 deletions
diff --git a/gdb/testsuite/gdb.base/break.c b/gdb/testsuite/gdb.base/break.c
index 0fd8f44..b22e430 100644
--- a/gdb/testsuite/gdb.base/break.c
+++ b/gdb/testsuite/gdb.base/break.c
@@ -18,17 +18,10 @@
#include <stdio.h>
#include <stdlib.h>
-#ifdef PROTOTYPES
extern int marker1 (void);
extern int marker2 (int a);
extern void marker3 (char *a, char *b);
extern void marker4 (long d);
-#else
-extern int marker1 ();
-extern int marker2 ();
-extern void marker3 ();
-extern void marker4 ();
-#endif
/* We're used by a test that requires malloc, so make sure it is in
the executable. */
@@ -42,17 +35,10 @@ void *need_malloc ()
* testing stack backtraces and such.
*/
-#ifdef PROTOTYPES
int factorial(int);
int
main (int argc, char **argv, char **envp)
-#else
-int
-main (argc, argv, envp)
-int argc;
-char *argv[], **envp;
-#endif
{
if (argc == 12345) { /* an unlikely value < 2^16, in case uninited */ /* set breakpoint 6 here */
fprintf (stderr, "usage: factorial <number>\n");
@@ -72,12 +58,7 @@ char *argv[], **envp;
return argc; /* set breakpoint 10 here */
} /* set breakpoint 10a here */
-#ifdef PROTOTYPES
int factorial (int value)
-#else
-int factorial (value)
-int value;
-#endif
{
if (value > 1) { /* set breakpoint 7 here */
value *= factorial (value - 1);
@@ -85,12 +66,7 @@ int value;
return (value); /* set breakpoint 19 here */
}
-#ifdef PROTOTYPES
int multi_line_if_conditional (int a, int b, int c)
-#else
-int multi_line_if_conditional (a, b, c)
- int a, b, c;
-#endif
{
if (a /* set breakpoint 3 here */
&& b
@@ -100,12 +76,7 @@ int multi_line_if_conditional (a, b, c)
return 1;
}
-#ifdef PROTOTYPES
int multi_line_while_conditional (int a, int b, int c)
-#else
-int multi_line_while_conditional (a, b, c)
- int a, b, c;
-#endif
{
while (a /* set breakpoint 4 here */
&& b