Skip to content

Commit

Permalink
don't run example as a test because it would wait forever
Browse files Browse the repository at this point in the history
  • Loading branch information
y21 committed Jul 2, 2023
1 parent a95e707 commit 8000b44
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions clippy_lints/src/methods/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3326,14 +3326,14 @@ declare_clippy_lint! {
/// The `.parse()` call will always fail.
///
/// ### Example
/// ```rust
/// ```rust,ignore
/// let mut input = String::new();
/// std::io::stdin().read_line(&mut input).expect("Failed to read a line");
/// let num: i32 = input.parse().expect("Not a number!");
/// assert_eq!(num, 42); // we never even get here!
/// ```
/// Use instead:
/// ```rust
/// ```rust,ignore
/// let mut input = String::new();
/// std::io::stdin().read_line(&mut input).expect("Failed to read a line");
/// let num: i32 = input.trim_end().parse().expect("Not a number!");
Expand Down

0 comments on commit 8000b44

Please sign in to comment.