From b2036a4db71afd67a78f932528143fb07faea538 Mon Sep 17 00:00:00 2001 From: Ryan Dahl Date: Tue, 16 Nov 2021 09:02:28 -0500 Subject: refactor: re-export anyhow from deno_core (#12777) --- core/async_cancel.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'core/async_cancel.rs') diff --git a/core/async_cancel.rs b/core/async_cancel.rs index e3110bf13..ab7ec2248 100644 --- a/core/async_cancel.rs +++ b/core/async_cancel.rs @@ -537,7 +537,7 @@ mod internal { #[cfg(test)] mod tests { use super::*; - use crate::error::AnyError; + use anyhow::Error; use futures::future::pending; use futures::future::poll_fn; use futures::future::ready; @@ -652,7 +652,7 @@ mod tests { // Cancel a spawned task before it actually runs. let cancel_handle = Rc::new(CancelHandle::new()); let future = spawn(async { panic!("the task should not be spawned") }) - .map_err(AnyError::from) + .map_err(Error::from) .try_or_cancel(&cancel_handle); cancel_handle.cancel(); let error = future.await.unwrap_err(); -- cgit v1.2.3