ruff/crates/ruff_linter/src/checkers/ast
w0nder1ng 08221454f6
[`perflint`] Implement fix for `manual-dict-comprehension` (`PERF403`) (#16719)
## Summary

This change adds an auto-fix for manual dict comprehensions. It also
copies many of the improvements from #13919 (and associated PRs fixing
issues with it), and moves some of the utility functions from
`manual_list_comprehension.rs` into a separate `helpers.rs` to be used
in both.

## Test Plan

I added a preview test case to showcase the new fix and added a test
case in `PERF403.py` to make sure lines with semicolons function. I
didn't yet make similar tests to the ones I added earlier to
`PERF401.py`, but the logic is the same, so it might be good to add
those to make sure they work.
2025-04-18 13:10:40 -04:00
..
analyze [`perflint`] Implement fix for `manual-dict-comprehension` (`PERF403`) (#16719) 2025-04-18 13:10:40 -04:00
annotation.rs Improve internal documentation for the semantic model (#10788) 2024-04-06 16:28:32 +00:00
deferred.rs Use string expression for parsing type annotation (#11717) 2024-06-03 13:04:03 +00:00
mod.rs [syntax-errors] `await` outside async functions (#17363) 2025-04-14 13:01:48 -04:00