Skip to content

Commit

Permalink
Format
Browse files Browse the repository at this point in the history
  • Loading branch information
long-long-float committed Apr 15, 2024
1 parent 9437f6d commit 9e0d856
Showing 1 changed file with 11 additions and 6 deletions.
17 changes: 11 additions & 6 deletions compiler/rustc_hir/src/hir.rs
Original file line number Diff line number Diff line change
Expand Up @@ -658,12 +658,17 @@ impl<'hir> Generics<'hir> {
&& segment.args().parenthesized == GenericArgsParentheses::ParenSugar
&& let [binding] = segment.args().bindings
&& let TypeBindingKind::Equality { term: Term::Ty(ret_ty) } = binding.kind
&& let TyKind::TraitObject(_, _, TraitObjectSyntax::Dyn | TraitObjectSyntax::DynStar) = ret_ty.kind
&& ret_ty.span.can_be_used_for_suggestions() {
Some(ret_ty.span)
} else {
None
};
&& let TyKind::TraitObject(
_,
_,
TraitObjectSyntax::Dyn | TraitObjectSyntax::DynStar,
) = ret_ty.kind
&& ret_ty.span.can_be_used_for_suggestions()
{
Some(ret_ty.span)
} else {
None
};

span_for_parentheses.map_or_else(
|| {
Expand Down

0 comments on commit 9e0d856

Please sign in to comment.