fix PR8007
reordering and redefinition issues still may linger, I plan to nail them next llvm-svn: 112333
This commit is contained in:
parent
83f9ff0452
commit
b6aba3ef28
|
@ -7709,7 +7709,12 @@ void Sema::MarkDeclarationReferenced(SourceLocation Loc, Decl *D) {
|
|||
else
|
||||
PendingInstantiations.push_back(std::make_pair(Function, Loc));
|
||||
}
|
||||
}
|
||||
} else // Walk redefinitions, as some of them may be instantiable.
|
||||
for (FunctionDecl::redecl_iterator i(Function->redecls_begin()),
|
||||
e(Function->redecls_end()); i != e; ++i) {
|
||||
if (i->isImplicitlyInstantiable())
|
||||
MarkDeclarationReferenced(Loc, *i);
|
||||
}
|
||||
|
||||
// FIXME: keep track of references to static functions
|
||||
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
// RUN: %clang %s -S -emit-llvm -o - | grep -e "define linkonce_odr.*_ZN6pr8007lsERNS_11std_ostreamERKNS_8StreamerINS_3FooEEE"
|
||||
// XFAIL: *
|
||||
|
||||
namespace pr8007 {
|
||||
|
||||
|
|
Loading…
Reference in New Issue