1
0
mirror of https://github.com/php/php-src.git synced 2026-03-24 16:22:37 +01:00
Files
archived-php-src/tests/classes/final_ctor3.phpt
Nikita Popov d1e5006c14 Fix lineno for more inheritance errors
And also include explicit linenos in tests.
2019-03-27 13:02:28 +01:00

16 lines
430 B
PHP

--TEST--
Ensure implicit final inherited old-style constructor cannot be overridden.
--FILE--
<?php
class A {
final function A() { }
}
class B extends A {
function A() { }
}
?>
--EXPECTF--
Deprecated: Methods with the same name as their class will not be constructors in a future version of PHP; A has a deprecated constructor in %s on line %d
Fatal error: Cannot override final method A::A() in %s on line 6