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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [cpp0x/] [alias-decl-3.C] - Blame information for rev 705

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

Line No. Rev Author Line
1 693 jeremybenn
// { dg-options "-std=c++0x" }
2
 
3
// Exercise some member alias templates ...
4
 
5
template class A0 {};
6
 
7
template
8
struct A1 {
9
    template struct S {};
10
    template using AA0 = A0;
11
 
12
  void f(A0);
13
 
14
  void
15
  foo()
16
  {
17
    AA0 a;
18
    const AA0 b;
19
    f(a);
20
    f(b);
21
  }
22
};
23
 
24
void
25
bar()
26
{
27
    A1 a1;
28
    a1.foo();
29
    A1::AA0 a1aa0;
30
    a1.f(a1aa0);
31
}
32
 
33
// ... some simple member alias ...
34
struct B {
35
    using A = int;
36
};
37
 
38
B::A a;
39
 
40
// ... and some simple alias
41
 
42
using Int = int;

powered by: WebSVN 2.1.0

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