Skip to content

Commit 35fd677

Browse files
committed
Format
1 parent e8355eb commit 35fd677

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

lib/valueflow.cpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2869,7 +2869,7 @@ static void valueFlowLifetimeClassConstructor(Token* tok,
28692869
args,
28702870
"Passed to constructor of '" + t->name() + "'.",
28712871
ValueFlow::Value::LifetimeKind::SubObject,
2872-
[&](LifetimeStore &ls) {
2872+
[&](LifetimeStore& ls) {
28732873
// Skip static variable
28742874
it = std::find_if(it, scope->varlist.cend(), [&](const Variable &var) {
28752875
return !var.isStatic() && (!hasDesignatedInitializers || var.name() == ls.argtok->astOperand1()->astOperand1()->str());
@@ -2883,8 +2883,7 @@ static void valueFlowLifetimeClassConstructor(Token* tok,
28832883
return; // TODO: check in isLifetimeBorrowed()?
28842884
if (var.isReference() || var.isRValueReference()) {
28852885
ls.byRef(tok, tokenlist, errorLogger, settings);
2886-
}
2887-
else if (ValueFlow::isLifetimeBorrowed(ls.argtok, settings)) {
2886+
} else if (ValueFlow::isLifetimeBorrowed(ls.argtok, settings)) {
28882887
ls.byVal(tok, tokenlist, errorLogger, settings);
28892888
}
28902889
if (hasDesignatedInitializers)

0 commit comments

Comments
 (0)