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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gcc.dg/] [c99-tag-2.c] - Blame information for rev 690

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

Line No. Rev Author Line
1 689 jeremybenn
/* Test for handling of tags.  A struct defined in an inner scope does
2
   not match one declared in an outer scope.  */
3
/* Origin: Joseph Myers <jsm@polyomino.org.uk> */
4
/* { dg-do compile } */
5
/* { dg-options "-std=iso9899:1999 -pedantic-errors" } */
6
 
7
struct s;
8
struct t { struct s *p; } x;
9
 
10
void
11
f (void)
12
{
13
  /* This is a different struct s from the outer one.  */
14
  struct s { int a; } y;
15
  x.p = &y; /* { dg-error "incompatible" } */
16
}

powered by: WebSVN 2.1.0

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