(root)/
gcc-13.2.0/
gcc/
testsuite/
c-c++-common/
pr30020.c
       1  /* PR c/30020 */
       2  /* { dg-do compile } */
       3  
       4  int
       5  foo (unsigned char c)
       6  {
       7    switch (c) { case 42: case -1: return -1; }; /* { dg-warning "25:case label value" } */
       8    switch (c) { case 42: case 300: return -1; }; /* { dg-warning "25:case label value" } */
       9    switch (c) { case 42: case -1 ... 2: return -1; }; /* { dg-warning "25:lower value in case" } */
      10    switch (c) { case 42: case 250 ... 300: return -1; }; /* { dg-warning "25:upper value in case" } */
      11    return 0;
      12  }