xref: /PHP-5.6/Zend/tests/bug33257.phpt (revision 610c7fbe)
1--TEST--
2Bug #33257 (array_splice() inconsistent when passed function instead of variable)
3--INI--
4error_reporting=4095
5--FILE--
6<?php
7class X {
8  protected static $arr = array("a", "b", "c");
9  public static function getArr() {
10    return self::$arr;
11  }
12}
13
14//$arr1 = X::getArr();
15array_splice(X::getArr(), 1, 1);
16print_r(X::getArr());
17?>
18--EXPECTF--
19Strict Standards: Only variables should be passed by reference in %sbug33257.php on line 10
20Array
21(
22    [0] => a
23    [1] => b
24    [2] => c
25)
26