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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gcc-4.2.2/] [gcc/] [testsuite/] [gcc.dg/] [c90-return-1.c] - Blame information for rev 816

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 149 jeremybenn
/* Test for constraints on return statements.  */
2
/* Origin: Joseph Myers <jsm28@cam.ac.uk> */
3
/* { dg-do compile } */
4
/* { dg-options "-std=iso9899:1990 -pedantic-errors" } */
5
 
6
int
7
foo (void)
8
{
9
  return;
10
}
11
 
12
void
13
bar (void)
14
{
15
  return 1; /* { dg-bogus "warning" "warning in place of error" } */
16
  /* { dg-error "with a value" "return constraint violation" { target *-*-* } 15 } */
17
}

powered by: WebSVN 2.1.0

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