mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-28 09:44:08 +00:00
Fix example
This commit is contained in:
parent
a427b12803
commit
9e9b3ddf69
@ -30,18 +30,12 @@ declare_clippy_lint! {
|
||||
///
|
||||
/// ### Example
|
||||
/// ```rust
|
||||
/// # fn foo(bar: usize) {}
|
||||
/// let x = Box::new(1);
|
||||
/// foo(*x);
|
||||
/// println!("{}", *x);
|
||||
/// fn foo(x: Box<u32>) {}
|
||||
/// ```
|
||||
///
|
||||
/// Use instead:
|
||||
/// ```rust
|
||||
/// # fn foo(bar: usize) {}
|
||||
/// let x = 1;
|
||||
/// foo(x);
|
||||
/// println!("{}", x);
|
||||
/// fn foo(x: u32) {}
|
||||
/// ```
|
||||
#[clippy::version = "pre 1.29.0"]
|
||||
pub BOXED_LOCAL,
|
||||
|
Loading…
Reference in New Issue
Block a user