}
else if (current.getNumChildren() > 2
&& (current.getKind() == kind::PLUS
- || current.getKind() == kind::MULT))
+ || current.getKind() == kind::MULT
+ || current.getKind() == kind::NONLINEAR_MULT))
{
Assert(cache.find(current[0]) != cache.end());
result = cache[current[0]];
{
// Not a leaf
vector<Node> children;
- unsigned max = 0;
- for (unsigned i = 0; i < current.getNumChildren(); ++i)
+ uint64_t max = 0;
+ for (const Node& nc : current)
{
- Assert(cache.find(current[i]) != cache.end());
- TNode childRes = cache[current[i]];
+ Assert(cache.find(nc) != cache.end());
+ TNode childRes = cache[nc];
TypeNode type = childRes.getType();
if (type.isBitVector())
{
- unsigned bvsize = type.getBitVectorSize();
+ uint32_t bvsize = type.getBitVectorSize();
if (bvsize > max)
{
max = bvsize;
max = max + 1;
break;
case kind::MULT:
+ case kind::NONLINEAR_MULT:
Assert(children.size() == 2);
newKind = kind::BITVECTOR_MULT;
max = max * 2;
}
break;
}
- for (unsigned i = 0; i < children.size(); ++i)
+ for (size_t i = 0, csize = children.size(); i < csize; ++i)
{
TypeNode type = children[i].getType();
if (!type.isBitVector())
{
continue;
}
- unsigned bvsize = type.getBitVectorSize();
+ uint32_t bvsize = type.getBitVectorSize();
if (bvsize < max)
{
// sign extend
if (current.getMetaKind() == kind::metakind::PARAMETERIZED) {
builder << current.getOperator();
}
- for (unsigned i = 0; i < children.size(); ++i)
- {
- builder << children[i];
- }
+ builder.append(children);
// Mark the substitution and continue
Node result = builder;
{
Rational constant = current.getConst<Rational>();
if (constant.isIntegral()) {
- AlwaysAssert(constant >= 0);
BitVector bv(size, constant.getNumerator());
if (bv.toSignedInteger() != constant.getNumerator())
{
regress0/incorrect1.smtv1.smt2
regress0/ineq_basic.smtv1.smt2
regress0/ineq_slack.smtv1.smt2
+ regress0/int-to-bv/basic.smt2
+ regress0/int-to-bv/neg-consts.smt2
+ regress0/int-to-bv/not-enough-bits.smt2
+ regress0/int-to-bv/overflow.smt2
regress0/issue1063-overloading-dt-cons.smt2
regress0/issue1063-overloading-dt-fun.smt2
regress0/issue1063-overloading-dt-sel.smt2