blob: d804f8f0fdc66dccb76a7d2bcd359f3354756be8 [file] [log] [blame]
/* Test diagnostics for duplicate label declarations. */
/* Origin: Joseph Myers <joseph@codesourcery.com> */
/* { dg-do compile } */
/* { dg-options "" } */
void
f (void)
{
__label__ a, b, a; /* { dg-error "error: duplicate label declaration 'a'" } */
/* { dg-error "error: previous declaration of 'a' was here" "previous" { target *-*-* } 9 } */
__label__ c; /* { dg-error "error: previous declaration of 'c' was here" } */
__label__ c; /* { dg-error "error: duplicate label declaration 'c'" } */
return;
}