view gcc/testsuite/gcc.dg/Wunused-local-typedefs.c @ 118:fd00160c1b76

ifdef TARGET_64BIT
author mir3636
date Tue, 27 Feb 2018 15:01:35 +0900
parents 04ced10e8804
children
line wrap: on
line source

/*  Origin PR c/53702
    { dg-options "-Wunused-local-typedefs" }
    { dg-do compile }
*/

/* Only test nested functions for C.  More tests that work for C and C++
   can be found in c-c++-common.
*/

void
test0 ()
{
  typedef int foo; /* { dg-warning "locally defined but not used" } */
  void f ()
  {
  }
}

void
test1 ()
{
  void f ()
  {
    typedef int foo; /* { dg-warning "locally defined but not used" } */
  }
}


void
test2 ()
{
  void f ()
  {
  }
  typedef int foo; /* { dg-warning "locally defined but not used" } */
}