diff options
| author | Alex Crichton <alex@alexcrichton.com> | 2014-10-30 09:03:21 -0700 |
|---|---|---|
| committer | Alex Crichton <alex@alexcrichton.com> | 2014-10-30 17:37:55 -0700 |
| commit | c10c1633772aae3075f1d24c7741a074ddde5527 (patch) | |
| tree | 00b29edfa7f82b77e92ec4b67b4ba87e2987102e /src/libstd/num | |
| parent | 5d6241ddafa816ec48ad8af4b8f968b32bf61e41 (diff) | |
| parent | 1d356624a1c03363be37886ffdad7dcf25ee81f6 (diff) | |
| download | rust-c10c1633772aae3075f1d24c7741a074ddde5527.tar.gz rust-c10c1633772aae3075f1d24c7741a074ddde5527.zip | |
rollup merge of #18445 : alexcrichton/index-mut
Conflicts: src/libcollections/vec.rs
Diffstat (limited to 'src/libstd/num')
| -rw-r--r-- | src/libstd/num/strconv.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libstd/num/strconv.rs b/src/libstd/num/strconv.rs index f372cedecb6..3b17f0bc79f 100644 --- a/src/libstd/num/strconv.rs +++ b/src/libstd/num/strconv.rs @@ -424,10 +424,10 @@ pub fn float_to_str_bytes_common<T:NumCast+Zero+One+PartialEq+PartialOrd+Float+ // or set to 0 if max and carry the 1. let current_digit = ascii2value(buf[i as uint]); if current_digit < (radix - 1) { - *buf.get_mut(i as uint) = value2ascii(current_digit+1); + buf[i as uint] = value2ascii(current_digit+1); break; } else { - *buf.get_mut(i as uint) = value2ascii(0); + buf[i as uint] = value2ascii(0); i -= 1; } } |
