From 1bee3d4704726e0428478a31e465bca78163d306 Mon Sep 17 00:00:00 2001 From: Justus Winter Date: Thu, 21 Mar 2019 15:58:19 +0100 Subject: openpgp: Drop nonsensical constructor. - UserAttribute packets contain subpackets, not strings. --- openpgp/src/packet/user_attribute.rs | 9 --------- 1 file changed, 9 deletions(-) diff --git a/openpgp/src/packet/user_attribute.rs b/openpgp/src/packet/user_attribute.rs index dac6a3dd..bf60c916 100644 --- a/openpgp/src/packet/user_attribute.rs +++ b/openpgp/src/packet/user_attribute.rs @@ -40,15 +40,6 @@ impl From> for UserAttribute { } } -impl<'a> From<&'a str> for UserAttribute { - fn from(u: &'a str) -> Self { - let b = u.as_bytes(); - let mut v = Vec::with_capacity(b.len()); - v.extend_from_slice(b); - v.into() - } -} - impl fmt::Debug for UserAttribute { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { f.debug_struct("UserAttribute") -- cgit v1.2.3