uce/site/doc/pages/2_DValue_to_f64.txt
2026-06-16 12:21:31 +00:00

20 lines
412 B
Plaintext

:sig
f64 DValue::to_f64(f64 default_value = 0) const
:params
f64 : fallback returned when conversion is not possible
return value : converted value or the fallback
:see
>types
0_DValue
2_DValue_get_by_path
:content
Converts strings, f64, bool, pointer, and single-value maps to a finite double. Invalid or empty strings return the default.
:example
DValue value;
value = "12.5";
print(value.to_f64(), "\n");