Apply review fixes

This commit is contained in:
DropDemBits 2022-02-14 20:41:01 -05:00
parent 86c1251afb
commit a1a23d343a
No known key found for this signature in database
GPG Key ID: 894910BF83E70347
2 changed files with 4 additions and 2 deletions

View File

@ -329,7 +329,9 @@ use foo::{bar::{self}};
use std$0::{fmt::*};
use std::{fmt::{self, Display}};
",
r"use std::{fmt::{self, *, Display}};",
r"
use std::{fmt::{self, *, Display}};
",
)
}

View File

@ -117,7 +117,7 @@ fn recursive_merge(lhs: &ast::UseTree, rhs: &ast::UseTree, merge: MergeBehavior)
.map(|tree_list| tree_list.use_trees().any(|it| tree_is_self(&it)))
// Glob imports aren't part of the use-tree lists,
// so they need to be handled explicitly
.or_else(|| tree.star_token().is_some().then(|| false))
.or_else(|| tree.star_token().map(|_| false))
};
match (tree_contains_self(lhs_t), tree_contains_self(&rhs_t)) {
(Some(true), None) => continue,