summaryrefslogtreecommitdiff
path: root/Zend/tests/foreach_018.phpt
blob: 3c0be7be190a5a16fac0001bf5fcd24dec2029d1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
--TEST--
Foreach on stdClass with properties looking like mangled properties
--FILE--
<?php

$obj = (object)[
    "\0A\0b" => 42,
    "\0*\0c" => 24,
];

foreach ($obj as $k => $v) {
    var_dump($k, $v);
}

?>
--EXPECT--
string(1) "b"
int(42)
string(1) "c"
int(24)