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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [tc1/] [dr80.C] - Blame information for rev 764

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

Line No. Rev Author Line
1 693 jeremybenn
// { dg-do compile }
2
// Origin: Giovanni Bajo 
3
// DR80: Class members with same name as class
4
 
5
struct A
6
{
7
  int A;
8
};
9
 
10
struct A2
11
{
12
  static int A2;  // { dg-error "same name as" }
13
};
14
 
15
 
16
template 
17
struct A3
18
{
19
  int A3;
20
};
21
 
22
template 
23
struct A4
24
{
25
  static int A4;  // { dg-error "same name as" }
26
};
27
 
28
 
29
struct B
30
{
31
  B();
32
  int B;  // { dg-error "same name as" }
33
};
34
 
35
struct B2
36
{
37
  B2();
38
  static int B2;  // { dg-error "same name as" }
39
};
40
 
41
template 
42
struct B3
43
{
44
  B3();
45
  int B3;  // { dg-error "same name as" "this error should appear at parsing time" { xfail *-*-* } }
46
};
47
 
48
template 
49
struct B4
50
{
51
  B4();
52
  static int B4;  // { dg-error "same name as" }
53
};

powered by: WebSVN 2.1.0

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