summaryrefslogtreecommitdiff
path: root/ext/spl/tests/array_008.phpt
diff options
context:
space:
mode:
authorFelipe Pena <felipe@php.net>2010-04-26 00:13:34 +0000
committerFelipe Pena <felipe@php.net>2010-04-26 00:13:34 +0000
commit0a6bcd44a72197bc8fb5658ce9fe4b46019ab9b3 (patch)
treeb015404b606eda42e2573e7a412c9b5518c5fa0a /ext/spl/tests/array_008.phpt
parent7211284ac7f217694f2f351ec223f94af7db0d16 (diff)
downloadphp-git-0a6bcd44a72197bc8fb5658ce9fe4b46019ab9b3.tar.gz
- Removed allow_call_time_pass_reference (Pierrick)
Diffstat (limited to 'ext/spl/tests/array_008.phpt')
-rwxr-xr-xext/spl/tests/array_008.phpt29
1 files changed, 0 insertions, 29 deletions
diff --git a/ext/spl/tests/array_008.phpt b/ext/spl/tests/array_008.phpt
index 61c7abd7c6..e7a618dda5 100755
--- a/ext/spl/tests/array_008.phpt
+++ b/ext/spl/tests/array_008.phpt
@@ -1,12 +1,8 @@
--TEST--
SPL: ArrayIterator and foreach reference
---INI--
-allow_call_time_pass_reference=1
--FILE--
<?php
-echo "==Normal==\n";
-
$arr = array(0=>0, 1=>1, 2=>2);
$obj = new ArrayObject($arr);
@@ -19,35 +15,10 @@ foreach($obj as $ak=>&$av) {
}
}
-echo "==UseRef==\n";
-
-$arr = array(0=>0, 1=>1, 2=>2);
-$obj = new ArrayObject(&$arr);
-
-foreach($obj as $ak=>&$av) {
- foreach($obj as $bk=>&$bv) {
- if ($ak==0 && $bk==0) {
- $bv = "modify";
- }
- echo "$ak=>$av - $bk=>$bv\n";
- }
-}
-
?>
===DONE===
<?php exit(0); ?>
--EXPECTF--
-==Normal==
-0=>modify - 0=>modify
-0=>modify - 1=>1
-0=>modify - 2=>2
-1=>1 - 0=>modify
-1=>1 - 1=>1
-1=>1 - 2=>2
-2=>2 - 0=>modify
-2=>2 - 1=>1
-2=>2 - 2=>2
-==UseRef==
0=>modify - 0=>modify
0=>modify - 1=>1
0=>modify - 2=>2