File tree 1 file changed +6
-4
lines changed
1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -1417,8 +1417,9 @@ class pointer_typet:public bitvector_typet
1417
1417
inline const pointer_typet &to_pointer_type (const typet &type)
1418
1418
{
1419
1419
PRECONDITION (type.id ()==ID_pointer);
1420
- PRECONDITION (!type.get (ID_width).empty ());
1421
- return static_cast <const pointer_typet &>(type);
1420
+ const pointer_typet &ret = static_cast <const pointer_typet &>(type);
1421
+ validate_type (ret);
1422
+ return ret;
1422
1423
}
1423
1424
1424
1425
/* ! \copydoc to_pointer_type(const typet &)
@@ -1427,8 +1428,9 @@ inline const pointer_typet &to_pointer_type(const typet &type)
1427
1428
inline pointer_typet &to_pointer_type (typet &type)
1428
1429
{
1429
1430
PRECONDITION (type.id ()==ID_pointer);
1430
- PRECONDITION (!type.get (ID_width).empty ());
1431
- return static_cast <pointer_typet &>(type);
1431
+ pointer_typet &ret = static_cast <pointer_typet &>(type);
1432
+ validate_type (ret);
1433
+ return ret;
1432
1434
}
1433
1435
1434
1436
template <>
You can’t perform that action at this time.
0 commit comments