]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - gdb/testsuite/gdb.reverse/ur1.c
Update years in copyright notice for the GDB files.
[thirdparty/binutils-gdb.git] / gdb / testsuite / gdb.reverse / ur1.c
1 /* This testcase is part of GDB, the GNU debugger.
2
3 Copyright 1992-2013 Free Software Foundation, Inc.
4
5 This program is free software; you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation; either version 3 of the License, or
8 (at your option) any later version.
9
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
14
15 You should have received a copy of the GNU General Public License
16 along with this program. If not, see <http://www.gnu.org/licenses/>. */
17
18 /* The code for this file was extracted from the gdb testsuite
19 testcase "break.c". */
20
21 /* The following functions do nothing useful. They are included
22 simply as places to try setting breakpoints at. They are
23 explicitly "one-line functions" to verify that this case works
24 (some versions of gcc have or have had problems with this).
25
26 These functions are in a separate source file to prevent an
27 optimizing compiler from inlining them and optimizing them away. */
28
29 #ifdef PROTOTYPES
30 int marker1 (void) { return (0); } /* set breakpoint 15 here */
31 int marker2 (int a) { return (1); } /* set breakpoint 8 here */
32 void marker3 (char *a, char *b) {} /* set breakpoint 17 here */
33 void marker4 (long d) {} /* set breakpoint 14 here */
34 #else
35 int marker1 () { return (0); } /* set breakpoint 16 here */
36 int marker2 (a) int a; { return (1); } /* set breakpoint 9 here */
37 void marker3 (a, b) char *a, *b; {} /* set breakpoint 18 here */
38 void marker4 (d) long d; {} /* set breakpoint 13 here */
39 #endif
40
41 /* A structure we use for field name completion tests. */
42 struct some_struct
43 {
44 int a_field;
45 int b_field;
46 };
47
48 struct some_struct values[50];