File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -300,15 +300,15 @@ impl<T> Handlers<T> {
300300 self . check_uninit ( ) ;
301301
302302 // SAFETY: `check_uninit` guarantees that the handlers have been initialized.
303- unsafe { self . handlers . assume_init_ref ( ) }
303+ unsafe { & * self . handlers . as_ptr ( ) }
304304 }
305305
306306 /// Checks if the handlers have been initialized, and initializes them if they have not been.
307307 fn check_uninit ( & self ) {
308308 if !self . init . load ( Ordering :: Acquire ) {
309309 // SAFETY: Memory location has been initialized therefore given pointer is valid.
310310 unsafe {
311- ZendObjectHandlers :: init :: < T > ( std :: mem :: transmute ( self . handlers . assume_init_ref ( ) ) ) ;
311+ ZendObjectHandlers :: init :: < T > ( self . handlers . as_ptr ( ) as * mut _ ) ;
312312 } ;
313313 self . init . store ( true , Ordering :: Release ) ;
314314 }
You can’t perform that action at this time.
0 commit comments