diff options
Diffstat (limited to 'tvix/eval/src/errors.rs')
-rw-r--r-- | tvix/eval/src/errors.rs | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/tvix/eval/src/errors.rs b/tvix/eval/src/errors.rs index 10bc9276adde..17b236d0385f 100644 --- a/tvix/eval/src/errors.rs +++ b/tvix/eval/src/errors.rs @@ -100,6 +100,15 @@ impl From<ParseIntError> for ErrorKind { } } +/// Implementation used if errors occur while forcing thunks (which +/// can potentially be threaded through a few contexts, i.e. nested +/// thunks). +impl From<Error> for ErrorKind { + fn from(e: Error) -> Self { + Self::ThunkForce(Box::new(e)) + } +} + #[derive(Clone, Debug)] pub struct Error { pub kind: ErrorKind, |