repo.or.cz
/
gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Fortran: Fix PR 47485.
[gcc.git]
/
gcc
/
testsuite
/
g++.dg
/
cpp0x
/
constexpr-base4.C
blob
ab664394e5e4447bdd137ccdab54f43ebcc81291
1
// PR c++/46626
2
// { dg-do run { target c++11 } }
3
4
struct A
5
{
6
virtual void f () = 0;
7
virtual ~A () { }
8
};
9
10
struct B : A
11
{
12
virtual void f () { }
13
};
14
15
static void
16
foo (A *a)
17
{
18
a->f ();
19
}
20
21
int
22
main ()
23
{
24
B b;
25
foo (&b);
26
return 0;
27
}