From 2b0f553e2e1b83ed8ff605f2ea25e2c31bb4c889 Mon Sep 17 00:00:00 2001 From: Ryan Dahl Date: Tue, 26 Mar 2019 11:56:34 -0400 Subject: Add deno_core::RecursiveLoad for async module loading (#2034) --- core/js_errors.rs | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'core/js_errors.rs') diff --git a/core/js_errors.rs b/core/js_errors.rs index ee3272baf..442d8f1d8 100644 --- a/core/js_errors.rs +++ b/core/js_errors.rs @@ -40,6 +40,12 @@ pub struct JSError { pub frames: Vec, } +impl std::error::Error for JSError { + fn source(&self) -> Option<&(dyn std::error::Error + 'static)> { + None + } +} + impl fmt::Display for StackFrame { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { // Note when we print to string, we change from 0-indexed to 1-indexed. -- cgit v1.2.3