mirror of
https://github.com/php/php-src.git
synced 2024-12-03 23:05:57 +08:00
d1e5006c14
And also include explicit linenos in tests.
15 lines
386 B
PHP
15 lines
386 B
PHP
--TEST--
|
|
Bug #61970 (Restraining __construct() access level in subclass gives a fatal error - stays when implementing abstract)
|
|
--FILE--
|
|
<?php
|
|
|
|
abstract class Foo {
|
|
abstract public function __construct();
|
|
}
|
|
|
|
class Bar extends Foo {
|
|
protected function __construct(){}
|
|
}
|
|
--EXPECTF--
|
|
Fatal error: Access level to Bar::__construct() must be public (as in class Foo) in %s on line 8
|