Implement Default for Task
This commit is contained in:
parent
9d56b488cc
commit
1a575550bf
1 changed files with 6 additions and 0 deletions
|
|
@ -383,6 +383,12 @@ impl<T, E> Task<Result<T, E>> {
|
|||
}
|
||||
}
|
||||
|
||||
impl<T> Default for Task<T> {
|
||||
fn default() -> Self {
|
||||
Task::none()
|
||||
}
|
||||
}
|
||||
|
||||
impl<T> From<()> for Task<T> {
|
||||
fn from(_value: ()) -> Self {
|
||||
Self::none()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue