@@ -84,14 +84,14 @@ use std::{
84
84
task:: { Context , Poll , Wake } ,
85
85
} ;
86
86
87
- use super :: { FutureResult , RustFutureContinuationCallback , RustFuturePoll , Scheduler } ;
87
+ use super :: { RustFutureContinuationCallback , RustFuturePoll , Scheduler , UniffiCompatibleFuture } ;
88
88
use crate :: { rust_call_with_out_status, FfiDefault , LiftArgsError , LowerReturn , RustCallStatus } ;
89
89
90
90
/// Wraps the actual future we're polling
91
91
struct WrappedFuture < F , T , UT >
92
92
where
93
93
// See rust_future_new for an explanation of these trait bounds
94
- F : FutureResult < T , LiftArgsError > ,
94
+ F : UniffiCompatibleFuture < Result < T , LiftArgsError > > + ' static ,
95
95
T : LowerReturn < UT > + Send + ' static ,
96
96
UT : Send + ' static ,
97
97
{
@@ -105,7 +105,7 @@ where
105
105
impl < F , T , UT > WrappedFuture < F , T , UT >
106
106
where
107
107
// See rust_future_new for an explanation of these trait bounds
108
- F : FutureResult < T , LiftArgsError > ,
108
+ F : UniffiCompatibleFuture < Result < T , LiftArgsError > > + ' static ,
109
109
T : LowerReturn < UT > + Send + ' static ,
110
110
UT : Send + ' static ,
111
111
{
@@ -185,7 +185,7 @@ where
185
185
unsafe impl < F , T , UT > Send for WrappedFuture < F , T , UT >
186
186
where
187
187
// See rust_future_new for an explanation of these trait bounds
188
- F : FutureResult < T , LiftArgsError > ,
188
+ F : UniffiCompatibleFuture < Result < T , LiftArgsError > > + ' static ,
189
189
T : LowerReturn < UT > + Send + ' static ,
190
190
UT : Send + ' static ,
191
191
{
@@ -195,7 +195,7 @@ where
195
195
pub ( super ) struct RustFuture < F , T , UT >
196
196
where
197
197
// See rust_future_new for an explanation of these trait bounds
198
- F : FutureResult < T , LiftArgsError > ,
198
+ F : UniffiCompatibleFuture < Result < T , LiftArgsError > > + ' static ,
199
199
T : LowerReturn < UT > + Send + ' static ,
200
200
UT : Send + ' static ,
201
201
{
@@ -211,7 +211,7 @@ where
211
211
impl < F , T , UT > RustFuture < F , T , UT >
212
212
where
213
213
// See rust_future_new for an explanation of these trait bounds
214
- F : FutureResult < T , LiftArgsError > ,
214
+ F : UniffiCompatibleFuture < Result < T , LiftArgsError > > + ' static ,
215
215
T : LowerReturn < UT > + Send + ' static ,
216
216
UT : Send + ' static ,
217
217
{
@@ -266,7 +266,7 @@ where
266
266
impl < F , T , UT > Wake for RustFuture < F , T , UT >
267
267
where
268
268
// See rust_future_new for an explanation of these trait bounds
269
- F : FutureResult < T , LiftArgsError > ,
269
+ F : UniffiCompatibleFuture < Result < T , LiftArgsError > > + ' static ,
270
270
T : LowerReturn < UT > + Send + ' static ,
271
271
UT : Send + ' static ,
272
272
{
@@ -301,7 +301,7 @@ pub trait RustFutureFfi<ReturnType>: Send + Sync {
301
301
impl < F , T , UT > RustFutureFfi < T :: ReturnType > for RustFuture < F , T , UT >
302
302
where
303
303
// See rust_future_new for an explanation of these trait bounds
304
- F : FutureResult < T , LiftArgsError > ,
304
+ F : UniffiCompatibleFuture < Result < T , LiftArgsError > > + ' static ,
305
305
T : LowerReturn < UT > + Send + ' static ,
306
306
UT : Send + ' static ,
307
307
{
0 commit comments