]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - gdb/testsuite/gdb.base/ptr-typedef.c
Copyright updates for 2007.
[thirdparty/binutils-gdb.git] / gdb / testsuite / gdb.base / ptr-typedef.c
1 /* This testcase is part of GDB, the GNU debugger.
2
3 Copyright 2005, 2007 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 2 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, write to the Free Software
17 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
18 USA. */
19
20 struct foo {
21 int x;
22 };
23
24 typedef struct foo *foz;
25
26 struct foo *foo_ptr;
27 foz foz_ptr;
28
29 int
30 marker1 (void)
31 {
32 return foo_ptr == foz_ptr;
33 }
34
35 int
36 main (void)
37 {
38 struct foo the_foo;
39 foo_ptr = &the_foo;
40 foz_ptr = &the_foo;
41
42 return marker1 ();
43 }