rust-analyzer/crates/syntax/src
Yuri Astrakhan d3dbf9c194 Moar linting: needless_borrow, let_unit_value, ...
* There are a few needless borrows that don't seem to be needed. I even did a quick assembly comparison and posted a q to stackoveflow on it. See [here](https://stackoverflow.com/questions/74910196/advantages-of-pass-by-ref-val-with-impl-intoiteratoritem-impl-asrefstr)
* removed several `let _ = ...` when they don't look necessary (even a few ones that were not suggested by clippy (?))
* there were a few `then(|| ctor{})` that clippy suggested to replace with `then_some(ctor{})` -- seems reasonable?
* some unneeded assignment+return - keep the code a bit leaner
* a few `writeln!` instead of `write!`, or even consolidate write!
* a nice optimization to use `ch.is_ascii_digit` instead of `ch.is_digit(10)`
2022-12-25 05:07:47 -05:00
..
ast Moar linting: needless_borrow, let_unit_value, ... 2022-12-25 05:07:47 -05:00
parsing dead code 2021-12-28 19:13:30 +03:00
tests Inline all format arguments where possible 2022-12-24 14:36:10 -05:00
validation Add semicolons for consistency 2021-10-03 23:39:43 +11:00
algo.rs Inline all format arguments where possible 2022-12-24 14:36:10 -05:00
ast.rs Move precedence handling to crates/syntax 2022-12-08 18:46:30 +00:00
fuzz.rs Inline all format arguments where possible 2022-12-24 14:36:10 -05:00
hacks.rs Inline all format arguments where possible 2022-12-24 14:36:10 -05:00
lib.rs ⬆️ rust-analyzer 2022-10-26 17:40:41 +03:00
parsing.rs dead code 2021-12-28 19:13:30 +03:00
ptr.rs Moar linting: needless_borrow, let_unit_value, ... 2022-12-25 05:07:47 -05:00
syntax_error.rs Run cargo fix --edition-idioms 2022-07-20 15:02:08 +02:00
syntax_node.rs Update remaining GitHub URLs 2022-07-08 15:44:49 +02:00
ted.rs Inline all format arguments where possible 2022-12-24 14:36:10 -05:00
tests.rs Inline all format arguments where possible 2022-12-24 14:36:10 -05:00
token_text.rs Run cargo fix --edition-idioms 2022-07-20 15:02:08 +02:00
utils.rs Better strip turbofishes 2021-03-08 23:59:39 +02:00
validation.rs Moar linting: needless_borrow, let_unit_value, ... 2022-12-25 05:07:47 -05:00