aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/tree-ssa/neg-cast-3.c
blob: 61b89403a9372b5946cebf52e0fc0dc0856884e4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
/* { dg-do compile } */
/* { dg-options "-O1 -fdump-tree-forwprop1 -fdump-tree-optimized" } */
/* PR tree-optimization/107137 */

unsigned f(_Bool a)
{
  int t = a;
  t = -t;
  return t;
}

/* There should be no cast to int at all. */
/* { dg-final { scan-tree-dump-not "\\\(int\\\)" "forwprop1" } } */