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

Subversion Repositories openrisc

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

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
// 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-error "" "unqualified name binds to N1::Base" }
14
    Base* p2;
15
    typename Derived::Base* p3;   // { dg-bogus "" "injected class name in derived classes" }
16
  };
17
 
18
  template struct Derived;  // { dg-bogus "required from here" "everything should be looked up at parsing time (after DR224)" }
19
}
20
 
21
 
22
namespace N2 {
23
  template  struct Base {};
24
  template  struct Derived: public Base {
25
    typename Derived::template Base* p1;  // { dg-bogus "" "" }
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.