diff options
author | Marcus Boerger <helly@php.net> | 2006-05-10 01:23:55 +0000 |
---|---|---|
committer | Marcus Boerger <helly@php.net> | 2006-05-10 01:23:55 +0000 |
commit | edfe649c6b1749e3e636a58e42f269c01333132d (patch) | |
tree | df84aebb2a21fcb46ea8f5f7c39b31a3f2a20c1a /tests/classes/ctor_in_interface_01.phpt | |
parent | 43217a3225171eb87d0bd0f24af7a85be0e87785 (diff) | |
download | php-git-edfe649c6b1749e3e636a58e42f269c01333132d.tar.gz |
- MFH Constructors in interfaces
Diffstat (limited to 'tests/classes/ctor_in_interface_01.phpt')
-rwxr-xr-x | tests/classes/ctor_in_interface_01.phpt | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/tests/classes/ctor_in_interface_01.phpt b/tests/classes/ctor_in_interface_01.phpt new file mode 100755 index 0000000000..f6f9b66eab --- /dev/null +++ b/tests/classes/ctor_in_interface_01.phpt @@ -0,0 +1,19 @@ +--TEST-- +ZE2 A class constructor must keep the signature of an interface +--FILE-- +<?php +interface constr +{ + function __construct(); +} + +class implem implements constr +{ + function __construct($a) + { + } +} + +?> +--EXPECTF-- +Fatal error: Declaration of implem::__construct() must be compatible with that of constr::__construct() in %s on line %d |