summaryrefslogtreecommitdiffstats
path: root/include/clang/Frontend/ChainedDiagnosticConsumer.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/clang/Frontend/ChainedDiagnosticConsumer.h')
-rw-r--r--include/clang/Frontend/ChainedDiagnosticConsumer.h10
1 files changed, 8 insertions, 2 deletions
diff --git a/include/clang/Frontend/ChainedDiagnosticConsumer.h b/include/clang/Frontend/ChainedDiagnosticConsumer.h
index f20cf6f..ce2b242 100644
--- a/include/clang/Frontend/ChainedDiagnosticConsumer.h
+++ b/include/clang/Frontend/ChainedDiagnosticConsumer.h
@@ -21,8 +21,9 @@ class LangOptions;
/// should be the "primary" client, and will be used for computing whether the
/// diagnostics should be included in counts.
class ChainedDiagnosticConsumer : public DiagnosticConsumer {
- llvm::OwningPtr<DiagnosticConsumer> Primary;
- llvm::OwningPtr<DiagnosticConsumer> Secondary;
+ virtual void anchor();
+ OwningPtr<DiagnosticConsumer> Primary;
+ OwningPtr<DiagnosticConsumer> Secondary;
public:
ChainedDiagnosticConsumer(DiagnosticConsumer *_Primary,
@@ -42,6 +43,11 @@ public:
Primary->EndSourceFile();
}
+ virtual void finish() {
+ Secondary->finish();
+ Primary->finish();
+ }
+
virtual bool IncludeInDiagnosticCounts() const {
return Primary->IncludeInDiagnosticCounts();
}
OpenPOWER on IntegriCloud