ecdsa: remove TryFrom/TryInto imports (#454) (#386)

Now that we've upgraded to Rust 2021 edition, these are now available
via the prelude, making explicit imports redundant.
This commit is contained in:
Tony Arcieri
2021-10-21 17:19:28 -06:00
committed by GitHub
parent f28ddca1f2
commit e0c357392c
6 changed files with 2 additions and 10 deletions
-1
View File
@@ -2,7 +2,6 @@
use crate::{Error, Result};
use core::{
convert::{TryFrom, TryInto},
fmt,
ops::{Add, Range},
};
-2
View File
@@ -32,7 +32,6 @@ pub struct TestVector {
#[cfg_attr(docsrs, doc(cfg(feature = "dev")))]
macro_rules! new_signing_test {
($curve:path, $vectors:expr) => {
use core::convert::TryInto;
use $crate::{
elliptic_curve::{
bigint::Encoding, generic_array::GenericArray, group::ff::PrimeField, Curve,
@@ -69,7 +68,6 @@ macro_rules! new_signing_test {
#[cfg_attr(docsrs, doc(cfg(feature = "dev")))]
macro_rules! new_verification_test {
($curve:path, $vectors:expr) => {
use core::convert::TryInto;
use $crate::{
elliptic_curve::{
generic_array::GenericArray,
-1
View File
@@ -92,7 +92,6 @@ pub use sign::SigningKey;
pub use verify::VerifyingKey;
use core::{
convert::TryFrom,
fmt::{self, Debug},
ops::Add,
};
+1 -4
View File
@@ -6,10 +6,7 @@ use crate::{
hazmat::{DigestPrimitive, SignPrimitive},
rfc6979, Error, Result, Signature, SignatureSize,
};
use core::{
convert::TryFrom,
fmt::{self, Debug},
};
use core::fmt::{self, Debug};
use elliptic_curve::{
generic_array::ArrayLength,
group::ff::PrimeField,
+1 -1
View File
@@ -4,7 +4,7 @@ use crate::{
hazmat::{DigestPrimitive, VerifyPrimitive},
Error, Result, Signature, SignatureSize,
};
use core::{cmp::Ordering, convert::TryFrom, fmt::Debug};
use core::{cmp::Ordering, fmt::Debug};
use elliptic_curve::{
generic_array::ArrayLength,
ops::Reduce,
-1
View File
@@ -2,7 +2,6 @@
#![cfg(feature = "dev")]
use core::convert::TryFrom;
use elliptic_curve::dev::MockCurve;
type Signature = ecdsa::Signature<MockCurve>;