Remove some unnecessary skip_binder
calls.
`is_fn_trait_compatible` is defined on both `FnSig` and `Binder<FnSig>`.
This commit is contained in:
parent
c4717cc9d1
commit
9e95a2b9a5
@ -461,7 +461,7 @@ pub(in crate::solve) fn extract_tupled_inputs_and_output_from_async_callable<I:
|
|||||||
|
|
||||||
ty::FnDef(def_id, _) => {
|
ty::FnDef(def_id, _) => {
|
||||||
let sig = self_ty.fn_sig(cx);
|
let sig = self_ty.fn_sig(cx);
|
||||||
if sig.skip_binder().is_fn_trait_compatible() && !cx.has_target_features(def_id) {
|
if sig.is_fn_trait_compatible() && !cx.has_target_features(def_id) {
|
||||||
fn_item_to_async_callable(cx, sig)
|
fn_item_to_async_callable(cx, sig)
|
||||||
} else {
|
} else {
|
||||||
Err(NoSolution)
|
Err(NoSolution)
|
||||||
@ -469,7 +469,7 @@ pub(in crate::solve) fn extract_tupled_inputs_and_output_from_async_callable<I:
|
|||||||
}
|
}
|
||||||
ty::FnPtr(..) => {
|
ty::FnPtr(..) => {
|
||||||
let sig = self_ty.fn_sig(cx);
|
let sig = self_ty.fn_sig(cx);
|
||||||
if sig.skip_binder().is_fn_trait_compatible() {
|
if sig.is_fn_trait_compatible() {
|
||||||
fn_item_to_async_callable(cx, sig)
|
fn_item_to_async_callable(cx, sig)
|
||||||
} else {
|
} else {
|
||||||
Err(NoSolution)
|
Err(NoSolution)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user