Skip to content

Commit 583ab50

Browse files
authored
der: simplify From<&UintRef<'a>> for Uint (#1840)
1 parent ea10f3b commit 583ab50

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

der/src/asn1/integer/uint.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -245,8 +245,9 @@ mod allocating {
245245

246246
impl<'a> From<&UintRef<'a>> for Uint {
247247
fn from(value: &UintRef<'a>) -> Uint {
248-
let inner = BytesOwned::new(value.as_bytes()).expect("Invalid Uint");
249-
Uint { inner }
248+
Uint {
249+
inner: value.inner.into(),
250+
}
250251
}
251252
}
252253

0 commit comments

Comments
 (0)