From 76c547717d8b5f63d95cee666d8ae4aa661d4bf2 Mon Sep 17 00:00:00 2001 From: Bazaah Date: Sun, 27 Mar 2022 09:08:55 +0000 Subject: [PATCH] scanner/error: add From impl for ScanError to public Error --- src/scanner/error.rs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/scanner/error.rs b/src/scanner/error.rs index f867f26..fb06d64 100644 --- a/src/scanner/error.rs +++ b/src/scanner/error.rs @@ -131,3 +131,11 @@ impl From for ErrorCode } } } + +impl From for crate::error::Error +{ + fn from(err: ScanError) -> Self + { + crate::error::mkError!(err, CODE) + } +}