Skip to content

Commit 5338129

Browse files
committed
Address review comment.
1 parent afdb848 commit 5338129

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

clang/lib/Sema/CheckExprLifetime.cpp

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -457,15 +457,15 @@ static void visitFunctionCallArguments(IndirectLocalPath &Path, Expr *Call,
457457
I != N; ++I) {
458458
if (CheckCoroCall || Callee->getParamDecl(I)->hasAttr<LifetimeBoundAttr>())
459459
VisitLifetimeBoundArg(Callee->getParamDecl(I), Args[I]);
460-
else if (EnableGSLAnalysis && I == 0) {
461-
if (shouldTrackFirstArgument(Callee)) { // gsl
460+
else if (EnableGSLAnalysis && I == 0) { // GSL
461+
if (shouldTrackFirstArgument(Callee)) {
462462
VisitGSLPointerArg(Callee, Args[0],
463463
!Callee->getReturnType()->isReferenceType());
464-
} else {
465-
if (auto *CCE = dyn_cast<CXXConstructExpr>(Call);
466-
CCE && CCE->getConstructor()->getParent()->hasAttr<PointerAttr>())
467-
VisitGSLPointerArg(CCE->getConstructor()->getParamDecl(0), Args[0],
468-
true);
464+
} else if (auto *CCE = dyn_cast<CXXConstructExpr>(Call);
465+
CCE &&
466+
CCE->getConstructor()->getParent()->hasAttr<PointerAttr>()) {
467+
VisitGSLPointerArg(CCE->getConstructor()->getParamDecl(0), Args[0],
468+
true);
469469
}
470470
}
471471
}

0 commit comments

Comments
 (0)