summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/weak/weak-18.c
blob: ebeb4d5ba8af8358267562793dd4b93193c29248 (plain)
1
2
3
4
5
6
7
8
9
/* PR middle-end/67330 */
/* { dg-do compile } */
/* { dg-require-weak "" } */

void
f (void)
{
  __attribute__ ((weak)) int a; /* { dg-error "weak declaration of .a. must be public" } */
}