Basic module

string_to_float_new

procedureSource

Like string_to_float, with the success flag first.

string_to_float_new :: (
    arg: string
) -> (success: bool, result: float, remainder: string)

Parameters

arg: string

Returns

success: bool
result: float
remainder: string
Example↗
ok, value, rest := string_to_float_new("2.5");
assert(ok && value == 2.5 && rest.count == 0);

See also