summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.c-torture/compile/pr56539.c
blob: 0fba96f4c8dd3f7c74d68741e4a2de84e35d7f18 (plain)
1
2
3
4
5
6
7
/* PR tree-optimization/56539 */

short
foo (const char *x, unsigned y)
{
  return y > 1 ? (x[y - 1] - '0') + 10 * foo (x, y - 1) : (*x - '0');
}