1231200Smm// { dg-do run }
2231200Smm
3231200Smm// Copyright (C) 2001 Free Software Foundation, Inc.
4231200Smm// Contributed by Nathan Sidwell 17 Oct 2002 <nathan@codesourcery.com>
5231200Smm
6231200Smm// PR 7209. We didn't SAVE_EXPR in the right place
7231200Smm
8231200Smmchar a[2][1][16]={
9231200Smm  {{0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00}},
10231200Smm  {{0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00}}};
11231200Smm
12231200Smmint f() {return 0;}
13231200Smm
14231200Smmchar * Foo (int d)
15231200Smm{
16231200Smm  char *c1;
17231200Smm
18231200Smm  c1=a[d==0 ? 0 : 1][f()];
19231200Smm
20231200Smm  return c1;
21231200Smm}
22231200Smm
23231200Smmint main ()
24231200Smm{
25231200Smm  if (Foo (0) != (void *)a)
26231200Smm    return 1;
27231200Smm  return 0;
28231200Smm}
29231200Smm