Enable clippy::useless_conversion
(#8724)
This PR enables the [`clippy::useless_conversion`](https://rust-lang.github.io/rust-clippy/master/index.html#/useless_conversion) rule and fixes the outstanding violations. Release Notes: - N/A
This commit is contained in:
parent
87efb75e53
commit
4b81b15cad
21 changed files with 44 additions and 44 deletions
|
@ -365,7 +365,7 @@ impl TerminalElement {
|
|||
};
|
||||
|
||||
let mut result = TextRun {
|
||||
len: indexed.c.len_utf8() as usize,
|
||||
len: indexed.c.len_utf8(),
|
||||
color: fg,
|
||||
background_color: None,
|
||||
font: Font {
|
||||
|
@ -1015,10 +1015,10 @@ fn to_highlighted_range_lines(
|
|||
let mut line_end = layout.dimensions.columns();
|
||||
|
||||
if line == clamped_start_line {
|
||||
line_start = unclamped_start.column.0 as usize;
|
||||
line_start = unclamped_start.column.0;
|
||||
}
|
||||
if line == clamped_end_line {
|
||||
line_end = unclamped_end.column.0 as usize + 1; //+1 for inclusive
|
||||
line_end = unclamped_end.column.0 + 1; // +1 for inclusive
|
||||
}
|
||||
|
||||
highlighted_range_lines.push(HighlightedRangeLine {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue