Home
last modified time | relevance | path

Searched refs:transmute (Results 1 – 21 of 21) sorted by relevance

/linux/rust/zerocopy/src/
H A Dmacros.rs72 macro_rules! transmute { macro
84 fn transmute<Src, Dst>(src: Src) -> Dst
94 transmute(e)
128 $crate::util::macro_util::core_reexport::mem::transmute(e)
168 fn transmute<Src, Dst>(src: Src) -> Dst
178 transmute(e)
188 $crate::util::macro_util::core_reexport::mem::transmute(e)
645 $crate::util::macro_util::core_reexport::mem::transmute(e)
984 $crate::transmute!(*::core::include_bytes!($file))
1276 let x: [[u8; 2]; 4] = transmute!(array_of_u8s); in test_transmute()
[all …]
H A Dwrappers.rs154 |c| T::is_bit_valid(c.transmute::<_, _, BecauseImmutable>())
203 let inner = Ptr::from_ref(self).transmute(); in try_deref()
223 let inner = Ptr::from_mut(self).transmute::<_, _, (_, (_, _))>(); in try_deref_mut()
249 unsafe { mem::transmute(self) } in deref_unchecked()
412 Ptr::from_ref(self).transmute().bikeshed_recall_aligned().as_ref() in deref()
419 Ptr::from_mut(self).transmute::<_, _, (_, (_, _))>().bikeshed_recall_aligned().as_mut() in deref_mut()
721 let ro = Ptr::from_ref(t).transmute::<_, _, (_, _)>(); in from()
H A Dlib.rs6492 unsafe { mem::transmute(slc) } in from_mut_slice()
7015 let bytes_with_prefix: [u8; 16] = transmute!([VAL_BYTES, [0; 8]]); in test_read_write()
7020 let bytes_with_suffix: [u8; 16] = transmute!([[0; 8], VAL_BYTES]); in test_read_write()
7031 let want: [u8; 16] = transmute!([VAL_BYTES, [0; 8]]); in test_read_write()
7035 let want: [u8; 16] = transmute!([[0; 8], VAL_BYTES]); in test_read_write()
H A Dbyteorder.rs922 transmute!($bits::$from(bytes))
929 let bits: $bits = transmute!(f);
H A Dimpls.rs866 T::is_bit_valid(candidate.transmute::<_, _, BecauseImmutable>()) in is_bit_valid()
/linux/samples/rust/
H A Drust_dma.rs58 unsafe impl kernel::transmute::AsBytes for MyStruct {}
60 unsafe impl kernel::transmute::FromBytes for MyStruct {}
/linux/rust/zerocopy/src/util/
H A Dmod.rs346 let dst = Ptr::from_ref(src).transmute(); in transmute_ref()
363 let dst = Ptr::from_mut(src).transmute(); in transmute_mut()
443 let dangling = unsafe { mem::transmute::<usize, *mut u8>(align) }; in new_box()
877 crate::transmute!(self)
H A Dmacros.rs239 <$repr as TryFromBytes>::is_bit_valid(candidate.transmute::<_, _, BecauseImmutable>())
H A Dmacro_util.rs749 mem::transmute(dst) in transmute_ref()
/linux/rust/syn/
H A Ddiscouraged.rs201 .set(unsafe { mem::transmute::<Cursor, Cursor<'static>>(fork.cursor()) }); in advance_to()
H A Dparse.rs384 unsafe { mem::transmute::<Cursor<'c>, Cursor<'a>>(to) } in advance_step_cursor()
395 cell: Cell::new(unsafe { mem::transmute::<Cursor, Cursor<'static>>(cursor) }), in new_parse_buffer()
/linux/rust/zerocopy/src/pointer/
H A Dmod.rs18 pub mod transmute; module
23 pub use transmute::*;
H A Dptr.rs22 transmute::{MutationCompatible, SizeEq, TransmuteFromPtr},
436 pub fn transmute<U, V, R>(self) -> Ptr<'a, U, (I::Aliasing, Unaligned, V)> in transmute() function
624 pointer::{cast::IdCast, transmute::TryTransmuteFromPtr},
782 if T::is_bit_valid(self.reborrow().transmute::<_, _, _>().reborrow_shared()) { in try_into_valid()
/linux/rust/kernel/
H A Dlib.rs141 pub mod transmute;
131 pub mod transmute; global() module
H A Duaccess.rs16 transmute::{AsBytes, FromBytes},
H A Ddma.rs28 transmute::{
/linux/rust/kernel/debugfs/
H A Dtraits.rs
H A Dfile_ops.rs63 unsafe { core::mem::transmute(self) } in deref()
/linux/rust/kernel/list/
H A Darc.rs339 // Use a transmute to skip destructor. in transmute_to_arc()
342 unsafe { core::mem::transmute(self) } in transmute_to_arc()
/linux/security/smack/
H A Dsmack_lsm.c800 bool transmute = false; in smack_set_mnt_opts()
825 transmute = true; in smack_set_mnt_opts()
862 transmute = true; in smack_set_mnt_opts()
871 if (transmute) {
1053 * requests transmutation then by all means transmute. in smack_inode_init_security()
3690 * set the transmute attribute on the directory in smack_d_instantiate()
3693 * If there is a transmute attribute on the in smack_d_instantiate()
791 bool transmute = false; smack_set_mnt_opts() local
/linux/Documentation/admin-guide/LSM/
H A DSmack.rst103 to the directory includes the transmute ("t") mode the object
833 sets the transmute flag on the root of the mount