| /linux/rust/zerocopy/src/pointer/ |
| H A D | mod.rs | 78 /// A `Cast` projection must preserve the address of the referent. It may 80 pub unsafe trait Cast<Src: ?Sized, Dst: ?Sized>: Project<Src, Dst> {} 82 /// A [`Cast`] which does not shrink the set of referent bytes. 87 pub unsafe trait CastExact<Src: ?Sized, Dst: ?Sized>: Cast<Src, Dst> {} 105 unsafe impl<T: ?Sized> Cast<T, T> for IdCast {} 134 unsafe impl<Src, Dst> Cast<Src, Dst> for CastSized {} 161 unsafe impl<Src, Dst> Cast<Src, Dst> for CastSizedExact {} 214 unsafe impl<Src, Dst> Cast<Src, Dst> for CastUnsized in project() 293 unsafe impl<T: ?Sized, Client, F, const FIELD_ID: i128> Cast<T, T::Type> 305 /// If `TU: Cast` an 83 pub unsafe trait Cast<Src: ?Sized, Dst: ?Sized>: Project<Src, Dst> {} global() interface 295 unsafe impl<T: ?Sized, F, const FIELD_ID: i128> Cast<T, T::Type> global() impl [all...] |
| H A D | ptr.rs | 581 // - By `CastSized: Cast`, `CastSized` preserves referent address, in into_unalign() 841 pointer::cast::{AsBytesCast, Cast}, in cast_unchecked() 862 pub unsafe fn cast_unchecked<U, C: Cast<T, U>>( in cast() 869 // - By `C: Cast`, `C` preserves the address of the referent. in cast() 892 C: Cast<T, U>, in project() 1257 define_cast!(unsafe { Cast<T: ?Sized> = UnsafeCell<T> => T }); in get_mut() 1280 let ptr = unsafe { self.project_transmute_unchecked::<_, _, Cast>() }; in iter()
|
| /linux/rust/syn/ |
| H A D | precedence.rs | 49 Cast, enumerator 123 Expr::Cast(_) => Precedence::Cast, in of()
|
| H A D | fixup.rs | 437 if let Expr::Cast(cast) = expr { in precedence() 488 Expr::Cast(_) => fixup.previous_operator < Precedence::Cast, in scan_left() 743 | Expr::Cast(_) in scan_right()
|
| H A D | classify.rs | 45 | Expr::Cast(_) in requires_comma_to_be_match_arm() 144 Expr::Cast(e) => expr = &e.expr, in expr_leading_label() 207 Expr::Cast(e) => return type_trailing_brace(&e.ty), in expr_trailing_brace()
|
| H A D | expr.rs | 141 Cast(ExprCast), 937 | Expr::Cast(ExprCast { attrs, .. }) in replace_attrs() 1373 } else if Precedence::Cast >= base && input.peek(Token![as]) { in parse_expr() 1379 lhs = Expr::Cast(ExprCast { in parse_expr() 1416 } else if Precedence::Cast >= base && input.peek(Token![as]) { in parse_expr() 1422 lhs = Expr::Cast(ExprCast { in parse_expr() 1478 Precedence::Cast in peek_precedence() 2399 ExprCast, Cast, "expected cast expression", 3220 Expr::Cast(e) => print_expr_cast(e, tokens, fixup), in print_expr() 3523 Precedence::Cast, in print_expr_cast() [all …]
|
| H A D | stmt.rs | 348 Expr::Cast(e) => &mut e.expr, in stmt_expr()
|
| /linux/rust/zerocopy/src/ |
| H A D | ref.rs | 1432 use crate::pointer::cast::{Cast, Project}; 1452 unsafe impl<T: ?Sized + KnownLayout> Cast<[u8], T> for CastForSized {}
|
| H A D | layout.rs | 1900 unsafe impl<Src, Dst> crate::pointer::cast::Cast<Src, Dst> for CastFrom<Dst> in test_validate_rust_layout()
|
| /linux/rust/zerocopy/src/util/ |
| H A D | macros.rs | 704 /// Defines a named [`Cast`] implementation. 711 /// [`Cast`]: crate::pointer::cast::Cast 734 unsafe impl $(<$tyvar $(: ?$optbound)?>)? $crate::pointer::cast::Cast<$src, $dst> for $name {}
|
| /linux/rust/syn/gen/ |
| H A D | clone.rs | 258 crate::Expr::Cast(v0) => crate::Expr::Cast(v0.clone()), in clone()
|
| H A D | eq.rs | 284 (crate::Expr::Cast(self0), crate::Expr::Cast(other0)) => self0 == other0, in eq()
|
| H A D | fold.rs | 1350 crate::Expr::Cast(_binding_0) => crate::Expr::Cast(f.fold_expr_cast(_binding_0)), in fold_expr()
|
| H A D | hash.rs | 394 crate::Expr::Cast(v0) => { in hash()
|
| H A D | debug.rs | 436 crate::Expr::Cast(v0) => v0.debug(formatter, "Cast"), in fmt()
|
| H A D | visit_mut.rs | 1335 crate::Expr::Cast(_binding_0) => { in visit_expr_mut()
|
| H A D | visit.rs | 1337 crate::Expr::Cast(_binding_0) => { in visit_expr()
|