mirror of
https://github.com/php/php-src.git
synced 2024-12-16 21:37:49 +08:00
814a932734
This prevents serialization and unserialization of a class and its children in a way that does not depend on the zend_class_serialize_deny and zend_class_unserialize_deny handlers that will be going away in PHP 9 together with the Serializable interface. In stubs, `@not-serializable` can be used to set this flag. This patch only uses the new flag for a handful of Zend classes, converting the remainder is left for later. Closes GH-7249. Fixes bug #81111.
38 lines
752 B
PHP
38 lines
752 B
PHP
<?php
|
|
|
|
/** @generate-class-entries */
|
|
|
|
/**
|
|
* @strict-properties
|
|
* @not-serializable
|
|
*/
|
|
final class Fiber
|
|
{
|
|
public function __construct(callable $callback) {}
|
|
|
|
public function start(mixed ...$args): mixed {}
|
|
|
|
public function resume(mixed $value = null): mixed {}
|
|
|
|
public function throw(Throwable $exception): mixed {}
|
|
|
|
public function isStarted(): bool {}
|
|
|
|
public function isSuspended(): bool {}
|
|
|
|
public function isRunning(): bool {}
|
|
|
|
public function isTerminated(): bool {}
|
|
|
|
public function getReturn(): mixed {}
|
|
|
|
public static function getCurrent(): ?Fiber {}
|
|
|
|
public static function suspend(mixed $value = null): mixed {}
|
|
}
|
|
|
|
final class FiberError extends Error
|
|
{
|
|
public function __construct() {}
|
|
}
|