OpenCores
URL https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk

Subversion Repositories openrisc_2011-10-31

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [gcc/] [testsuite/] [gcc.dg/] [array-2.c] - Blame information for rev 404

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

Line No. Rev Author Line
1 298 jeremybenn
/* { dg-do compile } */
2
/* { dg-options "" } */
3
 
4
/* Verify that we can't do things to get ourselves in trouble
5
   with GCC's initialized flexible array member extension.  */
6
 
7
struct f { int w; int x[]; };
8
struct g { struct f f; };
9
struct g g1 = { { 0, { } } };
10
struct g g2 = { { 0, { 1 } } }; /* { dg-error "nested context" "nested" } */
11
                                /* { dg-error "near init" "near" { target *-*-* } 10 } */
12
struct h { int x[0]; int y; };
13
struct h h1 = { { 0 }, 1 }; /* { dg-warning "excess elements" "excess" } */
14
                            /* { dg-warning "near init" "before end" { target *-*-* } 13 } */

powered by: WebSVN 2.1.0

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