URL
https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk
Only display areas with differences |
Details |
Blame |
View Log
Rev 149 |
Rev 154 |
/* Test for handling of tags. A struct defined in an inner scope does
|
/* Test for handling of tags. A struct defined in an inner scope does
|
not match one declared in an outer scope. */
|
not match one declared in an outer scope. */
|
/* Origin: Joseph Myers <jsm@polyomino.org.uk> */
|
/* Origin: Joseph Myers <jsm@polyomino.org.uk> */
|
/* { dg-do compile } */
|
/* { dg-do compile } */
|
/* { dg-options "-std=iso9899:1999 -pedantic-errors" } */
|
/* { dg-options "-std=iso9899:1999 -pedantic-errors" } */
|
|
|
struct s;
|
struct s;
|
struct t { struct s *p; } x;
|
struct t { struct s *p; } x;
|
|
|
void
|
void
|
f (void)
|
f (void)
|
{
|
{
|
/* This is a different struct s from the outer one. */
|
/* This is a different struct s from the outer one. */
|
struct s { int a; } y;
|
struct s { int a; } y;
|
x.p = &y; /* { dg-error "incompatible" } */
|
x.p = &y; /* { dg-error "incompatible" } */
|
}
|
}
|
|
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.