Skip to content

Commit

Permalink
task: fix incorrect signature in Builder::spawn_on (#4953)
Browse files Browse the repository at this point in the history
  • Loading branch information
TennyZhuang authored Aug 30, 2022
1 parent ba93b28 commit 5a2bc85
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions tokio/src/task/builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -99,11 +99,7 @@ impl<'a> Builder<'a> {
/// [runtime handle]: crate::runtime::Handle
/// [`Handle::spawn`]: crate::runtime::Handle::spawn
#[track_caller]
pub fn spawn_on<Fut>(
&mut self,
future: Fut,
handle: &Handle,
) -> io::Result<JoinHandle<Fut::Output>>
pub fn spawn_on<Fut>(self, future: Fut, handle: &Handle) -> io::Result<JoinHandle<Fut::Output>>
where
Fut: Future + Send + 'static,
Fut::Output: Send + 'static,
Expand Down

0 comments on commit 5a2bc85

Please sign in to comment.