Skip to content

Commit d17e4ba

Browse files
committed
Simplifier: do not create extractbits with pointer type
This is a fix-up for 525c23d: we must not remove typecasts towards pointers when the operand is extractbits as our back-ends do not support extractbits with pointer type.
1 parent d148ae6 commit d17e4ba

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/util/simplify_expr.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1343,6 +1343,7 @@ simplify_exprt::simplify_typecast(const typecast_exprt &expr)
13431343
{
13441344
if(
13451345
can_cast_type<bitvector_typet>(expr_type) &&
1346+
expr_type_id != ID_pointer &&
13461347
can_cast_type<bitvector_typet>(operand.type()) &&
13471348
to_bitvector_type(expr_type).get_width() ==
13481349
to_bitvector_type(operand.type()).get_width())

0 commit comments

Comments
 (0)