repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
diagnostics: avoid using global_dc in path-printing
[official-gcc.git]
/
gcc
/
testsuite
/
g++.dg
/
init
/
ctor7.C
blob
3378a150e2e0267d09fbe35e5a6dcdb005fab5c9
1
// { dg-do run }
2
3
// Copyright (C) 2005 Free Software Foundation, Inc.
4
// Contributed by Nathan Sidwell 13 Oct 2005 <nathan@codesourcery.com>
5
6
// PR 23984:ICE
7
// Origin: Andrew Pinski pinskia@gcc.gnu.org
8
9
struct B
10
{
11
virtual void Foo ();
12
};
13
14
void B::Foo ()
15
{
16
}
17
18
struct D : virtual B
19
{
20
};
21
22
struct E
23
{
24
B *ptr;
25
26
E (B *);
27
};
28
29
static B *ptr;
30
31
E::E (B *ptr_)
32
:ptr (ptr_)
33
{
34
}
35
36
struct G : D, E
37
{
38
G ();
39
};
40
41
G::G ()
42
: E (this)
43
{
44
}
45
46
int main ()
47
{
48
G object;
49
50
return object.ptr != &object;
51
}