OSDN Git Service

2011-01-08 Dominique d'Humieres <dominiq@lps.ens.fr>
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / objc.dg / keywords-3.m
1 /* Test that 'class', 'public', 'private', protected', 'try', 'catch',
2    'throw' are not keywords in pure Objective-C if not after a '@'.
3 */
4 /* { dg-do compile } */
5
6 int class (int public)
7 {
8   int private = public;
9   int protected = private * 2;
10   int try = protected * 2;
11   int catch = try * 2;
12   int throw = catch * 2;
13
14   return throw;
15 }
16
17 int main (void)
18 {
19   return class (0);
20 }