PR middle-end/77357 - strlen of constant strings not folded
[official-gcc.git] / gcc / testsuite / gcc.dg / tree-ssa / forwprop-2.c
blob6c43f95d1c13acee09e1b9f22ba7351c10abb516
1 /* { dg-do compile } */
2 /* { dg-options "-O2 -fdump-tree-forwprop1" } */
4 /* We may not optimize this to b->t[i] = 1. */
6 struct a
8 char t[10];
9 };
11 struct a *b;
13 void f(__SIZE_TYPE__ i)
15 char *c = b->t;
16 c[i] = 1;
19 /* { dg-final { scan-tree-dump-times "\\\[\[^\n\r\]*\\\] = 1;" 0 "forwprop1" } } */