Lines Matching defs:DropGuard
220 // Marker types that determines type of `DropGuard`'s let bindings.
252 pub fn write(self, value: T) -> DropGuard<P, T>
262 unsafe { DropGuard::new(self.ptr) }
269 pub fn init<E>(self, init: impl Init<T, E>) -> Result<DropGuard<Unpinned, T>, E> {
279 Ok(unsafe { DropGuard::new(self.ptr) })
286 pub fn init<E>(self, init: impl PinInit<T, E>) -> Result<DropGuard<Pinned, T>, E> {
297 Ok(unsafe { DropGuard::new(self.ptr) })
310 pub struct DropGuard<P, T: ?Sized> {
315 impl<P, T: ?Sized> DropGuard<P, T> {
335 impl<T: ?Sized> DropGuard<Unpinned, T> {
344 impl<T: ?Sized> DropGuard<Pinned, T> {
354 impl<P, T: ?Sized> Drop for DropGuard<P, T> {