From c177bf4fc5660bfe9ddf0d4ca9843ef26aadccce Mon Sep 17 00:00:00 2001 From: Goldfinch Date: Sat, 18 Jul 2026 19:03:01 -0600 Subject: [PATCH] Remove the if_break unused-import shim TREE-98 shipped without if_break gaining a caller in the rules, so the placeholder alias (and its #[allow(unused_imports)]) had outlived its purpose. The IfBreak primitive itself stays: it is part of the doc IR's public API and covered by the printer unit tests. The one remaining #[allow] in the workspace is wrong_self_convention on rules::from_clause, which is named for SyntaxKind::FromClause rather than a from_x conversion and keeps its justifying comment. Co-Authored-By: Claude Fable 5 --- crates/formatter/src/rules.rs | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/crates/formatter/src/rules.rs b/crates/formatter/src/rules.rs index 762b687..7101783 100644 --- a/crates/formatter/src/rules.rs +++ b/crates/formatter/src/rules.rs @@ -13,8 +13,8 @@ use parser::syntax::{SyntaxElement, SyntaxKind, SyntaxNode, SyntaxToken}; use crate::attr_order; use crate::doc::{ - Doc, IdentPos, break_parent, concat, fill, fresh_line, group, hard_line, ident, if_break, - indent, keyword, nil, soft_line, soft_line_or_space, space, text, verbatim, + Doc, IdentPos, break_parent, concat, fill, fresh_line, group, hard_line, ident, indent, + keyword, nil, soft_line, soft_line_or_space, space, text, verbatim, }; /// Does this node's first non-trivia token open a paren group? @@ -2184,7 +2184,3 @@ impl ListJoiner { self.any = true; } } - -// Suppress an unused-import lint when if_break gains users in TREE-98. -#[allow(unused_imports)] -use if_break as _if_break; -- 2.51.2