summaryrefslogtreecommitdiff
path: root/ext/spl/tests/fixedarray_006.phpt
blob: 2e762467c4f42b62923850a2c4290b135fc74941 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
--TEST--
SPL: FixedArray: Assigning objects
--FILE--
<?php

$b = 10000;
$a = new SplFixedArray($b);

try {
    for ($i = 0; $i < 100; $i++) {
        $a[] = new stdClass;
    }
} catch (Exception $e) {
    echo $e->getMessage(), "\n";
}

print "ok\n";

?>
--EXPECT--
Index invalid or out of range
ok