summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNikita Popov <nikita.ppv@gmail.com>2020-02-26 16:48:03 +0100
committerNikita Popov <nikita.ppv@gmail.com>2020-02-26 16:48:03 +0100
commit8c8f8c419378822f336aab13f301519cf2b95feb (patch)
treeb477cccb63d69bf3c52ebe7d8631d5c5d12220dd
parent1e50c81f6fbb1ff6dd40fc5f02919a3351978254 (diff)
downloadphp-git-8c8f8c419378822f336aab13f301519cf2b95feb.tar.gz
Add test for bug #60161
This has been fixed in PHP 7.4, let's make sure it stays fixed.
-rw-r--r--Zend/tests/bug60161.phpt18
1 files changed, 18 insertions, 0 deletions
diff --git a/Zend/tests/bug60161.phpt b/Zend/tests/bug60161.phpt
new file mode 100644
index 0000000000..0d71aaecb2
--- /dev/null
+++ b/Zend/tests/bug60161.phpt
@@ -0,0 +1,18 @@
+--TEST--
+Bug #60161: Implementing an interface extending Traversable is order dependent
+--FILE--
+<?php
+
+interface Foo extends Traversable {
+}
+
+class Example implements Foo, IteratorAggregate {
+ public function getIterator() {
+ return new ArrayIterator([]);
+ }
+}
+
+?>
+===DONE===
+--EXPECT--
+===DONE===