diff options
-rw-r--r-- | clang/lib/Format/Format.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/Format/Format.cpp b/clang/lib/Format/Format.cpp index 2252dd97436..dfeb5d9d079 100644 --- a/clang/lib/Format/Format.cpp +++ b/clang/lib/Format/Format.cpp @@ -466,7 +466,7 @@ template <> struct DocumentListTraits<std::vector<FormatStyle>> { if (Index >= Seq.size()) { assert(Index == Seq.size()); FormatStyle Template; - if (Seq.size() > 0 && Seq[0].Language == FormatStyle::LK_None) { + if (!Seq.empty() && Seq[0].Language == FormatStyle::LK_None) { Template = Seq[0]; } else { Template = *((const FormatStyle *)IO.getContext()); |