X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=src%2Flib.rs;h=91a315678f18f107a1a1e955e5c636121f9bc1db;hb=78af60e0fbddbf73c44a7a46952c42b0a57be2cb;hp=6aedb700fe29c256652f77c8f42a1cba1ae75272;hpb=ed08985212345ac11904b2db5b7f78be0d8885e3;p=dnssec-prover diff --git a/src/lib.rs b/src/lib.rs index 6aedb70..91a3156 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -35,8 +35,16 @@ // const_slice_from_raw_parts was stabilized in 1.64, however we support building on 1.63 as well. // Luckily, it seems to work fine in 1.63 with the feature flag (and RUSTC_BOOTSTRAP=1) enabled. -#![allow(stable_features)] -#![feature(const_slice_from_raw_parts)] +#![cfg_attr(rust_1_63, feature(const_slice_from_raw_parts))] + +#![allow(clippy::new_without_default)] // why is this even a lint +#![allow(clippy::result_unit_err)] // Why in the hell is this a lint? +#![allow(clippy::get_first)] // Sometimes this improves readability +#![allow(clippy::needless_lifetimes)] // lifetimes improve readability +#![allow(clippy::needless_borrow)] // borrows indicate read-only/non-move +#![allow(clippy::too_many_arguments)] // sometimes we don't have an option +#![allow(clippy::identity_op)] // sometimes identities improve readability for repeated actions +#![allow(clippy::erasing_op)] // sometimes identities improve readability for repeated actions #![cfg_attr(not(feature = "std"), no_std)] extern crate alloc; @@ -55,3 +63,6 @@ pub mod query; #[cfg(feature = "validation")] pub mod validation; + +#[cfg(all(feature = "std", feature = "validation", test))] +mod test;