1
0
mirror of https://github.com/php/php-src.git synced 2026-03-24 00:02:20 +01:00
Files
archived-php-src/Zend/tests/property_hooks/interface_get_set_readonly.phpt
2024-08-05 14:30:37 +02:00

14 lines
395 B
PHP

--TEST--
readonly property does not satisfy get/set interface property
--FILE--
<?php
interface I {
public int $prop { get; set; }
}
class C implements I {
public function __construct(public readonly int $prop) {}
}
?>
--EXPECTF--
Fatal error: Class C contains 1 abstract method and must therefore be declared abstract or implement the remaining methods (I::$prop::set) in %s on line %d