OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gcc.dg/] [Wunused-value-2.c] - Blame information for rev 801

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 689 jeremybenn
/* Test -Wunused-value.  Bug 30729.  */
2
/* { dg-do compile } */
3
/* { dg-options "-Wunused-value" } */
4
/* Make sure va_arg does not cause a value computed is not used warning
5
   because it has side effects.   */
6
#include <stdarg.h>
7
 
8
int f(int t, ...)
9
{
10
  va_list a;
11
  va_start (a, t);
12
  va_arg(a, int);/* { dg-bogus "value computed is not used" } */
13
  int t1 = va_arg(a, int);
14
  va_end(a);
15
  return t1;
16
}
17
 
18
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.