aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Format/UnwrappedLineParser.cpp
diff options
context:
space:
mode:
authorOwen Pan <owenpiano@gmail.com>2025-07-06 23:50:00 -0700
committerOwen Pan <owenpiano@gmail.com>2025-07-06 23:54:00 -0700
commita5af8745039f906c4fc4184a1fe0d35d42355f52 (patch)
tree16a59d61437304d7a4bdb23258232a030be7a108 /clang/lib/Format/UnwrappedLineParser.cpp
parent0fbaeafd7ff725d6e7705d934638a7917fc8a3f1 (diff)
downloadllvm-a5af8745039f906c4fc4184a1fe0d35d42355f52.zip
llvm-a5af8745039f906c4fc4184a1fe0d35d42355f52.tar.gz
llvm-a5af8745039f906c4fc4184a1fe0d35d42355f52.tar.bz2
[clang-format][NFC] Use `empty()` instead of comparing size() to 0 or 1
Diffstat (limited to 'clang/lib/Format/UnwrappedLineParser.cpp')
-rw-r--r--clang/lib/Format/UnwrappedLineParser.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/Format/UnwrappedLineParser.cpp b/clang/lib/Format/UnwrappedLineParser.cpp
index c961ce7..7e8634a 100644
--- a/clang/lib/Format/UnwrappedLineParser.cpp
+++ b/clang/lib/Format/UnwrappedLineParser.cpp
@@ -4601,7 +4601,7 @@ void UnwrappedLineParser::addUnwrappedLine(LineLevel AdjustLevel) {
} else {
// At the top level we only get here when no unexpansion is going on, or
// when conditional formatting led to unfinished macro reconstructions.
- assert(!Reconstruct || (CurrentLines != &Lines) || PPStack.size() > 0);
+ assert(!Reconstruct || (CurrentLines != &Lines) || !PPStack.empty());
CurrentLines->push_back(std::move(*Line));
}
Line->Tokens.clear();