implement basic support for __label__. I wouldn't be shocked if there are
[clang.git] / test / Parser / goto.c
bloba3e01174eb94f5a18aa7d6af5ed09934aecc6e82
1 /* RUN: %clang_cc1 -fsyntax-only -verify %s
2 */
4 void test1() {
5 goto ; /* expected-error {{expected identifier}} */
9 void test2() {
10 l: /* expected-note {{previous definition is here}} */
13 __label__ l;
14 l: goto l;
18 __label__ l;
19 __label__ h; /* expected-error {{use of undeclared label 'h'}} */
20 l: goto l;
23 /* PR3429 & rdar://8287027
26 l: /* expected-error {{redefinition of label 'l'}} */