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

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.2.2/] [gcc/] [testsuite/] [gcc.dg/] [vla-init-1.c] - Diff between revs 149 and 154

Go to most recent revision | Only display areas with differences | Details | Blame | View Log

Rev 149 Rev 154
/* Test for tree-checking error when initializing a variable-length array
/* Test for tree-checking error when initializing a variable-length array
   (not allowed): constructor_max_index needs to be an INTEGER_CST.  */
   (not allowed): constructor_max_index needs to be an INTEGER_CST.  */
/* Origin: Joseph Myers <jsm28@cam.ac.uk>.  */
/* Origin: Joseph Myers <jsm28@cam.ac.uk>.  */
/* { dg-do compile } */
/* { dg-do compile } */
/* { dg-options "" } */
/* { dg-options "" } */
 
 
int a;
int a;
 
 
void
void
foo (void)
foo (void)
{
{
  int x[a] = { 1 }; /* { dg-error "init" "VLA init" } */
  int x[a] = { 1 }; /* { dg-error "init" "VLA init" } */
}
}
 
 

powered by: WebSVN 2.1.0

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