extern "C" is printed by the decl itself.

This commit is contained in:
Axel Naumann 2014-09-23 14:37:05 +02:00 committed by sftnight
parent c216c82cde
commit f0f6835a22

View File

@ -758,18 +758,9 @@ namespace cling {
}
void ForwardDeclPrinter::VisitLinkageSpecDecl(LinkageSpecDecl *D) {
PrintLinkageOpen(D);
if (D->hasBraces()) {
// VisitDeclContext(D); //To skip weird typedefs and struct definitions
for (auto it = D->decls_begin(); it != D->decls_end(); ++it) {
Visit(*it);
skipCurrentDecl(false);
}
Out() << "}";
} else {
Out() << "{\n"; // print braces anyway, as the decl may end up getting skipped
Visit(*D->decls_begin());
Out() << ";}\n";
for (auto it = D->decls_begin(); it != D->decls_end(); ++it) {
Visit(*it);
skipCurrentDecl(false);
}
}