diff --git a/clang/include/clang/Basic/Diagnostic.h b/clang/include/clang/Basic/Diagnostic.h index 3b7c282d37ad..8e6bc2dea2e1 100644 --- a/clang/include/clang/Basic/Diagnostic.h +++ b/clang/include/clang/Basic/Diagnostic.h @@ -1264,7 +1264,7 @@ class StoredDiagnostic { std::vector FixIts; public: - StoredDiagnostic(); + StoredDiagnostic() = default; StoredDiagnostic(DiagnosticsEngine::Level Level, const Diagnostic &Info); StoredDiagnostic(DiagnosticsEngine::Level Level, unsigned ID, StringRef Message); @@ -1272,7 +1272,6 @@ public: StringRef Message, FullSourceLoc Loc, ArrayRef Ranges, ArrayRef Fixits); - ~StoredDiagnostic(); /// \brief Evaluates true when this object stores a diagnostic. explicit operator bool() const { return Message.size() > 0; } diff --git a/clang/lib/Basic/Diagnostic.cpp b/clang/lib/Basic/Diagnostic.cpp index f89caf7b248f..0caa876a57b7 100644 --- a/clang/lib/Basic/Diagnostic.cpp +++ b/clang/lib/Basic/Diagnostic.cpp @@ -945,8 +945,6 @@ FormatDiagnostic(const char *DiagStr, const char *DiagEnd, OutStr.append(Tree.begin(), Tree.end()); } -StoredDiagnostic::StoredDiagnostic() { } - StoredDiagnostic::StoredDiagnostic(DiagnosticsEngine::Level Level, unsigned ID, StringRef Message) : ID(ID), Level(Level), Loc(), Message(Message) { } @@ -975,8 +973,6 @@ StoredDiagnostic::StoredDiagnostic(DiagnosticsEngine::Level Level, unsigned ID, { } -StoredDiagnostic::~StoredDiagnostic() { } - /// IncludeInDiagnosticCounts - This method (whose default implementation /// returns true) indicates whether the diagnostics handled by this /// DiagnosticConsumer should be included in the number of diagnostics