summaryrefslogtreecommitdiff
path: root/Zend/tests/foreach_006.phpt
diff options
context:
space:
mode:
Diffstat (limited to 'Zend/tests/foreach_006.phpt')
-rw-r--r--Zend/tests/foreach_006.phpt20
1 files changed, 20 insertions, 0 deletions
diff --git a/Zend/tests/foreach_006.phpt b/Zend/tests/foreach_006.phpt
new file mode 100644
index 0000000000..65d6fdc52c
--- /dev/null
+++ b/Zend/tests/foreach_006.phpt
@@ -0,0 +1,20 @@
+--TEST--
+Foreach by reference on constant
+--FILE--
+<?php
+for ($i = 0; $i < 3; $i++) {
+ foreach ([1,2,3] as &$val) {
+ echo "$val\n";
+ }
+}
+?>
+--EXPECT--
+1
+2
+3
+1
+2
+3
+1
+2
+3