Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ rand_chacha = "0.3"
[features]
default = ["rand"]
alloc = ["serdect?/alloc"]
std = ["alloc"]

extra-sizes = []
rand = ["rand_core/std"]
Expand Down
3 changes: 0 additions & 3 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -155,9 +155,6 @@
#[macro_use]
extern crate alloc;

#[cfg(feature = "std")]
extern crate std;

#[macro_use]
mod macros;

Expand Down
1 change: 0 additions & 1 deletion src/modular/boxed_monty_form.rs
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,6 @@ impl BoxedMontyForm {
}

/// Instantiates a new [`BoxedMontyForm`] that represents an integer modulo the provided params.
#[cfg(feature = "std")]
pub fn new_with_arc(mut integer: BoxedUint, params: Arc<BoxedMontyParams>) -> Self {
debug_assert_eq!(integer.bits_precision(), params.bits_precision());
convert_to_montgomery(&mut integer, &params);
Expand Down
7 changes: 3 additions & 4 deletions src/traits.rs
Original file line number Diff line number Diff line change
Expand Up @@ -337,8 +337,8 @@ impl fmt::Display for RandomBitsError {
}
}

#[cfg(feature = "std")]
impl std::error::Error for RandomBitsError {}
#[cfg(feature = "rand_core")]
impl core::error::Error for RandomBitsError {}

/// Random bits generation support.
#[cfg(feature = "rand_core")]
Expand Down Expand Up @@ -572,8 +572,7 @@ impl fmt::Display for DecodeError {
}
}

#[cfg(feature = "std")]
impl std::error::Error for DecodeError {}
impl core::error::Error for DecodeError {}

/// Support for optimized squaring
pub trait Square {
Expand Down