view gcc/testsuite/c-c++-common/Wsequence-point-1.c @ 16:04ced10e8804

gcc 7
author kono
date Fri, 27 Oct 2017 22:46:09 +0900
parents
children
line wrap: on
line source

/* PR c++/57274 */
/* { dg-do compile } */
/* { dg-options "-Wsequence-point" } */

void foo (int, int);

void
bar (int *x)
{
  foo (*x++, sizeof (*x));	/* { dg-bogus "may be undefined" } */
}

void
baz (int *x)
{
  foo (*x, sizeof (*x++) + sizeof (*x++));	/* { dg-bogus "may be undefined" } */
}