graydon/rust — pull request #1030 by Yoric (2011-10-12 09:02:49+00:00)
Title: Fix #1015

This should fix issue #1015. I have reimplemented `str_to_float` to extend the grammar that it can parse. Including, say, strings with a decimal part :)

I take the opportunity to replace the implementation of `int::pow` to use fast exponentiation, to add a few functions to the new `float` module, as well as a few tests. I also renamed `str_to_float` and `float_to_str` into `float::from_str` and `float::to_str`, to harmonize with the `int` module.