Skip to content

Commit be58ea7

Browse files
committed
valueflow.cpp: avoid unnecessary copies in valueFlowInferCondition()
1 parent 0edd83e commit be58ea7

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

lib/valueflow.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5070,8 +5070,7 @@ static void valueFlowInferCondition(TokenList& tokenlist, const Settings& settin
50705070
std::vector<ValueFlow::Value> result = infer(makeIntegralInferModel(), "!=", tok->values(), 0);
50715071
if (result.size() != 1)
50725072
continue;
5073-
ValueFlow::Value value = result.front();
5074-
setTokenValue(tok, std::move(value), settings);
5073+
setTokenValue(tok, std::move(result.front()), settings);
50755074
}
50765075
}
50775076
}

0 commit comments

Comments
 (0)