File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -850,14 +850,16 @@ bvt bv_pointers_widet::add_addr(const exprt &expr)
850850
851851 const pointer_typet type = pointer_type (expr.type ());
852852 const std::size_t object_bits = get_object_width (type);
853- const std:: size_t max_objects = std::size_t ( 1 ) << object_bits;
853+ const mp_integer max_objects = power ( 2 , object_bits) ;
854854
855- if (a == max_objects)
855+ if (a >= max_objects)
856+ {
856857 throw analysis_exceptiont (
857858 " too many addressed objects: maximum number of objects is set to 2^n=" +
858- std::to_string (max_objects) + " (with n=" + std::to_string (object_bits) +
859+ integer2string (max_objects) + " (with n=" + std::to_string (object_bits) +
859860 " ); " +
860861 " use the `--object-bits n` option to increase the maximum number" );
862+ }
861863
862864 return encode (a, type);
863865}
You can’t perform that action at this time.
0 commit comments