view gcc/testsuite/gcc.dg/pr52549.c @ 144:8f4e72ab4e11

fix segmentation fault caused by nothing next cur_op to end
author Takahiro SHIMIZU <anatofuz@cr.ie.u-ryukyu.ac.jp>
date Sun, 23 Dec 2018 21:23:56 +0900
parents 04ced10e8804
children
line wrap: on
line source

/* { dg-do compile } */

#ifdef __SIZE_TYPE__
_mark (__SIZE_TYPE__ obj, int i, char *a)
{
  (char *)&(((long *)(obj)) [i]) - a;
}
#elif __SIZEOF_POINTER__ == __SIZEOF_LONG__
_mark (long obj, int i, char *a)
{
  (char *)&(((long *)(obj)) [i]) - a;
}
#elif __SIZEOF_POINTER__ == __SIZEOF_INT__
_mark (int obj, int i, char *a)
{
  (char *)&(((int *)(obj)) [i]) - a;
}
#elif __SIZEOF_POINTER__ == __SIZEOF_LONG_LONG__
__extension__ _mark (long long obj, int i, char *a)
{
  (char *)&(((int *)(obj)) [i]) - a;
}
#endif