Skip to content

Commit

Permalink
Remove obsolte TODO
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaReiser committed Jul 11, 2023
1 parent e5aeaba commit 30e7756
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions crates/ruff_python_formatter/src/expression/expr_subscript.rs
Original file line number Diff line number Diff line change
Expand Up @@ -90,10 +90,6 @@ impl NeedsParentheses for ExprSubscript {
parenthesize: Parenthesize,
context: &PyFormatContext,
) -> Parentheses {
// TODO: Issue, returns `Never` here but parentheses are necessary in return type positions.
// We don't have the position information available here which sux.
// Rename `optional_parentheses` to `parenthesize_if_breaks`
// Create a new optional parentheses function that does the whole magic stuff.
match default_expression_needs_parentheses(self.into(), parenthesize, context) {
Parentheses::Optional => Parentheses::Never,
parentheses => parentheses,
Expand Down

0 comments on commit 30e7756

Please sign in to comment.