From 46f0b38eb5f4965bd3230ceeba4a3ed7d0e5f68e Mon Sep 17 00:00:00 2001 From: Vadim Petrochenkov Date: Thu, 1 Dec 2022 18:51:20 +0300 Subject: [PATCH] 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/imports.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/imports.rs b/src/imports.rs index b6530c69243..d9dc8d004af 100644 --- a/src/imports.rs +++ b/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`.