NOTE: Please file security related issues to security@mabe.berlin
to be able to coordinate releases across dependent projects privately.
Detailed description:
PHP 8.5 deprecates the __sleep() and __wakeup() magic methods, see https://wiki.php.net/rfc/deprecations_php_8_5.
The recommendation is to implement __serialize() instead (or in addition, if support for old PHP versions is necessary)
This package uses it here:
|
/** |
|
* @throws LogicException Serialization is not supported by default in this pseudo-enum implementation |
|
* |
|
* @psalm-return never-return |
|
*/ |
|
final public function __sleep() |
|
{ |
|
throw new LogicException('Serialization is not supported by default in this pseudo-enum implementation'); |
|
} |
Steps to reproduce:
- Run on PHP 8.5
Expected behavior:
No deprecation warnings :)
Environment:
Important information of your environment.
- PHP Version: PHP 8.5.0-dev (cli) (built: Sep 10 2025 21:48:22) (NTS)
- PHP Extensions + Versions: ...
- PHP Configuration: ...
- ...
Additional context:
N/A
NOTE: Please file security related issues to security@mabe.berlin
to be able to coordinate releases across dependent projects privately.
Detailed description:
PHP 8.5 deprecates the
__sleep()and__wakeup()magic methods, see https://wiki.php.net/rfc/deprecations_php_8_5.The recommendation is to implement
__serialize()instead (or in addition, if support for old PHP versions is necessary)This package uses it here:
php-enum/src/Enum.php
Lines 89 to 97 in 7159809
Steps to reproduce:
Expected behavior:
No deprecation warnings :)
Environment:
Important information of your environment.
Additional context:
N/A