From 5039170b1467b84ef4f4758efeba2bec7f4dde28 Mon Sep 17 00:00:00 2001 From: Christian Schwarz Date: Fri, 14 Jun 2024 20:11:43 +0200 Subject: [PATCH] impl From for RenderErrorReason --- src/error.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/error.rs b/src/error.rs index cf33ee00f..d029eff2a 100644 --- a/src/error.rs +++ b/src/error.rs @@ -150,6 +150,12 @@ impl From for RenderError { } } +impl From for RenderErrorReason { + fn from(e: RenderError) -> Self { + *e.reason + } +} + impl RenderError { #[deprecated(since = "5.0.0", note = "Use RenderErrorReason instead")] pub fn new>(desc: T) -> RenderError {