From 61bd3a1dc612af9bde0765f9f4e6c2847554d2ac Mon Sep 17 00:00:00 2001 From: Daniel Jasper Date: Tue, 4 Dec 2012 21:05:31 +0000 Subject: Add missing destructors found with -Wnon-virtual-dtor. llvm-svn: 169303 --- clang/lib/Format/Format.cpp | 3 +++ clang/lib/Format/UnwrappedLineParser.h | 2 ++ 2 files changed, 5 insertions(+) (limited to 'clang/lib/Format') diff --git a/clang/lib/Format/Format.cpp b/clang/lib/Format/Format.cpp index 87deccbb376..d928aa95804 100644 --- a/clang/lib/Format/Format.cpp +++ b/clang/lib/Format/Format.cpp @@ -686,6 +686,9 @@ public: StructuralError(false) { } + virtual ~Formatter() { + } + tooling::Replacements format() { UnwrappedLineParser Parser(Lex, SourceMgr, *this); StructuralError = Parser.parse(); diff --git a/clang/lib/Format/UnwrappedLineParser.h b/clang/lib/Format/UnwrappedLineParser.h index 63f3659706b..20ff4f55d69 100644 --- a/clang/lib/Format/UnwrappedLineParser.h +++ b/clang/lib/Format/UnwrappedLineParser.h @@ -71,6 +71,8 @@ struct UnwrappedLine { class UnwrappedLineConsumer { public: + virtual ~UnwrappedLineConsumer() { + } virtual void formatUnwrappedLine(const UnwrappedLine &Line) = 0; }; -- cgit v1.2.3