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

Subversion Repositories openrisc

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

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 693 jeremybenn
// { dg-do compile }
2
// { dg-options --std=c++0x }
3
 
4
struct X {};
5
 
6
struct B {
7
        int i;
8
        B (int _i) : i(_i) { }
9
        ~B () { i = 0; }
10
};
11
 
12
template 
13
struct A : public B {
14
        A () : B(-1) { }
15
        ~A () { }
16
};
17
 
18
template 
19
struct A : public B {
20
        A () : B(-1) { }
21
        A (int i) : A() { }
22
        A (double b) : A(static_cast(b)) { }
23
        A (double b, double b2) : A(b2) { }
24
        ~A () { }
25
};
26
 
27
void f_A () { A a(2.0, 3.0); }
28
 
29
struct C {
30
        C () { }
31
        virtual ~C() { }
32
        virtual int f () = 0;
33
};
34
 
35
template 
36
struct D : public C {
37
        int i;
38
        D (int _i) : C(), i(_i) { }
39
};
40
 
41
template <>
42
struct D : public C {
43
        int i;
44
        D (int _i) : C(), i(_i) { }
45
        D () : D(-1) { }
46
        virtual ~D() { }
47
        virtual int f () { }
48
};
49
 
50
void f_D () { D* d = new D(); }
51
 
52
template 
53
struct E {
54
};
55
 
56
template <>
57
struct E {
58
        int i;
59
        E () : E(0) { }
60
        E (int _i) : i(_i) { }
61
};
62
 
63
void f_E () { E e; }

powered by: WebSVN 2.1.0

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