diff --git a/clang/lib/Format/Format.cpp b/clang/lib/Format/Format.cpp --- a/clang/lib/Format/Format.cpp +++ b/clang/lib/Format/Format.cpp @@ -2603,7 +2603,7 @@ ArrayRef Ranges, StringRef FileName, unsigned *Cursor) { tooling::Replacements Replaces; - if (!Style.SortIncludes) + if (!Style.SortIncludes || Style.DisableFormat) return Replaces; if (isLikelyXml(Code)) return Replaces;