@@ -33,9 +33,10 @@ class string_constraint_generatort: messaget
33
33
// string constraints for different string functions and add them
34
34
// to the axiom list.
35
35
36
- string_constraint_generatort ():
36
+ string_constraint_generatort (namespacet _ns ):
37
37
max_string_length (std::numeric_limits<size_t >::max()),
38
- force_printable_characters (false )
38
+ force_printable_characters (false ),
39
+ ns(_ns)
39
40
{ }
40
41
41
42
// Constraints on the maximal length of strings
@@ -107,6 +108,7 @@ class string_constraint_generatort: messaget
107
108
const std::size_t MAX_DOUBLE_LENGTH=30 ;
108
109
109
110
std::map<function_application_exprt, exprt> function_application_cache;
111
+ namespacet ns;
110
112
111
113
static irep_idt extract_java_string (const symbol_exprt &s);
112
114
@@ -305,16 +307,21 @@ class string_constraint_generatort: messaget
305
307
exprt add_axioms_for_offset_by_code_point (
306
308
const function_application_exprt &f);
307
309
308
- exprt add_axioms_for_characters_in_integer_string (
309
- const symbol_exprt& x,
310
- const typet& type,
311
- const typet& char_type,
312
- const typet& index_type,
313
- const string_exprt& str,
310
+ void add_axioms_for_characters_in_integer_string (
311
+ const exprt &input_int,
312
+ const typet &type,
313
+ const bool strict_formatting,
314
+ const string_exprt &str,
314
315
const std::size_t max_string_length,
315
- const exprt& radix);
316
+ const exprt &radix,
317
+ const unsigned long radix_ul);
316
318
void add_axioms_for_correct_number_format (
317
- const string_exprt &str, const exprt &radix, std::size_t max_size);
319
+ const exprt &input_int,
320
+ const string_exprt &str,
321
+ const exprt &radix_as_char,
322
+ const unsigned long radix_ul,
323
+ const std::size_t max_size,
324
+ const bool strict_formatting);
318
325
exprt add_axioms_for_parse_int (const function_application_exprt &f);
319
326
exprt add_axioms_for_to_char_array (const function_application_exprt &f);
320
327
exprt add_axioms_for_compare_to (const function_application_exprt &f);
@@ -348,18 +355,21 @@ class string_constraint_generatort: messaget
348
355
exprt char1, exprt char2, exprt char_a, exprt char_A, exprt char_Z);
349
356
bool is_constant_string (const string_exprt &expr) const ;
350
357
string_exprt empty_string (const refined_string_typet &ref_type);
358
+ unsigned long to_integer_or_default (const exprt &expr, unsigned long def);
351
359
};
352
360
353
- exprt is_digit_with_radix (const exprt &chr, const exprt &radix);
354
- exprt is_digit_with_radix_lower_case (
355
- const exprt &chr, const exprt &radix_char_type, unsigned long radix=36ul );
361
+ exprt is_digit_with_radix (
362
+ const exprt &chr,
363
+ const bool strict_formatting,
364
+ const exprt &radix_as_char,
365
+ const unsigned long radix_ul);
356
366
exprt get_numeric_value_from_character (
357
367
const exprt &chr,
358
368
const typet &char_type,
359
369
const typet &type,
360
- unsigned long radix=36ul );
370
+ const bool strict_formatting,
371
+ unsigned long radix_ul);
361
372
size_t max_printed_string_length (const typet &type, unsigned long ul_radix);
362
- unsigned long to_integer_or_default (const exprt &expr, unsigned long def);
363
373
std::string utf16_constant_array_to_java (
364
374
const array_exprt &arr, unsigned length);
365
375
0 commit comments