File tree 1 file changed +4
-2
lines changed
1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -779,7 +779,8 @@ simplify_exprt::simplify_typecast(const typecast_exprt &expr)
779
779
// (void*)(intX)expr -> (void*)expr
780
780
if (
781
781
expr_type.id () == ID_pointer && expr.op ().id () == ID_typecast &&
782
- (op_type.id () == ID_signedbv || op_type.id () == ID_unsignedbv) &&
782
+ (op_type.id () == ID_signedbv || op_type.id () == ID_unsignedbv ||
783
+ op_type.id () == ID_bv) &&
783
784
to_bitvector_type (op_type).get_width () >=
784
785
to_bitvector_type (expr_type).get_width ())
785
786
{
@@ -1305,7 +1306,8 @@ simplify_exprt::simplify_typecast(const typecast_exprt &expr)
1305
1306
// where T1 has fewer bits than T2
1306
1307
if (
1307
1308
op_type_id == expr_type_id &&
1308
- (expr_type_id == ID_unsignedbv || expr_type_id == ID_signedbv) &&
1309
+ (expr_type_id == ID_unsignedbv || expr_type_id == ID_signedbv ||
1310
+ expr_type_id == ID_bv) &&
1309
1311
to_bitvector_type (expr_type).get_width () <=
1310
1312
to_bitvector_type (operand.type ()).get_width ())
1311
1313
{
You can’t perform that action at this time.
0 commit comments