diff --git a/build/gen_stub.php b/build/gen_stub.php index 5349adb1bf6..5143715179c 100755 --- a/build/gen_stub.php +++ b/build/gen_stub.php @@ -531,6 +531,8 @@ class SimpleType { } } +// Instances of Type are immutable and do not need to be cloned +// when held by an object that is cloned class Type { /** @var SimpleType[] */ public /* readonly */ array $types; @@ -3146,13 +3148,6 @@ class PropertyInfo extends VariableLike $fieldsynopsisElement->appendChild($doc->createElement("modifier", "readonly")); } } - - public function __clone() - { - if ($this->type) { - $this->type = clone $this->type; - } - } } class EnumCaseInfo {