From c80eaa919f210014312f77c4c73f502406b4989d Mon Sep 17 00:00:00 2001 From: owenca Date: Tue, 12 Apr 2022 14:28:02 -0700 Subject: [PATCH] Revert "[clang-format] Allow empty .clang-format file" This reverts commit 6eafda0ef0543cad4b190002e9dae93b036a4ded. --- clang/lib/Format/Format.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/clang/lib/Format/Format.cpp b/clang/lib/Format/Format.cpp index bce66d1..0bbd543 100644 --- a/clang/lib/Format/Format.cpp +++ b/clang/lib/Format/Format.cpp @@ -1722,7 +1722,7 @@ std::error_code parseConfiguration(llvm::MemoryBufferRef Config, FormatStyle::LanguageKind Language = Style->Language; assert(Language != FormatStyle::LK_None); if (Config.getBuffer().trim().empty()) - return make_error_code(ParseError::Success); + return make_error_code(ParseError::Error); Style->StyleSet.Clear(); std::vector Styles; llvm::yaml::Input Input(Config, /*Ctxt=*/nullptr, DiagHandler, -- 2.7.4