2022-08-18 19:27:29 +01:00
|
|
|
#![deny(rustc::untranslatable_diagnostic)]
|
|
|
|
|
#![deny(rustc::diagnostic_outside_of_impl)]
|
2022-10-28 18:45:55 +03:30
|
|
|
#![cfg_attr(feature = "nightly", feature(allow_internal_unstable))]
|
|
|
|
|
#![cfg_attr(feature = "nightly", feature(extend_one))]
|
|
|
|
|
#![cfg_attr(feature = "nightly", feature(min_specialization))]
|
|
|
|
|
#![cfg_attr(feature = "nightly", feature(new_uninit))]
|
|
|
|
|
#![cfg_attr(feature = "nightly", feature(step_trait))]
|
|
|
|
|
#![cfg_attr(feature = "nightly", feature(stmt_expr_attributes))]
|
|
|
|
|
#![cfg_attr(feature = "nightly", feature(test))]
|
2019-09-26 03:09:51 +08:00
|
|
|
|
2022-10-28 18:45:55 +03:30
|
|
|
#[cfg(feature = "nightly")]
|
2019-09-26 03:26:16 +00:00
|
|
|
pub mod bit_set;
|
2022-10-28 18:45:55 +03:30
|
|
|
#[cfg(feature = "nightly")]
|
2021-11-05 14:50:29 -04:00
|
|
|
pub mod interval;
|
2019-09-26 05:38:33 +00:00
|
|
|
pub mod vec;
|
2022-02-10 00:47:48 +11:00
|
|
|
|
2022-10-28 18:45:55 +03:30
|
|
|
#[cfg(feature = "rustc_macros")]
|
2022-02-09 17:24:51 -05:00
|
|
|
pub use rustc_macros::newtype_index;
|
|
|
|
|
|
2022-02-10 00:47:48 +11:00
|
|
|
/// Type size assertion. The first argument is a type and the second argument is its expected size.
|
|
|
|
|
#[macro_export]
|
|
|
|
|
macro_rules! static_assert_size {
|
|
|
|
|
($ty:ty, $size:expr) => {
|
|
|
|
|
const _: [(); $size] = [(); ::std::mem::size_of::<$ty>()];
|
|
|
|
|
};
|
|
|
|
|
}
|