From b32a4edb2078ca61ebcd9bad993905873f4a990a Mon Sep 17 00:00:00 2001 From: Vadim Petrochenkov Date: Thu, 1 Dec 2022 18:51:20 +0300 Subject: rustc_ast_lowering: Stop lowering imports into multiple items Lower them into a single item with multiple resolutions instead. This also allows to remove additional `NodId`s and `DefId`s related to those additional items. --- src/tools/rustfmt/src/imports.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/tools/rustfmt') diff --git a/src/tools/rustfmt/src/imports.rs b/src/tools/rustfmt/src/imports.rs index b6530c69243..d9dc8d004af 100644 --- a/src/tools/rustfmt/src/imports.rs +++ b/src/tools/rustfmt/src/imports.rs @@ -490,7 +490,7 @@ impl UseTree { ); result.path.push(UseSegment { kind, version }); } - UseTreeKind::Simple(ref rename, ..) => { + UseTreeKind::Simple(ref rename) => { // If the path has leading double colons and is composed of only 2 segments, then we // bypass the call to path_to_imported_ident which would get only the ident and // lose the path root, e.g., `that` in `::that`. -- cgit 1.4.1-3-g733a5