Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

num::cast documentation is wrong #9870

Closed
metajack opened this issue Oct 15, 2013 · 1 comment · Fixed by #9900
Closed

num::cast documentation is wrong #9870

metajack opened this issue Oct 15, 2013 · 1 comment · Fixed by #9900
Labels
E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.

Comments

@metajack
Copy link
Contributor

num::cast now returns an Option<U> instead of U, so the examples are now incorrect.

@hatahet
Copy link
Contributor

hatahet commented Oct 16, 2013

You're referring to the comment in num.rs, correct? I can take care of this.

@bors bors closed this as completed in 2cb96a4 Oct 17, 2013
flip1995 pushed a commit to flip1995/rust that referenced this issue Nov 21, 2022
…rcho

Keep original literal notation in suggestion

While I did some investigation of rust-lang/rust-clippy#9866 (I couldn't reproduce it though) I found that `unused_rounding` formats as follows:

```rust
3.0_f64.round() // => 3.0f64
```

This PR makes them preserve as the original notation.

```rust
3.0_f64.round() // => 3.0_f64
```

changelog: Suggestion Enhancement: [`unused_rounding`]: The suggestion now preserves the original float literal notation
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants