summaryrefslogtreecommitdiff
path: root/ext/spl/tests/bug60577.phpt
diff options
context:
space:
mode:
authorLevi Morrison <levim@php.net>2013-09-12 16:03:39 -0600
committerDavid Soria Parra <dsp@php.net>2013-09-16 04:04:53 +0200
commit8a936e8eb938965b0daaf076c109ec60141e57a7 (patch)
tree6bfac0cbd40c2b4b85db07c7602daba927d2ddcb /ext/spl/tests/bug60577.phpt
parentc0afe829e33c5f5690c6967a102148984836d5aa (diff)
downloadphp-git-8a936e8eb938965b0daaf076c109ec60141e57a7.tar.gz
EmptyIterator now implements Countable; fixes bug 60577
(cherry picked from commit 6398844c86bee08abe4ee3f206ecd86ad0a498f9)
Diffstat (limited to 'ext/spl/tests/bug60577.phpt')
-rw-r--r--ext/spl/tests/bug60577.phpt8
1 files changed, 8 insertions, 0 deletions
diff --git a/ext/spl/tests/bug60577.phpt b/ext/spl/tests/bug60577.phpt
new file mode 100644
index 0000000000..33fc133d0f
--- /dev/null
+++ b/ext/spl/tests/bug60577.phpt
@@ -0,0 +1,8 @@
+--TEST--
+count(new EmptyIterator) should return zero
+--FILE--
+<?php
+$it = new EmptyIterator;
+var_dump(count($it));
+--EXPECT--
+int(0)