@@ -166,7 +166,7 @@ bool simplify_exprt::simplify_mult(exprt &expr)
166
166
exprt::operandst &operands=expr.operands ();
167
167
168
168
// result of the simplification
169
- bool result = true ;
169
+ bool no_change = true ;
170
170
171
171
// position of the constant
172
172
exprt::operandst::iterator constant;
@@ -226,7 +226,7 @@ bool simplify_exprt::simplify_mult(exprt &expr)
226
226
if (do_erase)
227
227
{
228
228
it=operands.erase (it);
229
- result = false ;
229
+ no_change = false ;
230
230
}
231
231
else
232
232
it++; // move to the next operand
@@ -246,7 +246,7 @@ bool simplify_exprt::simplify_mult(exprt &expr)
246
246
exprt product (operands.front ());
247
247
expr.swap (product);
248
248
249
- result = false ;
249
+ no_change = false ;
250
250
}
251
251
else
252
252
{
@@ -255,7 +255,7 @@ bool simplify_exprt::simplify_mult(exprt &expr)
255
255
{
256
256
// just delete it
257
257
operands.erase (constant);
258
- result= false ;
258
+ no_change = false ;
259
259
260
260
if (operands.size ()==1 )
261
261
{
@@ -265,7 +265,7 @@ bool simplify_exprt::simplify_mult(exprt &expr)
265
265
}
266
266
}
267
267
268
- return result ;
268
+ return no_change ;
269
269
}
270
270
271
271
bool simplify_exprt::simplify_div (exprt &expr)
@@ -428,7 +428,7 @@ bool simplify_exprt::simplify_plus(exprt &expr)
428
428
if (!is_number (plus_expr.type ()) && plus_expr.type ().id () != ID_pointer)
429
429
return true ;
430
430
431
- bool result= true ;
431
+ bool no_change = true ;
432
432
433
433
exprt::operandst &operands=expr.operands ();
434
434
@@ -506,7 +506,7 @@ bool simplify_exprt::simplify_plus(exprt &expr)
506
506
to_constant_expr (*it)))
507
507
{
508
508
*it=from_integer (0 , it->type ());
509
- result= false ;
509
+ no_change = false ;
510
510
}
511
511
}
512
512
}
@@ -539,7 +539,7 @@ bool simplify_exprt::simplify_plus(exprt &expr)
539
539
*(itm->second )=from_integer (0 , expr.type ());
540
540
*it=from_integer (0 , expr.type ());
541
541
expr_map.erase (itm);
542
- result= false ;
542
+ no_change = false ;
543
543
}
544
544
}
545
545
@@ -554,7 +554,7 @@ bool simplify_exprt::simplify_plus(exprt &expr)
554
554
if (is_number (it->type ()) && it->is_zero ())
555
555
{
556
556
it=operands.erase (it);
557
- result= false ;
557
+ no_change = false ;
558
558
}
559
559
else
560
560
it++;
@@ -573,7 +573,7 @@ bool simplify_exprt::simplify_plus(exprt &expr)
573
573
return false ;
574
574
}
575
575
576
- return result ;
576
+ return no_change ;
577
577
}
578
578
579
579
bool simplify_exprt::simplify_minus (exprt &expr)
@@ -694,7 +694,7 @@ bool simplify_exprt::simplify_bitwise(exprt &expr)
694
694
}
695
695
}
696
696
697
- bool result= true ;
697
+ bool no_change = true ;
698
698
699
699
// try to merge constants
700
700
@@ -740,7 +740,7 @@ bool simplify_exprt::simplify_bitwise(exprt &expr)
740
740
expr.operands ().erase (expr.operands ().begin ());
741
741
expr.op0 ().swap (new_op);
742
742
743
- result= false ;
743
+ no_change = false ;
744
744
}
745
745
746
746
// now erase 'all zeros' out of bitor, bitxor
@@ -755,7 +755,7 @@ bool simplify_exprt::simplify_bitwise(exprt &expr)
755
755
if (it->is_zero () && expr.operands ().size ()>1 )
756
756
{
757
757
it=expr.operands ().erase (it);
758
- result= false ;
758
+ no_change = false ;
759
759
}
760
760
else
761
761
it++;
@@ -779,7 +779,7 @@ bool simplify_exprt::simplify_bitwise(exprt &expr)
779
779
expr.operands ().size () > 1 )
780
780
{
781
781
it=expr.operands ().erase (it);
782
- result= false ;
782
+ no_change = false ;
783
783
}
784
784
else
785
785
it++;
@@ -814,7 +814,7 @@ bool simplify_exprt::simplify_bitwise(exprt &expr)
814
814
return false ;
815
815
}
816
816
817
- return result ;
817
+ return no_change ;
818
818
}
819
819
820
820
bool simplify_exprt::simplify_extractbit (exprt &expr)
@@ -853,7 +853,7 @@ bool simplify_exprt::simplify_extractbit(exprt &expr)
853
853
854
854
bool simplify_exprt::simplify_concatenation (exprt &expr)
855
855
{
856
- bool result= true ;
856
+ bool no_change = true ;
857
857
858
858
if (is_bitvector_type (expr.type ()))
859
859
{
@@ -865,7 +865,7 @@ bool simplify_exprt::simplify_concatenation(exprt &expr)
865
865
{
866
866
const bool value = op.is_true ();
867
867
op = from_integer (value, unsignedbv_typet (1 ));
868
- result = false ;
868
+ no_change = false ;
869
869
}
870
870
}
871
871
@@ -899,7 +899,7 @@ bool simplify_exprt::simplify_concatenation(exprt &expr)
899
899
to_bitvector_type (opi.type ()).set_width (new_width);
900
900
// erase opn
901
901
expr.operands ().erase (expr.operands ().begin ()+i+1 );
902
- result = false ;
902
+ no_change = false ;
903
903
}
904
904
else
905
905
i++;
@@ -930,7 +930,7 @@ bool simplify_exprt::simplify_concatenation(exprt &expr)
930
930
opi.type ().id (ID_verilog_unsignedbv);
931
931
// erase opn
932
932
expr.operands ().erase (expr.operands ().begin ()+i+1 );
933
- result = false ;
933
+ no_change = false ;
934
934
}
935
935
else
936
936
i++;
@@ -943,10 +943,10 @@ bool simplify_exprt::simplify_concatenation(exprt &expr)
943
943
exprt tmp;
944
944
tmp.swap (expr.op0 ());
945
945
expr.swap (tmp);
946
- result= false ;
946
+ no_change = false ;
947
947
}
948
948
949
- return result ;
949
+ return no_change ;
950
950
}
951
951
952
952
bool simplify_exprt::simplify_shifts (exprt &expr)
@@ -1530,23 +1530,23 @@ bool simplify_exprt::eliminate_common_addends(
1530
1530
1531
1531
if (op0.id ()==ID_plus)
1532
1532
{
1533
- bool result= true ;
1533
+ bool no_change = true ;
1534
1534
1535
1535
Forall_operands (it, op0)
1536
1536
if (!eliminate_common_addends (*it, op1))
1537
- result= false ;
1537
+ no_change = false ;
1538
1538
1539
- return result ;
1539
+ return no_change ;
1540
1540
}
1541
1541
else if (op1.id ()==ID_plus)
1542
1542
{
1543
- bool result= true ;
1543
+ bool no_change = true ;
1544
1544
1545
1545
Forall_operands (it, op1)
1546
1546
if (!eliminate_common_addends (op0, *it))
1547
- result= false ;
1547
+ no_change = false ;
1548
1548
1549
- return result ;
1549
+ return no_change ;
1550
1550
}
1551
1551
else if (op0==op1)
1552
1552
{
0 commit comments