original_string: public static function decodePhp( $data ) {
  		if ( !is_string( $data ) ) {
  			throw new \InvalidArgumentException( '$data must be a string' );
  		}
  
  		$ret = [];
  		while ( $data !== '' && $data !== false ) {
  			$i = strpos( $data, '|' );
  			if ( $i === false ) {
  				if ( substr( $data, -1 ) !== '!' ) {
  					self::$logger->warning( 'Ignoring garbage at end of string' );
  				}
  				break;
  			}
  
  			$key = substr( $data, 0, $i );
  			$data = substr( $data, $i + 1 );
  
  			if ( strpos( $key, '!' ) !== false ) {
  				self::$logger->warning( "Decoding found a key with unsupported characters: \"$key\"" );
  			}
  
  			if ( $data === '' || $data === false ) {
  				self::$logger->error( 'Unserialize failed: unexpected end of string' );
  				return null;
  			}
  
  			list( $ok, $value ) = self::unserializeValue( $data );
  			if ( !$ok ) {
  				return null;
  			}
  			$ret[$key] = $value;
  		}
  		return $ret;
  	}
code: public static function decodePhp( $data ) {
  		if ( !is_string( $data ) ) {
  			throw new \InvalidArgumentException( '$data must be a string' );
  		}
  
  		$ret = [];
  		while ( $data !== '' && $data !== false ) {
  			$i = strpos( $data, '|' );
  			if ( $i === false ) {
  				if ( substr( $data, -1 ) !== '!' ) {
  					self::$logger->warning( 'Ignoring garbage at end of string' );
  				}
  				break;
  			}
  
  			$key = substr( $data, 0, $i );
  			$data = substr( $data, $i + 1 );
  
  			if ( strpos( $key, '!' ) !== false ) {
  				self::$logger->warning( "Decoding found a key with unsupported characters: \"$key\"" );
  			}
  
  			if ( $data === '' || $data === false ) {
  				self::$logger->error( 'Unserialize failed: unexpected end of string' );
  				return null;
  			}
  
  			list( $ok, $value ) = self::unserializeValue( $data );
  			if ( !$ok ) {
  				return null;
  			}
  			$ret[$key] = $value;
  		}
  		return $ret;
  	}
code_tokens: public static function decodePhp ( $ data ) { if ( ! is_string ( $ data ) ) { throw new \ InvalidArgumentException ( '$data must be a string' ) ; } $ ret = [ ] ; while ( $ data !== '' && $ data !== false ) { $ i = strpos ( $ data , '|' ) ; if ( $ i === false ) { if ( substr ( $ data , - 1 ) !== '!' ) { self :: $ logger -> warning ( 'Ignoring garbage at end of string' ) ; } break ; } $ key = substr ( $ data , 0 , $ i ) ; $ data = substr ( $ data , $ i + 1 ) ; if ( strpos ( $ key , '!' ) !== false ) { self :: $ logger -> warning ( "Decoding found a key with unsupported characters: \"$key\"" ) ; } if ( $ data === '' || $ data === false ) { self :: $ logger -> error ( 'Unserialize failed: unexpected end of string' ) ; return null ; } list ( $ ok , $ value ) = self :: unserializeValue ( $ data ) ; if ( ! $ ok ) { return null ; } $ ret [ $ key ] = $ value ; } return $ ret ; }
docstring: Decode a session string in 'php' format to an array
  @note Generally you'll use self::decode() instead of this method.
  @param string $data Session data. Use the same caution in passing
  user-controlled data here that you would to PHP's unserialize function.
  @return array|null Data, or null on failure
  @throws \\InvalidArgumentException
docstring_tokens: Decode a session string in php format to an array