Enable clippy::needless_borrowed_reference
(#8746)
This PR enables the [`clippy::needless_borrowed_reference`](https://rust-lang.github.io/rust-clippy/master/index.html#/needless_borrowed_reference) rule and fixes the outstanding violations. Release Notes: - N/A
This commit is contained in:
parent
bd00aed7db
commit
ca9d5a2f6b
2 changed files with 1 additions and 2 deletions
|
@ -3273,7 +3273,7 @@ impl PositionMap {
|
||||||
let (column, x_overshoot_after_line_end) = if let Some(line) = self
|
let (column, x_overshoot_after_line_end) = if let Some(line) = self
|
||||||
.line_layouts
|
.line_layouts
|
||||||
.get(row as usize - scroll_position.y as usize)
|
.get(row as usize - scroll_position.y as usize)
|
||||||
.map(|&LineWithInvisibles { ref line, .. }| line)
|
.map(|LineWithInvisibles { line, .. }| line)
|
||||||
{
|
{
|
||||||
if let Some(ix) = line.index_for_x(x) {
|
if let Some(ix) = line.index_for_x(x) {
|
||||||
(ix as u32, px(0.))
|
(ix as u32, px(0.))
|
||||||
|
|
|
@ -100,7 +100,6 @@ fn run_clippy(args: ClippyArgs) -> Result<()> {
|
||||||
"clippy::iter_overeager_cloned",
|
"clippy::iter_overeager_cloned",
|
||||||
"clippy::let_underscore_future",
|
"clippy::let_underscore_future",
|
||||||
"clippy::map_entry",
|
"clippy::map_entry",
|
||||||
"clippy::needless_borrowed_reference",
|
|
||||||
"clippy::needless_lifetimes",
|
"clippy::needless_lifetimes",
|
||||||
"clippy::needless_option_as_deref",
|
"clippy::needless_option_as_deref",
|
||||||
"clippy::needless_question_mark",
|
"clippy::needless_question_mark",
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue