Uh oh!
There was an error while loading. Please reload this page.
doc: show that f32::log and f64::log are not correctly rounded - #47277
Conversation
rust-highfive
commented
Jan 8, 2018
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @aidanhs (or someone else) soon. If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes. Please see the contribution instructions for more information. |
hanna-kruppe
commented
Jan 8, 2018
FWIW I'm not a big fan of putting the implementation in the docs. |
aidanhs
commented
Jan 9, 2018
I'm inclined to agree. What about removing the implementation details and saying something like
? |
tspiteri
commented
Jan 9, 2018
I've removed the implementation details from the doc. (BTW, rust-highfive suggests extra commits for changes, which is what I did; if I should squash the commits into one please let me know.) |
hanna-kruppe
commented
Jan 9, 2018
Adding new commits can be useful for big changes, but for small things like this I personally don't see the need. In any case, we prefer to squash before merging. |
aidanhs
commented
Jan 9, 2018
This seems good to me but I'd like to get a docs team member to take a look - r? @frewsxcv |
frewsxcv
commented
Jan 13, 2018
looks good to me, thanks! @bors r+ rollup |
bors
commented
Jan 13, 2018
📌 Commit 6d82e78 has been approved by |
doc: show that `f32::log` and `f64::log` are not correctly rounded Fixesrust-lang#47273. One thing I'm not sure about is whether the "calculated as `self.ln() / base.ln()`" bit is being too specific, maybe we do not want to make this such a strong commitment. I think it's fine, but we should not make commitments in the API documentation by accident. In case that is removed, the added sentence "`self.log2()` can ... base 10." still makes it amply clear that the `log` methods can be more inaccurate than other methods. If the above clause is removed, this second sentence can be moved to the first paragraph, kind of like the accuracy comment for the [`mul_add`](https://doc.rust-lang.org/std/primitive.f32.html#method.mul_add) method.
doc: show that `f32::log` and `f64::log` are not correctly rounded Fixesrust-lang#47273. One thing I'm not sure about is whether the "calculated as `self.ln() / base.ln()`" bit is being too specific, maybe we do not want to make this such a strong commitment. I think it's fine, but we should not make commitments in the API documentation by accident. In case that is removed, the added sentence "`self.log2()` can ... base 10." still makes it amply clear that the `log` methods can be more inaccurate than other methods. If the above clause is removed, this second sentence can be moved to the first paragraph, kind of like the accuracy comment for the [`mul_add`](https://doc.rust-lang.org/std/primitive.f32.html#method.mul_add) method.
bors
commented
Jan 15, 2018
☔ The latest upstream changes (presumably #47445) made this pull request unmergeable. Please resolve the merge conflicts. |
Fixes#47273.
One thing I'm not sure about is whether the "calculated as
self.ln() / base.ln()" bit is being too specific, maybe we do not want to make this such a strong commitment. I think it's fine, but we should not make commitments in the API documentation by accident.In case that is removed, the added sentence "
self.log2()can ... base 10." still makes it amply clear that thelogmethods can be more inaccurate than other methods. If the above clause is removed, this second sentence can be moved to the first paragraph, kind of like the accuracy comment for themul_addmethod.