Skip to content

Commit 309d9ba

Browse files
committed
dec2flt: Provide more valid inputs examples
I was just looking at the specifics of how the parsing is handled here and I wasn't sure if the examples were incomplete or the grammar below was misleading. The grammar was correct so I figured I'd add these examples to clarify.
1 parent bfb736f commit 309d9ba

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

core/src/num/dec2flt/mod.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,8 @@ macro_rules! from_str_float_impl {
124124
/// * '2.5E-10'
125125
/// * '5.'
126126
/// * '.5', or, equivalently, '0.5'
127+
/// * '5'
128+
/// * '005'
127129
/// * 'inf', '-inf', '+infinity', 'NaN'
128130
///
129131
/// Note that alphabetical characters are not case-sensitive.

0 commit comments

Comments
 (0)