Skip to content

Commit 9c933a0

Browse files
pfultz2Copilot
andauthored
Limit values size to a maximum of 10
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
1 parent 25e26ff commit 9c933a0

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

‎lib/programmemory.cpp‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,8 @@ void ProgramMemory::record(const Token* expr, const ValueFlow::Value& value)
183183
!values.front().isImpossible()) {
184184
values.assign(1, value);
185185
} else {
186+
if (values.size() >= 10U)
187+
return;
186188
values.push_back(value);
187189
Token::removeContradictions(values);
188190
}

0 commit comments

Comments
 (0)