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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [lookup/] [scoped1.C] - Blame information for rev 693

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 693 jeremybenn
// Test that explicitly scoped references to static members work even if
2
// they belong to an inaccessible base.
3
 
4
struct A
5
{
6
  static int i1;
7
  int i2; // { dg-error "inaccessible" "" }
8
  static void f1 ();
9
  void f2 ();
10
};
11
 
12
struct B: private A { };
13
struct C: public B
14
{
15
  void g ()
16
  {
17
    ::A::i1 = 1;
18
    ::A::i2 = 1;                // { dg-error "(access)|(context)" "" }
19
    ::A::f1 ();
20
    ::A::f2 ();                 // { dg-error "" }
21
  }
22
};

powered by: WebSVN 2.1.0

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