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
Merge -r 127928:132243 from trunk
[official-gcc.git]
/
gcc
/
testsuite
/
g++.old-deja
/
g++.pt
/
instantiate4.C
blob
9c1aaf58f3ed95edb3f39644819e68a5d3cc2927
1
// { dg-do link }
2
// { dg-options "-frepo -Werror" }
3
// { dg-require-host-local "" }
4
// Build then link:
5
6
7
// Submitted by Melissa O'Neill <oneill@cs.sfu.ca>
8
// the vtable of Foo<int> wouldn't be generated
9
10
template <typename A>
11
struct Foo {
12
virtual void foo() {}
13
};
14
15
template <typename A>
16
struct Bar {
17
void bar();
18
};
19
20
template <typename A>
21
void Bar<A>::bar() {
22
Foo<A> oof;
23
}
24
25
int main () {
26
Bar<int> rab;
27
28
rab.bar();
29
}
30
31
// { dg-final { cleanup-repo-files } }