]> granicus.if.org Git - php/commitdiff
my commits are bad, and I feel bad (test for bug #71414)
authorJoe Watkins <krakjoe@php.net>
Sat, 26 Mar 2016 23:59:46 +0000 (23:59 +0000)
committerJoe Watkins <krakjoe@php.net>
Sat, 26 Mar 2016 23:59:46 +0000 (23:59 +0000)
Zend/tests/bug71414.phpt [new file with mode: 0644]

diff --git a/Zend/tests/bug71414.phpt b/Zend/tests/bug71414.phpt
new file mode 100644 (file)
index 0000000..09f8b7d
--- /dev/null
@@ -0,0 +1,25 @@
+--TEST--
+Bug #71414 (Interface method override inherited method and implemented in a trait causes fatal error)
+--FILE--
+<?php
+interface InterfaceY {
+    public function z(): string;
+}
+
+trait TraitY {
+    public function z(): string {
+    }
+}
+
+class X {
+    public function z() {
+    }
+}
+
+class Y extends X implements InterfaceY {
+    use TraitY;
+}
+
+echo "ok";
+--EXPECT--
+ok