Skip to content

Commit fde86e5

Browse files
We do not need impl_trait_in_assoc_ty
1 parent 0e6f7c6 commit fde86e5

File tree

2 files changed

+6
-7
lines changed

2 files changed

+6
-7
lines changed

library/core/src/lib.rs

-1
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,6 @@
227227
#![feature(fundamental)]
228228
#![feature(generic_arg_infer)]
229229
#![feature(if_let_guard)]
230-
#![feature(impl_trait_in_assoc_type)]
231230
#![feature(inline_const)]
232231
#![feature(intra_doc_pointers)]
233232
#![feature(intrinsics)]

library/core/src/ops/async_function.rs

+6-6
Original file line numberDiff line numberDiff line change
@@ -70,10 +70,10 @@ mod impls {
7070
where
7171
<F as FnOnce<A>>::Output: Future,
7272
{
73-
type CallFuture<'a> = impl Future<Output = Self::Output> where Self: 'a;
73+
type CallFuture<'a> = <F as FnOnce<A>>::Output where Self: 'a;
7474

7575
extern "rust-call" fn async_call(&self, args: A) -> Self::CallFuture<'_> {
76-
async { self.call(args).await }
76+
self.call(args)
7777
}
7878
}
7979

@@ -82,10 +82,10 @@ mod impls {
8282
where
8383
<F as FnOnce<A>>::Output: Future,
8484
{
85-
type CallMutFuture<'a> = impl Future<Output = Self::Output> where Self: 'a;
85+
type CallMutFuture<'a> = <F as FnOnce<A>>::Output where Self: 'a;
8686

8787
extern "rust-call" fn async_call_mut(&mut self, args: A) -> Self::CallMutFuture<'_> {
88-
async { self.call_mut(args).await }
88+
self.call_mut(args)
8989
}
9090
}
9191

@@ -94,12 +94,12 @@ mod impls {
9494
where
9595
<F as FnOnce<A>>::Output: Future,
9696
{
97-
type CallOnceFuture = impl Future<Output = Self::Output>;
97+
type CallOnceFuture = <F as FnOnce<A>>::Output;
9898

9999
type Output = <<F as FnOnce<A>>::Output as Future>::Output;
100100

101101
extern "rust-call" fn async_call_once(self, args: A) -> Self::CallOnceFuture {
102-
async { self.call_once(args).await }
102+
self.call_once(args)
103103
}
104104
}
105105
}

0 commit comments

Comments
 (0)