summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.other/typedef1.C
blob: 38d77e1c69dc1e591897d4dca704978c5f04eca2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
// { dg-do assemble  }

typedef const struct {
   int x;
} Test;

static void foo(Test);

static void foo(Test t)
{
  t.x = 0; // { dg-error "" } assignment of read-only member
  return;
}