Module static_assertions

Source
Expand description

Compile-time assertions about constants, types, etc.

See crate ::static_assertions.

Modules§

_core
The Rust Core Library

Macros§

assert_cfg
Asserts that a given configuration is set.
assert_eq_align
Asserts that types are equal in alignment.
assert_eq_size
Asserts that types are equal in size.
assert_eq_size_ptr
Asserts that values pointed to are equal in size.
assert_eq_size_val
Asserts that values are equal in size.
assert_fields
Asserts that the type has the given fields.
assert_impl_all
Asserts that the type implements all of the given traits.
assert_impl_any
Asserts that the type implements any of the given traits.
assert_impl_one
Asserts that the type implements exactly one in a set of traits.
assert_not_impl_all
Asserts that the type does not implement all of the given traits.
assert_not_impl_any
Asserts that the type does not implement any of the given traits.
assert_obj_safe
Asserts that the traits support dynamic dispatch (object-safety).
assert_trait_sub_all
Asserts that the trait is a child of all of the other traits.
assert_trait_super_all
Asserts that the trait is a parent of all of the other traits.
assert_type_eq_all
Asserts that all types in a list are equal to each other.
assert_type_ne_all
Asserts that all types are not equal to each other.
const_assert
Asserts that constant expressions evaluate to true.
const_assert_eq
Asserts that constants are equal in value.
const_assert_ne
Asserts that constants are not equal in value.