diff options
author | Bartek IwaĆczuk <biwanczuk@gmail.com> | 2020-12-16 17:14:12 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-12-16 17:14:12 +0100 |
commit | 6984b63f2f3c8d0819fe2dced8252a81f3400ae7 (patch) | |
tree | 5201bc962f913927409ae2770aca48ffa3aaaa34 /runtime/errors.rs | |
parent | 9fe26f8ca189ac81d9c20c454b9dbfa5e1011c3f (diff) |
refactor: rewrite ops to use ResourceTable2 (#8512)
This commit migrates all ops to use new resource table
and "AsyncRefCell".
Old implementation of resource table was completely
removed and all code referencing it was updated to use
new system.
Diffstat (limited to 'runtime/errors.rs')
-rw-r--r-- | runtime/errors.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/runtime/errors.rs b/runtime/errors.rs index f8f71a859..f82d95ed8 100644 --- a/runtime/errors.rs +++ b/runtime/errors.rs @@ -169,6 +169,12 @@ pub fn get_error_class_name(e: &AnyError) -> Option<&'static str> { .map(get_dlopen_error_class) }) .or_else(|| { + e.downcast_ref::<deno_core::Canceled>().map(|e| { + let io_err: io::Error = e.to_owned().into(); + get_io_error_class(&io_err) + }) + }) + .or_else(|| { e.downcast_ref::<env::VarError>() .map(get_env_var_error_class) }) |