(root)/
gcc-13.2.0/
gcc/
testsuite/
gcc.c-torture/
execute/
const-addr-expr-1.c
       1  #include        <stdio.h>
       2  #include        <stdlib.h>
       3  extern void abort();
       4  
       5  typedef struct foo
       6  {
       7          int     uaattrid;
       8          char    *name;
       9  } FOO;
      10  
      11  FOO     Upgrade_items[] =
      12  {
      13          {1, "1"},
      14          {2, "2"},
      15          {0, NULL}
      16  };
      17  
      18  int     *Upgd_minor_ID = 
      19          (int *) &((Upgrade_items + 1)->uaattrid);
      20  
      21  int     *Upgd_minor_ID1 = 
      22          (int *) &((Upgrade_items)->uaattrid);
      23  
      24  int
      25  main(int argc, char **argv)
      26  {
      27  	if (*Upgd_minor_ID != 2)
      28  	  abort();
      29  
      30  	if (*Upgd_minor_ID1 != 1)
      31  	  abort();
      32  	return 0;
      33  }