aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/gcc.target/i386/990213-2.c
blob: 21392bfca79206c4ebd97e10ddcce3780cfb98a8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
/* { dg-do compile } */
/* { dg-require-effective-target fpic } */
/* { dg-options "-fPIC" } */

struct normal_encoding {};
struct unknown_encoding {};
static const struct normal_encoding latin1_encoding = {};

struct encoding*
XmlInitUnknownEncoding(void *mem)
{
  int i;
  struct unknown_encoding *e = mem;
  for (i = 0; i < sizeof(struct normal_encoding); i++)
    ((char *)mem)[i] = ((char *)&latin1_encoding)[i];
  return 0;
}