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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gcc-4.2.2/] [gcc/] [testsuite/] [g++.dg/] [tc1/] [dr176.C] - Blame information for rev 841

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

Line No. Rev Author Line
1 149 jeremybenn
// { dg-do compile }
2
// Origin: Giovanni Bajo 
3
// DR176: Name injection and templates
4
 
5
namespace N1 {
6
  template  struct Base {
7
    Base* p;
8
    Base* p2;
9
    ::Base* p3;    // { dg-error "" "" }
10
  };
11
 
12
  template  struct Derived: public Base {
13
    Base* p;     // { dg-bogus "" "injected class name in derived classes" { xfail *-*-* } }
14
    Base* p2;
15
    typename Derived::Base* p3;   // { dg-bogus "" "injected class name in derived classes" { xfail *-*-* } }
16
  };
17
 
18
  template struct Derived;  // { dg-bogus "instantiated from here" "everything should be looked up at parsing time (after DR224)" { xfail *-*-* } }
19
}
20
 
21
 
22
namespace N2 {
23
  template  struct Base {};
24
  template  struct Derived: public Base {
25
    typename Derived::template Base* p1;  // { dg-bogus "" "" { xfail *-*-* } }
26
  };
27
 
28
  template struct Derived;
29
}

powered by: WebSVN 2.1.0

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