summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Reynolds <andrew.j.reynolds@gmail.com>2020-12-04 12:26:12 -0600
committerGitHub <noreply@github.com>2020-12-04 19:26:12 +0100
commit144b9610867ad4ea021f690f25151e60ab6bce65 (patch)
treed1f4b6d561bd39a6e499f4761f9d1be66e8551e3
parentcba58392bcd234e9b09095a36e012b0b0cff6ba5 (diff)
Fix bug in hasBoundVar (#5600)
Led to issues while debugging another issue related to free variables in assumptions.
-rw-r--r--src/expr/node_algorithm.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/expr/node_algorithm.cpp b/src/expr/node_algorithm.cpp
index 9d1c6ab41..f41bef37b 100644
--- a/src/expr/node_algorithm.cpp
+++ b/src/expr/node_algorithm.cpp
@@ -261,7 +261,11 @@ bool hasBoundVar(TNode n)
{
for (auto i = n.begin(); i != n.end() && !hasBv; ++i)
{
- hasBv = hasBoundVar(*i);
+ if (hasBoundVar(*i))
+ {
+ hasBv = true;
+ break;
+ }
}
}
if (!hasBv && n.hasOperator())
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback