Skip to content

Commit 5399ca9

Browse files
authored
[clang][sema][NFC] Use a for-range loop in checkBuiltinVerboseTrap (#159114)
We don't use `I` at all, so use a for-range loop.
1 parent ec2ce34 commit 5399ca9

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

clang/lib/Sema/SemaChecking.cpp

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -177,9 +177,7 @@ bool Sema::checkArgCount(CallExpr *Call, unsigned DesiredArgCount) {
177177
static bool checkBuiltinVerboseTrap(CallExpr *Call, Sema &S) {
178178
bool HasError = false;
179179

180-
for (unsigned I = 0; I < Call->getNumArgs(); ++I) {
181-
Expr *Arg = Call->getArg(I);
182-
180+
for (const Expr *Arg : Call->arguments()) {
183181
if (Arg->isValueDependent())
184182
continue;
185183

0 commit comments

Comments
 (0)