@@ -23,7 +23,7 @@ impl ZendIterator {
2323 /// iterator cannot be rewound.
2424 // TODO: Check iter not returning iterator
2525 #[ allow( clippy:: iter_not_returning_iterator) ]
26- pub fn iter ( & mut self ) -> Option < Iter > {
26+ pub fn iter ( & mut self ) -> Option < Iter < ' _ > > {
2727 self . index = 0 ;
2828
2929 if self . rewind ( ) {
@@ -39,7 +39,7 @@ impl ZendIterator {
3939 /// `\Iterator` interface. see <https://www.php.net/manual/en/iterator.valid.php>
4040 pub fn valid ( & mut self ) -> bool {
4141 if let Some ( valid) = unsafe { ( * self . funcs ) . valid } {
42- let valid = unsafe { valid ( & mut * self ) == ZEND_RESULT_CODE_SUCCESS } ;
42+ let valid = unsafe { valid ( & raw mut * self ) == ZEND_RESULT_CODE_SUCCESS } ;
4343
4444 if ExecutorGlobals :: has_exception ( ) {
4545 return false ;
@@ -63,7 +63,7 @@ impl ZendIterator {
6363 pub fn rewind ( & mut self ) -> bool {
6464 if let Some ( rewind) = unsafe { ( * self . funcs ) . rewind } {
6565 unsafe {
66- rewind ( & mut * self ) ;
66+ rewind ( & raw mut * self ) ;
6767 }
6868 }
6969
@@ -82,7 +82,7 @@ impl ZendIterator {
8282 pub fn move_forward ( & mut self ) -> bool {
8383 if let Some ( move_forward) = unsafe { ( * self . funcs ) . move_forward } {
8484 unsafe {
85- move_forward ( & mut * self ) ;
85+ move_forward ( & raw mut * self ) ;
8686 }
8787 }
8888
@@ -97,7 +97,7 @@ impl ZendIterator {
9797 /// , [`None`] otherwise.
9898 pub fn get_current_data < ' a > ( & mut self ) -> Option < & ' a Zval > {
9999 let get_current_data = unsafe { ( * self . funcs ) . get_current_data } ?;
100- let value = unsafe { & * get_current_data ( & mut * self ) } ;
100+ let value = unsafe { & * get_current_data ( & raw mut * self ) } ;
101101
102102 if ExecutorGlobals :: has_exception ( ) {
103103 return None ;
@@ -117,7 +117,7 @@ impl ZendIterator {
117117 let mut key = Zval :: new ( ) ;
118118
119119 unsafe {
120- get_current_key ( & mut * self , & mut key) ;
120+ get_current_key ( & raw mut * self , & raw mut key) ;
121121 }
122122
123123 if ExecutorGlobals :: has_exception ( ) {
0 commit comments