From 47ee00f35a4033ce35d8473922ebafecbce730a4 Mon Sep 17 00:00:00 2001 From: Sebastian K Date: Sun, 13 Aug 2023 16:53:04 +0100 Subject: [PATCH] impl From for Name --- pdf/src/primitive.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pdf/src/primitive.rs b/pdf/src/primitive.rs index 7bd5f81a..c7f05acb 100644 --- a/pdf/src/primitive.rs +++ b/pdf/src/primitive.rs @@ -298,6 +298,12 @@ impl Deref for Name { &self.0 } } +impl From for Name { + #[inline] + fn from(s: String) -> Name { + Name(s.into()) + } +} impl From for Name { #[inline] fn from(s: SmallString) -> Name {