Skip to content

Commit

Permalink
Fix clippy warnings: constants have by default a 'static lifetime (#107)
Browse files Browse the repository at this point in the history
warning: constants have by default a `'static` lifetime
  --> src/pb.rs:19:16
   |
19 | const FORMAT: &'static str = "[=>-]";
   |               -^^^^^^^---- help: consider removing `'static`: `&str`
   |
   = note: `#[warn(clippy::redundant_static_lifetimes)]` on by default
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_static_lifetimes

warning: constants have by default a `'static` lifetime
  --> src/pb.rs:20:21
   |
20 | const TICK_FORMAT: &'static str = "\\|/-";
   |                    -^^^^^^^---- help: consider removing `'static`: `&str`
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_static_lifetimes
  • Loading branch information
LingMan committed Jul 2, 2022
1 parent a68277e commit b92ee9a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/pb.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ macro_rules! kb_fmt {
}};
}

const FORMAT: &'static str = "[=>-]";
const TICK_FORMAT: &'static str = "\\|/-";
const FORMAT: &str = "[=>-]";
const TICK_FORMAT: &str = "\\|/-";

// Output type format, indicate which format wil be used in
// the speed box.
Expand Down

0 comments on commit b92ee9a

Please sign in to comment.