[−][src]Struct core_extensions::type_asserts::AssertEq
Struct used to assert that its type parameters are the same type.
This is most useful in tests,to make sure that types are the same.
Example
use core_extensions::type_asserts::AssertEq; let _:AssertEq<u32,u32>; let _=AssertEq::new( &0u32, &0u32 );
Non-compiling
ⓘThis example deliberately fails to compile
use core_extensions::type_asserts::AssertEq; let _:AssertEq<(),u32>; let _=AssertEq::new( &(), &0u32 );
ⓘThis example deliberately fails to compile
use core_extensions::type_asserts::AssertEq; let _:AssertEq<u32,()>; let _=AssertEq::new( &0u32, &() );
Methods
impl<A> AssertEq<A, A>
[src]
Auto Trait Implementations
impl<L: ?Sized, R: ?Sized> Send for AssertEq<L, R> where
L: Send,
R: Send,
L: Send,
R: Send,
impl<L: ?Sized, R: ?Sized> Sync for AssertEq<L, R> where
L: Sync,
R: Sync,
L: Sync,
R: Sync,
impl<L: ?Sized, R: ?Sized> Unpin for AssertEq<L, R> where
L: Unpin,
R: Unpin,
L: Unpin,
R: Unpin,
impl<L: ?Sized, R: ?Sized> UnwindSafe for AssertEq<L, R> where
L: UnwindSafe,
R: UnwindSafe,
L: UnwindSafe,
R: UnwindSafe,
impl<L: ?Sized, R: ?Sized> RefUnwindSafe for AssertEq<L, R> where
L: RefUnwindSafe,
R: RefUnwindSafe,
L: RefUnwindSafe,
R: RefUnwindSafe,
Blanket Implementations
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The error type returned when the conversion fails.
fn try_into(Self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,