1 .TH fl_conversion_dynamic_partial_to_unsigned_detect "3" "July 2023" "FLL - Featureless Linux Library 0.6.7" "Library Functions"
3 fl_conversion_dynamic_partial_to_unsigned_detect
6 .B #include <fll/level_1/conversion.h>
8 \fBf_status_t fl_conversion_dynamic_partial_to_unsigned_detect\fP(
9 \fBconst fl_conversion_data_t \fP\fIdata\fP,
10 \fBconst f_string_static_t \fP\fIbuffer\fP,
11 \fBconst f_string_range_t \fP\fIrange\fP,
12 \fBf_number_unsigned_t *const \fP\fInumber\fP
17 Convert a series of positive number characters into an f_number_unsigned_t.
19 decimal is used for all other cases.
21 Leading 0's and whitespace are ignored. Whitespace after the first digit is considered invalid.
23 This function is similar to strtoull(), but the behavior of error handling and special bases are different. In particular, octals are specified here with '0b' prefix or '0B' prefix instead of the ridiculous '0' prefix. Negative values are reported as such instead of being converted into the unsigned equivalent.
27 Conversion data for specifying things such as treating this as a negative number. This auto-detects the base and negative, ignoring the base number and negative flag.
31 The string to convert.
35 The start/stop range to convert.
39 This will store the value of the converted string. This value is only changed on success.
43 \fBF_none\fP on success.
45 \fBF_data_not\fP if string starts with a null (length is 0).
47 \fBF_base_not\fP (with error bit) if no supported or valid base unit is provided.
49 \fBF_complete_not_utf\fP (with error bit) if an incomplete UTF-8 fragment is found.
51 \fBF_number\fP (with error bit) if parameter is not a number.
53 \fBF_number_decimal\fP (with error bit) if number has a decimal digit.
55 \fBF_number_negative\fP (with error bit) on negative value.
57 \fBF_number_positive\fP (with error bit) on positive value (has a +, such as '+1', when only '1' is valid here).
59 \fBF_number_overflow\fP (with error bit) on integer overflow.
61 \fBF_parameter\fP (with error bit) if a parameter is invalid.
66 Copyright \(co 2007-2023 Kevin Day, GNU LGPL Version 2.1 or later.