summaryrefslogtreecommitdiff
path: root/gcc/testsuite/obj-c++.dg/keywords-2.mm
blob: c81cb4d0cac80e3bfb1f04df396568ce6d06ccdf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
/* Test that 'encode', 'end', 'compatibility_alias', 'defs',
   'protocol', 'selector', finally', 'synchronized', 'interface',
   'implementation' are not keywords if not after a '@'.
*/
/* { dg-do compile } */

int encode (int end)
{
  int compatibility_alias = end * 2;
  int defs = compatibility_alias * 2;
  int protocol = defs * 2;
  int selector = protocol * 2;
  int finally = selector * 2;
  int synchronized = finally * 2;
  int interface = synchronized * 2;
  int implementation = interface * 2;

  return implementation;
}

int main (void)
{
  return encode (0);
}