Load the specified result with the specified value, even if a non-zero status is returned (truncating fractional digits if necessary). Return 0 on success, k_OVERFLOW if value is larger than can be represented by result, k_UNDERFLOW if value is smaller than can be represented by result, and k_NOT_INTEGRAL if value is not an integral number (i.e., there is a fractional part). For underflow, result will be loaded with the minimum representable value, for overflow, result will be loaded with the maximum representable value, for non-integral values result will be loaded with the integer part of value (truncating the fractional part of value). The behavior is undefined unless isValidNumber(value) is true. Note that this operation will correctly handle exponents (e.g., a value of "0.00000000000000000001e20" will produce a result of 1).
Declared in <bdljsn_numberutil.h>
static
int
asShort(
short* result,
std::string_view const& value);