echo "Done\n";
?>
--EXPECT--
-Undefined constant ''
+Undefined constant ""
int(1)
string(4) "test"
Done
Warning: Undefined variable $b in %s on line %d
int(1)
-Warning: Attempt to read property '1' on int in %s on line %d
+Warning: Attempt to read property "1" on int in %s on line %d
NULL
-Warning: Attempt to read property '1' on int in %s on line %d
+Warning: Attempt to read property "1" on int in %s on line %d
NULL
Warning: Undefined variable $c in %s on line %d
Warning: Trying to access array offset on value of type null in %s on line %d
-Warning: Attempt to read property '1' on int in %s on line %d
+Warning: Attempt to read property "1" on int in %s on line %d
-Warning: Attempt to read property '' on null in %s on line %d
+Warning: Attempt to read property "" on null in %s on line %d
NULL
?>
--EXPECTF--
-Warning: Attempt to read property 'a' on null in %s on line %d
+Warning: Attempt to read property "a" on null in %s on line %d
ok
-Attempt to assign property 'a' on null
+Attempt to assign property "a" on null
ok
bool(true)
bool(true)
-Notice: Undefined offset: 2 in %s on line %d
+Notice: Undefined array key 2 in %s on line %d
Fatal error: Uncaught Error: Value of type null is not callable in %s:%d
Stack trace:
Warning: Trying to access array offset on value of type null in %s on line %d
-Warning: Attempt to read property 'foo' on null in %s on line %d
-Attempt to assign property 'foo' on null
-Attempt to assign property 'bar' on null
+Warning: Attempt to read property "foo" on null in %s on line %d
+Attempt to assign property "foo" on null
+Attempt to assign property "bar" on null
--EXPECTF--
int(1)
-Fatal error: Uncaught Error: Access to undeclared static property: Closure::$x in %s:%d
+Fatal error: Uncaught Error: Access to undeclared static property Closure::$x in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
?>
--EXPECTF--
-Fatal error: Call to protected method B1::f() from context 'B2' in %s on line %d
+Fatal error: Call to protected method B1::f() from scope B2 in %s on line %d
--EXPECTF--
bool(false)
-Fatal error: Call to protected method B1::f() from context 'B2' in %s on line %d
+Fatal error: Call to protected method B1::f() from scope B2 in %s on line %d
?>
--EXPECTF--
-Fatal error: Uncaught Error: Call to private method d::test2() from context 'a' in %s:%d
+Fatal error: Uncaught Error: Call to private method d::test2() from scope a in %s:%d
Stack trace:
#0 %s(%d): a->test()
#1 %s(%d): c->__construct()
echo "Done\n";
?>
--EXPECTF--
-Notice: Undefined offset: -1 in %s on line 3
+Notice: Undefined array key -1 in %s on line %d
-Notice: Undefined offset: -1 in %s on line 4
+Notice: Undefined array key -1 in %s on line %d
-Notice: Undefined offset: -1 in %s on line 5
+Notice: Undefined array key -1 in %s on line 5
-Notice: Undefined offset: -1 in %s on line 6
+Notice: Undefined array key -1 in %s on line 6
Done
[2]=>
int(3)
}
-Exception: Cannot declare self-referencing constant 'self::B'
+Exception: Cannot declare self-referencing constant self::B
Illegal offset type
Illegal offset type
Cannot use a scalar value as an array
-Attempt to assign property 'foo' on bool
-Attempt to assign property 'foo' on bool
+Attempt to assign property "foo" on bool
+Attempt to assign property "foo" on bool
}
int(1)
-string(30) "Class 'MissingClass' not found"
-string(30) "Class 'MissingClass' not found"
-
+string(30) "Class "MissingClass" not found"
+string(30) "Class "MissingClass" not found"
string(74) "A1::__construct(): Argument #1 ($name) must be of type string, array given"
string(7) "ERROR 3"
-string(30) "Attribute class 'A2' not found"
+string(30) "Attribute class "A2" not found"
string(7) "ERROR 4"
-string(50) "Attribute constructor of class 'A3' must be public"
+string(48) "Attribute constructor of class A3 must be public"
string(7) "ERROR 5"
-string(71) "Attribute class 'A4' does not have a constructor, cannot pass arguments"
+string(69) "Attribute class A4 does not have a constructor, cannot pass arguments"
string(7) "ERROR 6"
-string(55) "Attempting to use non-attribute class 'A5' as attribute"
+string(55) "Attempting to use non-attribute class "A5" as attribute"
string(7) "ERROR 1"
string(103) "ReflectionFunctionAbstract::getAttributes(): Argument #2 ($flags) must be a valid attribute filter flag"
string(7) "ERROR 2"
-string(34) "Class 'SomeMissingClass' not found"
+string(34) "Class "SomeMissingClass" not found"
class C2
{
use T1;
-
+
private const FOO = 'bar';
}
[1] => bar
)
string(7) "ERROR 1"
-string(36) "Undefined class constant 'self::FOO'"
+string(28) "Undefined constant self::FOO"
bool(true)
string(3) "bar"
?>
--EXPECTF--
-Fatal error: Class 'Foo' not found in %s
+Fatal error: Class "Foo" not found in %s on line %d
string(10) "string('')"
}
-Fatal error: Uncaught Error: Cannot access property started with '\0' in %s:%d
+Fatal error: Uncaught Error: Cannot access property starting with "\0" in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
bool(true)
bool(true)
-Warning: Uninitialized string offset: -10 in %s on line %d
+Warning: Uninitialized string offset -10 in %s on line %d
string(0) ""
string(1) "u"
string(1) "u"
}
?>
--EXPECTF--
-Fatal error: Uncaught Error: Interface 'a' not found in %s:%d
+Fatal error: Uncaught Error: Interface "a" not found in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
echo "ok\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Interface 'RecurisiveFooFar' not found in %s:%d
+Fatal error: Uncaught Error: Interface "RecurisiveFooFar" not found in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
ok
ok
-Warning: Attempt to read property 'wrong' on string in %s on line %d
+Warning: Attempt to read property "wrong" on string in %s on line %d
ok
-Warning: Illegal string offset 'wrong' in %s on line %d
+Warning: Illegal string offset "wrong" in %s on line %d
ok
ok
-Warning: Illegal string offset 'wrong' in %s on line %d
+Warning: Illegal string offset "wrong" in %s on line %d
ok
Caught: {closure}
{closure}(Test3,3)
-Fatal error: Uncaught Error: Class 'Test3' not found in %sbug31102.php(%d) : eval()'d code:1
+Fatal error: Uncaught Error: Class "Test3" not found in %s:%d
Stack trace:
#0 %s(%d): eval()
#1 {main}
C2::test
B4::doTest
-Fatal error: Uncaught Error: Call to protected C4::__construct() from context 'B4' in %sbug37632.php:%d
+Fatal error: Uncaught Error: Call to protected C4::__construct() from scope B4 in %s:%d
Stack trace:
#0 %s(%d): B4::doTest()
#1 {main}
--EXPECTF--
string(3) "bar"
-Notice: Undefined offset: 2 in %sbug37667.php on line 16
+Notice: Undefined array key 2 in %s on line %d
NULL
object(Test)#%d (1) {
["property":protected]=>
Warning: Constants may only evaluate to scalar values, arrays or resources in %sbug37811.php on line %d
-Fatal error: Uncaught Error: Undefined constant 'Baz' in %s:%d
+Fatal error: Uncaught Error: Undefined constant "Baz" in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
--EXPECTF--
Warning: String offset cast occurred in %s on line %d
-Warning: Uninitialized string offset: %s in %s on line %d
+Warning: Uninitialized string offset %d in %s on line %d
-Warning: Uninitialized string offset: 0 in %s on line %d
+Warning: Uninitialized string offset 0 in %s on line %d
-Warning: Uninitialized string offset: 0 in %s on line %d
+Warning: Uninitialized string offset 0 in %s on line %d
Warning: String offset cast occurred in %s on line %d
-Warning: Uninitialized string offset: %i in %s on line %d
+Warning: Uninitialized string offset %d in %s on line %d
Warning: String offset cast occurred in %s on line %d
-Warning: Uninitialized string offset: %i in %s on line %d
+Warning: Uninitialized string offset %d in %s on line %d
-Warning: Uninitialized string offset: 0 in %s on line %d
+Warning: Uninitialized string offset 0 in %s on line %d
-Warning: Uninitialized string offset: 4 in %s on line %d
+Warning: Uninitialized string offset 4 in %s on line %d
-Warning: Uninitialized string offset: 4 in %s on line %d
+Warning: Uninitialized string offset 4 in %s on line %d
-Warning: Uninitialized string offset: 4 in %s on line %d
+Warning: Uninitialized string offset 4 in %s on line %d
-Warning: Uninitialized string offset: 4 in %s on line %d
+Warning: Uninitialized string offset 4 in %s on line %d
-Warning: Uninitialized string offset: 4 in %s on line %d
+Warning: Uninitialized string offset 4 in %s on line %d
Warning: String offset cast occurred in %s on line %d
-Warning: Uninitialized string offset: 12 in %s on line %d
+Warning: Uninitialized string offset 12 in %s on line %d
Warning: String offset cast occurred in %s on line %d
-Warning: Uninitialized string offset: 12 in %s on line %d
+Warning: Uninitialized string offset 12 in %s on line %d
Warning: String offset cast occurred in %s on line %d
var_dump($a,$b);
?>
--EXPECTF--
-Warning: Uninitialized string offset: 0 in %s on line %d
+Warning: Uninitialized string offset 0 in %s on line %d
NULL
NULL
echo Foo::A."\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Undefined class constant 'self::B' in %sbug41633_2.php:5
+Fatal error: Uncaught Error: Undefined constant self::B in %s:%d
Stack trace:
#0 {main}
thrown in %sbug41633_2.php on line 5
echo Foo::A;
?>
--EXPECTF--
-Fatal error: Uncaught Error: Cannot declare self-referencing constant 'Foo::B' in %sbug41633_3.php:%d
+Fatal error: Uncaught Error: Cannot declare self-referencing constant Foo::B in %s:%d
Stack trace:
#0 {main}
thrown in %sbug41633_3.php on line %d
[1] => 1
)
-Fatal error: Uncaught Error: Undefined constant 'foo\foo\unknown' in %sbug42819.php:%d
+Fatal error: Uncaught Error: Undefined constant "foo\foo\unknown" in %s:%d
Stack trace:
#0 %s(%d): foo\oops()
#1 {main}
test4
test5
-Fatal error: Uncaught Error: Call to undefined method C::test6() in %sbug42937.php:21
+Fatal error: Uncaught Error: Call to undefined method C::test6() in %s:%d
Stack trace:
#0 %s(%d): B->test()
#1 {main}
?>
--EXPECT--
-Undefined constant 'Foo\bar'
-Undefined constant 'Foo\bar'
-Undefined constant 'Foo\bar'
-Undefined constant 'Foo\bar'
+Undefined constant "Foo\bar"
+Undefined constant "Foo\bar"
+Undefined constant "Foo\bar"
+Undefined constant "Foo\bar"
echo namespace\bar."\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'bar' in %sbug43344_10.php:%d
+Fatal error: Uncaught Error: Undefined constant "bar" in %s:%d
Stack trace:
#0 {main}
thrown in %sbug43344_10.php on line %d
echo f()."\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'bar' in %sbug43344_11.php:%d
+Fatal error: Uncaught Error: Undefined constant "bar" in %s:%d
Stack trace:
#0 %s(%d): f()
#1 {main}
echo f()."\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'bar' in %sbug43344_12.php:%d
+Fatal error: Uncaught Error: Undefined constant "bar" in %s:%d
Stack trace:
#0 %s(%d): f()
#1 {main}
echo f()."\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'bar' in %sbug43344_13.php:%d
+Fatal error: Uncaught Error: Undefined constant "bar" in %s:%d
Stack trace:
#0 %s(%d): f()
#1 {main}
echo Foo::bar."\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Class 'Foo\Foo' not found in %sbug43344_2.php:%d
+Fatal error: Uncaught Error: Class "Foo\Foo" not found in %s:%d
Stack trace:
#0 {main}
thrown in %sbug43344_2.php on line %d
echo f()."\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Class 'Foo\Foo' not found in %s:%d
+Fatal error: Uncaught Error: Class "Foo\Foo" not found in %s:%d
Stack trace:
#0 %s(%d): Foo\f()
#1 {main}
echo f()."\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Class 'Foo\Foo' not found in %s:%d
+Fatal error: Uncaught Error: Class "Foo\Foo" not found in %s:%d
Stack trace:
#0 %s(%d): Foo\f()
#1 {main}
echo f()."\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Class 'Foo\Foo' not found in %s:%d
+Fatal error: Uncaught Error: Class "Foo\Foo" not found in %s:%d
Stack trace:
#0 %s(%d): Foo\f()
#1 {main}
echo namespace\bar."\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'Foo\bar' in %sbug43344_6.php:%d
+Fatal error: Uncaught Error: Undefined constant "Foo\bar" in %s:%d
Stack trace:
#0 {main}
thrown in %sbug43344_6.php on line %d
echo f()."\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'Foo\bar' in %sbug43344_7.php:%d
+Fatal error: Uncaught Error: Undefined constant "Foo\bar" in %s:%d
Stack trace:
#0 %s(%d): Foo\f()
#1 {main}
echo f()."\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'Foo\bar' in %sbug43344_8.php:%d
+Fatal error: Uncaught Error: Undefined constant "Foo\bar" in %s:%d
Stack trace:
#0 %s(%d): Foo\f()
#1 {main}
echo f()."\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'Foo\bar' in %sbug43344_9.php:%d
+Fatal error: Uncaught Error: Undefined constant "Foo\bar" in %s:%d
Stack trace:
#0 %s(%d): Foo\f()
#1 {main}
$y = Y::cheat(5);
echo $y->x, PHP_EOL;
--EXPECTF--
-Fatal error: Uncaught Error: Call to private X::__construct() from context 'Y' in %sbug44141.php:15
+Fatal error: Uncaught Error: Call to private X::__construct() from scope Y in %s:%d
Stack trace:
#0 %s(%d): Y::cheat(5)
#1 {main}
?>
--EXPECTF--
--> read access:
-Warning: Attempt to read property 'p' on bool in %s on line %d
+Warning: Attempt to read property "p" on bool in %s on line %d
--> direct assignment:
-Attempt to assign property 'p' on bool
+Attempt to assign property "p" on bool
--> increment:
-Attempt to increment/decrement property 'p' on bool
+Attempt to increment/decrement property "p" on bool
--> reference assignment:
-Attempt to modify property 'p' on bool
+Attempt to modify property "p" on bool
--> reference assignment:
-Attempt to modify property 'p' on bool
+Attempt to modify property "p" on bool
--> indexed assignment:
-Attempt to modify property 'p' on bool
+Attempt to modify property "p" on bool
--> Confirm assignments have had no impact:
bool(true)
ok
__callstatic:
string(3) "www"
-call_user_func(): Argument #1 ($function) must be a valid callback, cannot access self:: when no class scope is active
+call_user_func(): Argument #1 ($function) must be a valid callback, cannot access "self" when no class scope is active
__call:
string(1) "y"
ok
-call_user_func(): Argument #1 ($function) must be a valid callback, class 'bar' does not have a method 'www'
-call_user_func(): Argument #1 ($function) must be a valid callback, cannot access self:: when no class scope is active
+call_user_func(): Argument #1 ($function) must be a valid callback, class bar does not have a method "www"
+call_user_func(): Argument #1 ($function) must be a valid callback, cannot access "self" when no class scope is active
value3
value3
-Fatal error: Uncaught Error: Undefined constant 'NS1\ns2\coNSt1' in %sbug46304.php:%d
+Fatal error: Uncaught Error: Undefined constant "NS1\ns2\coNSt1" in %s:%d
Stack trace:
#0 {main}
thrown in %sbug46304.php on line %d
--EXPECTF--
Warning: Undefined variable $a in %s on line %d
-Warning: Attempt to read property 'ab' on null in %s on line %d
+Warning: Attempt to read property "ab" on null in %s on line %d
?>
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'FOO' in %s:%d
+Fatal error: Uncaught Error: Undefined constant "FOO" in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
?>
--EXPECTF--
BB
-Fatal error: Uncaught Error: Class 'X' not found in %sbug47699.php:%d
+Fatal error: Uncaught Error: Class "X" not found in %s:%d
Stack trace:
#0 {main}
thrown in %sbug47699.php on line %d
string(27) "B::func2: This should work!"
string(27) "B::func3: This should work!"
call_user_func_array(): Argument #1 ($function) must be a valid callback, cannot access private method B::func22()
-call_user_func_array(): Argument #1 ($function) must be a valid callback, class 'B' does not have a method 'inexistent'
+call_user_func_array(): Argument #1 ($function) must be a valid callback, class B does not have a method "inexistent"
--EXPECT--
string(27) "B::func2: This should work!"
string(27) "B::func3: This should work!"
-call_user_func_array(): Argument #1 ($function) must be a valid callback, class 'C' does not have a method 'inexistent'
+call_user_func_array(): Argument #1 ($function) must be a valid callback, class C does not have a method "inexistent"
?>
--EXPECT--
-Undefined class constant 'A::B1'
+Undefined constant A::B1
?>
--EXPECTF--
Warning: Undefined variable $x in %s on line %d
-Attempt to assign property 'a' on null
+Attempt to assign property "a" on null
Warning: Undefined variable $x in %s on line %d
-Attempt to modify property 'a' on null
+Attempt to modify property "a" on null
Warning: Undefined variable $x in %s on line %d
-Attempt to increment/decrement property 'a' on null
+Attempt to increment/decrement property "a" on null
Warning: Undefined variable $x in %s on line %d
-Attempt to modify property 'a' on null
+Attempt to modify property "a" on null
Warning: Undefined variable $x in %s on line %d
-Attempt to assign property 'a' on null
+Attempt to assign property "a" on null
Warning: Undefined variable $x in %s on line %d
-Attempt to modify property 'a' on null
+Attempt to modify property "a" on null
Warning: Undefined variable $x in %s on line %d
Warning: Undefined variable $x in %s on line %d
-Notice: Undefined offset: 0 in %s on line %d
+Notice: Undefined array key 0 in %s on line %d
Warning: Undefined variable $x in %s on line %d
-Notice: Undefined offset: 0 in %s on line %d
+Notice: Undefined array key 0 in %s on line %d
-Notice: Undefined offset: 0 in %s on line %d
+Notice: Undefined array key 0 in %s on line %d
Warning: Undefined variable $x in %s on line %d
-Notice: Undefined offset: 0 in %s on line %d
+Notice: Undefined array key 0 in %s on line %d
Warning: Undefined variable $x in %s on line %d
-Notice: Undefined offset: 0 in %s on line %d
+Notice: Undefined array key 0 in %s on line %d
-Notice: Undefined offset: 0 in %s on line %d
+Notice: Undefined array key 0 in %s on line %d
Warning: Undefined variable $x in %s on line %d
NULL
?>
--EXPECTF--
-Fatal error: Uncaught Error: Cannot access property started with '\0' in %s:%d
+Fatal error: Uncaught Error: Cannot access property starting with "\0" in %s:%d
Stack trace:
#0 %s(%d): A->__unset('\x00')
#1 {main}
?>
--EXPECTF--
-Fatal error: Uncaught Error: Cannot access property started with '\0' in %s:%d
+Fatal error: Uncaught Error: Cannot access property starting with "\0" in %s:%d
Stack trace:
#0 %s(%d): A->__set('\x00', 2)
#1 {main}
?>
--EXPECTF--
-Fatal error: Uncaught Error: Cannot access property started with '\0' in %s:%d
+Fatal error: Uncaught Error: Cannot access property starting with "\0" in %s:%d
Stack trace:
#0 %s(%d): A->__get('\x00')
#1 {main}
}
array(0) {
}
-Attempt to assign property 'a' on null
+Attempt to assign property "a" on null
NULL
object(stdClass)#3 (1) {
["a"]=>
string(1) "a"
string(6) " a"
-Warning: Illegal string offset: -1 in %s on line %d
+Warning: Illegal string offset -1 in %s on line %d
NULL
string(0) ""
-Warning: Illegal string offset 'foo' in %s on line %d
+Warning: Illegal string offset "foo" in %s on line %d
string(1) "a"
string(1) "a"
Error: [] operator not supported for strings
Warning: The magic method Bar::__invoke() must have public visibility in %sbug61025.php on line %d
Bar
-Fatal error: Uncaught Error: Call to private method Bar::__invoke() from context '' in %sbug61025.php:%d
+Fatal error: Uncaught Error: Call to private method Bar::__invoke() from global scope in %s:%d
Stack trace:
#0 {main}
thrown in %sbug61025.php on line %d
x($y);
print_r($y);
--EXPECT--
-string(25) "Illegal string offset 'a'"
+string(25) "Illegal string offset "a""
1
#0 %sbug65784.php(52): foo3()
#1 {main}
-Next Error: Class 'NotExists' not found in %sbug65784.php:46
+Next Error: Class "NotExists" not found in %s:%d
Stack trace:
#0 %sbug65784.php(52): foo3()
#1 {main}
$obj->go();
?>
--EXPECTF--
-Fatal error: Uncaught Error: Access to undeclared static property: A::$this in %s:%d
+Fatal error: Uncaught Error: Access to undeclared static property A::$this in %s:%d
Stack trace:
#0 %s(%d): B->go()
#1 {main}
Static method called with args: arg1, arg2, arg3
Static method called with args: arg1, arg2, arg3
Call to undefined method TestClass::undefinedMethod()
-Class 'UndefinedClass' not found
+Class "UndefinedClass" not found
c . 10;
?>
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'c' in %s:%d
+Fatal error: Uncaught Error: Undefined constant "c" in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
--FILE--
<?php [t.[]]; ?>
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 't' in %s:%d
+Fatal error: Uncaught Error: Undefined constant "t" in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
%d
%d
-Fatal error: Uncaught Error: Undefined constant 'Foo\__COMPILER_HALT_OFFSET__' in %s:%d
+Fatal error: Uncaught Error: Undefined constant "Foo\__COMPILER_HALT_OFFSET__" in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
}
?>
--EXPECT--
-array_map(): Argument #1 ($callback) must be a valid callback, function '%n' not found or invalid function name
-array_map(): Argument #1 ($callback) must be a valid callback, function '%n %i' not found or invalid function name
-array_map(): Argument #1 ($callback) must be a valid callback, function '%n %i aoeu %f aoeu %p' not found or invalid function name
+array_map(): Argument #1 ($callback) must be a valid callback, function "%n" not found or invalid function name
+array_map(): Argument #1 ($callback) must be a valid callback, function "%n %i" not found or invalid function name
+array_map(): Argument #1 ($callback) must be a valid callback, function "%n %i aoeu %f aoeu %p" not found or invalid function name
}
?>
--EXPECT--
-array_map(): Argument #1 ($callback) must be a valid callback, function '0000000000000000000000000000000000' not found or invalid function name
+array_map(): Argument #1 ($callback) must be a valid callback, function "0000000000000000000000000000000000" not found or invalid function name
$re = $st->fetchObject('%Z');
?>
--EXPECTREGEX--
-Fatal error: Class '%Z' not found in .+bug70914.php on line \d+
+Fatal error: Class "%Z" not found in .+bug70914.php on line \d+
}
?>
--EXPECT--
-string(52) "Cannot access static:: when no class scope is active"
-string(52) "Cannot access parent:: when no class scope is active"
-string(50) "Cannot access self:: when no class scope is active"
-string(52) "Cannot access static:: when no class scope is active"
-string(52) "Cannot access static:: when no class scope is active"
-string(52) "Cannot access static:: when no class scope is active"
+string(52) "Cannot access "static" when no class scope is active"
+string(52) "Cannot access "parent" when no class scope is active"
+string(50) "Cannot access "self" when no class scope is active"
+string(52) "Cannot access "static" when no class scope is active"
+string(52) "Cannot access "static" when no class scope is active"
+string(52) "Cannot access "static" when no class scope is active"
$a = $b = $c = 0;
$foo->bar($a, $b, $c);
--EXPECTF--
-Fatal error: Uncaught Error: Class 'DoesNotExists' not found in %sbug72101.php:61
+Fatal error: Uncaught Error: Class "DoesNotExists" not found in %s:%d
Stack trace:
#0 %sbug72101.php(8): {closure}(2, 'MethodCallbackB...', '%s', 8)
#1 %sbug72101.php(27): PHPUnit_Framework_MockObject_Stub_ReturnCallback->invoke(Object(PHPUnit_Framework_MockObject_Invocation_Static))
var_dump($array[$a]);
?>
--EXPECTF--
-Notice: Undefined index: lest in %sbug72943.php on line %d
+Notice: Undefined array key "lest" in %s on line %d
NULL
-Notice: Undefined index: fest in %sbug72943.php on line %d
+Notice: Undefined array key "fest" in %s on line %d
NULL
int(1)
echo 'done';
?>
--EXPECTF--
-Warning: Illegal string offset 'bbb' in %sbug73792.php on line 4
+Warning: Illegal string offset "bbb" in %s on line %d
Fatal error: Uncaught Error: Cannot iterate on string offsets by reference in %sbug73792.php:4
Stack trace:
"000000"[0]::d;
?>
--EXPECTF--
-Fatal error: Uncaught Error: Class '0' not found in %sbug74546.php:%d
+Fatal error: Uncaught Error: Class "0" not found in %s:%d
Stack trace:
#0 {main}
thrown in %sbug74546.php on line %d
var_dump((new C)->options);
?>
--EXPECTF--
-Fatal error: Uncaught Error: Undefined class constant 'I::FOO' in %sbug74657.php:%d
+Fatal error: Uncaught Error: Undefined constant I::FOO in %s:%d
Stack trace:
#0 {main}
thrown in %sbug74657.php on line %d
string(2) "42"
bool(true)
-Notice: Undefined index: 010 in %s on line %d
+Notice: Undefined array key "010" in %s on line %d
NULL
bool(false)
-Notice: Undefined index: 010 in %s on line %d
+Notice: Undefined array key "010" in %s on line %d
NULL
bool(false)
var_dump($d);
?>
--EXPECTF--
-Fatal error: Uncaught Error: Attempt to modify property 'd' on null in %s:%d
+Fatal error: Uncaught Error: Attempt to modify property "d" on null in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
?>
--EXPECTF--
-Attempt to assign property 'a' on null
+Attempt to assign property "a" on null
Warning: Undefined variable $null in %s on line %d
NULL
-Attempt to modify property 'a' on null
+Attempt to modify property "a" on null
Warning: Undefined variable $null in %s on line %d
NULL
-Attempt to modify property 'a' on null
+Attempt to modify property "a" on null
Warning: Undefined variable $null in %s on line %d
NULL
-Attempt to modify property 'a' on null
+Attempt to modify property "a" on null
Warning: Undefined variable $null in %s on line %d
NULL
-Attempt to modify property 'a' on null
+Attempt to modify property "a" on null
Warning: Undefined variable $null in %s on line %d
NULL
$y = &$x["bar"];
?>
--EXPECTF--
-Fatal error: Uncaught Exception: Illegal string offset 'bar' in %sbug76534.php:%d
+Fatal error: Uncaught Exception: Illegal string offset "bar" in %s:%d
Stack trace:
#0 %sbug76534.php(%d): {closure}(2, 'Illegal string ...', '%s', %d)
#1 {main}
--EXPECTF--
Warning: Undefined variable $undefined in %s on line %d
-Warning: Attempt to read property '1' on null in %s on line %d
+Warning: Attempt to read property "1" on null in %s on line %d
Warning: Division by zero in %s on line %d
Warning: Undefined variable $undefined in %s on line %d
-Warning: Attempt to read property 'NAN' on null in %s on line %d
+Warning: Attempt to read property "NAN" on null in %s on line %d
Warning: Division by zero in %s on line %d
Warning: Undefined variable $undefined in %s on line %d
-Warning: Attempt to read property 'NAN' on null in %s on line %d
+Warning: Attempt to read property "NAN" on null in %s on line %d
Warning: Division by zero in %s on line %d
}
?>
--EXPECT--
-Exception: Call to protected method B::f() from context ''
+Exception: Call to protected method B::f() from global scope
__COMPILER_HALT_OFFSET__;
; // <- important
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant '__COMPILER_HALT_OFFSET__' in %s:%d
+Fatal error: Uncaught Error: Undefined constant "__COMPILER_HALT_OFFSET__" in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
var_dump($var);
?>
--EXPECT--
-Attempt to modify property 'prop' on null
+Attempt to modify property "prop" on null
NULL
?>
--EXPECTF--
-Fatal error: Uncaught Error: Cannot access protected const A::FOO in %s:%d
+Fatal error: Uncaught Error: Cannot access protected constant A::FOO in %s:%d
Stack trace:
#0 %s(%d): C->method()
#1 {main}
?>
--EXPECTF--
Warning: Undefined variable $u1 in %s on line %d
-Attempt to assign property 'a' on null
+Attempt to assign property "a" on null
Warning: Undefined variable $u2 in %s on line %d
-Attempt to increment/decrement property 'a' on null
+Attempt to increment/decrement property "a" on null
Warning: Undefined variable $u3 in %s on line %d
-Attempt to increment/decrement property 'a' on null
+Attempt to increment/decrement property "a" on null
Warning: Undefined variable $u4 in %s on line %d
-Attempt to modify property 'a' on null
+Attempt to modify property "a" on null
?>
--EXPECTF--
-Warning: Class 'AAAABBBB' not found in %s on line %d
+Warning: Class "AAAABBBB" not found in %s on line %d
?>
--EXPECT--
-Class 'A' not found
+Class "A" not found
bool(false)
?>
--EXPECT--
-Undefined index: foobar
+Undefined array key "foobar"
array(1) {
["foobar"]=>
int(1)
}
-Undefined index: foobarbaz
+Undefined array key "foobarbaz"
array(2) {
["foobar"]=>
int(1)
test(new stdClass);
?>
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'UNDEFINED' in %s:%d
+Fatal error: Uncaught Error: Undefined constant "UNDEFINED" in %s:%d
Stack trace:
#0 %s(%d): test(Object(stdClass))
#1 {main}
?>
--EXPECTF--
string(3) "foo"
-call_user_func(): Argument #1 ($function) must be a valid callback, class 'foo' not found
-call_user_func(): Argument #1 ($function) must be a valid callback, class '' not found
+call_user_func(): Argument #1 ($function) must be a valid callback, class "foo" not found
+call_user_func(): Argument #1 ($function) must be a valid callback, class "" not found
Warning: Undefined variable $foo in %s on line %d
call_user_func(): Argument #1 ($function) must be a valid callback, first array member is not a valid class name or object
?>
--EXPECTF--
-Notice: Undefined offset: 0 in %s on line %d
+Notice: Undefined array key 0 in %s on line %d
Warning: Trying to access array offset on value of type null in %s on line %d
?>
--EXPECTF--
-Warning: Class 'bar' not found in %s on line %d
+Warning: Class "bar" not found in %s on line %d
object(foo\bar)#%d (0) {
}
-Fatal error: Uncaught Error: Class 'foo\foo' not found in %s:%d
+Fatal error: Uncaught Error: Class "foo\foo" not found in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
object(foo\bar\foo)#2 (0) {
}
-Fatal error: Uncaught Error: Class 'foo\bar' not found in %s:%d
+Fatal error: Uncaught Error: Class "foo\bar" not found in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
string(6) "string"
int(1)
-Fatal error: Uncaught Error: Undefined class constant 'test::val3' in %s:%d
+Fatal error: Uncaught Error: Undefined constant test::val3 in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
int(5)
int(10)
-Fatal error: Uncaught Error: Class 'NoSuchClass' not found in %s:%d
+Fatal error: Uncaught Error: Class "NoSuchClass" not found in %s:%d
Stack trace:
#0 %s(%d): bar()
#1 {main}
?>
--EXPECTF--
-Fatal error: Uncaught Error: Cannot use "static" when no class scope is active in %s:3
+Fatal error: Uncaught Error: Cannot use "static" in the global scope in %s:%d
Stack trace:
#0 {main}
thrown in %s on line 3
?>
--EXPECTF--
-Fatal error: Uncaught Error: Cannot use "parent" when no class scope is active in %s:3
+Fatal error: Uncaught Error: Cannot use "parent" in the global scope in %s:%d
Stack trace:
#0 {main}
thrown in %s on line 3
?>
--EXPECT--
-Cannot use "self" when no class scope is active
-Cannot use "self" when no class scope is active
+Cannot use "self" in the global scope
+Cannot use "self" in the global scope
?>
--EXPECTF--
-Fatal error: Cannot use ::class on value of type int in %s on line %d
+Fatal error: Cannot use "::class" on value of type int in %s on line %d
string(8) "stdClass"
string(8) "stdClass"
string(8) "stdClass"
-Cannot use ::class on value of type null
+Cannot use "::class" on value of type null
--EXPECTF--
{closure}()
-Fatal error: Uncaught Error: Call to private method Test::func() from context '' in %sclosure_033.php:%d
+Fatal error: Uncaught Error: Call to private method Test::func() from global scope in %s:%d
Stack trace:
#0 {main}
thrown in %sclosure_033.php on line %d
--EXPECTF--
Warning: Array to string conversion in %s on line %d
-Warning: Class 'Array' not found in %s on line %d
+Warning: Class "Array" not found in %s on line %d
Warning: Cannot bind an instance to a static closure in %s on line %d
?>
--EXPECT--
-ERROR: Instantiation of 'Closure' is not allowed
+ERROR: Instantiation of class Closure is not allowed
--EXPECTF--
int(4)
-Notice: Undefined index: foo in %sconst_dereference_001.php on line %d
+Notice: Undefined array key "foo" in %s on line %d
NULL
int(6)
123
string(1) "b"
string(1) "o"
-Warning: Illegal string offset 'foo' in %sconst_dereference_002.php on line %d
+Warning: Illegal string offset "foo" in %s on line %d
-Warning: Illegal string offset 'bar' in %sconst_dereference_002.php on line %d
+Warning: Illegal string offset "bar" in %s on line %d
string(1) "f"
--EXPECTF--
int(4)
-Notice: Undefined index: foo in %sconst_dereference_003.php on line %d
+Notice: Undefined array key "foo" in %s on line %d
NULL
int(6)
123
int(4)
int(1)
-Notice: Undefined offset: 3 in %s on line %d
+Notice: Undefined array key 3 in %s on line %d
array(3) {
[0]=>
int(1)
var_dump(A::FOO);
?>
--EXPECTF--
-Fatal error: Uncaught Error: Cannot declare self-referencing constant 'self::BAR' in %s:%d
+Fatal error: Uncaught Error: Cannot declare self-referencing constant self::BAR in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
?>
--EXPECTF--
Warning: Constants may only evaluate to scalar values, arrays or resources in %s on line %d
-Undefined constant 'foo'
+Undefined constant "foo"
resource(5) of type (stream)
function b() {
return array();
}
-var_dump(b()[0]); // Notice: Undefined offset: 0
+var_dump(b()[0]); // Notice: Undefined array key 0
class foo {
public $y = 1;
--EXPECTF--
int(5)
-Notice: Undefined offset: 0 in %s on line %d
+Notice: Undefined array key 0 in %s on line %d
NULL
int(1)
string(1) "b"
Warning: Trying to access array offset on value of type int in %s on line %d
NULL
-Notice: Undefined offset: 4 in %s on line %d
+Notice: Undefined array key 4 in %s on line %d
NULL
-Notice: Undefined offset: 3 in %s on line %d
+Notice: Undefined array key 3 in %s on line %d
Fatal error: Uncaught Error: Call to a member function bar() on null in %s:%d
Stack trace:
int(1)
}
-Notice: Undefined offset: %d in %s on line %d
+Notice: Undefined array key 2 in %s on line %d
NULL
--EXPECTF--
Warning: Trying to access array offset on value of type null in %s on line %d
-Warning: Attempt to read property 'a' on null in %s on line %d
+Warning: Attempt to read property "a" on null in %s on line %d
NULL
Warning: Trying to access array offset on value of type null in %s on line %d
-Warning: Attempt to read property 'b' on null in %s on line %d
+Warning: Attempt to read property "b" on null in %s on line %d
NULL
var_dump(C::$a);
?>
--EXPECTF--
-Exception: Access to undeclared static property: C::$a in %sexception_013.php on line 7
+Exception: Access to undeclared static property C::$a in %s on line %d
Exception: Cannot access private property C::$p in %sexception_013.php on line 13
Exception: Attempt to unset static property C::$a in %sexception_013.php on line 19
-Fatal error: Uncaught Error: Access to undeclared static property: C::$a in %sexception_013.php:24
+Fatal error: Uncaught Error: Access to undeclared static property C::$a in %s:%d
Stack trace:
#0 {main}
thrown in %sexception_013.php on line 24
?>
--EXPECT--
-set_exception_handler(): Argument #1 ($exception_handler) must be a valid callback or null, function 'fo' not found or invalid function name
-set_exception_handler(): Argument #1 ($exception_handler) must be a valid callback or null, class '' not found
+set_exception_handler(): Argument #1 ($exception_handler) must be a valid callback or null, function "fo" not found or invalid function name
+set_exception_handler(): Argument #1 ($exception_handler) must be a valid callback or null, class "" not found
--EXPECTF--
foo
-Fatal error: Uncaught Error: Call to undefined method stdClass::fatalError() in %sbug63066.php:5
+Fatal error: Uncaught Error: Call to undefined method stdClass::fatalError() in %s:%d
Stack trace:
#0 %s(%d): gen(Object(stdClass))
#1 {main}
int(%d)
string(%d) "%s"
-Notice: Undefined index: PHP_SELF in %s on line %d
+Notice: Undefined array key "PHP_SELF" in %s on line %d
NULL
Warning: Undefined variable $_SERVER in %s on line %d
int(%d)
string(%d) "%s"
-Notice: Undefined index: PHP_SELF in %s on line %d
+Notice: Undefined array key "PHP_SELF" in %s on line %d
NULL
Warning: Undefined variable $_SERVER in %s on line %d
int(%d)
string(%d) "%s"
-Notice: Undefined index: PHP_SELF in %s on line %d
+Notice: Undefined array key "PHP_SELF" in %s on line %d
NULL
Warning: Undefined variable $_SERVER in %s on line %d
int(%d)
string(%d) "%s"
-Notice: Undefined index: PHP_SELF in %s on line %d
+Notice: Undefined array key "PHP_SELF" in %s on line %d
NULL
Warning: Undefined variable $_SERVER in %s on line %d
}
class B extends A {
public function test2($x) {
- $x->test(); // Uncaught Error: Call to protected method D::test() from context 'B'
+ $x->test(); // Uncaught Error: Call to protected method D::test() from scope B
}
}
class C extends A {
__COMPILER_HALT_OFFSET__;
{}
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant '__COMPILER_HALT_OFFSET__' in %s:%d
+Fatal error: Uncaught Error: Undefined constant "__COMPILER_HALT_OFFSET__" in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
}
}
-Warning: Illegal string offset 'foo' in %s on line %d
+Warning: Illegal string offset "foo" in %s on line %d
Warning: Array to string conversion in %s on line %d
Warning: Only the first byte will be assigned to the string offset in %s on line %d
string(1) "A"
-Warning: Illegal string offset 'foo' in %s on line %d
+Warning: Illegal string offset "foo" in %s on line %d
Warning: Array to string conversion in %s on line %d
?>
--EXPECTF--
-Fatal error: Uncaught Error: Class 'a' not found in %s:%d
+Fatal error: Uncaught Error: Class "a" not found in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
--EXPECT--
string(0) ""
string(0) ""
-Class '' not found
-Class '' not found
-Class '' not found
-Class '' not found
+Class "" not found
+Class "" not found
+Class "" not found
+Class "" not found
Call to undefined function Class:()
Call to undefined function :method()
Call to undefined function :()
int(24)
int(24)
int(24)
-Access to undeclared static property: Foo::$42
-Access to undeclared static property: Foo::$42
-Access to undeclared static property: Foo::$42
+Access to undeclared static property Foo::$42
+Access to undeclared static property Foo::$42
+Access to undeclared static property Foo::$42
?>
--EXPECT--
-Cannot access parent:: when current class scope has no parent
+Cannot access "parent" when current class scope has no parent
Warning: Trying to access array offset on value of type null in %s on line %d
-Warning: Attempt to read property '' on string in %s on line %d
+Warning: Attempt to read property "" on string in %s on line %d
bool(false)
bool(true)
bool(false)
}
}
-Notice: Undefined offset: 2 in %s on line %d
+Notice: Undefined array key 2 in %s on line %d
object(StorageNoRef)#2 (1) {
["s":"StorageNoRef":private]=>
array(2) {
?>
--EXPECTF--
-Notice: Undefined offset: 0 in %s on line %d
+Notice: Undefined array key 0 in %s on line %d
-Notice: Undefined offset: 1 in %s on line %d
+Notice: Undefined array key 1 in %s on line %d
Warning: Resource ID#%d used as offset, casting to integer (%d) in %s on line %d
-Notice: Undefined offset: 1 in %s on line %d
+Notice: Undefined array key 1 in %s on line %d
?>
--EXPECTF--
-Notice: Undefined offset: 5 in %s on line %d
+Notice: Undefined array key 5 in %s on line %d
-Notice: Undefined index: duke in %s on line %d
+Notice: Undefined array key "duke" in %s on line %d
NULL
NULL
echo get_class(new Exception()),"\n";
--EXPECTF--
-Fatal error: Uncaught Error: Class 'test\ns1\Exception' not found in %sns_004.php:%d
+Fatal error: Uncaught Error: Class "test\ns1\Exception" not found in %s:%d
Stack trace:
#0 {main}
thrown in %sns_004.php on line %d
--EXPECTF--
ok
-Fatal error: Uncaught Error: Call to undefined method Exception::bar() in %sns_038.php:7
+Fatal error: Uncaught Error: Call to undefined method Exception::bar() in %s:%d
Stack trace:
#0 {main}
thrown in %sns_038.php on line 7
ok
ok
-Fatal error: Uncaught Error: Undefined constant 'test\ns1\BAR' in %s:%d
+Fatal error: Uncaught Error: Undefined constant "test\ns1\BAR" in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
class ok
ok
-Fatal error: Uncaught Error: Undefined constant 'Test\ns1\unknown' in %sns_057.php:%d
+Fatal error: Uncaught Error: Undefined constant "Test\ns1\unknown" in %s:%d
Stack trace:
#0 {main}
thrown in %sns_057.php on line %d
class ok
ok
-Fatal error: Uncaught Error: Undefined constant 'unknown' in %sns_058.php:%d
+Fatal error: Uncaught Error: Undefined constant "unknown" in %s:%d
Stack trace:
#0 {main}
thrown in %sns_058.php on line %d
?>
--EXPECT--
-Undefined constant 'foo\unknown'
-Undefined constant 'foo\unknown'
-Undefined constant 'unknown'
+Undefined constant "foo\unknown"
+Undefined constant "foo\unknown"
+Undefined constant "unknown"
foo();
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'unknown' in %sns_077_%d.php:%d
+Fatal error: Uncaught Error: Undefined constant "unknown" in %s:%d
Stack trace:
#0 %s(%d): foo\foo()
#1 {main}
foo();
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'unknown' in %sns_077_%d.php:%d
+Fatal error: Uncaught Error: Undefined constant "unknown" in %s:%d
Stack trace:
#0 %s(%d): foo\foo()
#1 {main}
foo();
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'foo\unknown' in %sns_077_%d.php:%d
+Fatal error: Uncaught Error: Undefined constant "foo\unknown" in %s:%d
Stack trace:
#0 %s(%d): foo\foo()
#1 {main}
foo();
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'foo\unknown' in %sns_077_%d.php:%d
+Fatal error: Uncaught Error: Undefined constant "foo\unknown" in %s:%d
Stack trace:
#0 %s(%d): foo\foo()
#1 {main}
foo();
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'unknown' in %sns_077_%d.php:%d
+Fatal error: Uncaught Error: Undefined constant "unknown" in %s:%d
Stack trace:
#0 %s(%d): foo()
#1 {main}
foo();
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'unknown' in %sns_077_%d.php:%d
+Fatal error: Uncaught Error: Undefined constant "unknown" in %s:%d
Stack trace:
#0 %s(%d): foo()
#1 {main}
foo();
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'unknown' in %sns_077_%d.php:%d
+Fatal error: Uncaught Error: Undefined constant "unknown" in %s:%d
Stack trace:
#0 %s(%d): foo()
#1 {main}
?>
--EXPECTF--
-Fatal error: Uncaught Error: Access to undeclared static property: foo::$f in %s:%d
+Fatal error: Uncaught Error: Access to undeclared static property foo::$f in %s:%d
Stack trace:
#0 %s(%d): foo->__construct()
#1 {main}
?>
--EXPECTF--
-Fatal error: Uncaught Error: Access to undeclared static property: bar::$f in %s:%d
+Fatal error: Uncaught Error: Access to undeclared static property bar::$f in %s:%d
Stack trace:
#0 %s(%d): foo->__construct()
#1 {main}
int(2)
int(1)
-Notice: Undefined index: in %s on line %d
+Notice: Undefined array key "" in %s on line %d
NULL
-Notice: Undefined index: run away in %s on line %d
+Notice: Undefined array key "run away" in %s on line %d
NULL
int(2)
int(1)
echo "Done\n";
?>
--EXPECTF--
-Warning: Illegal string offset 'x' in %soffset_assign.php on line %d
+Warning: Illegal string offset "x" in %s on line %d
Fatal error: Uncaught Error: Cannot use string offset as an array in %soffset_assign.php:%d
Stack trace:
Warning: String offset cast occurred in %s on line %d
string(1) "S"
-Warning: Illegal string offset 'run away' in %s on line %d
+Warning: Illegal string offset "run away" in %s on line %d
string(1) "S"
string(1) "c"
-Warning: Illegal string offset '14.5' in %s on line %d
+Warning: Illegal string offset "14.5" in %s on line %d
string(1) "o"
Notice: A non well formed numeric value encountered in %s on line %d
$x->y;
echo "ok\n";
--EXPECTF--
-Warning: Uninitialized string offset: 3 in %s on line %d
+Warning: Uninitialized string offset 3 in %s on line %d
ok
?>
--EXPECT--
-Cannot access self:: when no class scope is active
+Cannot access "self" when no class scope is active
?>
--EXPECT--
-Cannot access self:: when no class scope is active
-Cannot access self:: when no class scope is active
-Cannot access self:: when no class scope is active
-Cannot access self:: when no class scope is active
+Cannot access "self" when no class scope is active
+Cannot access "self" when no class scope is active
+Cannot access "self" when no class scope is active
+Cannot access "self" when no class scope is active
?>
--EXPECT--
-Class 'Test' not found
+Class "Test" not found
string(1) "b"
string(1) "c"
-Warning: Uninitialized string offset: 3 in %s on line %d
+Warning: Uninitialized string offset 3 in %s on line %d
string(0) ""
string(1) "b"
-Warning: Uninitialized string offset: 1 in %s on line %d
+Warning: Uninitialized string offset 1 in %s on line %d
string(0) ""
string(1) "a"
string(1) "b"
string(1) "c"
-Warning: Uninitialized string offset: 3 in %s on line %d
+Warning: Uninitialized string offset 3 in %s on line %d
string(0) ""
string(1) "b"
-Warning: Uninitialized string offset: 1 in %s on line %d
+Warning: Uninitialized string offset 1 in %s on line %d
string(0) ""
foo($str[2][-1]);
?>
--EXPECTF--
-Warning: Uninitialized string offset: -10 in %s on line %d
+Warning: Uninitialized string offset -10 in %s on line %d
string(0) ""
string(1) "d"
-Warning: Uninitialized string offset: -2 in %s on line %d
+Warning: Uninitialized string offset -2 in %s on line %d
string(0) ""
string(1) "c"
-Warning: Uninitialized string offset: -10 in %s on line %d
+Warning: Uninitialized string offset -10 in %s on line %d
string(0) ""
string(1) "d"
-Warning: Uninitialized string offset: -2 in %s on line %d
+Warning: Uninitialized string offset -2 in %s on line %d
string(0) ""
string(1) "c"
string(15) "abCZefghijPlmno"
string(15) "abCZefghijPQmno"
-Warning: Illegal string offset: -20 in %sstr_offset_004.php on line %d
+Warning: Illegal string offset -20 in %s on line %d
string(15) "abCZefghijPQmno"
string(15) "AbCZefghijPQmno"
string(21) "AbCZefghijPQmno N"
?>
--EXPECTF--
-Warning: Uninitialized string offset: %d in %s on line %d
+Warning: Uninitialized string offset %d in %s on line %d
string(0) ""
-Warning: Uninitialized string offset: -%d in %s on line %d
+Warning: Uninitialized string offset -%d in %s on line %d
string(0) ""
?>
--EXPECT--
-Access to undeclared static property: Foo::$property
+Access to undeclared static property Foo::$property
?>
--EXPECTF--
-Fatal error: Trait 'THello' not found in %s on line %d
+Fatal error: Trait "THello" not found in %s on line %d
?>
--EXPECTF--
-Fatal error: Trait 'abc' not found in %s on line %d
+Fatal error: Trait "abc" not found in %s on line %d
?>
--EXPECTF--
-Fatal error: Uncaught Error: Call to protected method bar::test() from context '' in %s:%d
+Fatal error: Uncaught Error: Call to protected method bar::test() from global scope in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
?>
--EXPECTF--
-Fatal error: Uncaught Error: Call to protected method MyClass::sayHello() from context '' in %s:%d
+Fatal error: Uncaught Error: Call to protected method MyClass::sayHello() from global scope in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
?>
--EXPECTF--
Hello World!Hello World!
-Fatal error: Uncaught Error: Call to private method MyClass::sayHelloWorld() from context '' in %s:%d
+Fatal error: Uncaught Error: Call to private method MyClass::sayHelloWorld() from global scope in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
}
?>
--EXPECT--
-Class 'BAR' not found
+Class "BAR" not found
$foo = new Foo();
?>
--EXPECTF--
-Fatal error: Uncaught Error: Class 'BAR' not found in %s:%d
+Fatal error: Uncaught Error: Class "BAR" not found in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
?>
--EXPECT--
-Class 'B' not found
+Class "B" not found
?>
--EXPECT--
-Interface 'B' not found
+Interface "B" not found
?>
--EXPECT--
-Undefined offset: 0
+Undefined array key 0
array(0) {
}
-Undefined index: key
+Undefined array key "key"
array(0) {
}
-Undefined index: test
+Undefined array key "test"
Undefined variable $test
--EXPECTF--
1
-Notice: Undefined index: x in %sunset_cv06.php on line %d
+Notice: Undefined array key "x" in %s on line %d
ok
?>
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'foo\bar\baz' in %s:%d
+Fatal error: Uncaught Error: Undefined constant "foo\bar\baz" in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
?>
--EXPECTF--
-Fatal error: Uncaught ReflectionException: Class A does not exist in %s:%d
+Fatal error: Uncaught ReflectionException: Class "A" does not exist in %s:%d
Stack trace:
#0 %s(%d): ReflectionClass->__construct('A')
#1 %s(%d): {closure}('I')
--EXPECTF--
string(1) "f"
-Warning: Attempt to read property 'prop' on string in %s on line %d
+Warning: Attempt to read property "prop" on string in %s on line %d
NULL
Call to a member function method() on string
int(42)
--EXPECTF--
string(1) "t"
-Warning: Attempt to read property 'prop' on string in %s on line %d
+Warning: Attempt to read property "prop" on string in %s on line %d
NULL
Call to a member function method() on string
?>
--EXPECTF--
-Warning: Attempt to read property 'bar' on string in %s on line %d
+Warning: Attempt to read property "bar" on string in %s on line %d
new WeakReference();
?>
--EXPECTF--
-Fatal error: Uncaught Error: Direct instantiation of 'WeakReference' is not allowed, use WeakReference::create instead in %s:2
+Fatal error: Uncaught Error: Direct instantiation of WeakReference is not allowed, use WeakReference::create instead in %s:2
Stack trace:
#0 %s(2): WeakReference->__construct()
#1 {main}
*pce = zend_lookup_class(Z_STR_P(arg));
if (ce_base) {
if ((!*pce || !instanceof_function(*pce, ce_base))) {
- zend_argument_type_error(num, "must be a class name derived from %s, '%s' given", ZSTR_VAL(ce_base->name), Z_STRVAL_P(arg));
+ zend_argument_type_error(num, "must be a class name derived from %s, %s given", ZSTR_VAL(ce_base->name), Z_STRVAL_P(arg));
*pce = NULL;
return 0;
}
}
if (!*pce) {
- zend_argument_type_error(num, "must be a valid class name, '%s' given", Z_STRVAL_P(arg));
+ zend_argument_type_error(num, "must be a valid class name, %s given", Z_STRVAL_P(arg));
return 0;
}
return 1;
}
if (ce_base) {
if ((!*pce || !instanceof_function(*pce, ce_base))) {
- zend_spprintf(error, 0, "a class name derived from %s%s, '%s' given",
+ zend_spprintf(error, 0, "a class name derived from %s%s, %s given",
ZSTR_VAL(ce_base->name), check_null ? " or null" : "", Z_STRVAL_P(arg));
*pce = NULL;
return "";
}
}
if (!*pce) {
- zend_spprintf(error, 0, "a valid class name%s, '%s' given",
+ zend_spprintf(error, 0, "a valid class name%s, %s given",
check_null ? " or null" : "", Z_STRVAL_P(arg));
return "";
}
*object = this_ptr;
if (ce && !instanceof_function(Z_OBJCE_P(this_ptr), ce)) {
- zend_error_noreturn(E_CORE_ERROR, "%s::%s() must be derived from %s::%s",
+ zend_error_noreturn(E_CORE_ERROR, "%s::%s() must be derived from %s::%s()",
ZSTR_VAL(Z_OBJCE_P(this_ptr)->name), get_active_function_name(), ZSTR_VAL(ce->name), get_active_function_name());
}
if (ce && !instanceof_function(Z_OBJCE_P(this_ptr), ce)) {
if (!(flags & ZEND_PARSE_PARAMS_QUIET)) {
- zend_error_noreturn(E_CORE_ERROR, "%s::%s() must be derived from %s::%s",
+ zend_error_noreturn(E_CORE_ERROR, "%s::%s() must be derived from %s::%s()",
ZSTR_VAL(ce->name), get_active_function_name(), ZSTR_VAL(Z_OBJCE_P(this_ptr)->name), get_active_function_name());
}
va_end(va);
if ((req_mod = zend_hash_find_ptr(&module_registry, lcname)) == NULL || !req_mod->module_started) {
zend_string_efree(lcname);
/* TODO: Check version relationship */
- zend_error(E_CORE_WARNING, "Cannot load module '%s' because required module '%s' is not loaded", module->name, dep->name);
+ zend_error(E_CORE_WARNING, "Cannot load module \"%s\" because required module \"%s\" is not loaded", module->name, dep->name);
module->module_started = 0;
return FAILURE;
}
if (zend_hash_exists(&module_registry, lcname) || zend_get_extension(dep->name)) {
zend_string_efree(lcname);
/* TODO: Check version relationship */
- zend_error(E_CORE_WARNING, "Cannot load module '%s' because conflicting module '%s' is already loaded", module->name, dep->name);
+ zend_error(E_CORE_WARNING, "Cannot load module \"%s\" because conflicting module \"%s\" is already loaded", module->name, dep->name);
return NULL;
}
zend_string_efree(lcname);
lcname = zend_new_interned_string(lcname);
if ((module_ptr = zend_hash_add_mem(&module_registry, lcname, module, sizeof(zend_module_entry))) == NULL) {
- zend_error(E_CORE_WARNING, "Module '%s' already loaded", module->name);
+ zend_error(E_CORE_WARNING, "Module \"%s\" is already loaded", module->name);
zend_string_release(lcname);
return NULL;
}
*strict_class = 0;
if (zend_string_equals_literal(lcname, "self")) {
if (!scope) {
- if (error) *error = estrdup("cannot access self:: when no class scope is active");
+ if (error) *error = estrdup("cannot access \"self\" when no class scope is active");
} else {
fcc->called_scope = zend_get_called_scope(EG(current_execute_data));
fcc->calling_scope = scope;
}
} else if (zend_string_equals_literal(lcname, "parent")) {
if (!scope) {
- if (error) *error = estrdup("cannot access parent:: when no class scope is active");
+ if (error) *error = estrdup("cannot access \"parent\" when no class scope is active");
} else if (!scope->parent) {
- if (error) *error = estrdup("cannot access parent:: when current class scope has no parent");
+ if (error) *error = estrdup("cannot access \"parent\" when current class scope has no parent");
} else {
fcc->called_scope = zend_get_called_scope(EG(current_execute_data));
fcc->calling_scope = scope->parent;
zend_class_entry *called_scope = zend_get_called_scope(EG(current_execute_data));
if (!called_scope) {
- if (error) *error = estrdup("cannot access static:: when no class scope is active");
+ if (error) *error = estrdup("cannot access \"static\" when no class scope is active");
} else {
fcc->called_scope = called_scope;
fcc->calling_scope = called_scope;
*strict_class = 1;
ret = 1;
} else {
- if (error) zend_spprintf(error, 0, "class '%.*s' not found", (int)name_len, ZSTR_VAL(name));
+ if (error) zend_spprintf(error, 0, "class \"%.*s\" not found", (int)name_len, ZSTR_VAL(name));
}
ZSTR_ALLOCA_FREE(lcname, use_heap);
return ret;
ftable = &fcc->calling_scope->function_table;
if (ce_org && !instanceof_function(ce_org, fcc->calling_scope)) {
- if (error) zend_spprintf(error, 0, "class '%s' is not a subclass of '%s'", ZSTR_VAL(ce_org->name), ZSTR_VAL(fcc->calling_scope->name));
+ if (error) zend_spprintf(error, 0, "class %s is not a subclass of %s", ZSTR_VAL(ce_org->name), ZSTR_VAL(fcc->calling_scope->name));
return 0;
}
mname = zend_string_init(Z_STRVAL_P(callable) + clen + 2, mlen, 0);
} else {
/* We already checked for plain function before. */
if (error && !(check_flags & IS_CALLABLE_CHECK_SILENT)) {
- zend_spprintf(error, 0, "function '%s' not found or invalid function name", Z_STRVAL_P(callable));
+ zend_spprintf(error, 0, "function \"%s\" not found or invalid function name", Z_STRVAL_P(callable));
}
return 0;
}
}
} else if (error && !(check_flags & IS_CALLABLE_CHECK_SILENT)) {
if (fcc->calling_scope) {
- if (error) zend_spprintf(error, 0, "class '%s' does not have a method '%s'", ZSTR_VAL(fcc->calling_scope->name), ZSTR_VAL(mname));
+ if (error) zend_spprintf(error, 0, "class %s does not have a method \"%s\"", ZSTR_VAL(fcc->calling_scope->name), ZSTR_VAL(mname));
} else {
- if (error) zend_spprintf(error, 0, "function '%s' does not exist", ZSTR_VAL(mname));
+ if (error) zend_spprintf(error, 0, "function %s() does not exist", ZSTR_VAL(mname));
}
}
zend_string_release_ex(lmname, 0);
RETURN_FALSE;
}
} else {
- zend_error(E_WARNING, "Class '%s' not found", ZSTR_VAL(class_name));
+ zend_error(E_WARNING, "Class \"%s\" not found", ZSTR_VAL(class_name));
RETURN_FALSE;
}
}
if (zend_string_equals_literal(class_name, "static")) {
ce = closure->func.common.scope;
} else if ((ce = zend_lookup_class(class_name)) == NULL) {
- zend_error(E_WARNING, "Class '%s' not found", ZSTR_VAL(class_name));
+ zend_error(E_WARNING, "Class \"%s\" not found", ZSTR_VAL(class_name));
zend_tmp_string_release(tmp_class_name);
RETURN_NULL();
}
static ZEND_COLD zend_function *zend_closure_get_constructor(zend_object *object) /* {{{ */
{
- zend_throw_error(NULL, "Instantiation of 'Closure' is not allowed");
+ zend_throw_error(NULL, "Instantiation of class Closure is not allowed");
return NULL;
}
/* }}} */
/* {{{ Private constructor preventing instantiation */
ZEND_COLD ZEND_METHOD(Closure, __construct)
{
- zend_throw_error(NULL, "Instantiation of 'Closure' is not allowed");
+ zend_throw_error(NULL, "Instantiation of class Closure is not allowed");
}
/* }}} */
if (expr_node.op_type == IS_CONST) {
/* Unlikely case that happen if class_ast is constant folded.
* Handle it here, to avoid needing a CONST specialization in the VM. */
- zend_error_noreturn(E_COMPILE_ERROR, "Cannot use ::class on value of type %s",
+ zend_error_noreturn(E_COMPILE_ERROR, "Cannot use \"::class\" on value of type %s",
zend_zval_type_name(&expr_node.u.constant));
}
if (zend_string_equals_literal_ci(class_name, "self")) {
if (UNEXPECTED(!scope)) {
- zend_throw_error(NULL, "Cannot access self:: when no class scope is active");
+ zend_throw_error(NULL, "Cannot access \"self\" when no class scope is active");
goto failure;
}
ce = scope;
} else if (zend_string_equals_literal_ci(class_name, "parent")) {
if (UNEXPECTED(!scope)) {
- zend_throw_error(NULL, "Cannot access parent:: when no class scope is active");
+ zend_throw_error(NULL, "Cannot access \"parent\" when no class scope is active");
goto failure;
} else if (UNEXPECTED(!scope->parent)) {
- zend_throw_error(NULL, "Cannot access parent:: when current class scope has no parent");
+ zend_throw_error(NULL, "Cannot access \"parent\" when current class scope has no parent");
goto failure;
} else {
ce = scope->parent;
} else if (zend_string_equals_literal_ci(class_name, "static")) {
ce = zend_get_called_scope(EG(current_execute_data));
if (UNEXPECTED(!ce)) {
- zend_throw_error(NULL, "Cannot access static:: when no class scope is active");
+ zend_throw_error(NULL, "Cannot access \"static\" when no class scope is active");
goto failure;
}
} else {
c = zend_hash_find_ptr(&ce->constants_table, constant_name);
if (c == NULL) {
if ((flags & ZEND_FETCH_CLASS_SILENT) == 0) {
- zend_throw_error(NULL, "Undefined class constant '%s::%s'", ZSTR_VAL(class_name), ZSTR_VAL(constant_name));
+ zend_throw_error(NULL, "Undefined constant %s::%s", ZSTR_VAL(class_name), ZSTR_VAL(constant_name));
goto failure;
}
ret_constant = NULL;
} else {
if (!zend_verify_const_access(c, scope)) {
if ((flags & ZEND_FETCH_CLASS_SILENT) == 0) {
- zend_throw_error(NULL, "Cannot access %s const %s::%s", zend_visibility_string(Z_ACCESS_FLAGS(c->value)), ZSTR_VAL(class_name), ZSTR_VAL(constant_name));
+ zend_throw_error(NULL, "Cannot access %s constant %s::%s", zend_visibility_string(Z_ACCESS_FLAGS(c->value)), ZSTR_VAL(class_name), ZSTR_VAL(constant_name));
}
goto failure;
}
int ret;
if (IS_CONSTANT_VISITED(ret_constant)) {
- zend_throw_error(NULL, "Cannot declare self-referencing constant '%s::%s'", ZSTR_VAL(class_name), ZSTR_VAL(constant_name));
+ zend_throw_error(NULL, "Cannot declare self-referencing constant %s::%s", ZSTR_VAL(class_name), ZSTR_VAL(constant_name));
ret_constant = NULL;
goto failure;
}
if (!c) {
if (!(flags & ZEND_FETCH_CLASS_SILENT)) {
- zend_throw_error(NULL, "Undefined constant '%s'", name);
+ zend_throw_error(NULL, "Undefined constant \"%s\"", name);
}
return NULL;
}
}
zend_error_va(E_WARNING, (file && ZSTR_LEN(file) > 0) ? ZSTR_VAL(file) : NULL, line,
- "Uncaught %s in exception handling during call to %s::__tostring()",
+ "Uncaught %s in exception handling during call to %s::__toString()",
ZSTR_VAL(Z_OBJCE(zv)->name), ZSTR_VAL(ce_exception->name));
if (file) {
/* We successfully unwound, nothing more to do */
result = SUCCESS;
} else {
- zend_error(severity, "Uncaught exception '%s'", ZSTR_VAL(ce_exception->name));
+ zend_error(severity, "Uncaught exception %s", ZSTR_VAL(ce_exception->name));
}
OBJ_RELEASE(ex);
|| opline->opcode == ZEND_POST_INC_OBJ
|| opline->opcode == ZEND_POST_DEC_OBJ) {
zend_throw_error(NULL,
- "Attempt to increment/decrement property '%s' on %s",
+ "Attempt to increment/decrement property \"%s\" on %s",
ZSTR_VAL(property_name), zend_zval_type_name(object)
);
} else if (opline->opcode == ZEND_FETCH_OBJ_W
|| opline->opcode == ZEND_FETCH_OBJ_FUNC_ARG
|| opline->opcode == ZEND_ASSIGN_OBJ_REF) {
zend_throw_error(NULL,
- "Attempt to modify property '%s' on %s",
+ "Attempt to modify property \"%s\" on %s",
ZSTR_VAL(property_name), zend_zval_type_name(object)
);
} else {
zend_throw_error(NULL,
- "Attempt to assign property '%s' on %s",
+ "Attempt to assign property \"%s\" on %s",
ZSTR_VAL(property_name), zend_zval_type_name(object)
);
}
break;
}
if (type != BP_VAR_UNSET) {
- zend_error(E_WARNING, "Illegal string offset '%s'", Z_STRVAL_P(dim));
+ zend_error(E_WARNING, "Illegal string offset \"%s\"", Z_STRVAL_P(dim));
}
break;
case IS_UNDEF:
{
zend_string *tmp_property_name;
zend_string *property_name = zval_get_tmp_string(property, &tmp_property_name);
- zend_error(E_WARNING, "Attempt to read property '%s' on %s", ZSTR_VAL(property_name), zend_zval_type_name(object));
+ zend_error(E_WARNING, "Attempt to read property \"%s\" on %s", ZSTR_VAL(property_name), zend_zval_type_name(object));
zend_tmp_string_release(tmp_property_name);
}
offset = zend_check_string_offset(dim, BP_VAR_W EXECUTE_DATA_CC);
if (offset < -(zend_long)Z_STRLEN_P(str)) {
/* Error on negative offset */
- zend_error(E_WARNING, "Illegal string offset: " ZEND_LONG_FMT, offset);
+ zend_error(E_WARNING, "Illegal string offset " ZEND_LONG_FMT, offset);
if (UNEXPECTED(RETURN_VALUE_USED(opline))) {
ZVAL_NULL(EX_VAR(opline->result.var));
}
static zend_never_inline ZEND_COLD void ZEND_FASTCALL zend_undefined_offset(zend_long lval)
{
- zend_error(E_NOTICE, "Undefined offset: " ZEND_LONG_FMT, lval);
+ zend_error(E_NOTICE, "Undefined array key " ZEND_LONG_FMT, lval);
}
static zend_never_inline ZEND_COLD void ZEND_FASTCALL zend_undefined_index(const zend_string *offset)
{
- zend_error(E_NOTICE, "Undefined index: %s", ZSTR_VAL(offset));
+ zend_error(E_NOTICE, "Undefined array key \"%s\"", ZSTR_VAL(offset));
}
ZEND_API ZEND_COLD int ZEND_FASTCALL zend_undefined_offset_write(HashTable *ht, zend_long lval)
ZVAL_NULL(result);
return;
}
- zend_error(E_WARNING, "Illegal string offset '%s'", Z_STRVAL_P(dim));
+ zend_error(E_WARNING, "Illegal string offset \"%s\"", Z_STRVAL_P(dim));
break;
case IS_UNDEF:
ZVAL_UNDEFINED_OP2();
if (UNEXPECTED(Z_STRLEN_P(container) < ((offset < 0) ? -(size_t)offset : ((size_t)offset + 1)))) {
if (type != BP_VAR_IS) {
- zend_error(E_WARNING, "Uninitialized string offset: " ZEND_LONG_FMT, offset);
+ zend_error(E_WARNING, "Uninitialized string offset " ZEND_LONG_FMT, offset);
ZVAL_EMPTY_STRING(result);
} else {
ZVAL_NULL(result);
static zend_never_inline ZEND_COLD void ZEND_FASTCALL zend_wrong_clone_call(zend_function *clone, zend_class_entry *scope)
{
- zend_throw_error(NULL, "Call to %s %s::__clone() from context '%s'", zend_visibility_string(clone->common.fn_flags), ZSTR_VAL(clone->common.scope->name), scope ? ZSTR_VAL(scope->name) : "");
+ zend_throw_error(NULL, "Call to %s %s::__clone() from %s%s",
+ zend_visibility_string(clone->common.fn_flags), ZSTR_VAL(clone->common.scope->name),
+ scope ? "scope " : "global scope",
+ scope ? ZSTR_VAL(scope->name) : ""
+ );
}
#if ZEND_INTENSIVE_DEBUGGING
if (!c) {
if (!check_defined_only) {
- zend_throw_error(NULL, "Undefined constant '%s'", Z_STRVAL_P(RT_CONSTANT(opline, opline->op2)));
+ zend_throw_error(NULL, "Undefined constant \"%s\"", Z_STRVAL_P(RT_CONSTANT(opline, opline->op2)));
ZVAL_UNDEF(EX_VAR(opline->result.var));
}
return FAILURE;
case ZEND_FETCH_CLASS_SELF:
scope = zend_get_executed_scope();
if (UNEXPECTED(!scope)) {
- zend_throw_or_error(fetch_type, NULL, "Cannot access self:: when no class scope is active");
+ zend_throw_or_error(fetch_type, NULL, "Cannot access \"self\" when no class scope is active");
}
return scope;
case ZEND_FETCH_CLASS_PARENT:
scope = zend_get_executed_scope();
if (UNEXPECTED(!scope)) {
- zend_throw_or_error(fetch_type, NULL, "Cannot access parent:: when no class scope is active");
+ zend_throw_or_error(fetch_type, NULL, "Cannot access \"parent\" when no class scope is active");
return NULL;
}
if (UNEXPECTED(!scope->parent)) {
- zend_throw_or_error(fetch_type, NULL, "Cannot access parent:: when current class scope has no parent");
+ zend_throw_or_error(fetch_type, NULL, "Cannot access \"parent\" when current class scope has no parent");
}
return scope->parent;
case ZEND_FETCH_CLASS_STATIC:
ce = zend_get_called_scope(EG(current_execute_data));
if (UNEXPECTED(!ce)) {
- zend_throw_or_error(fetch_type, NULL, "Cannot access static:: when no class scope is active");
+ zend_throw_or_error(fetch_type, NULL, "Cannot access \"static\" when no class scope is active");
return NULL;
}
return ce;
} else if ((ce = zend_lookup_class_ex(class_name, NULL, fetch_type)) == NULL) {
if (!(fetch_type & ZEND_FETCH_CLASS_SILENT) && !EG(exception)) {
if (fetch_sub_type == ZEND_FETCH_CLASS_INTERFACE) {
- zend_throw_or_error(fetch_type, NULL, "Interface '%s' not found", ZSTR_VAL(class_name));
+ zend_throw_or_error(fetch_type, NULL, "Interface \"%s\" not found", ZSTR_VAL(class_name));
} else if (fetch_sub_type == ZEND_FETCH_CLASS_TRAIT) {
- zend_throw_or_error(fetch_type, NULL, "Trait '%s' not found", ZSTR_VAL(class_name));
+ zend_throw_or_error(fetch_type, NULL, "Trait \"%s\" not found", ZSTR_VAL(class_name));
} else {
- zend_throw_or_error(fetch_type, NULL, "Class '%s' not found", ZSTR_VAL(class_name));
+ zend_throw_or_error(fetch_type, NULL, "Class \"%s\" not found", ZSTR_VAL(class_name));
}
}
return NULL;
return NULL;
}
if ((fetch_type & ZEND_FETCH_CLASS_MASK) == ZEND_FETCH_CLASS_INTERFACE) {
- zend_throw_or_error(fetch_type, NULL, "Interface '%s' not found", ZSTR_VAL(class_name));
+ zend_throw_or_error(fetch_type, NULL, "Interface \"%s\" not found", ZSTR_VAL(class_name));
} else if ((fetch_type & ZEND_FETCH_CLASS_MASK) == ZEND_FETCH_CLASS_TRAIT) {
- zend_throw_or_error(fetch_type, NULL, "Trait '%s' not found", ZSTR_VAL(class_name));
+ zend_throw_or_error(fetch_type, NULL, "Trait \"%s\" not found", ZSTR_VAL(class_name));
} else {
- zend_throw_or_error(fetch_type, NULL, "Class '%s' not found", ZSTR_VAL(class_name));
+ zend_throw_or_error(fetch_type, NULL, "Class \"%s\" not found", ZSTR_VAL(class_name));
}
return NULL;
}
static ZEND_COLD zend_never_inline void zend_bad_property_name(void) /* {{{ */
{
- zend_throw_error(NULL, "Cannot access property started with '\\0'");
+ zend_throw_error(NULL, "Cannot access property starting with \"\\0\"");
}
/* }}} */
static ZEND_COLD zend_never_inline void zend_bad_method_call(zend_function *fbc, zend_string *method_name, zend_class_entry *scope) /* {{{ */
{
- zend_throw_error(NULL, "Call to %s method %s::%s() from context '%s'", zend_visibility_string(fbc->common.fn_flags), ZEND_FN_SCOPE_NAME(fbc), ZSTR_VAL(method_name), scope ? ZSTR_VAL(scope->name) : "");
+ zend_throw_error(NULL, "Call to %s method %s::%s() from %s%s",
+ zend_visibility_string(fbc->common.fn_flags), ZEND_FN_SCOPE_NAME(fbc), ZSTR_VAL(method_name),
+ scope ? "scope " : "global scope",
+ scope ? ZSTR_VAL(scope->name) : ""
+ );
}
/* }}} */
/* right now this function is used for non static method lookup too */
/* Is the function static */
if (UNEXPECTED(!(fbc->common.fn_flags & ZEND_ACC_STATIC))) {
- zend_error_noreturn(E_ERROR, "Cannot call non static method %s::%s() without object", ZEND_FN_SCOPE_NAME(fbc), ZSTR_VAL(fbc->common.function_name));
+ zend_error_noreturn(E_ERROR, "Cannot call non-static method %s::%s() without object", ZEND_FN_SCOPE_NAME(fbc), ZSTR_VAL(fbc->common.function_name));
}
#endif
if (!(fbc->op_array.fn_flags & ZEND_ACC_PUBLIC)) {
} else {
undeclared_property:
if (type != BP_VAR_IS) {
- zend_throw_error(NULL, "Access to undeclared static property: %s::$%s", ZSTR_VAL(ce->name), ZSTR_VAL(property_name));
+ zend_throw_error(NULL, "Access to undeclared static property %s::$%s", ZSTR_VAL(ce->name), ZSTR_VAL(property_name));
}
return NULL;
}
static ZEND_COLD zend_never_inline void zend_bad_constructor_call(zend_function *constructor, zend_class_entry *scope) /* {{{ */
{
if (scope) {
- zend_throw_error(NULL, "Call to %s %s::%s() from context '%s'", zend_visibility_string(constructor->common.fn_flags), ZSTR_VAL(constructor->common.scope->name), ZSTR_VAL(constructor->common.function_name), ZSTR_VAL(scope->name));
+ zend_throw_error(NULL, "Call to %s %s::%s() from scope %s",
+ zend_visibility_string(constructor->common.fn_flags), ZSTR_VAL(constructor->common.scope->name),
+ ZSTR_VAL(constructor->common.function_name), ZSTR_VAL(scope->name)
+ );
} else {
- zend_throw_error(NULL, "Call to %s %s::%s() from invalid context", zend_visibility_string(constructor->common.fn_flags), ZSTR_VAL(constructor->common.scope->name), ZSTR_VAL(constructor->common.function_name));
+ zend_throw_error(NULL, "Call to %s %s::%s() from global scope", zend_visibility_string(constructor->common.fn_flags), ZSTR_VAL(constructor->common.scope->name), ZSTR_VAL(constructor->common.function_name));
}
}
/* }}} */
if (object->ce != scope) {
zend_throw_error(NULL,
- "Call to private %s::__destruct() from context '%s'",
+ "Call to private %s::__destruct() from %s%s",
ZSTR_VAL(object->ce->name),
- scope ? ZSTR_VAL(scope->name) : "");
+ scope ? "scope " : "global scope",
+ scope ? ZSTR_VAL(scope->name) : ""
+ );
return;
}
} else {
zend_error(E_WARNING,
- "Call to private %s::__destruct() from context '' during shutdown ignored",
+ "Call to private %s::__destruct() from global scope during shutdown ignored",
ZSTR_VAL(object->ce->name));
return;
}
if (!zend_check_protected(zend_get_function_root_class(destructor), scope)) {
zend_throw_error(NULL,
- "Call to protected %s::__destruct() from context '%s'",
+ "Call to protected %s::__destruct() from %s%s",
ZSTR_VAL(object->ce->name),
- scope ? ZSTR_VAL(scope->name) : "");
+ scope ? "scope " : "global scope",
+ scope ? ZSTR_VAL(scope->name) : ""
+ );
return;
}
} else {
zend_error(E_WARNING,
- "Call to protected %s::__destruct() from context '' during shutdown ignored",
+ "Call to protected %s::__destruct() from global scope during shutdown ignored",
ZSTR_VAL(object->ce->name));
return;
}
c = Z_PTR_P(zv);
scope = EX(func)->op_array.scope;
if (!zend_verify_const_access(c, scope)) {
- zend_throw_error(NULL, "Cannot access %s const %s::%s", zend_visibility_string(Z_ACCESS_FLAGS(c->value)), ZSTR_VAL(ce->name), Z_STRVAL_P(RT_CONSTANT(opline, opline->op2)));
+ zend_throw_error(NULL, "Cannot access %s constant %s::%s", zend_visibility_string(Z_ACCESS_FLAGS(c->value)), ZSTR_VAL(ce->name), Z_STRVAL_P(RT_CONSTANT(opline, opline->op2)));
ZVAL_UNDEF(EX_VAR(opline->result.var));
HANDLE_EXCEPTION();
}
}
CACHE_POLYMORPHIC_PTR(opline->extended_value, ce, value);
} else {
- zend_throw_error(NULL, "Undefined class constant '%s::%s'",
+ zend_throw_error(NULL, "Undefined constant %s::%s",
ZSTR_VAL(ce->name), Z_STRVAL_P(RT_CONSTANT(opline, opline->op2)));
ZVAL_UNDEF(EX_VAR(opline->result.var));
HANDLE_EXCEPTION();
if (UNEXPECTED(Z_TYPE_P(op) != IS_OBJECT)) {
ZVAL_DEREF(op);
if (Z_TYPE_P(op) != IS_OBJECT) {
- zend_type_error("Cannot use ::class on value of type %s", zend_zval_type_name(op));
+ zend_type_error("Cannot use \"::class\" on value of type %s", zend_zval_type_name(op));
ZVAL_UNDEF(EX_VAR(opline->result.var));
FREE_OP1();
HANDLE_EXCEPTION();
scope = EX(func)->op_array.scope;
if (UNEXPECTED(scope == NULL)) {
SAVE_OPLINE();
- zend_throw_error(NULL, "Cannot use \"%s\" when no class scope is active",
+ zend_throw_error(NULL, "Cannot use \"%s\" in the global scope",
fetch_type == ZEND_FETCH_CLASS_SELF ? "self" :
fetch_type == ZEND_FETCH_CLASS_PARENT ? "parent" : "static");
ZVAL_UNDEF(EX_VAR(opline->result.var));
c = Z_PTR_P(zv);
scope = EX(func)->op_array.scope;
if (!zend_verify_const_access(c, scope)) {
- zend_throw_error(NULL, "Cannot access %s const %s::%s", zend_visibility_string(Z_ACCESS_FLAGS(c->value)), ZSTR_VAL(ce->name), Z_STRVAL_P(RT_CONSTANT(opline, opline->op2)));
+ zend_throw_error(NULL, "Cannot access %s constant %s::%s", zend_visibility_string(Z_ACCESS_FLAGS(c->value)), ZSTR_VAL(ce->name), Z_STRVAL_P(RT_CONSTANT(opline, opline->op2)));
ZVAL_UNDEF(EX_VAR(opline->result.var));
HANDLE_EXCEPTION();
}
}
CACHE_POLYMORPHIC_PTR(opline->extended_value, ce, value);
} else {
- zend_throw_error(NULL, "Undefined class constant '%s::%s'",
+ zend_throw_error(NULL, "Undefined constant %s::%s",
ZSTR_VAL(ce->name), Z_STRVAL_P(RT_CONSTANT(opline, opline->op2)));
ZVAL_UNDEF(EX_VAR(opline->result.var));
HANDLE_EXCEPTION();
if (UNEXPECTED(Z_TYPE_P(op) != IS_OBJECT)) {
ZVAL_DEREF(op);
if (Z_TYPE_P(op) != IS_OBJECT) {
- zend_type_error("Cannot use ::class on value of type %s", zend_zval_type_name(op));
+ zend_type_error("Cannot use \"::class\" on value of type %s", zend_zval_type_name(op));
ZVAL_UNDEF(EX_VAR(opline->result.var));
zval_ptr_dtor_nogc(EX_VAR(opline->op1.var));
HANDLE_EXCEPTION();
scope = EX(func)->op_array.scope;
if (UNEXPECTED(scope == NULL)) {
SAVE_OPLINE();
- zend_throw_error(NULL, "Cannot use \"%s\" when no class scope is active",
+ zend_throw_error(NULL, "Cannot use \"%s\" in the global scope",
fetch_type == ZEND_FETCH_CLASS_SELF ? "self" :
fetch_type == ZEND_FETCH_CLASS_PARENT ? "parent" : "static");
ZVAL_UNDEF(EX_VAR(opline->result.var));
c = Z_PTR_P(zv);
scope = EX(func)->op_array.scope;
if (!zend_verify_const_access(c, scope)) {
- zend_throw_error(NULL, "Cannot access %s const %s::%s", zend_visibility_string(Z_ACCESS_FLAGS(c->value)), ZSTR_VAL(ce->name), Z_STRVAL_P(RT_CONSTANT(opline, opline->op2)));
+ zend_throw_error(NULL, "Cannot access %s constant %s::%s", zend_visibility_string(Z_ACCESS_FLAGS(c->value)), ZSTR_VAL(ce->name), Z_STRVAL_P(RT_CONSTANT(opline, opline->op2)));
ZVAL_UNDEF(EX_VAR(opline->result.var));
HANDLE_EXCEPTION();
}
}
CACHE_POLYMORPHIC_PTR(opline->extended_value, ce, value);
} else {
- zend_throw_error(NULL, "Undefined class constant '%s::%s'",
+ zend_throw_error(NULL, "Undefined constant %s::%s",
ZSTR_VAL(ce->name), Z_STRVAL_P(RT_CONSTANT(opline, opline->op2)));
ZVAL_UNDEF(EX_VAR(opline->result.var));
HANDLE_EXCEPTION();
if (UNEXPECTED(Z_TYPE_P(op) != IS_OBJECT)) {
ZVAL_DEREF(op);
if (Z_TYPE_P(op) != IS_OBJECT) {
- zend_type_error("Cannot use ::class on value of type %s", zend_zval_type_name(op));
+ zend_type_error("Cannot use \"::class\" on value of type %s", zend_zval_type_name(op));
ZVAL_UNDEF(EX_VAR(opline->result.var));
HANDLE_EXCEPTION();
scope = EX(func)->op_array.scope;
if (UNEXPECTED(scope == NULL)) {
SAVE_OPLINE();
- zend_throw_error(NULL, "Cannot use \"%s\" when no class scope is active",
+ zend_throw_error(NULL, "Cannot use \"%s\" in the global scope",
fetch_type == ZEND_FETCH_CLASS_SELF ? "self" :
fetch_type == ZEND_FETCH_CLASS_PARENT ? "parent" : "static");
ZVAL_UNDEF(EX_VAR(opline->result.var));
c = Z_PTR_P(zv);
scope = EX(func)->op_array.scope;
if (!zend_verify_const_access(c, scope)) {
- zend_throw_error(NULL, "Cannot access %s const %s::%s", zend_visibility_string(Z_ACCESS_FLAGS(c->value)), ZSTR_VAL(ce->name), Z_STRVAL_P(RT_CONSTANT(opline, opline->op2)));
+ zend_throw_error(NULL, "Cannot access %s constant %s::%s", zend_visibility_string(Z_ACCESS_FLAGS(c->value)), ZSTR_VAL(ce->name), Z_STRVAL_P(RT_CONSTANT(opline, opline->op2)));
ZVAL_UNDEF(EX_VAR(opline->result.var));
HANDLE_EXCEPTION();
}
}
CACHE_POLYMORPHIC_PTR(opline->extended_value, ce, value);
} else {
- zend_throw_error(NULL, "Undefined class constant '%s::%s'",
+ zend_throw_error(NULL, "Undefined constant %s::%s",
ZSTR_VAL(ce->name), Z_STRVAL_P(RT_CONSTANT(opline, opline->op2)));
ZVAL_UNDEF(EX_VAR(opline->result.var));
HANDLE_EXCEPTION();
if (UNEXPECTED(Z_TYPE_P(op) != IS_OBJECT)) {
ZVAL_DEREF(op);
if (Z_TYPE_P(op) != IS_OBJECT) {
- zend_type_error("Cannot use ::class on value of type %s", zend_zval_type_name(op));
+ zend_type_error("Cannot use \"::class\" on value of type %s", zend_zval_type_name(op));
ZVAL_UNDEF(EX_VAR(opline->result.var));
HANDLE_EXCEPTION();
scope = EX(func)->op_array.scope;
if (UNEXPECTED(scope == NULL)) {
SAVE_OPLINE();
- zend_throw_error(NULL, "Cannot use \"%s\" when no class scope is active",
+ zend_throw_error(NULL, "Cannot use \"%s\" in the global scope",
fetch_type == ZEND_FETCH_CLASS_SELF ? "self" :
fetch_type == ZEND_FETCH_CLASS_PARENT ? "parent" : "static");
ZVAL_UNDEF(EX_VAR(opline->result.var));
ZEND_COLD ZEND_METHOD(WeakReference, __construct)
{
- zend_throw_error(NULL,
- "Direct instantiation of 'WeakReference' is not allowed, "
- "use WeakReference::create instead");
+ zend_throw_error(NULL, "Direct instantiation of WeakReference is not allowed, use WeakReference::create instead");
}
ZEND_METHOD(WeakReference, create)
}
if (mode_len != 1 || (mode[0] != 'r' && mode[0] != 'w')) {
- zend_argument_value_error(2, "must be either 'r' or 'w'");
+ zend_argument_value_error(2, "must be either \"r\" or \"w\"");
RETURN_THROWS();
}
?>
--EXPECTF--
-bzopen(): Argument #2 ($mode) must be either 'r' or 'w'
+bzopen(): Argument #2 ($mode) must be either "r" or "w"
Warning: bzopen(): Filename cannot be empty in %s on line %d
bool(false)
Warning: bzopen(): Filename cannot be empty in %s on line %d
bool(false)
-bzopen(): Argument #2 ($mode) must be either 'r' or 'w'
-bzopen(): Argument #2 ($mode) must be either 'r' or 'w'
+bzopen(): Argument #2 ($mode) must be either "r" or "w"
+bzopen(): Argument #2 ($mode) must be either "r" or "w"
Warning: bzopen(no_such_file): Failed to open stream: No such file or directory in %s on line %d
bool(false)
size_t len;
if (zend_hash_num_elements(Z_ARRVAL_P(key)) != 2) {
- zend_argument_error(NULL, 1, "must have exactly two elements: 'key' and 'name'");
+ zend_argument_error(NULL, 1, "must have exactly two elements: \"key\" and \"name\"");
return 0;
}
zend_hash_internal_pointer_reset_ex(Z_ARRVAL_P(key), &pos);
--EXPECTF--
database handler: %s
-Fatal error: Uncaught Error: dba_insert(): Argument #1 ($key) must have exactly two elements: 'key' and 'name' in %s.php:%d
+Fatal error: Uncaught Error: dba_insert(): Argument #1 ($key) must have exactly two elements: "key" and "name" in %s.php:%d
Stack trace:
#0 %sdba013.php(6): dba_insert(Array, '%s', Resource id #%d)
#1 {main}
--EXPECTF--
database handler: %s
-Fatal error: Uncaught Error: dba_insert(): Argument #1 ($key) must have exactly two elements: 'key' and 'name' in %s.php:%d
+Fatal error: Uncaught Error: dba_insert(): Argument #1 ($key) must have exactly two elements: "key" and "name" in %s.php:%d
Stack trace:
#0 %sdba014.php(6): dba_insert(Array, '%s', Resource id #%d)
#1 {main}
RETURN_TRUE;
}
- zend_argument_error(NULL, 2, "must be a class name derived from %s or null, '%s' given", ZSTR_VAL(basece->name), ZSTR_VAL(ce->name));
+ zend_argument_error(NULL, 2, "must be a class name derived from %s or null, %s given", ZSTR_VAL(basece->name), ZSTR_VAL(ce->name));
}
/* }}} */
?>
--EXPECT--
-Attempt to assign property 'nodeValue' on null
-Attempt to assign property 'nodeValue' on null
+Attempt to assign property "nodeValue" on null
+Attempt to assign property "nodeValue" on null
Array
(
[0] => Value
testing property access
string(4) "data"
-Warning: Attempt to read property 'textContent' on null in %s on line %d
+Warning: Attempt to read property "textContent" on null in %s on line %d
NULL
testing offset not a long
array(1) {
string(4) "test"
}
-Warning: Attempt to read property 'textContent' on null in %s on line %d
+Warning: Attempt to read property "textContent" on null in %s on line %d
bool(false)
NULL
array(1) {
static int zend_ffi_validate_vla(zend_ffi_type *type) /* {{{ */
{
if (!FFI_G(allow_vla) && (type->attr & ZEND_FFI_ATTR_VLA)) {
- zend_ffi_throw_parser_error("'[*]' not allowed in other than function prototype scope at line %d", FFI_G(line));
+ zend_ffi_throw_parser_error("\"[*]\" is not allowed in other than function prototype scope at line %d", FFI_G(line));
return FAILURE;
}
return SUCCESS;
ZEND_HASH_FOREACH_STR_KEY_PTR(FFI_G(tags), key, tag) {
if (ZEND_FFI_TYPE(tag->type) == type) {
if (type->kind == ZEND_FFI_TYPE_ENUM) {
- zend_ffi_throw_parser_error("Incomplete 'enum %s' at line %d", ZSTR_VAL(key), FFI_G(line));
+ zend_ffi_throw_parser_error("Incomplete enum \"%s\" at line %d", ZSTR_VAL(key), FFI_G(line));
} else if (type->attr & ZEND_FFI_ATTR_UNION) {
- zend_ffi_throw_parser_error("Incomplete 'union %s' at line %d", ZSTR_VAL(key), FFI_G(line));
+ zend_ffi_throw_parser_error("Incomplete union \"%s\" at line %d", ZSTR_VAL(key), FFI_G(line));
} else {
- zend_ffi_throw_parser_error("Incomplete 'struct %s' at line %d", ZSTR_VAL(key), FFI_G(line));
+ zend_ffi_throw_parser_error("Incomplete struct \"%s\" at line %d", ZSTR_VAL(key), FFI_G(line));
}
return FAILURE;
}
ZEND_HASH_FOREACH_STR_KEY_PTR(FFI_G(symbols), key, sym) {
if (type == ZEND_FFI_TYPE(sym->type)) {
- zend_ffi_throw_parser_error("Incomplete C type '%s' at line %d", ZSTR_VAL(key), FFI_G(line));
+ zend_ffi_throw_parser_error("Incomplete C type %s at line %d", ZSTR_VAL(key), FFI_G(line));
return FAILURE;
}
} ZEND_HASH_FOREACH_END();
zend_ffi_throw_parser_error("Incomplete type at line %d", FFI_G(line));
return FAILURE;
} else if (!allow_incomplete_array && (type->attr & ZEND_FFI_ATTR_INCOMPLETE_ARRAY)) {
- zend_ffi_throw_parser_error("'[]' not allowed at line %d", FFI_G(line));
+ zend_ffi_throw_parser_error("\"[]\" is not allowed at line %d", FFI_G(line));
return FAILURE;
} else if (!FFI_G(allow_vla) && (type->attr & ZEND_FFI_ATTR_VLA)) {
- zend_ffi_throw_parser_error("'[*]' not allowed in other than function prototype scope at line %d", FFI_G(line));
+ zend_ffi_throw_parser_error("\"[*]\" is not allowed in other than function prototype scope at line %d", FFI_G(line));
return FAILURE;
}
return SUCCESS;
static int zend_ffi_validate_type(zend_ffi_type *type, zend_bool allow_incomplete_tag, zend_bool allow_incomplete_array) /* {{{ */
{
if (type->kind == ZEND_FFI_TYPE_VOID) {
- zend_ffi_throw_parser_error("'void' type is not allowed at line %d", FFI_G(line));
+ zend_ffi_throw_parser_error("void type is not allowed at line %d", FFI_G(line));
return FAILURE;
}
return zend_ffi_validate_incomplete_type(type, allow_incomplete_tag, allow_incomplete_array);
static int zend_ffi_validate_var_type(zend_ffi_type *type, zend_bool allow_incomplete_array) /* {{{ */
{
if (type->kind == ZEND_FFI_TYPE_FUNC) {
- zend_ffi_throw_parser_error("'function' type is not allowed at line %d", FFI_G(line));
+ zend_ffi_throw_parser_error("function type is not allowed at line %d", FFI_G(line));
return FAILURE;
}
return zend_ffi_validate_type(type, 0, allow_incomplete_array);
zend_throw_error(zend_ffi_exception_ce, "Only the leftmost array can be undimensioned");
RETURN_THROWS();
} else if (type->kind == ZEND_FFI_TYPE_VOID) {
- zend_throw_error(zend_ffi_exception_ce, "Array of 'void' is not allowed");
+ zend_throw_error(zend_ffi_exception_ce, "Array of void type is not allowed");
RETURN_THROWS();
} else if (type->attr & ZEND_FFI_ATTR_INCOMPLETE_TAG) {
zend_throw_error(zend_ffi_exception_ce, "Array of incomplete type is not allowed");
static ZEND_COLD zend_function *zend_fake_get_constructor(zend_object *object) /* {{{ */
{
- zend_throw_error(NULL, "Instantiation of '%s' is not allowed", ZSTR_VAL(object->ce->name));
+ zend_throw_error(NULL, "Instantiation of %s is not allowed", ZSTR_VAL(object->ce->name));
return NULL;
}
/* }}} */
case ZEND_FFI_DCL_FLOAT|ZEND_FFI_DCL_COMPLEX:
case ZEND_FFI_DCL_DOUBLE|ZEND_FFI_DCL_COMPLEX:
case ZEND_FFI_DCL_DOUBLE|ZEND_FFI_DCL_LONG|ZEND_FFI_DCL_COMPLEX:
- zend_ffi_parser_error("unsupported type '_Complex' at line %d", FFI_G(line));
+ zend_ffi_parser_error("Unsupported type _Complex at line %d", FFI_G(line));
break;
default:
- zend_ffi_parser_error("unsupported type specifier combination at line %d", FFI_G(line));
+ zend_ffi_parser_error("Unsupported type specifier combination at line %d", FFI_G(line));
break;
}
dcl->flags &= ~ZEND_FFI_DCL_TYPE_SPECIFIERS;
dcl->type = type;
return;
}
- zend_ffi_parser_error("undefined C type '%.*s' at line %d", name_len, name, FFI_G(line));
+ zend_ffi_parser_error("Undefined C type \"%.*s\" at line %d", name_len, name, FFI_G(line));
}
/* }}} */
}
value = val->u64;
} else {
- zend_ffi_parser_error("enumerator value '%.*s' must be an integer at line %d", name_len, name, FFI_G(line));
+ zend_ffi_parser_error("Enumerator value \"%.*s\" must be an integer at line %d", name_len, name, FFI_G(line));
return;
}
if (overflow) {
- zend_ffi_parser_error("overflow in enumeration values '%.*s' at line %d", name_len, name, FFI_G(line));
+ zend_ffi_parser_error("Overflow in enumeration values \"%.*s\" at line %d", name_len, name, FFI_G(line));
return;
}
}
sym = zend_hash_str_find_ptr(FFI_G(symbols), name, name_len);
if (sym) {
- zend_ffi_parser_error("redeclaration of '%.*s' at line %d", name_len, name, FFI_G(line));
+ zend_ffi_parser_error("Redeclaration of \"%.*s\" at line %d", name_len, name, FFI_G(line));
} else {
sym = pemalloc(sizeof(zend_ffi_symbol), FFI_G(persistent));
sym->kind = ZEND_FFI_SYM_CONST;
if (!zend_hash_str_add_ptr(&struct_type->record.fields, name, name_len, field)) {
zend_ffi_type_dtor(field->type);
pefree(field, FFI_G(persistent));
- zend_ffi_parser_error("duplicate field name '%.*s' at line %d", name_len, name, FFI_G(line));
+ zend_ffi_parser_error("Duplicate field name \"%.*s\" at line %d", name_len, name, FFI_G(line));
}
}
/* }}} */
field_type = ZEND_FFI_TYPE(field_dcl->type);
if (field_type->kind != ZEND_FFI_TYPE_STRUCT) {
zend_ffi_cleanup_dcl(field_dcl);
- zend_ffi_parser_error("declaration does not declare anything at line %d", FFI_G(line));
+ zend_ffi_parser_error("Declaration does not declare anything at line %d", FFI_G(line));
return;
}
if (!zend_hash_add_ptr(&struct_type->record.fields, key, new_field)) {
zend_ffi_type_dtor(new_field->type);
pefree(new_field, FFI_G(persistent));
- zend_ffi_parser_error("duplicate field name '%s' at line %d", ZSTR_VAL(key), FFI_G(line));
+ zend_ffi_parser_error("Duplicate field name \"%s\" at line %d", ZSTR_VAL(key), FFI_G(line));
return;
}
} else {
if (field_type->kind < ZEND_FFI_TYPE_UINT8 || field_type->kind > ZEND_FFI_TYPE_BOOL) {
zend_ffi_cleanup_dcl(field_dcl);
- zend_ffi_parser_error("wrong type of bit field '%.*s' at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
+ zend_ffi_parser_error("Wrong type of bit field \"%.*s\" at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
}
if (bits->kind == ZEND_FFI_VAL_INT32 || bits->kind == ZEND_FFI_VAL_INT64) {
if (bits->i64 < 0) {
zend_ffi_cleanup_dcl(field_dcl);
- zend_ffi_parser_error("negative width in bit-field '%.*s' at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
+ zend_ffi_parser_error("Negative width in bit-field \"%.*s\" at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
} else if (bits->i64 == 0) {
zend_ffi_cleanup_dcl(field_dcl);
if (name) {
- zend_ffi_parser_error("zero width in bit-field '%.*s' at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
+ zend_ffi_parser_error("Zero width in bit-field \"%.*s\" at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
}
return;
} else if (bits->i64 > field_type->size * 8) {
zend_ffi_cleanup_dcl(field_dcl);
- zend_ffi_parser_error("width of '%.*s' exceeds its type at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
+ zend_ffi_parser_error("Width of \"%.*s\" exceeds its type at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
}
} else if (bits->kind == ZEND_FFI_VAL_UINT32 || bits->kind == ZEND_FFI_VAL_UINT64) {
if (bits->u64 == 0) {
zend_ffi_cleanup_dcl(field_dcl);
if (name) {
- zend_ffi_parser_error("zero width in bit-field '%.*s' at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
+ zend_ffi_parser_error("Zero width in bit-field \"%.*s\" at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
}
return;
} else if (bits->u64 > field_type->size * 8) {
zend_ffi_cleanup_dcl(field_dcl);
- zend_ffi_parser_error("width of '%.*s' exceeds its type at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
+ zend_ffi_parser_error("Width of \"%.*s\" exceeds its type at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
}
} else {
zend_ffi_cleanup_dcl(field_dcl);
- zend_ffi_parser_error("bit field '%.*s' width not an integer constant at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
+ zend_ffi_parser_error("Bit field \"%.*s\" width not an integer constant at line %d", name ? name_len : sizeof("<anonymous>")-1, name ? name : "<anonymous>", FFI_G(line));
}
field = pemalloc(sizeof(zend_ffi_field), FFI_G(persistent));
if (!zend_hash_str_add_ptr(&struct_type->record.fields, name, name_len, field)) {
zend_ffi_type_dtor(field->type);
pefree(field, FFI_G(persistent));
- zend_ffi_parser_error("duplicate field name '%.*s' at line %d", name_len, name, FFI_G(line));
+ zend_ffi_parser_error("Duplicate field name \"%.*s\" at line %d", name_len, name, FFI_G(line));
}
} else {
zend_hash_next_index_insert_ptr(&struct_type->record.fields, field);
length = len->ch;
} else {
zend_ffi_cleanup_dcl(dcl);
- zend_ffi_parser_error("unsupported array index type at line %d", FFI_G(line));
+ zend_ffi_parser_error("Unsupported array index type at line %d", FFI_G(line));
return;
}
if (length < 0) {
zend_ffi_cleanup_dcl(dcl);
- zend_ffi_parser_error("negative array index at line %d", FFI_G(line));
+ zend_ffi_parser_error("Negative array index at line %d", FFI_G(line));
return;
}
zend_ffi_cleanup_dcl(dcl);
zend_hash_destroy(args);
pefree(args, FFI_G(persistent));
- zend_ffi_parser_error("'void' type is not allowed at line %d", FFI_G(line));
+ zend_ffi_parser_error("void type is not allowed at line %d", FFI_G(line));
return;
} else {
no_args = 1;
zend_ffi_cleanup_dcl(dcl);
zend_hash_destroy(args);
pefree(args, FFI_G(persistent));
- zend_ffi_parser_error("'float'/'double' type not allowed at position " ZEND_ULONG_FMT " with __vectorcall at line %d", i+1, FFI_G(line));
+ zend_ffi_parser_error("Type float/double is not allowed at position " ZEND_ULONG_FMT " with __vectorcall at line %d", i+1, FFI_G(line));
return;
}
} ZEND_HASH_FOREACH_END();
}
}
}
- zend_ffi_parser_error("redeclaration of '%.*s' at line %d", name_len, name, FFI_G(line));
+ zend_ffi_parser_error("Redeclaration of \"%.*s\" at line %d", name_len, name, FFI_G(line));
} else {
if ((dcl->flags & ZEND_FFI_DCL_STORAGE_CLASS) == ZEND_FFI_DCL_TYPEDEF) {
if (zend_ffi_validate_vla(ZEND_FFI_TYPE(dcl->type)) != SUCCESS) {
if (dcl->flags & ZEND_FFI_DCL_STRUCT) {
if (tag->kind != ZEND_FFI_TAG_STRUCT) {
- zend_ffi_parser_error("'%.*s' defined as wrong kind of tag at line %d", name_len, name, FFI_G(line));
+ zend_ffi_parser_error("\"%.*s\" defined as wrong kind of tag at line %d", name_len, name, FFI_G(line));
return;
} else if (!incomplete && !(type->attr & ZEND_FFI_ATTR_INCOMPLETE_TAG)) {
- zend_ffi_parser_error("redefinition of 'struct %.*s' at line %d", name_len, name, FFI_G(line));
+ zend_ffi_parser_error("Redefinition of \"struct %.*s\" at line %d", name_len, name, FFI_G(line));
return;
}
} else if (dcl->flags & ZEND_FFI_DCL_UNION) {
if (tag->kind != ZEND_FFI_TAG_UNION) {
- zend_ffi_parser_error("'%.*s' defined as wrong kind of tag at line %d", name_len, name, FFI_G(line));
+ zend_ffi_parser_error("\"%.*s\" defined as wrong kind of tag at line %d", name_len, name, FFI_G(line));
return;
} else if (!incomplete && !(type->attr & ZEND_FFI_ATTR_INCOMPLETE_TAG)) {
- zend_ffi_parser_error("redefinition of 'union %.*s' at line %d", name_len, name, FFI_G(line));
+ zend_ffi_parser_error("Redefinition of \"union %.*s\" at line %d", name_len, name, FFI_G(line));
return;
}
} else if (dcl->flags & ZEND_FFI_DCL_ENUM) {
if (tag->kind != ZEND_FFI_TAG_ENUM) {
- zend_ffi_parser_error("'%.*s' defined as wrong kind of tag at line %d", name_len, name, FFI_G(line));
+ zend_ffi_parser_error("\"%.*s\" defined as wrong kind of tag at line %d", name_len, name, FFI_G(line));
return;
} else if (!incomplete && !(type->attr & ZEND_FFI_ATTR_INCOMPLETE_TAG)) {
- zend_ffi_parser_error("redefinition of 'enum %.*s' at line %d", name_len, name, FFI_G(line));
+ zend_ffi_parser_error("Redefinition of \"enum %.*s\" at line %d", name_len, name, FFI_G(line));
return;
}
} else {
void zend_ffi_set_abi(zend_ffi_dcl *dcl, uint16_t abi) /* {{{ */
{
if (dcl->abi != ZEND_FFI_ABI_DEFAULT) {
- zend_ffi_parser_error("multiple calling convention specifiers at line %d", FFI_G(line));
+ zend_ffi_parser_error("Multiple calling convention specifiers at line %d", FFI_G(line));
} else {
dcl->abi = abi;
}
dcl->attr |= ZEND_FFI_ATTR_GCC_STRUCT;
break;
case attr_unsupported:
- zend_ffi_parser_error("unsupported attribute '%.*s' at line %d", name_len, name, FFI_G(line));
+ zend_ffi_parser_error("Unsupported attribute \"%.*s\" at line %d", name_len, name, FFI_G(line));
break;
default:
/* ignore */
&& val->i64 == 3) {
zend_ffi_set_abi(dcl, ZEND_FFI_ABI_REGISTER);
} else {
- zend_ffi_parser_error("incorrect 'regparam' value at line %d", FFI_G(line));
+ zend_ffi_parser_error("Incorrect \"regparam\" value at line %d", FFI_G(line));
}
break;
case attr_aligned:
&& val->i64 > 0 && val->i64 <= 0x80000000 && (val->i64 & (val->i64 - 1)) == 0) {
dcl->align = val->i64;
} else {
- zend_ffi_parser_error("incorrect 'alignment' value at line %d", FFI_G(line));
+ zend_ffi_parser_error("Incorrect \"alignment\" value at line %d", FFI_G(line));
}
break;
case attr_mode:
}
}
}
- zend_ffi_parser_error("unsupported 'mode' value at line %d", FFI_G(line));
+ zend_ffi_parser_error("Unsupported \"mode\" value at line %d", FFI_G(line));
// TODO: ???
case attr_unsupported:
- zend_ffi_parser_error("unsupported attribute '%.*s' at line %d", name_len, name, FFI_G(line));
+ zend_ffi_parser_error("Unsupported attribute \"%.*s\" at line %d", name_len, name, FFI_G(line));
break;
default:
/* ignore */
&& val->i64 > 0 && val->i64 <= 0x80000000 && (val->i64 & (val->i64 - 1)) == 0) {
dcl->align = val->i64;
} else {
- zend_ffi_parser_error("incorrect 'alignment' value at line %d", FFI_G(line));
+ zend_ffi_parser_error("Incorrect \"alignment\" value at line %d", FFI_G(line));
}
} else {
/* ignore */
["x"]=>
int(0)
}
-FFI\ParserException: Incomplete 'struct _e' at line 1
-FFI\ParserException: Incomplete 'struct _f' at line 1
+FFI\ParserException: Incomplete struct "_e" at line 1
+FFI\ParserException: Incomplete struct "_f" at line 1
ok
[1]=>
int(0)
}
-FFI\ParserException: Incomplete 'enum _e' at line 1
-FFI\ParserException: Incomplete 'enum _f' at line 1
+FFI\ParserException: Incomplete enum "_e" at line 1
+FFI\ParserException: Incomplete enum "_f" at line 1
ok
int(1)
int(2)
int(3)
-FFI\ParserException: 'void' type is not allowed at line 1
-FFI\ParserException: 'void' type is not allowed at line 1
+FFI\ParserException: void type is not allowed at line 1
+FFI\ParserException: void type is not allowed at line 1
FFI\ParserException: Function returning array is not allowed at line 1
FFI\ParserException: Array of functions is not allowed at line 1
FFI\ParserException: Function returning function is not allowed at line 1
?>
ok
--EXPECT--
-FFI\ParserException: Incomplete 'struct DIR' at line 1
+FFI\ParserException: Incomplete struct "DIR" at line 1
ok
-FFI\ParserException: Incomplete 'struct DIR' at line 1
+FFI\ParserException: Incomplete struct "DIR" at line 1
ok
ok
ok
?>
ok
--EXPECT--
-FFI\ParserException: 'function' type is not allowed at line 1
+FFI\ParserException: function type is not allowed at line 1
FFI\ParserException: Struct/union can't contain an instance of itself at line 1
ok
ok
?>
ok
--EXPECTF--
-FFI\ParserException: 'function' type is not allowed at line 1
+FFI\ParserException: function type is not allowed at line 1
FFI\ParserException: Struct/union can't contain an instance of itself at line 1
object(FFI\CData:struct X)#%d (1) {
["ptr"]=>
?>
ok
--EXPECT--
-FFI\ParserException: Incomplete 'struct X' at line 1
+FFI\ParserException: Incomplete struct "X" at line 1
ok
ok
}
?>
--EXPECT--
-FFI\ParserException: '[*]' not allowed in other than function prototype scope at line 1
-FFI\ParserException: '[*]' not allowed in other than function prototype scope at line 1
-FFI\ParserException: '[*]' not allowed in other than function prototype scope at line 1
+FFI\ParserException: "[*]" is not allowed in other than function prototype scope at line 1
+FFI\ParserException: "[*]" is not allowed in other than function prototype scope at line 1
+FFI\ParserException: "[*]" is not allowed in other than function prototype scope at line 1
ok
FFI\Exception: Cannot instantiate FFI\CData of zero size
-FFI\ParserException: '[]' not allowed at line 1
-FFI\ParserException: '[]' not allowed at line 1
+FFI\ParserException: "[]" is not allowed at line 1
+FFI\ParserException: "[]" is not allowed at line 1
ok
ok
ok
");
?>
--EXPECTF--
-Fatal error: Uncaught FFI\ParserException: redeclaration of 'a' at line 3 in %s043.php:2
+Fatal error: Uncaught FFI\ParserException: Redeclaration of "a" at line 3 in %s043.php:2
Stack trace:
#0 %s043.php(2): FFI::cdef('%s')
#1 {main}
if ((tmp = zend_hash_str_find(Z_ARRVAL_P(z_rect), "x", sizeof("x") -1)) != NULL) {
rect.x = zval_get_long(tmp);
} else {
- zend_argument_value_error(2, "must have an 'x' key");
+ zend_argument_value_error(2, "must have an \"x\" key");
RETURN_THROWS();
}
if ((tmp = zend_hash_str_find(Z_ARRVAL_P(z_rect), "y", sizeof("y") - 1)) != NULL) {
rect.y = zval_get_long(tmp);
} else {
- zend_argument_value_error(2, "must have a 'y' key");
+ zend_argument_value_error(2, "must have a \"y\" key");
RETURN_THROWS();
}
if ((tmp = zend_hash_str_find(Z_ARRVAL_P(z_rect), "width", sizeof("width") - 1)) != NULL) {
rect.width = zval_get_long(tmp);
} else {
- zend_argument_value_error(2, "must have a 'width' key");
+ zend_argument_value_error(2, "must have a \"width\" key");
RETURN_THROWS();
}
if ((tmp = zend_hash_str_find(Z_ARRVAL_P(z_rect), "height", sizeof("height") - 1)) != NULL) {
rect.height = zval_get_long(tmp);
} else {
- zend_argument_value_error(2, "must have a 'height' key");
+ zend_argument_value_error(2, "must have a \"height\" key");
RETURN_THROWS();
}
if ((tmp = zend_hash_str_find(Z_ARRVAL_P(z_rect), "x", sizeof("x") - 1)) != NULL) {
rect.x = zval_get_long(tmp);
} else {
- zend_argument_value_error(3, "must have an 'x' key");
+ zend_argument_value_error(3, "must have an \"x\" key");
RETURN_THROWS();
}
if ((tmp = zend_hash_str_find(Z_ARRVAL_P(z_rect), "y", sizeof("y") - 1)) != NULL) {
rect.y = zval_get_long(tmp);
} else {
- zend_argument_value_error(3, "must have a 'y' key");
+ zend_argument_value_error(3, "must have a \"y\" key");
RETURN_THROWS();
}
if ((tmp = zend_hash_str_find(Z_ARRVAL_P(z_rect), "width", sizeof("width") - 1)) != NULL) {
rect.width = zval_get_long(tmp);
} else {
- zend_argument_value_error(3, "must have a 'width' key");
+ zend_argument_value_error(3, "must have a \"width\" key");
RETURN_THROWS();
}
if ((tmp = zend_hash_str_find(Z_ARRVAL_P(z_rect), "height", sizeof("height") - 1)) != NULL) {
rect.height = zval_get_long(tmp);
} else {
- zend_argument_value_error(3, "must have a 'height' key");
+ zend_argument_value_error(3, "must have a \"height\" key");
RETURN_THROWS();
}
pRect = ▭
if ((tmp = zend_hash_str_find(Z_ARRVAL_P(options), "x", sizeof("x") - 1)) != NULL) {
x = zval_get_double(tmp);
} else {
- zend_argument_value_error(2, "must have an 'x' key");
+ zend_argument_value_error(2, "must have an \"x\" key");
RETURN_THROWS();
}
if ((tmp = zend_hash_str_find(Z_ARRVAL_P(options), "y", sizeof("y") - 1)) != NULL) {
y = zval_get_double(tmp);
} else {
- zend_argument_value_error(2, "must have a 'y' key");
+ zend_argument_value_error(2, "must have a \"y\" key");
RETURN_THROWS();
}
echo "Exception: {$e->getMessage()}\n";
}
--EXPECT--
-Exception: Call to private HashContext::__construct() from invalid context
+Exception: Call to private HashContext::__construct() from global scope
new IntlBreakIterator();
--EXPECTF--
-Fatal error: Uncaught Error: Call to private IntlBreakIterator::__construct() from invalid context in %s:%d
+Fatal error: Uncaught Error: Call to private IntlBreakIterator::__construct() from global scope in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
size_t num_tmpstrings1 = 0, num_tmpstrings2 = 0;
if ((val = zend_hash_str_find(Z_ARRVAL_P(array), "oid", sizeof("oid") - 1)) == NULL) {
- php_error_docref(NULL, E_WARNING, "Control must have an oid key");
+ php_error_docref(NULL, E_WARNING, "Control must have an \"oid\" key");
return -1;
}
--EXPECTF--
bool(false)
-Warning: ldap_set_option(): Control must have an oid key in %s on line %d
+Warning: ldap_set_option(): Control must have an "oid" key in %s on line %d
bool(false)
Warning: ldap_set_option(): The array value must contain only arrays, where each array is a control in %s on line %d
Warning: DOMDocument::loadXML(): Entity 'file' not defined in Entity, line: 4 in %s on line %d
-Warning: Attempt to read property 'firstChild' on null in %s on line %d
+Warning: Attempt to read property "firstChild" on null in %s on line %d
-Warning: Attempt to read property 'nodeValue' on null in %s on line %d
+Warning: Attempt to read property "nodeValue" on null in %s on line %d
RETURN_TRUE;
}
/* Invalid string value */
- zend_argument_value_error(1, "must be 'none', 'long', 'entity' or a valid codepoint");
+ zend_argument_value_error(1, "must be \"none\", \"long\", \"entity\" or a valid codepoint");
RETURN_THROWS();
}
/* Integer codepoint passed */
bool(true)
string(6) "entity"
string(20) "262378323636303b82a0"
-mb_substitute_character(): Argument #1 ($substitute_character) must be 'none', 'long', 'entity' or a valid codepoint
+mb_substitute_character(): Argument #1 ($substitute_character) must be "none", "long", "entity" or a valid codepoint
string(4) "none"
bool(true)
string(4) "long"
-mb_substitute_character(): Argument #1 ($substitute_character) must be 'none', 'long', 'entity' or a valid codepoint
+mb_substitute_character(): Argument #1 ($substitute_character) must be "none", "long", "entity" or a valid codepoint
--uppercase FALSE--
TypeError: mb_substitute_character(): Argument #1 ($substitute_character) must be of type string|int|null, bool given
--empty string DQ--
-ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be 'none', 'long', 'entity' or a valid codepoint
+ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be "none", "long", "entity" or a valid codepoint
--empty string SQ--
-ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be 'none', 'long', 'entity' or a valid codepoint
+ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be "none", "long", "entity" or a valid codepoint
--string DQ--
-ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be 'none', 'long', 'entity' or a valid codepoint
+ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be "none", "long", "entity" or a valid codepoint
--string SQ--
-ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be 'none', 'long', 'entity' or a valid codepoint
+ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be "none", "long", "entity" or a valid codepoint
--mixed case string--
-ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be 'none', 'long', 'entity' or a valid codepoint
+ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be "none", "long", "entity" or a valid codepoint
--heredoc--
-ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be 'none', 'long', 'entity' or a valid codepoint
+ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be "none", "long", "entity" or a valid codepoint
--instance of classWithToString--
TypeError: mb_substitute_character(): Argument #1 ($substitute_character) must be of type string|int|null, classWithToString given
--instance of classWithoutToString--
--float -10.5--
ValueError: mb_substitute_character(): Argument #1 ($substitute_character) is not a valid codepoint
--float 10.0e19--
-ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be 'none', 'long', 'entity' or a valid codepoint
+ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be "none", "long", "entity" or a valid codepoint
--float -10.0e19--
-ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be 'none', 'long', 'entity' or a valid codepoint
+ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be "none", "long", "entity" or a valid codepoint
--float .5--
bool(true)
--empty array--
--uppercase FALSE--
bool(true)
--empty string DQ--
-ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be 'none', 'long', 'entity' or a valid codepoint
+ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be "none", "long", "entity" or a valid codepoint
--empty string SQ--
-ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be 'none', 'long', 'entity' or a valid codepoint
+ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be "none", "long", "entity" or a valid codepoint
--string DQ--
-ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be 'none', 'long', 'entity' or a valid codepoint
+ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be "none", "long", "entity" or a valid codepoint
--string SQ--
-ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be 'none', 'long', 'entity' or a valid codepoint
+ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be "none", "long", "entity" or a valid codepoint
--mixed case string--
-ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be 'none', 'long', 'entity' or a valid codepoint
+ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be "none", "long", "entity" or a valid codepoint
--heredoc--
-ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be 'none', 'long', 'entity' or a valid codepoint
+ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be "none", "long", "entity" or a valid codepoint
--instance of classWithToString--
-ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be 'none', 'long', 'entity' or a valid codepoint
+ValueError: mb_substitute_character(): Argument #1 ($substitute_character) must be "none", "long", "entity" or a valid codepoint
--instance of classWithoutToString--
TypeError: mb_substitute_character(): Argument #1 ($substitute_character) must be of type string|int|null, classWithoutToString given
--undefined var--
return;
}
if (UNEXPECTED(ce->ce_flags & (ZEND_ACC_INTERFACE|ZEND_ACC_TRAIT|ZEND_ACC_IMPLICIT_ABSTRACT_CLASS|ZEND_ACC_EXPLICIT_ABSTRACT_CLASS))) {
- zend_throw_error(NULL, "Class '%s' cannot be instantiated", ZSTR_VAL(ce->name));
+ zend_throw_error(NULL, "Class %s cannot be instantiated", ZSTR_VAL(ce->name));
RETURN_THROWS();
}
fetchtype = MYSQLI_ASSOC;
echo "Done\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Call to private DB::__construct() from invalid context in %s
+Fatal error: Uncaught Error: Call to private DB::__construct() from global scope in %s
Stack trace:
#0 {main}
thrown in %s
?>
==DONE==
--EXPECTF--
-Fatal error: Uncaught Error: Class 'test' cannot be instantiated in %sbug74968.php:%d
+Fatal error: Uncaught Error: Class test cannot be instantiated in %sbug74968.php:%d
Stack trace:
#0 %sbug74968.php(%d): mysqli_result->fetch_object('test')
#1 {main}
mysqli_result object is already closed
[0] mysqli_fetch_object(): Argument #3 ($params) must be of type array, string given in %s on line %d
-Fatal error: Class 'this_class_does_not_exist' not found in %s on line %d
+Fatal error: Class "this_class_does_not_exist" not found in %s on line %d
NULL
mysqli_result object is already closed
-Fatal error: Class 'this_class_does_not_exist' not found in %s on line %d
+Fatal error: Class "this_class_does_not_exist" not found in %s on line %d
if (UNEXPECTED(Z_TYPE_P(retval) == IS_INDIRECT)) {
retval = Z_INDIRECT_P(retval);
if (UNEXPECTED(Z_TYPE_P(retval) == IS_UNDEF)) {
- zend_error(E_NOTICE, "Undefined index: %s", ZSTR_VAL(offset_key));
+ zend_error(E_NOTICE, "Undefined array key \"%s\"", ZSTR_VAL(offset_key));
ZVAL_NULL(result);
return;
}
}
} else {
- zend_error(E_NOTICE, "Undefined index: %s", ZSTR_VAL(offset_key));
+ zend_error(E_NOTICE, "Undefined array key \"%s\"", ZSTR_VAL(offset_key));
ZVAL_NULL(result);
return;
}
return;
num_undef:
- zend_error(E_NOTICE,"Undefined offset: " ZEND_LONG_FMT, hval);
+ zend_error(E_NOTICE,"Undefined array key " ZEND_LONG_FMT, hval);
ZVAL_NULL(result);
}
if (IS_LONG == is_numeric_string(Z_STRVAL_P(dim), Z_STRLEN_P(dim), NULL, NULL, -1)) {
break;
}
- zend_error(E_WARNING, "Illegal string offset '%s'", Z_STRVAL_P(dim));
+ zend_error(E_WARNING, "Illegal string offset \"%s\"", Z_STRVAL_P(dim));
break;
case IS_UNDEF:
zend_jit_undefined_op_helper(EG(current_execute_data)->opline->op2.var);
}
if (UNEXPECTED(Z_STRLEN_P(container) < ((offset < 0) ? -(size_t)offset : ((size_t)offset + 1)))) {
- zend_error(E_WARNING, "Uninitialized string offset: " ZEND_LONG_FMT, offset);
+ zend_error(E_WARNING, "Uninitialized string offset " ZEND_LONG_FMT, offset);
ZVAL_EMPTY_STRING(result);
} else {
zend_uchar c;
static zval* ZEND_FASTCALL zend_jit_fetch_dimension_rw_long_helper(HashTable *ht, zend_long hval)
{
- zend_error(E_NOTICE,"Undefined offset: " ZEND_LONG_FMT, hval);
+ zend_error(E_NOTICE,"Undefined array key " ZEND_LONG_FMT, hval);
return zend_hash_index_update(ht, hval, &EG(uninitialized_zval));
}
break;
}
if (type != BP_VAR_UNSET) {
- zend_error(E_WARNING, "Illegal string offset '%s'", Z_STRVAL_P(dim));
+ zend_error(E_WARNING, "Illegal string offset \"%s\"", Z_STRVAL_P(dim));
}
break;
case IS_UNDEF:
offset = zend_check_string_offset(dim, BP_VAR_W);
if (offset < -(zend_long)Z_STRLEN_P(str)) {
/* Error on negative offset */
- zend_error(E_WARNING, "Illegal string offset: " ZEND_LONG_FMT, offset);
+ zend_error(E_WARNING, "Illegal string offset " ZEND_LONG_FMT, offset);
if (result) {
ZVAL_NULL(result);
}
static void ZEND_FASTCALL zend_jit_invalid_property_read(zval *container, const char *property_name)
{
- zend_error(E_WARNING, "Attempt to read property '%s' on %s", property_name, zend_zval_type_name(container));
+ zend_error(E_WARNING, "Attempt to read property \"%s\" on %s", property_name, zend_zval_type_name(container));
}
static void ZEND_FASTCALL zend_jit_invalid_property_write(zval *container, const char *property_name)
{
zend_throw_error(NULL,
- "Attempt to modify property '%s' on %s",
+ "Attempt to modify property \"%s\" on %s",
property_name, zend_zval_type_name(container));
}
if (!c) {
if (!check_defined_only) {
- zend_throw_error(NULL, "Undefined constant '%s'", Z_STRVAL_P(RT_CONSTANT(opline, opline->op2)));
+ zend_throw_error(NULL, "Undefined constant \"%s\"", Z_STRVAL_P(RT_CONSTANT(opline, opline->op2)));
ZVAL_UNDEF(EX_VAR(opline->result.var));
}
CACHE_PTR(opline->extended_value, ENCODE_SPECIAL_CACHE_NUM(zend_hash_num_elements(EG(zend_constants))));
|3:
|.if X64WIN
| mov CARG1, E_NOTICE
- | LOAD_ADDR CARG2, "Undefined offset: " ZEND_LONG_FMT
+ | LOAD_ADDR CARG2, "Undefined array key " ZEND_LONG_FMT
| mov CARG3, aword [r0]
| EXT_CALL zend_error, r0
| add r4, 0x28 // stack alignment
|.elif X64
| mov CARG1, E_NOTICE
- | LOAD_ADDR CARG2, "Undefined offset: " ZEND_LONG_FMT
+ | LOAD_ADDR CARG2, "Undefined array key " ZEND_LONG_FMT
| mov CARG3, aword [r0]
| EXT_CALL zend_error, r0
| add r4, 8 // stack alignment
|.else
| sub r4, 4
| push aword [r0]
- | push "Undefined offset: " ZEND_LONG_FMT
+ | push "Undefined array key " ZEND_LONG_FMT
| push E_NOTICE
| EXT_CALL zend_error, r0
| add r4, 28
|3:
|.if X64WIN
| mov CARG1, E_NOTICE
- | LOAD_ADDR CARG2, "Undefined index: %s"
+ | LOAD_ADDR CARG2, "Undefined array key \"%s\""
| mov CARG3, aword [r0]
| add CARG3, offsetof(zend_string, val)
| EXT_CALL zend_error, r0
| add r4, 0x28
|.elif X64
| mov CARG1, E_NOTICE
- | LOAD_ADDR CARG2, "Undefined index: %s"
+ | LOAD_ADDR CARG2, "Undefined array key \"%s\""
| mov CARG3, aword [r0]
| add CARG3, offsetof(zend_string, val)
| EXT_CALL zend_error, r0
| mov r0, aword [r0]
| add r0, offsetof(zend_string, val)
| push r0
- | push "Undefined index: %s"
+ | push "Undefined array key \"%s\""
| push E_NOTICE
| EXT_CALL zend_error, r0
| add r4, 28
switch (type) {
case BP_VAR_R:
if (JIT_G(trigger) != ZEND_JIT_ON_HOT_TRACE) {
- | // zend_error(E_NOTICE,"Undefined offset: " ZEND_LONG_FMT, hval);
+ | // zend_error(E_NOTICE,"Undefined array key " ZEND_LONG_FMT, hval);
| // retval = &EG(uninitialized_zval);
| UNDEFINED_OFFSET opline
| jmp >9
|2:
if (JIT_G(trigger) != ZEND_JIT_ON_HOT_TRACE) {
| SAVE_VALID_OPLINE opline, r0
- | // zend_error(E_NOTICE,"Undefined offset: " ZEND_LONG_FMT, hval);
+ | // zend_error(E_NOTICE,"Undefined arary offset " ZEND_LONG_FMT, hval);
| //retval = zend_hash_index_update(ht, hval, &EG(uninitialized_zval));
| EXT_CALL zend_jit_fetch_dimension_rw_long_helper, r0
}
switch (type) {
case BP_VAR_R:
if (JIT_G(trigger) != ZEND_JIT_ON_HOT_TRACE) {
- // zend_error(E_NOTICE, "Undefined index: %s", ZSTR_VAL(offset_key));
+ // zend_error(E_NOTICE, "Undefined array key \"%s\"", ZSTR_VAL(offset_key));
| UNDEFINED_INDEX opline
| jmp >9
} else {
?>
--EXPECTF--
-Notice: Undefined offset: 0 in %s on line %d
-Attempt to assign property 'y' on null
+Notice: Undefined array key 0 in %s on line %d
+Attempt to assign property "y" on null
function getA() {return A;}
?>
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'A' in %s:%d
+Fatal error: Uncaught Error: Undefined constant "A" in %s:%d
Stack trace:
#0 %s(%d): getA()
#1 {main}
Warning: Can't preload class B with unresolved initializer for constant X in %s on line %d
-Fatal error: Uncaught Error: Class 'C' not found in %sbug78014.php:5
+Fatal error: Uncaught Error: Class "C" not found in %sbug78014.php:5
Stack trace:
#0 {main}
thrown in %sbug78014.php on line 5
Warning: Can't preload unlinked class Bar@anonymous: Unknown parent Bar in %spreload_bug78937.inc on line 3
-Fatal error: Uncaught Error: Class 'Bar' not found in %spreload_bug78937.inc:3
+Fatal error: Uncaught Error: Class "Bar" not found in %spreload_bug78937.inc:3
Stack trace:
#0 %sbug78937_3.php(3): foo()
#1 {main}
Warning: Can't preload unlinked class Bar@anonymous: Unknown parent Bar in %spreload_bug78937.inc on line 3
-Fatal error: Uncaught Error: Class 'Bar' not found in %spreload_bug78937.inc:6
+Fatal error: Uncaught Error: Class "Bar" not found in %spreload_bug78937.inc:6
Stack trace:
#0 %sbug78937_6.php(3): bar()
#1 {main}
Cannot instantiate abstract class Foo
Cannot instantiate interface Bar
Cannot instantiate trait Baz
-Cannot declare self-referencing constant 'Abc::BAR'
+Cannot declare self-referencing constant Abc::BAR
Warning: String offset cast occurred in %s on line %d
string(1) "A"
-Warning: Illegal string offset 'ab' in %sfetch_dim_r_003.php on line 12
+Warning: Illegal string offset "ab" in %sfetch_dim_r_003.php on line 12
string(1) "A"
-Warning: Illegal string offset 'ab' in %sfetch_dim_r_003.php on line 15
+Warning: Illegal string offset "ab" in %sfetch_dim_r_003.php on line 15
string(1) "A"
Notice: A non well formed numeric value encountered in %sfetch_dim_r_003.php on line 16
Warning: String offset cast occurred in %s on line %d
string(1) "A"
-Warning: Illegal string offset 'ab' in %sfetch_dim_r_004.php on line 4
+Warning: Illegal string offset "ab" in %sfetch_dim_r_004.php on line 4
string(1) "A"
-Warning: Illegal string offset 'ab' in %sfetch_dim_r_004.php on line 4
+Warning: Illegal string offset "ab" in %sfetch_dim_r_004.php on line 4
string(1) "A"
Notice: A non well formed numeric value encountered in %sfetch_dim_r_004.php on line 4
--EXPECTF--
Warning: Undefined variable $a in %s on line %d
-Notice: Undefined offset: 0 in %sfetch_dim_rw_001.php on line 3
+Notice: Undefined array key 0 in %sfetch_dim_rw_001.php on line 3
-Notice: Undefined offset: 0 in %sfetch_dim_rw_001.php on line 3
+Notice: Undefined array key 0 in %sfetch_dim_rw_001.php on line 3
array(1) {
[0]=>
int(2)
array(0) {
}
}
-Attempt to modify property 'abc' on array
+Attempt to modify property "abc" on array
array(0) {
}
-Attempt to modify property 'abc' on null
+Attempt to modify property "abc" on null
NULL
-Attempt to modify property 'abc' on string
+Attempt to modify property "abc" on string
string(0) ""
?>
OK
--EXPECT--
-Exception: Undefined constant 'UNDEFINED_CONST'
-OK
\ No newline at end of file
+Exception: Undefined constant "UNDEFINED_CONST"
+OK
var_dump(class_exists('Foo'));
?>
--EXPECT--
-Fatal error: Undefined class constant 'self::DOES_NOT_EXIST' in Unknown on line 0
+Fatal error: Undefined constant self::DOES_NOT_EXIST in Unknown on line 0
Fatal error: Failed to resolve initializers of class Foo during preloading in Unknown on line 0
var_dump(class_exists('Foo'));
?>
--EXPECT--
-Fatal error: Undefined constant 'UNDEF' in Unknown on line 0
+Fatal error: Undefined constant "UNDEF" in Unknown on line 0
Fatal error: Failed to resolve initializers of class Foo during preloading in Unknown on line 0
--FILE--
Unreachable
--EXPECT--
-Fatal error: Undefined constant 'UNDEF' in Unknown on line 0
+Fatal error: Undefined constant "UNDEF" in Unknown on line 0
Fatal error: Failed to resolve initializers of class Test during preloading in Unknown on line 0
this is a private method.
foo
-Fatal error: Uncaught Error: Call to protected method test::isProtected() from context '' in %s:%d
+Fatal error: Uncaught Error: Call to protected method test::isProtected() from global scope in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
string(19) "SELECT id FROM test"
----------------------------------
-Warning: Attempt to read property 'queryString' on bool in %s on line %d
+Warning: Attempt to read property "queryString" on bool in %s on line %d
NULL
string(0) ""
}
-Warning: PDOStatement::fetchAll(): SQLSTATE[HY000]: General error: function 'nothing' not found or invalid function name in %s on line %d
+Warning: PDOStatement::fetchAll(): SQLSTATE[HY000]: General error: function "nothing" not found or invalid function name in %s on line %d
Warning: PDOStatement::fetchAll(): SQLSTATE[HY000]: General error in %s on line %d
bool(false)
-Warning: PDOStatement::fetchAll(): SQLSTATE[HY000]: General error: function '' not found or invalid function name in %s on line %d
+Warning: PDOStatement::fetchAll(): SQLSTATE[HY000]: General error: function "" not found or invalid function name in %s on line %d
Warning: PDOStatement::fetchAll(): SQLSTATE[HY000]: General error in %s on line %d
bool(false)
Warning: PDOStatement::fetchAll(): SQLSTATE[HY000]: General error in %s on line %d
bool(false)
-Warning: PDOStatement::fetchAll(): SQLSTATE[HY000]: General error: class 'PDOStatement' does not have a method 'foo' in %s on line %d
+Warning: PDOStatement::fetchAll(): SQLSTATE[HY000]: General error: class PDOStatement does not have a method "foo" in %s on line %d
Warning: PDOStatement::fetchAll(): SQLSTATE[HY000]: General error in %s on line %d
bool(false)
Warning: PDOStatement::fetchAll(): SQLSTATE[HY000]: General error in %s on line %d
bool(false)
-Warning: PDOStatement::fetchAll(): SQLSTATE[HY000]: General error: class 'bar' does not have a method 'inexistent' in %s on line %d
+Warning: PDOStatement::fetchAll(): SQLSTATE[HY000]: General error: class bar does not have a method "inexistent" in %s on line %d
Warning: PDOStatement::fetchAll(): SQLSTATE[HY000]: General error in %s on line %d
bool(false)
__halt_compiler();
?>
--EXPECTF--
-SplFileInfo::setFileClass(): Argument #1 ($class_name) must be a class name derived from SplFileObject, 'SplFileInfo' given
+SplFileInfo::setFileClass(): Argument #1 ($class_name) must be a class name derived from SplFileObject, SplFileInfo given
MyFile::__construct(phar://%s/a.php)
a.php
MyFile::__construct(phar://%s/b/c.php)
xx
xxx
-Warning: Uncaught Error: Undefined constant 'FOO' in php shell code:1
+Warning: Uncaught Error: Undefined constant "FOO" in php shell code:1
Stack trace:
#0 {main}
thrown in php shell code on line 1
php > FOO
php > ;
-Warning: Uncaught Error: Undefined constant 'FOO' in php shell code:1
+Warning: Uncaught Error: Undefined constant "FOO" in php shell code:1
Stack trace:
#0 {main}
thrown in php shell code on line 1
if (name && (flags & REFLECTION_ATTRIBUTE_IS_INSTANCEOF)) {
if (NULL == (base = zend_lookup_class(name))) {
if (!EG(exception)) {
- zend_throw_error(NULL, "Class '%s' not found", ZSTR_VAL(name));
+ zend_throw_error(NULL, "Class \"%s\" not found", ZSTR_VAL(name));
}
RETURN_THROWS();
}
if ((ce = zend_lookup_class(name)) == NULL) {
zend_throw_exception_ex(reflection_exception_ptr, 0,
- "Class %s does not exist", ZSTR_VAL(name));
+ "Class \"%s\" does not exist", ZSTR_VAL(name));
zend_string_release(name);
RETURN_THROWS();
}
ce = param->fptr->common.scope;
if (!ce) {
zend_throw_exception_ex(reflection_exception_ptr, 0,
- "Parameter uses 'self' as type hint but function is not a class member!");
+ "Parameter uses \"self\" as type but function is not a class member");
RETURN_THROWS();
}
} else if (0 == zend_binary_strcasecmp(ZSTR_VAL(class_name), ZSTR_LEN(class_name), "parent", sizeof("parent")- 1)) {
ce = param->fptr->common.scope;
if (!ce) {
zend_throw_exception_ex(reflection_exception_ptr, 0,
- "Parameter uses 'parent' as type hint but function is not a class member!");
+ "Parameter uses \"parent\" as type but function is not a class member");
RETURN_THROWS();
}
if (!ce->parent) {
zend_throw_exception_ex(reflection_exception_ptr, 0,
- "Parameter uses 'parent' as type hint although class does not have a parent!");
+ "Parameter uses \"parent\" as type although class does not have a parent");
RETURN_THROWS();
}
ce = ce->parent;
ce = zend_lookup_class(class_name);
if (!ce) {
zend_throw_exception_ex(reflection_exception_ptr, 0,
- "Class %s does not exist", ZSTR_VAL(class_name));
+ "Class \"%s\" does not exist", ZSTR_VAL(class_name));
RETURN_THROWS();
}
}
if ((ce = zend_lookup_class(Z_STR_P(classname))) == NULL) {
if (!EG(exception)) {
zend_throw_exception_ex(reflection_exception_ptr, 0,
- "Class %s does not exist", Z_STRVAL_P(classname));
+ "Class \"%s\" does not exist", Z_STRVAL_P(classname));
}
if (classname == &ztmp) {
zval_ptr_dtor_str(&ztmp);
case IS_STRING:
if ((ce = zend_lookup_class(Z_STR_P(classname))) == NULL) {
zend_throw_exception_ex(reflection_exception_ptr, 0,
- "Class %s does not exist", Z_STRVAL_P(classname));
+ "Class \"%s\" does not exist", Z_STRVAL_P(classname));
RETURN_THROWS();
}
break;
}
if ((constant = zend_hash_find_ptr(&ce->constants_table, constname)) == NULL) {
- zend_throw_exception_ex(reflection_exception_ptr, 0, "Class Constant %s::%s does not exist", ZSTR_VAL(ce->name), ZSTR_VAL(constname));
+ zend_throw_exception_ex(reflection_exception_ptr, 0, "Constant %s::%s does not exist", ZSTR_VAL(ce->name), ZSTR_VAL(constname));
RETURN_THROWS();
}
if ((ce = zend_lookup_class(Z_STR_P(argument))) == NULL) {
if (!EG(exception)) {
- zend_throw_exception_ex(reflection_exception_ptr, -1, "Class %s does not exist", Z_STRVAL_P(argument));
+ zend_throw_exception_ex(reflection_exception_ptr, -1, "Class \"%s\" does not exist", Z_STRVAL_P(argument));
}
RETURN_THROWS();
}
ZVAL_COPY(return_value, def_value);
} else {
zend_throw_exception_ex(reflection_exception_ptr, 0,
- "Class %s does not have a property named %s", ZSTR_VAL(ce->name), ZSTR_VAL(name));
+ "Property %s::$%s does not exist", ZSTR_VAL(ce->name), ZSTR_VAL(name));
}
return;
} else {
reflection_method_factory(ce, mptr, NULL, return_value);
} else {
zend_throw_exception_ex(reflection_exception_ptr, 0,
- "Method %s does not exist", ZSTR_VAL(name));
+ "Method %s::%s() does not exist", ZSTR_VAL(ce->name), ZSTR_VAL(name));
}
zend_string_release(lc_name);
}
ce2 = zend_lookup_class(classname);
if (!ce2) {
if (!EG(exception)) {
- zend_throw_exception_ex(reflection_exception_ptr, -1, "Class %s does not exist", ZSTR_VAL(classname));
+ zend_throw_exception_ex(reflection_exception_ptr, -1, "Class \"%s\" does not exist", ZSTR_VAL(classname));
}
zend_string_release_ex(classname, 0);
RETURN_THROWS();
zend_string_release_ex(classname, 0);
if (!instanceof_function(ce, ce2)) {
- zend_throw_exception_ex(reflection_exception_ptr, -1, "Fully qualified property name %s::%s does not specify a base class of %s", ZSTR_VAL(ce2->name), str_name, ZSTR_VAL(ce->name));
+ zend_throw_exception_ex(reflection_exception_ptr, -1, "Fully qualified property name %s::$%s does not specify a base class of %s", ZSTR_VAL(ce2->name), str_name, ZSTR_VAL(ce->name));
RETURN_THROWS();
}
ce = ce2;
return;
}
}
- zend_throw_exception_ex(reflection_exception_ptr, 0,
- "Property %s does not exist", str_name);
+ zend_throw_exception_ex(reflection_exception_ptr, 0, "Property %s::$%s does not exist", ZSTR_VAL(ce->name), str_name);
}
/* }}} */
case IS_STRING:
if ((class_ce = zend_lookup_class(Z_STR_P(class_name))) == NULL) {
zend_throw_exception_ex(reflection_exception_ptr, 0,
- "Class %s does not exist", Z_STRVAL_P(class_name));
+ "Class \"%s\" does not exist", Z_STRVAL_P(class_name));
RETURN_THROWS();
}
break;
case IS_STRING:
if ((interface_ce = zend_lookup_class(Z_STR_P(interface))) == NULL) {
zend_throw_exception_ex(reflection_exception_ptr, 0,
- "Interface %s does not exist", Z_STRVAL_P(interface));
+ "Interface \"%s\" does not exist", Z_STRVAL_P(interface));
RETURN_THROWS();
}
break;
case IS_STRING:
if ((ce = zend_lookup_class(Z_STR_P(classname))) == NULL) {
zend_throw_exception_ex(reflection_exception_ptr, 0,
- "Class %s does not exist", Z_STRVAL_P(classname));
+ "Class \"%s\" does not exist", Z_STRVAL_P(classname));
RETURN_THROWS();
}
break;
if (!(prop_get_flags(ref) & ZEND_ACC_PUBLIC) && intern->ignore_visibility == 0) {
zend_throw_exception_ex(reflection_exception_ptr, 0,
- "Cannot access non-public member %s::$%s",
+ "Cannot access non-public property %s::$%s",
ZSTR_VAL(intern->ce->name), ZSTR_VAL(ref->unmangled_name));
RETURN_THROWS();
}
if (!(prop_get_flags(ref) & ZEND_ACC_PUBLIC) && intern->ignore_visibility == 0) {
zend_throw_exception_ex(reflection_exception_ptr, 0,
- "Cannot access non-public member %s::$%s",
+ "Cannot access non-public property %s::$%s",
ZSTR_VAL(intern->ce->name), ZSTR_VAL(ref->unmangled_name));
RETURN_THROWS();
}
if (!(prop_get_flags(ref) & ZEND_ACC_PUBLIC) && intern->ignore_visibility == 0) {
zend_throw_exception_ex(reflection_exception_ptr, 0,
- "Cannot access non-public member %s::$%s",
+ "Cannot access non-public property %s::$%s",
ZSTR_VAL(intern->ce->name), ZSTR_VAL(ref->unmangled_name));
RETURN_THROWS();
}
if ((module = zend_hash_str_find_ptr(&module_registry, lcname, name_len)) == NULL) {
free_alloca(lcname, use_heap);
zend_throw_exception_ex(reflection_exception_ptr, 0,
- "Extension %s does not exist", name_str);
+ "Extension \"%s\" does not exist", name_str);
RETURN_THROWS();
}
free_alloca(lcname, use_heap);
extension = zend_get_extension(name_str);
if (!extension) {
zend_throw_exception_ex(reflection_exception_ptr, 0,
- "Zend Extension %s does not exist", name_str);
+ "Zend Extension \"%s\" does not exist", name_str);
RETURN_THROWS();
}
ZVAL_STRING(reflection_prop_name(object), extension->name);
ZEND_ASSERT(ctor != NULL);
if (!(ctor->common.fn_flags & ZEND_ACC_PUBLIC)) {
- zend_throw_error(NULL, "Attribute constructor of class '%s' must be public", ZSTR_VAL(ce->name));
+ zend_throw_error(NULL, "Attribute constructor of class %s must be public", ZSTR_VAL(ce->name));
return FAILURE;
}
GET_REFLECTION_OBJECT_PTR(attr);
if (NULL == (ce = zend_lookup_class(attr->data->name))) {
- zend_throw_error(NULL, "Attribute class '%s' not found", ZSTR_VAL(attr->data->name));
+ zend_throw_error(NULL, "Attribute class \"%s\" not found", ZSTR_VAL(attr->data->name));
RETURN_THROWS();
}
if (NULL == (marker = zend_get_attribute_str(ce->attributes, ZEND_STRL("attribute")))) {
- zend_throw_error(NULL, "Attempting to use non-attribute class '%s' as attribute", ZSTR_VAL(attr->data->name));
+ zend_throw_error(NULL, "Attempting to use non-attribute class \"%s\" as attribute", ZSTR_VAL(attr->data->name));
RETURN_THROWS();
}
}
} else if (argc) {
attribute_ctor_cleanup(&obj, args, argc);
- zend_throw_error(NULL, "Attribute class '%s' does not have a constructor, cannot pass arguments", ZSTR_VAL(ce->name));
+ zend_throw_error(NULL, "Attribute class %s does not have a constructor, cannot pass arguments", ZSTR_VAL(ce->name));
RETURN_THROWS();
}
--EXPECTF--
====>Class_does_not_exist
{closure}(Class_does_not_exist)
-string(41) "Class Class_does_not_exist does not exist"
+string(43) "Class "Class_does_not_exist" does not exist"
====>NoCtor
====>newInstance()
object(NoCtor)#%d (0) {
}
object(WithCtorWithArgs)#%d (0) {
}
-
--EXPECT--
string(91) "ReflectionMethod::__construct(): Argument #1 ($class_or_method) must be a valid method name"
string(91) "ReflectionMethod::__construct(): Argument #1 ($class_or_method) must be a valid method name"
-string(21) "Class does not exist"
-string(22) "Class a does not exist"
-string(21) "Class does not exist"
-string(22) "Class a does not exist"
-string(21) "Class does not exist"
+string(23) "Class "" does not exist"
+string(24) "Class "a" does not exist"
+string(23) "Class "" does not exist"
+string(24) "Class "a" does not exist"
+string(23) "Class "" does not exist"
string(104) "ReflectionMethod::__construct(): Argument #1 ($class_or_method) must be of type object|string, int given"
-string(21) "Class does not exist"
+string(23) "Class "" does not exist"
Done
**********************************
-Fatal error: Uncaught ReflectionException: Class Constant TestClass::BAD_CONST does not exist in %s:%d
+Fatal error: Uncaught ReflectionException: Constant TestClass::BAD_CONST does not exist in %s:%d
Stack trace:
#0 %s(%d): ReflectionClassConstant->__construct(Object(TestClass), 'BAD_CONST')
#1 %s(%d): reflectClassConstant(Object(TestClass), 'BAD_CONST')
?>
--EXPECTF--
ReflectionClass::__construct() expects exactly 1 parameter, 0 given
-Class does not exist
-Class 1 does not exist
-Class 1 does not exist
+Class "" does not exist
+Class "1" does not exist
+Class "1" does not exist
Warning: Array to string conversion in %s on line %d
-Class Array does not exist
+Class "Array" does not exist
ReflectionClass::__construct() expects exactly 1 parameter, 2 given
-Class X does not exist
+Class "X" does not exist
["class"]=>
string(4) "pubf"
}
- --> Check for doesNotExist(): Method doesNotExist does not exist
+ --> Check for doesNotExist(): Method pubf::doesNotExist() does not exist
Reflecting on class subpubf:
--> Check for f(): object(ReflectionMethod)#%d (2) {
["name"]=>
["class"]=>
string(4) "pubf"
}
- --> Check for doesNotExist(): Method doesNotExist does not exist
+ --> Check for doesNotExist(): Method subpubf::doesNotExist() does not exist
Reflecting on class protf:
--> Check for f(): object(ReflectionMethod)#%d (2) {
["name"]=>
["class"]=>
string(5) "protf"
}
- --> Check for doesNotExist(): Method doesNotExist does not exist
+ --> Check for doesNotExist(): Method protf::doesNotExist() does not exist
Reflecting on class subprotf:
--> Check for f(): object(ReflectionMethod)#%d (2) {
["name"]=>
["class"]=>
string(5) "protf"
}
- --> Check for doesNotExist(): Method doesNotExist does not exist
+ --> Check for doesNotExist(): Method subprotf::doesNotExist() does not exist
Reflecting on class privf:
--> Check for f(): object(ReflectionMethod)#%d (2) {
["name"]=>
["class"]=>
string(5) "privf"
}
- --> Check for doesNotExist(): Method doesNotExist does not exist
+ --> Check for doesNotExist(): Method privf::doesNotExist() does not exist
Reflecting on class subprivf:
--> Check for f(): object(ReflectionMethod)#%d (2) {
["name"]=>
["class"]=>
string(5) "privf"
}
- --> Check for doesNotExist(): Method doesNotExist does not exist
+ --> Check for doesNotExist(): Method subprivf::doesNotExist() does not exist
Check invalid params:
ReflectionClass::getMethod() expects exactly 1 parameter, 0 given
ReflectionClass::getMethod() expects exactly 1 parameter, 2 given
-Method does not exist
-Method 1 does not exist
-Method 1.5 does not exist
-Method 1 does not exist
+Method C::() does not exist
+Method C::1() does not exist
+Method C::1.5() does not exist
+Method C::1() does not exist
ReflectionClass::getMethod(): Argument #1 ($name) must be of type string, array given
ReflectionClass::getMethod(): Argument #1 ($name) must be of type string, C given
["class"]=>
string(4) "pubf"
}
- --> Check for A: Property A does not exist
- --> Check for doesNotExist: Property doesNotExist does not exist
+ --> Check for A: Property pubf::$A does not exist
+ --> Check for doesNotExist: Property pubf::$doesNotExist does not exist
Reflecting on class subpubf:
--> Check for s: object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(4) "pubf"
}
- --> Check for A: Property A does not exist
- --> Check for doesNotExist: Property doesNotExist does not exist
+ --> Check for A: Property subpubf::$A does not exist
+ --> Check for doesNotExist: Property subpubf::$doesNotExist does not exist
Reflecting on class protf:
--> Check for s: object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(5) "protf"
}
- --> Check for A: Property A does not exist
- --> Check for doesNotExist: Property doesNotExist does not exist
+ --> Check for A: Property protf::$A does not exist
+ --> Check for doesNotExist: Property protf::$doesNotExist does not exist
Reflecting on class subprotf:
--> Check for s: object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(5) "protf"
}
- --> Check for A: Property A does not exist
- --> Check for doesNotExist: Property doesNotExist does not exist
+ --> Check for A: Property subprotf::$A does not exist
+ --> Check for doesNotExist: Property subprotf::$doesNotExist does not exist
Reflecting on class privf:
--> Check for s: object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(5) "privf"
}
- --> Check for A: Property A does not exist
- --> Check for doesNotExist: Property doesNotExist does not exist
+ --> Check for A: Property privf::$A does not exist
+ --> Check for doesNotExist: Property privf::$doesNotExist does not exist
Reflecting on class subprivf:
--> Check for s: object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(5) "privf"
}
- --> Check for a: Property a does not exist
- --> Check for A: Property A does not exist
- --> Check for doesNotExist: Property doesNotExist does not exist
+ --> Check for a: Property subprivf::$a does not exist
+ --> Check for A: Property subprivf::$A does not exist
+ --> Check for doesNotExist: Property subprivf::$doesNotExist does not exist
Check invalid params:
ReflectionClass::getProperty() expects exactly 1 parameter, 0 given
ReflectionClass::getProperty() expects exactly 1 parameter, 2 given
-Property does not exist
-Property 1 does not exist
-Property 1.5 does not exist
-Property 1 does not exist
+Property C::$ does not exist
+Property C::$1 does not exist
+Property C::$1.5 does not exist
+Property C::$1 does not exist
ReflectionClass::getProperty(): Argument #1 ($name) must be of type string, array given
ReflectionClass::getProperty(): Argument #1 ($name) must be of type string, C given
["class"]=>
string(1) "A"
}
-Cannot access non-public member C::$protA
+Cannot access non-public property C::$protA
--- (Reflecting on privA) ---
-Property privA does not exist
+Property C::$privA does not exist
--- (Reflecting on pubB) ---
object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(1) "B"
}
-Cannot access non-public member C::$protB
+Cannot access non-public property C::$protB
--- (Reflecting on privB) ---
-Property privB does not exist
+Property C::$privB does not exist
--- (Reflecting on pubC) ---
object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(1) "C"
}
-Cannot access non-public member C::$protC
+Cannot access non-public property C::$protC
--- (Reflecting on privC) ---
object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(1) "C"
}
-Cannot access non-public member C::$privC
+Cannot access non-public property C::$privC
--- (Reflecting on doesNotExist) ---
-Property doesNotExist does not exist
+Property C::$doesNotExist does not exist
--- (Reflecting on A::pubC) ---
object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(1) "A"
}
-Cannot access non-public member A::$protC
+Cannot access non-public property A::$protC
--- (Reflecting on A::privC) ---
object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(1) "A"
}
-Cannot access non-public member A::$privC
+Cannot access non-public property A::$privC
--- (Reflecting on B::pubC) ---
object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(1) "B"
}
-Cannot access non-public member B::$protC
+Cannot access non-public property B::$protC
--- (Reflecting on B::privC) ---
object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(1) "B"
}
-Cannot access non-public member B::$privC
+Cannot access non-public property B::$privC
--- (Reflecting on c::pubC) ---
object(ReflectionProperty)#%d (2) {
["name"]=>
}
string(9) "pubC in C"
--- (Reflecting on c::PUBC) ---
-Property PUBC does not exist
+Property C::$PUBC does not exist
--- (Reflecting on C::pubC) ---
object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(1) "C"
}
-Cannot access non-public member C::$protC
+Cannot access non-public property C::$protC
--- (Reflecting on C::privC) ---
object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(1) "C"
}
-Cannot access non-public member C::$privC
+Cannot access non-public property C::$privC
--- (Reflecting on X::pubC) ---
-Fully qualified property name X::pubC does not specify a base class of C
+Fully qualified property name X::$pubC does not specify a base class of C
--- (Reflecting on X::protC) ---
-Fully qualified property name X::protC does not specify a base class of C
+Fully qualified property name X::$protC does not specify a base class of C
--- (Reflecting on X::privC) ---
-Fully qualified property name X::privC does not specify a base class of C
+Fully qualified property name X::$privC does not specify a base class of C
--- (Reflecting on X::doesNotExist) ---
-Fully qualified property name X::doesNotExist does not specify a base class of C
+Fully qualified property name X::$doesNotExist does not specify a base class of C
--- (Reflecting on doesNotexist::doesNotExist) ---
-Class doesnotexist does not exist
+Class "doesnotexist" does not exist
["class"]=>
string(1) "A"
}
-Cannot access non-public member C::$protA
+Cannot access non-public property C::$protA
--- (Reflecting on privA) ---
-Property privA does not exist
+Property C::$privA does not exist
--- (Reflecting on pubB) ---
object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(1) "B"
}
-Cannot access non-public member C::$protB
+Cannot access non-public property C::$protB
--- (Reflecting on privB) ---
-Property privB does not exist
+Property C::$privB does not exist
--- (Reflecting on pubC) ---
object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(1) "C"
}
-Cannot access non-public member C::$protC
+Cannot access non-public property C::$protC
--- (Reflecting on privC) ---
object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(1) "C"
}
-Cannot access non-public member C::$privC
+Cannot access non-public property C::$privC
--- (Reflecting on doesNotExist) ---
-Property doesNotExist does not exist
+Property C::$doesNotExist does not exist
--- (Reflecting on A::pubC) ---
object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(1) "A"
}
-Cannot access non-public member A::$protC
+Cannot access non-public property A::$protC
--- (Reflecting on A::privC) ---
object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(1) "A"
}
-Cannot access non-public member A::$privC
+Cannot access non-public property A::$privC
--- (Reflecting on B::pubC) ---
object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(1) "B"
}
-Cannot access non-public member B::$protC
+Cannot access non-public property B::$protC
--- (Reflecting on B::privC) ---
object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(1) "B"
}
-Cannot access non-public member B::$privC
+Cannot access non-public property B::$privC
--- (Reflecting on c::pubC) ---
object(ReflectionProperty)#%d (2) {
["name"]=>
}
string(9) "pubC in C"
--- (Reflecting on c::PUBC) ---
-Property PUBC does not exist
+Property C::$PUBC does not exist
--- (Reflecting on C::pubC) ---
object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(1) "C"
}
-Cannot access non-public member C::$protC
+Cannot access non-public property C::$protC
--- (Reflecting on C::privC) ---
object(ReflectionProperty)#%d (2) {
["name"]=>
["class"]=>
string(1) "C"
}
-Cannot access non-public member C::$privC
+Cannot access non-public property C::$privC
--- (Reflecting on X::pubC) ---
-Fully qualified property name X::pubC does not specify a base class of C
+Fully qualified property name X::$pubC does not specify a base class of C
--- (Reflecting on X::protC) ---
-Fully qualified property name X::protC does not specify a base class of C
+Fully qualified property name X::$protC does not specify a base class of C
--- (Reflecting on X::privC) ---
-Fully qualified property name X::privC does not specify a base class of C
+Fully qualified property name X::$privC does not specify a base class of C
--- (Reflecting on X::doesNotExist) ---
-Fully qualified property name X::doesNotExist does not specify a base class of C
+Fully qualified property name X::$doesNotExist does not specify a base class of C
--- (Reflecting on doesNotexist::doesNotExist) ---
-Class doesnotexist does not exist
+Class "doesnotexist" does not exist
string(14) "changed public"
Retrieving non-existent values from A with no default value:
-Class A does not have a property named protectedDoesNotExist
-Class A does not have a property named privateDoesNotExist
+Property A::$protectedDoesNotExist does not exist
+Property A::$privateDoesNotExist does not exist
--EXPECT--
ReflectionClass::getStaticPropertyValue() expects at most 2 parameters, 3 given
ReflectionClass::getStaticPropertyValue() expects at least 1 parameter, 0 given
-Class C does not have a property named
+Property C::$ does not exist
string(3) "def"
ReflectionClass::getStaticPropertyValue(): Argument #1 ($name) must be of type string, array given
ReflectionClass::implementsInterface() expects exactly 1 parameter, 0 given
ReflectionClass::implementsInterface() expects exactly 1 parameter, 2 given
ReflectionClass::implementsInterface(): Argument #1 ($interface) must be of type ReflectionClass|string, null given
-Interface ThisClassDoesNotExist does not exist
+Interface "ThisClassDoesNotExist" does not exist
ReflectionClass::implementsInterface(): Argument #1 ($interface) must be of type ReflectionClass|string, int given
ReflectionClass::isSubclassOf() expects exactly 1 parameter, 0 given
ReflectionClass::isSubclassOf() expects exactly 1 parameter, 2 given
ReflectionClass::isSubclassOf(): Argument #1 ($class) must be of type ReflectionClass|string, null given
-Class ThisClassDoesNotExist does not exist
+Class "ThisClassDoesNotExist" does not exist
ReflectionClass::isSubclassOf(): Argument #1 ($class) must be of type ReflectionClass|string, int given
?>
--EXPECTF--
-Fatal error: Uncaught ReflectionException: Class X does not exist in %s:5
+Fatal error: Uncaught ReflectionException: Class "X" does not exist in %s:%d
Stack trace:
#0 %s(5): ReflectionClass->isSubclassOf('X')
#1 {main}
#0 %s ReflectionMethod->__construct(true, 'foo')
#1 {main}
Wrong type of argument (string, bool):
-ReflectionException: Method TestClass::1() does not exist in %s
+ReflectionException: Method TestClass::1() does not exist in %s:%d
Stack trace:
#0 %s ReflectionMethod->__construct('TestClass', '1')
#1 {main}
#0 %s ReflectionMethod->__construct('TestClass')
#1 {main}
Class and Method in same string, bad method name:
-ReflectionException: Method TestClass::foop::dedoop() does not exist in %s
+ReflectionException: Method TestClass::foop::dedoop() does not exist in %s:%d
Stack trace:
#0 %s ReflectionMethod->__construct('TestClass::foop...')
#1 {main}
Class and Method in same string, bad class name:
-ReflectionException: Class TestCla does not exist in %s
+ReflectionException: Class "TestCla" does not exist in %s:%d
Stack trace:
#0 %s ReflectionMethod->__construct('TestCla::foo')
#1 {main}
Too many arguments:
Ok - ReflectionMethod::__construct() expects exactly 1 parameter, 3 given
-Ok - Class InvalidClassName does not exist
+Ok - Class "InvalidClassName" does not exist
Ok - ReflectionMethod::__construct(): Argument #1 ($class_or_method) must be of type object|string, array given
Ok - ReflectionMethod::__construct() expects exactly 1 parameter, 2 given
ReflectionClass::isSubclassOf() expects exactly 1 parameter, 0 given
ReflectionClass::isSubclassOf() expects exactly 1 parameter, 2 given
ReflectionClass::isSubclassOf(): Argument #1 ($class) must be of type ReflectionClass|string, null given
-Class ThisClassDoesNotExist does not exist
+Class "ThisClassDoesNotExist" does not exist
ReflectionClass::isSubclassOf(): Argument #1 ($class) must be of type ReflectionClass|string, int given
?>
--EXPECTF--
-Fatal error: Uncaught ReflectionException: Class X does not exist in %s:%d
+Fatal error: Uncaught ReflectionException: Class "X" does not exist in %s:%d
Stack trace:
#0 %s(%d): ReflectionClass->isSubclassOf('X')
#1 {main}
?>
--EXPECT--
-Class A does not exist
+Class "A" does not exist
Method C::b() does not exist
Method C::b() does not exist
Ok - ReflectionParameter::__construct() expects exactly 2 parameters, 1 given
?>
--EXPECT--
Non-existent class:
-Class NonExistentClass does not exist
+Class "NonExistentClass" does not exist
Wrong property parameter type:
ReflectionProperty::__construct(): Argument #1 ($class) must be of type object|string, int given
ReflectionProperty::getValue() expects at most 1 parameter, 2 given
Protected property:
-Cannot access non-public member TestClass::$prot
+Cannot access non-public property TestClass::$prot
Invalid instance:
Given object is not an instance of the class this property was declared in
bool(true)
bool(false)
Visibility handling:
-Cannot access non-public member A::$p
+Cannot access non-public property A::$p
bool(false)
Object type:
bool(false)
var_dump($private->getValue($b));
?>
--EXPECT--
-string(45) "Cannot access non-public member A::$protected"
-string(51) "Cannot access non-public member A::$protectedStatic"
-string(43) "Cannot access non-public member A::$private"
-string(49) "Cannot access non-public member A::$privateStatic"
+string(47) "Cannot access non-public property A::$protected"
+string(53) "Cannot access non-public property A::$protectedStatic"
+string(45) "Cannot access non-public property A::$private"
+string(51) "Cannot access non-public property A::$privateStatic"
string(1) "a"
string(1) "b"
string(1) "c"
string(1) "f"
string(1) "g"
string(1) "h"
-string(45) "Cannot access non-public member B::$protected"
-string(51) "Cannot access non-public member B::$protectedStatic"
-string(43) "Cannot access non-public member A::$private"
+string(47) "Cannot access non-public property B::$protected"
+string(53) "Cannot access non-public property B::$protectedStatic"
+string(45) "Cannot access non-public property A::$private"
string(1) "a"
string(1) "f"
string(1) "c"
?>
--EXPECT--
Protected property:
-Cannot access non-public member TestClass::$prot
+Cannot access non-public property TestClass::$prot
Instance without property:
NULL
?>
--EXPECTF--
-Call to private ReflectionReference::__construct() from invalid context
+Call to private ReflectionReference::__construct() from global scope
ReflectionReference::fromArrayElement(): Argument #1 ($array) must be of type array, stdClass given
ReflectionReference::fromArrayElement(): Argument #2 ($key) must be of type string|int, float given
Array key not found
?>
--EXPECT--
-Zend Extension zend_opcache does not exist
+Zend Extension "zend_opcache" does not exist
?>
--EXPECT--
-Caught: Cannot access non-public member TestClass::$p
+Caught: Cannot access non-public property TestClass::$p
bool(false)
bool(false)
bool(false)
-string(25) "Property a does not exist"
+string(29) "Property B::$a does not exist"
int(2)
echo $class;
?>
--EXPECTF--
-Fatal error: Uncaught Error: Undefined constant 'PHP_SELF' in %s:%d
+Fatal error: Uncaught Error: Undefined constant "PHP_SELF" in %s:%d
Stack trace:
#0 %s(%d): ReflectionClass->__toString()
#1 {main}
isPassedByReference: bool(false)
Deprecated: Method ReflectionParameter::getClass() is deprecated in %s on line %d
-Class NonExistingClass does not exist
+Class "NonExistingClass" does not exist
getDeclaringClass: NULL
isArray:
Deprecated: Method ReflectionParameter::isArray() is deprecated in %s on line %d
isPassedByReference: bool(false)
Deprecated: Method ReflectionParameter::getClass() is deprecated in %s on line %d
-Class NonExistingClass does not exist
+Class "NonExistingClass" does not exist
getDeclaringClass: test
isArray:
Deprecated: Method ReflectionParameter::isArray() is deprecated in %s on line %d
var_dump($_SESSION);
?>
--EXPECTF--
-Notice: Undefined index: foo in %s on line %d
+Notice: Undefined array key "foo" in %s on line %d
-Notice: Undefined index: bar in %s on line %d
+Notice: Undefined array key "bar" in %s on line %d
NULL
NULL
array(0) {
$client->__soapCall('', array());
?>
--EXPECTF--
-Fatal error: Uncaught SoapFault exception: [Client] Access to undeclared static property: XSoapClient::$crash in %sbug54911.php:4
+Fatal error: Uncaught SoapFault exception: [Client] Access to undeclared static property XSoapClient::$crash in %sbug54911.php:4
Stack trace:
#0 [internal function]: XSoapClient->__doRequest('<?xml version="...', '', '#', 1, 0)
#1 %sbug54911.php(8): SoapClient->__soapCall('', Array)
if (Z_TYPE_P(retval) == IS_UNDEF) {
switch (type) {
case BP_VAR_R:
- zend_error(E_NOTICE, "Undefined index: %s", ZSTR_VAL(offset_key));
+ zend_error(E_NOTICE, "Undefined array key \"%s\"", ZSTR_VAL(offset_key));
case BP_VAR_UNSET:
case BP_VAR_IS:
retval = &EG(uninitialized_zval);
break;
case BP_VAR_RW:
- zend_error(E_NOTICE,"Undefined index: %s", ZSTR_VAL(offset_key));
+ zend_error(E_NOTICE,"Undefined array key \"%s\"", ZSTR_VAL(offset_key));
case BP_VAR_W: {
ZVAL_NULL(retval);
}
} else {
switch (type) {
case BP_VAR_R:
- zend_error(E_NOTICE, "Undefined index: %s", ZSTR_VAL(offset_key));
+ zend_error(E_NOTICE, "Undefined array key \"%s\"", ZSTR_VAL(offset_key));
case BP_VAR_UNSET:
case BP_VAR_IS:
retval = &EG(uninitialized_zval);
break;
case BP_VAR_RW:
- zend_error(E_NOTICE,"Undefined index: %s", ZSTR_VAL(offset_key));
+ zend_error(E_NOTICE,"Undefined array key \"%s\"", ZSTR_VAL(offset_key));
case BP_VAR_W: {
zval value;
ZVAL_NULL(&value);
if ((retval = zend_hash_index_find(ht, index)) == NULL) {
switch (type) {
case BP_VAR_R:
- zend_error(E_NOTICE, "Undefined offset: " ZEND_LONG_FMT, index);
+ zend_error(E_NOTICE, "Undefined array key " ZEND_LONG_FMT, index);
case BP_VAR_UNSET:
case BP_VAR_IS:
retval = &EG(uninitialized_zval);
break;
case BP_VAR_RW:
- zend_error(E_NOTICE, "Undefined offset: " ZEND_LONG_FMT, index);
+ zend_error(E_NOTICE, "Undefined array key " ZEND_LONG_FMT, index);
case BP_VAR_W: {
zval value;
ZVAL_UNDEF(&value);
ht = spl_array_get_hash_table(intern);
if (ht == &EG(symbol_table)) {
if (zend_delete_global_variable(Z_STR_P(offset))) {
- zend_error(E_NOTICE,"Undefined index: %s", Z_STRVAL_P(offset));
+ zend_error(E_NOTICE,"Undefined array key \"%s\"", Z_STRVAL_P(offset));
}
} else {
zval *data = zend_symtable_find(ht, Z_STR_P(offset));
if (Z_TYPE_P(data) == IS_INDIRECT) {
data = Z_INDIRECT_P(data);
if (Z_TYPE_P(data) == IS_UNDEF) {
- zend_error(E_NOTICE,"Undefined index: %s", Z_STRVAL_P(offset));
+ zend_error(E_NOTICE,"Undefined array key \"%s\"", Z_STRVAL_P(offset));
} else {
zval_ptr_dtor(data);
ZVAL_UNDEF(data);
}
}
} else if (zend_symtable_del(ht, Z_STR_P(offset)) == FAILURE) {
- zend_error(E_NOTICE,"Undefined index: %s", Z_STRVAL_P(offset));
+ zend_error(E_NOTICE,"Undefined array key \"%s\"", Z_STRVAL_P(offset));
}
} else {
- zend_error(E_NOTICE,"Undefined index: %s", Z_STRVAL_P(offset));
+ zend_error(E_NOTICE,"Undefined array key \"%s\"", Z_STRVAL_P(offset));
}
}
break;
num_index:
ht = spl_array_get_hash_table(intern);
if (zend_hash_index_del(ht, index) == FAILURE) {
- zend_error(E_NOTICE,"Undefined offset: " ZEND_LONG_FMT, index);
+ zend_error(E_NOTICE,"Undefined array key " ZEND_LONG_FMT, index);
}
break;
case IS_REFERENCE:
zend_function *func_ptr; \
func_ptr = (zend_function *)zend_hash_str_find_ptr(EG(function_table), #func_name, sizeof(#func_name) - 1); \
if (func_ptr == NULL) { \
- zend_throw_exception_ex(spl_ce_RuntimeException, 0, "Internal error, function '%s' not found. Please report", #func_name); \
+ zend_throw_exception_ex(spl_ce_RuntimeException, 0, "Internal error, function %s() not found. Please report", #func_name); \
return; \
} \
spl_filesystem_file_call(intern, func_ptr, pass_num_args, return_value, arg2); \
}
if ((value = zend_symtable_find(Z_ARRVAL(intern->u.caching.zcache), key)) == NULL) {
- zend_error(E_NOTICE, "Undefined index: %s", ZSTR_VAL(key));
+ zend_error(E_NOTICE, "Undefined array key \"%s\"", ZSTR_VAL(key));
return;
}
?>
--EXPECT--
-SplFileInfo::setFileClass(): Argument #1 ($class_name) must be a class name derived from SplFileObject, 'stdClass' given
+SplFileInfo::setFileClass(): Argument #1 ($class_name) must be a class name derived from SplFileObject, stdClass given
?>
--EXPECT--
-SplFileInfo::setInfoClass(): Argument #1 ($class_name) must be a class name derived from SplFileInfo, 'stdClass' given
+SplFileInfo::setInfoClass(): Argument #1 ($class_name) must be a class name derived from SplFileInfo, stdClass given
Warning: Undefined property: ArrayObject::$prop in %s on line %d
-Notice: Undefined index: prop in %s on line 40
+Notice: Undefined array key "prop" in %s on line %d
NULL
NULL
- After:
Warning: Undefined property: MyArrayObject::$prop in %s on line %d
-Notice: Undefined index: prop in %s on line 40
+Notice: Undefined array key "prop" in %s on line %d
NULL
NULL
- After:
Warning: Undefined property: ArrayObject::$prop in %s on line %d
-Notice: Undefined index: prop in %s on line 40
+Notice: Undefined array key "prop" in %s on line %d
NULL
NULL
- After:
Warning: Undefined property: MyArrayObject::$prop in %s on line %d
-Notice: Undefined index: prop in %s on line 40
+Notice: Undefined array key "prop" in %s on line %d
NULL
NULL
- After:
bool(true)
- Unset:
-Notice: Undefined index: prop in %s on line 39
+Notice: Undefined array key "prop" in %s on line %d
-Notice: Undefined index: prop in %s on line 40
+Notice: Undefined array key "prop" in %s on line %d
-Notice: Undefined index: prop in %s on line 40
+Notice: Undefined array key "prop" in %s on line %d
NULL
NULL
- After:
bool(true)
- Unset:
-Notice: Undefined index: prop in %s on line 40
+Notice: Undefined array key "prop" in %s on line %d
-Notice: Undefined index: prop in %s on line 40
+Notice: Undefined array key "prop" in %s on line %d
NULL
NULL
- After:
bool(true)
- Unset:
-Notice: Undefined index: prop in %s on line 39
+Notice: Undefined array key "prop" in %s on line %d
-Notice: Undefined index: prop in %s on line 40
+Notice: Undefined array key "prop" in %s on line %d
-Notice: Undefined index: prop in %s on line 40
+Notice: Undefined array key "prop" in %s on line %d
NULL
NULL
- After:
bool(true)
- Unset:
-Notice: Undefined index: prop in %s on line 40
+Notice: Undefined array key "prop" in %s on line %d
-Notice: Undefined index: prop in %s on line 40
+Notice: Undefined array key "prop" in %s on line %d
NULL
NULL
- After:
?>
--EXPECT--
Bad iterator type:
-ArrayObject::__construct(): Argument #3 ($iterator_class) must be a class name derived from Iterator, 'Exception' given(6)
+ArrayObject::__construct(): Argument #3 ($iterator_class) must be a class name derived from Iterator, Exception given(6)
Non-existent class:
-ArrayObject::__construct(): Argument #3 ($iterator_class) must be a class name derived from Iterator, 'nonExistentClassName' given(13)
+ArrayObject::__construct(): Argument #3 ($iterator_class) must be a class name derived from Iterator, nonExistentClassName given(13)
--> Read existent, non-existent and dynamic:
string(7) "changed"
-Notice: Undefined index: nonexistent in %s on line 42
+Notice: Undefined array key "nonexistent" in %s on line %d
NULL
string(11) "new.changed"
Original wrapped object:
--> Unset existent, non-existent and dynamic:
-Notice: Undefined index: nonexistent in %s on line 60
+Notice: Undefined array key "nonexistent" in %s on line %d
Original wrapped object:
object(UsesMagic)#1 (3) {
["b"]=>
--> Read existent, non-existent and dynamic:
string(7) "changed"
-Notice: Undefined index: nonexistent in %s on line 42
+Notice: Undefined array key "nonexistent" in %s on line %d
NULL
string(11) "new.changed"
Original wrapped object:
--> Unset existent, non-existent and dynamic:
-Notice: Undefined index: nonexistent in %s on line 60
+Notice: Undefined array key "nonexistent" in %s on line %d
Original wrapped object:
object(UsesMagic)#1 (3) {
["b"]=>
--> Read existent, non-existent and dynamic:
string(7) "changed"
-Notice: Undefined index: nonexistent in %s on line 45
+Notice: Undefined array key "nonexistent" in %s on line %d
NULL
string(11) "new.changed"
Original wrapped object:
--> Unset existent, non-existent and dynamic:
-Notice: Undefined index: nonexistent in %s on line 63
+Notice: Undefined array key "nonexistent" in %s on line %d
Original wrapped object:
object(C)#1 (3) {
["b"]=>
--> Read existent, non-existent and dynamic:
string(7) "changed"
-Notice: Undefined index: nonexistent in %s on line 45
+Notice: Undefined array key "nonexistent" in %s on line %d
NULL
string(11) "new.changed"
Original wrapped object:
--> Unset existent, non-existent and dynamic:
-Notice: Undefined index: nonexistent in %s on line 63
+Notice: Undefined array key "nonexistent" in %s on line %d
Original wrapped object:
object(C)#1 (3) {
["b"]=>
--> Remove the array element and try access again:
bool(false)
-Notice: Undefined index: p in %s on line 10
+Notice: Undefined array key "p" in %s on line %d
NULL
-Notice: Undefined index: p in %s on line 12
+Notice: Undefined array key "p" in %s on line %d
string(8) ".changed"
?>
--EXPECT--
-string(130) "ArrayObject::setIteratorClass(): Argument #1 ($iteratorClass) must be a class name derived from Iterator, 'nonExistentClass' given"
-string(122) "ArrayObject::setIteratorClass(): Argument #1 ($iteratorClass) must be a class name derived from Iterator, 'stdClass' given"
-string(126) "ArrayObject::__construct(): Argument #3 ($iterator_class) must be a class name derived from Iterator, 'nonExistentClass' given"
-string(118) "ArrayObject::__construct(): Argument #3 ($iterator_class) must be a class name derived from Iterator, 'stdClass' given"
+string(128) "ArrayObject::setIteratorClass(): Argument #1 ($iteratorClass) must be a class name derived from Iterator, nonExistentClass given"
+string(120) "ArrayObject::setIteratorClass(): Argument #1 ($iteratorClass) must be a class name derived from Iterator, stdClass given"
+string(124) "ArrayObject::__construct(): Argument #3 ($iterator_class) must be a class name derived from Iterator, nonExistentClass given"
+string(116) "ArrayObject::__construct(): Argument #3 ($iterator_class) must be a class name derived from Iterator, stdClass given"
}
int(0)
-Notice: Undefined offset: 6 in %sarray_001.php on line %d
+Notice: Undefined array key 6 in %s on line %d
NULL
-Notice: Undefined index: b in %sarray_001.php on line %d
+Notice: Undefined array key "b" in %s on line %d
NULL
-Notice: Undefined offset: 7 in %sarray_001.php on line %d
+Notice: Undefined array key 7 in %s on line %d
-Notice: Undefined index: c in %sarray_001.php on line %d
+Notice: Undefined array key "c" in %s on line %d
object(ArrayObject)#%d (1) {
["storage":"ArrayObject":private]=>
array(2) {
string(3) "3rd"
int(4)
-Notice: Undefined index: 5th in %sarray_010.php on line %d
+Notice: Undefined array key "5th" in %sarray_010.php on line %d
NULL
-Notice: Undefined offset: 6 in %sarray_010.php on line %d
+Notice: Undefined array key 6 in %sarray_010.php on line %d
NULL
===offsetSet===
WRITE 1
string(9) "changed 6"
}
-Notice: Undefined offset: 7 in %sarray_010.php on line %d
+Notice: Undefined array key 7 in %sarray_010.php on line %d
-Notice: Undefined index: 8th in %sarray_010.php on line %d
+Notice: Undefined array key "8th" in %sarray_010.php on line %d
array(4) {
[0]=>
string(3) "1st"
new ThisClassDoesNotExistEverFoo();
?>
--EXPECTF--
-Fatal error: Uncaught Error: Class 'ThisClassDoesNotExistEverFoo' not found in %s:%d
+Fatal error: Uncaught Error: Class "ThisClassDoesNotExistEverFoo" not found in %s:%d
Stack trace:
#0 {main}
thrown in %s on line 3
--> Remove the array element and try access again:
bool(false)
-Notice: Undefined index: p in %s on line %d
+Notice: Undefined array key "p" in %s on line %d
NULL
--> Re-add the real property:
--EXPECTF--
Doesn't trigger __get.
-Notice: Undefined index: prop1 in %s on line 11
+Notice: Undefined array key "prop1" in %s on line %d
Doesn't trigger __set.
Doesn't trigger __unset.
-Notice: Undefined index: prop3 in %s on line 17
+Notice: Undefined array key "prop3" in %s on line %d
Shouldn't trigger __isset.
?>
===DONE===
--EXPECTF--
-Fatal error: Uncaught Error: Class 'Foo' not found in %s:%d
+Fatal error: Uncaught Error: Class "Foo" not found in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
--EXPECTF--
Warning: Undefined property: C::$prop in %s on line %d
-Notice: Undefined index: prop in %sbug54323.php on line 14
+Notice: Undefined array key "prop" in %sbug54323.php on line 14
NULL
NULL
fclose($fp);
--EXPECTF--
-Notice: Undefined index: epic_magic in %sbug62978.php on line %d
+Notice: Undefined array key "epic_magic" in %s on line %d
NULL
-Notice: Undefined index: epic_magic in %sbug62978.php on line %d
+Notice: Undefined array key "epic_magic" in %s on line %d
NULL
Warning: Undefined variable $c in %s on line %d
Warning: Trying to access array offset on value of type null in %s on line %d
NULL
-Notice: Undefined index: epic_magic in %sbug62978.php on line %d
+Notice: Undefined array key "epic_magic" in %s on line %d
NULL
-Notice: Undefined index: epic_magic in %sbug62978.php on line %d
+Notice: Undefined array key "epic_magic" in %s on line %d
NULL
-Notice: Undefined index: epic_magic in %sbug62978.php on line %d
+Notice: Undefined array key "epic_magic" in %s on line %d
NULL
bool(false)
Warning: Resource ID#%d used as offset, casting to integer (%d) in %sbug62978.php on line %d
-Notice: Undefined offset: %d in %sbug62978.php on line %d
+Notice: Undefined array key %d in %sbug62978.php on line %d
NULL
bool(true)
==== class with offsetGet() and offsetSet() ====
-Notice: Undefined index: foo in %s on line %d
+Notice: Undefined array key "foo" in %s on line %d
bool(false)
bool(true)
bool(false)
var_dump($y[NULL]++);
?>
--EXPECTF--
-Notice: Undefined index: in %s on line %d
+Notice: Undefined array key "" in %s on line %d
NULL
-Notice: Undefined index: in %s on line %d
+Notice: Undefined array key "" in %s on line %d
NULL
new A();
?>
--EXPECTF--
-Fatal error: Uncaught Error: Class 'A' not found in %sbug71204.php:%d
+Fatal error: Uncaught Error: Class "A" not found in %s:%d
Stack trace:
#0 {main}
thrown in %sbug71204.php on line %d
?>
--EXPECTF--
-Fatal error: Uncaught Error: Class 'NotExists' not found in %s:%d
+Fatal error: Uncaught Error: Class "NotExists" not found in %s:%d
Stack trace:
#0 %s(%d): eval()
#1 %s(%d): fooIterator->__destruct()
#2 {main}
-Next Error: Class 'NotExists' not found in %s:%d
+Next Error: Class "NotExists" not found in %s:%d
Stack trace:
#0 %s(%d): eval()
#1 %s(%d): fooIterator->__destruct()
}
?>
--EXPECT--
-Exception: Class 'teException' not found
+Exception: Class "teException" not found
0 => test1
1 => test2
-Notice: Undefined index: foo in %s on line %d
+Notice: Undefined array key "foo" in %s on line %d
NULL
object(SelfArray)#9 (1) {
["foo"]=>
int(0)
bool(false)
-Notice: Undefined index: 0 in %siterator_044.php on line %d
+Notice: Undefined array key "0" in %s on line %d
NULL
===1===
object(stdClass)#%d (0) {
}
bool(false)
-Notice: Undefined index: foo in %siterator_044.php on line %d
+Notice: Undefined array key "foo" in %s on line %d
NULL
===3===
NULL
bool(false)
-Notice: Undefined index: in %siterator_044.php on line %d
+Notice: Undefined array key "" in %s on line %d
NULL
===4===
int(2)
bool(false)
-Notice: Undefined index: 2 in %siterator_044.php on line %d
+Notice: Undefined array key "2" in %s on line %d
NULL
===5===
string(3) "foo"
bool(false)
-Notice: Undefined index: foo in %siterator_044.php on line %d
+Notice: Undefined array key "foo" in %s on line %d
NULL
===6===
int(3)
bool(false)
-Notice: Undefined index: 3 in %siterator_044.php on line %d
+Notice: Undefined array key "3" in %s on line %d
NULL
===FILL===
===0===
NULL
bool(false)
-Notice: Undefined index: in %siterator_044.php on line %d
+Notice: Undefined array key "" in %s on line %d
NULL
===4===
int(2)
int(3)
bool(false)
-Notice: Undefined index: 3 in %siterator_044.php on line %d
+Notice: Undefined array key "3" in %s on line %d
NULL
int(4)
===ERRORS===
iterator_apply(): Argument #3 ($args) must be of type ?array, int given
-iterator_apply(): Argument #2 ($function) must be a valid callback, function 'non_existing_function' not found or invalid function name
+iterator_apply(): Argument #2 ($function) must be a valid callback, function "non_existing_function" not found or invalid function name
iterator_apply() expects at most 3 parameters, 4 given
%stestclass.class.inc
bool(true)
===NOFUNCTION===
-spl_autoload_register(): Argument #1 ($autoload_function) must be a valid callback, function 'unavailable_autoload_function' not found or invalid function name
+spl_autoload_register(): Argument #1 ($autoload_function) must be a valid callback, function "unavailable_autoload_function" not found or invalid function name
?>
--EXPECTF--
string(22) "MyAutoLoader::notExist"
-spl_autoload_register(): Argument #1 ($autoload_function) must be a valid callback, class 'MyAutoLoader' does not have a method 'notExist'
+spl_autoload_register(): Argument #1 ($autoload_function) must be a valid callback, class MyAutoLoader does not have a method "notExist"
string(22) "MyAutoLoader::noAccess"
spl_autoload_register(): Argument #1 ($autoload_function) must be a valid callback, cannot access protected method MyAutoLoader::noAccess()
[1]=>
string(8) "notExist"
}
-spl_autoload_register(): Argument #1 ($autoload_function) must be a valid callback, class 'MyAutoLoader' does not have a method 'notExist'
+spl_autoload_register(): Argument #1 ($autoload_function) must be a valid callback, class MyAutoLoader does not have a method "notExist"
array(2) {
[0]=>
[1]=>
string(8) "notExist"
}
-spl_autoload_register(): Argument #1 ($autoload_function) must be a valid callback, class 'MyAutoLoader' does not have a method 'notExist'
+spl_autoload_register(): Argument #1 ($autoload_function) must be a valid callback, class MyAutoLoader does not have a method "notExist"
array(2) {
[0]=>
if (!zend_is_callable(&tick_fe.arguments[0], 0, &function_name)) {
efree(tick_fe.arguments);
- zend_argument_type_error(1, "must be a valid tick callback, '%s' given", ZSTR_VAL(function_name));
+ zend_argument_type_error(1, "must be a valid tick callback, \"%s\" given", ZSTR_VAL(function_name));
zend_string_release_ex(function_name, 0);
RETURN_THROWS();
} else if (function_name) {
/* break missing intentionally */
default:
- zend_value_error("Unknown format specifier '%c'", *format);
+ zend_value_error("Unknown format specifier \"%c\"", *format);
goto fail;
}
format++;
?>
--EXPECT--
*** Testing array_diff_ukey() : usage variation ***
-array_diff_ukey(): Argument #3 must be a valid callback, function 'unknown_function' not found or invalid function name
-array_diff_ukey(): Argument #3 must be a valid callback, function 'unknown_function' not found or invalid function name
+array_diff_ukey(): Argument #3 must be a valid callback, function "unknown_function" not found or invalid function name
+array_diff_ukey(): Argument #3 must be a valid callback, function "unknown_function" not found or invalid function name
[6]=>
NULL
}
-array_filter(): Argument #2 ($callback) must be a valid callback, function 'echo' not found or invalid function name
-array_filter(): Argument #2 ($callback) must be a valid callback, function 'exit' not found or invalid function name
+array_filter(): Argument #2 ($callback) must be a valid callback, function "echo" not found or invalid function name
+array_filter(): Argument #2 ($callback) must be a valid callback, function "exit" not found or invalid function name
Done
?>
--EXPECT--
*** Testing array_intersect_ukey() : usage variation ***
-array_intersect_ukey(): Argument #3 must be a valid callback, function 'unknown_function' not found or invalid function name
-array_intersect_ukey(): Argument #3 must be a valid callback, function 'unknown_function' not found or invalid function name
+array_intersect_ukey(): Argument #3 must be a valid callback, function "unknown_function" not found or invalid function name
+array_intersect_ukey(): Argument #3 must be a valid callback, function "unknown_function" not found or invalid function name
--EXPECT--
*** Testing array_map() : with non-existent class and method ***
-- with non-existent class --
-array_map(): Argument #1 ($callback) must be a valid callback, class 'non-existent' not found
+array_map(): Argument #1 ($callback) must be a valid callback, class "non-existent" not found
-- with existent class and non-existent method --
-array_map(): Argument #1 ($callback) must be a valid callback, class 'SimpleClass' does not have a method 'non-existent'
+array_map(): Argument #1 ($callback) must be a valid callback, class SimpleClass does not have a method "non-existent"
Done
int(7)
}
-- accessing child method from parent class --
-array_map(): Argument #1 ($callback) must be a valid callback, class 'ParentClass' does not have a method 'staticChild'
+array_map(): Argument #1 ($callback) must be a valid callback, class ParentClass does not have a method "staticChild"
-- accessing parent method using child class object --
array(3) {
[0]=>
int(7)
}
-- accessing child method using parent class object --
-array_map(): Argument #1 ($callback) must be a valid callback, class 'ParentClass' does not have a method 'staticChild'
+array_map(): Argument #1 ($callback) must be a valid callback, class ParentClass does not have a method "staticChild"
Done
-- with built-in function 'pow' and one parameter --
pow() expects exactly 2 parameters, 1 given
-- with language construct --
-array_map(): Argument #1 ($callback) must be a valid callback, function 'echo' not found or invalid function name
+array_map(): Argument #1 ($callback) must be a valid callback, function "echo" not found or invalid function name
Done
int(2)
}
-- with empty string --
-array_map(): Argument #1 ($callback) must be a valid callback, function '' not found or invalid function name
+array_map(): Argument #1 ($callback) must be a valid callback, function "" not found or invalid function name
-- with empty array --
array_map(): Argument #1 ($callback) must be a valid callback, array must have exactly two members
Done
?>
--EXPECT--
*** Testing array_map() : non existent 'callback' function ***
-array_map(): Argument #1 ($callback) must be a valid callback, function 'non_existent' not found or invalid function name
+array_map(): Argument #1 ($callback) must be a valid callback, function "non_existent" not found or invalid function name
Done
--EXPECT--
*** Testing array_map() : non-permmited built-in functions ***
-- Iteration 1 --
-array_map(): Argument #1 ($callback) must be a valid callback, function 'echo' not found or invalid function name
+array_map(): Argument #1 ($callback) must be a valid callback, function "echo" not found or invalid function name
-- Iteration 2 --
-array_map(): Argument #1 ($callback) must be a valid callback, function 'array' not found or invalid function name
+array_map(): Argument #1 ($callback) must be a valid callback, function "array" not found or invalid function name
-- Iteration 3 --
-array_map(): Argument #1 ($callback) must be a valid callback, function 'empty' not found or invalid function name
+array_map(): Argument #1 ($callback) must be a valid callback, function "empty" not found or invalid function name
-- Iteration 4 --
-array_map(): Argument #1 ($callback) must be a valid callback, function 'eval' not found or invalid function name
+array_map(): Argument #1 ($callback) must be a valid callback, function "eval" not found or invalid function name
-- Iteration 5 --
-array_map(): Argument #1 ($callback) must be a valid callback, function 'exit' not found or invalid function name
+array_map(): Argument #1 ($callback) must be a valid callback, function "exit" not found or invalid function name
-- Iteration 6 --
-array_map(): Argument #1 ($callback) must be a valid callback, function 'isset' not found or invalid function name
+array_map(): Argument #1 ($callback) must be a valid callback, function "isset" not found or invalid function name
-- Iteration 7 --
-array_map(): Argument #1 ($callback) must be a valid callback, function 'list' not found or invalid function name
+array_map(): Argument #1 ($callback) must be a valid callback, function "list" not found or invalid function name
-- Iteration 8 --
-array_map(): Argument #1 ($callback) must be a valid callback, function 'print' not found or invalid function name
+array_map(): Argument #1 ($callback) must be a valid callback, function "print" not found or invalid function name
Done
array_map(): Argument #1 ($callback) must be a valid callback, no array or string given
-- Iteration 14 --
-array_map(): Argument #1 ($callback) must be a valid callback, function '' not found or invalid function name
+array_map(): Argument #1 ($callback) must be a valid callback, function "" not found or invalid function name
-- Iteration 15 --
-array_map(): Argument #1 ($callback) must be a valid callback, function '' not found or invalid function name
+array_map(): Argument #1 ($callback) must be a valid callback, function "" not found or invalid function name
-- Iteration 16 --
array_map(): Argument #1 ($callback) must be a valid callback, array must have exactly two members
-- With 'min' built-in function --
bool(true)
-- With 'echo' language construct --
-array_walk_recursive(): Argument #2 ($funcname) must be a valid callback, function 'echo' not found or invalid function name
+array_walk_recursive(): Argument #2 ($funcname) must be a valid callback, function "echo" not found or invalid function name
Done
-- With 'min' built-in function --
bool(true)
-- With 'echo' language construct --
-array_walk(): Argument #2 ($funcname) must be a valid callback, function 'echo' not found or invalid function name
+array_walk(): Argument #2 ($funcname) must be a valid callback, function "echo" not found or invalid function name
Done
Warning: file_get_contents(): Unable to create or locate filter "sample.filter" in %s on line %d
Warning: file_get_contents(): Unable to create filter (sample.filter) in %s on line %d
-Undefined constant 'FOO'
+Undefined constant "FOO"
Warning: main(): Unable to create or locate filter "sample.filter" in %s on line %d
Warning: main(): Unable to create filter (sample.filter) in %s on line %d
-Undefined constant 'FOO'
+Undefined constant "FOO"
}
?>
--EXPECT--
-Cannot access private const Foo::C1
+Cannot access private constant Foo::C1
$this|O::who
O
$this|B::who
-call_user_func(): Argument #1 ($function) must be a valid callback, class 'P' is not a subclass of 'B'
+call_user_func(): Argument #1 ($function) must be a valid callback, class P is not a subclass of B
?>
--EXPECT--
-call_user_func(): Argument #1 ($function) must be a valid callback, class 'Foo' not found
+call_user_func(): Argument #1 ($function) must be a valid callback, class "Foo" not found
call_user_func(): Argument #1 ($function) must be a valid callback, first array member is not a valid class name or object
call_user_func(): Argument #1 ($function) must be a valid callback, second array member is not a valid method
}
?>
--EXPECT--
-register_tick_function(): Argument #1 ($function) must be a valid tick callback, 'a' given
+register_tick_function(): Argument #1 ($function) must be a valid tick callback, "a" given
?>
--EXPECTF--
Invalid max_depth:
-unserialize(): 'max_depth' option must be of type int, string given
-unserialize(): 'max_depth' option must be greater than or equal to 0
+unserialize(): "max_depth" option must be of type int, string given
+unserialize(): "max_depth" option must be greater than or equal to 0
Array:
bool(true)
file_get_contents('error://test');
?>
--EXPECTF--
-Fatal error: Uncaught Error: Undefined class constant 'self::INVALID' in %sbug77664.php:%d
+Fatal error: Uncaught Error: Undefined constant self::INVALID in %s:%d
Stack trace:
#0 %sbug77664.php(%d): file_get_contents('error://test')
#1 {main}
12345678900.00000000000000000000000000000000000000000000000000000
*** Output for invalid width(-15) specifier ***
-Unknown format specifier '-'
+Unknown format specifier "-"
*** Output for '%F' as the format parameter ***
12345678900.000000
12345678900.0000000000%d
*** Output for invalid width(-15) specifier ***
-Unknown format specifier '-'
+Unknown format specifier "-"
*** Output for '%F' as the format parameter ***
12345678900.000000
string(65) "12345678900.00000000000000000000000000000000000000000000000000000"
-- Testing for invalid width(-15) specifier --
-Unknown format specifier '-'
+Unknown format specifier "-"
-- Testing for '%X' as the format parameter --
string(1) "C"
-- Testing vfprintf() function with wrong variable types as argument --
vfprintf(): Argument #2 ($format) must be of type string, array given
vfprintf(): Argument #3 ($args) must be of type array, string given
-Unknown format specifier 'y'
+Unknown format specifier "y"
string(0) ""
ZEND_PARSE_PARAMETERS_END();
if (NULL == (pzbucket = zend_hash_str_find(Z_OBJPROP_P(zobject), "bucket", sizeof("bucket")-1))) {
- zend_argument_value_error(2, "must be an object that has a 'bucket' property");
+ zend_argument_value_error(2, "must be an object that has a \"bucket\" property");
RETURN_THROWS();
}
max_depth = zend_hash_str_find_deref(Z_ARRVAL_P(options), "max_depth", sizeof("max_depth") - 1);
if (max_depth) {
if (Z_TYPE_P(max_depth) != IS_LONG) {
- zend_type_error("unserialize(): 'max_depth' option must be of type int, %s given", zend_zval_type_name(max_depth));
+ zend_type_error("unserialize(): \"max_depth\" option must be of type int, %s given", zend_zval_type_name(max_depth));
goto cleanup;
}
if (Z_LVAL_P(max_depth) < 0) {
- zend_value_error("unserialize(): 'max_depth' option must be greater than or equal to 0");
+ zend_value_error("unserialize(): \"max_depth\" option must be greater than or equal to 0");
goto cleanup;
}
new tidyNode;
?>
--EXPECTF--
-Fatal error: Uncaught Error: Call to private tidyNode::__construct() from invalid context in %s:%d
+Fatal error: Uncaught Error: Call to private tidyNode::__construct() from global scope in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
?>
--EXPECT--
-Undefined constant 'UNKNOWN'
+Undefined constant "UNKNOWN"
Cannot instantiate abstract class MyPhpToken2
?>
--EXPECTF--
-Compression level (1000) must be within -1..9
+gzcompress(): Argument #2 ($level) must be between -1 and 9
string(%d) "%a"
string(%d) "%a"
string(%d) "%a"
Warning: gzuncompress(): %s error in %s on line %d
bool(false)
-Length (-1) must be greater or equal zero
+gzuncompress(): Argument #2 ($max_decoded_len) must be greater than or equal to 0
Warning: gzuncompress(): %s error in %s on line %d
bool(false)
?>
--EXPECTF--
-Compression level (1000) must be within -1..9
+gzcompress(): Argument #2 ($level) must be between -1 and 9
string(%d) "%a"
string(%d) "%a"
string(%d) "%a"
Warning: gzinflate(): data error in %s on line %d
bool(false)
-Length (-1) must be greater or equal zero
+gzinflate(): Argument #2 ($max_decoded_len) must be greater than or equal to 0
Warning: gzinflate(): data error in %s on line %d
bool(false)
?>
--EXPECTF--
-Compression level (-10) must be within -1..9
-Compression level (100) must be within -1..9
-Encoding mode must be either ZLIB_ENCODING_RAW, ZLIB_ENCODING_GZIP or ZLIB_ENCODING_DEFLATE
+gzencode(): Argument #2 ($level) must be between -1 and 9
+gzencode(): Argument #2 ($level) must be between -1 and 9
+gzencode(): Argument #3 ($encoding) must be either ZLIB_ENCODING_RAW, ZLIB_ENCODING_GZIP, or ZLIB_ENCODING_DEFLATE
string(%d) "%a"
string(%d) "%a"
-Encoding mode must be either ZLIB_ENCODING_RAW, ZLIB_ENCODING_GZIP or ZLIB_ENCODING_DEFLATE
+gzencode(): Argument #3 ($encoding) must be either ZLIB_ENCODING_RAW, ZLIB_ENCODING_GZIP, or ZLIB_ENCODING_DEFLATE
string(%d) "%a"
string(%d) "%a"
*** Testing gzcompress() : error conditions ***
-- Testing with incorrect compression level --
-Compression level (99) must be within -1..9
+gzcompress(): Argument #2 ($level) must be between -1 and 9
-- Testing with invalid encoding --
-Encoding mode must be either ZLIB_ENCODING_RAW, ZLIB_ENCODING_GZIP or ZLIB_ENCODING_DEFLATE
+gzcompress(): Argument #3 ($encoding) must be either ZLIB_ENCODING_RAW, ZLIB_ENCODING_GZIP, or ZLIB_ENCODING_DEFLATE
*** Testing gzdeflate() : error conditions ***
-- Testing with incorrect compression level --
-Compression level (99) must be within -1..9
+gzdeflate(): Argument #2 ($level) must be between -1 and 9
-- Testing with incorrect encoding --
-Encoding mode must be either ZLIB_ENCODING_RAW, ZLIB_ENCODING_GZIP or ZLIB_ENCODING_DEFLATE
+gzdeflate(): Argument #3 ($encoding) must be either ZLIB_ENCODING_RAW, ZLIB_ENCODING_GZIP, or ZLIB_ENCODING_DEFLATE
*** Testing gzencode() : error conditions ***
-- Testing with incorrect compression level --
-Compression level (99) must be within -1..9
+gzencode(): Argument #2 ($level) must be between -1 and 9
-- Testing with incorrect encoding_mode --
-Encoding mode must be either ZLIB_ENCODING_RAW, ZLIB_ENCODING_GZIP or ZLIB_ENCODING_DEFLATE
+gzencode(): Argument #3 ($encoding) must be either ZLIB_ENCODING_RAW, ZLIB_ENCODING_GZIP, or ZLIB_ENCODING_DEFLATE
} \
} \
if (level < -1 || level > 9) { \
- zend_value_error("Compression level (" ZEND_LONG_FMT ") must be within -1..9", level); \
+ zend_argument_value_error(default_encoding ? 2 : 3, "must be between -1 and 9"); \
RETURN_THROWS(); \
} \
switch (encoding) { \
case PHP_ZLIB_ENCODING_DEFLATE: \
break; \
default: \
- zend_value_error("Encoding mode must be either ZLIB_ENCODING_RAW, ZLIB_ENCODING_GZIP or ZLIB_ENCODING_DEFLATE"); \
+ zend_argument_value_error(default_encoding ? 3 : 2, "must be either ZLIB_ENCODING_RAW, ZLIB_ENCODING_GZIP, or ZLIB_ENCODING_DEFLATE"); \
RETURN_THROWS(); \
} \
if ((out = php_zlib_encode(ZSTR_VAL(in), ZSTR_LEN(in), encoding, level)) == NULL) { \
RETURN_THROWS(); \
} \
if (max_len < 0) { \
- zend_value_error("Length (" ZEND_LONG_FMT ") must be greater or equal zero", max_len); \
+ zend_argument_value_error(2, "must be greater than or equal to 0"); \
RETURN_THROWS(); \
} \
if (SUCCESS != php_zlib_decode(in_buf, in_len, &out_buf, &out_len, encoding, max_len)) { \
if (FAILURE == php_stream_parse_fopen_modes(mode, &open_flags)) {
if (options & REPORT_ERRORS) {
- zend_value_error("`%s' is not a valid mode for fopen", mode);
+ zend_value_error("\"%s\" is not a valid mode for fopen", mode);
}
return NULL;
}
echo "Done\n";
?>
--EXPECT--
-string(40) "Exception: Class unknown does not exist
+string(42) "Exception: Class "unknown" does not exist
"
string(183) "Class [ <internal:Core> class stdClass ] {
echo "Done\n";
?>
--EXPECTF--
-string(44) "Exception: Extension unknown does not exist
+string(46) "Exception: Extension "unknown" does not exist
"
-string(37) "Exception: Extension does not exist
+string(39) "Exception: Extension "" does not exist
"
string(%d) "Extension [ <persistent> extension #%d pcre version %s ] {
int(4)
ObjectOne::offsetGet(5th)
-Notice: Undefined index: 5th in %sarray_access_001.php on line %d
+Notice: Undefined array key "5th" in %s on line %d
NULL
ObjectOne::offsetGet(6)
-Notice: Undefined offset: 6 in %sarray_access_001.php on line %d
+Notice: Undefined array key 6 in %s on line %d
NULL
===offsetSet===
WRITE 1
int(4)
ObjectOne::offsetGet(5th)
-Notice: Undefined index: 5th in %sarray_access_002.php on line %d
+Notice: Undefined array key "5th" in %s on line %d
NULL
ObjectOne::offsetGet(6)
-Notice: Undefined offset: 6 in %sarray_access_002.php on line %d
+Notice: Undefined array key 6 in %s on line %d
NULL
===offsetSet===
WRITE 1
--EXPECTF--
In autoload: string(6) "UndefI"
-Fatal error: Uncaught Error: Interface 'UndefI' not found in %s:%d
+Fatal error: Uncaught Error: Interface "UndefI" not found in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
--EXPECTF--
In autoload: string(9) "UndefBase"
-Fatal error: Uncaught Error: Class 'UndefBase' not found in %s:%d
+Fatal error: Uncaught Error: Class "UndefBase" not found in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
?>
--EXPECT--
In autoload: string(6) "UndefC"
-call_user_func(): Argument #1 ($function) must be a valid callback, class 'UndefC' not found
+call_user_func(): Argument #1 ($function) must be a valid callback, class "UndefC" not found
?>
--EXPECT--
In autoload: string(6) "UndefC"
-Class UndefC does not exist
+Class "UndefC" does not exist
?>
--EXPECT--
In autoload: string(6) "UndefC"
-Class UndefC does not exist
+Class "UndefC" does not exist
?>
--EXPECT--
In autoload: string(6) "UndefC"
-Class UndefC does not exist
+Class "UndefC" does not exist
?>
--EXPECT--
In autoload: string(6) "undefc"
-Class undefc does not exist
+Class "undefc" does not exist
?>
--EXPECT--
In autoload: string(6) "UndefI"
-Interface UndefI does not exist
+Interface "UndefI" does not exist
echo "BUG\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Class '../BUG' not found in %sautoload_021.php:6
+Fatal error: Uncaught Error: Class "../BUG" not found in %s:%d
Stack trace:
#0 {main}
thrown in %sautoload_021.php on line 6
--EXPECT--
Called function foo:bar(1)
call_user_func_array(): Argument #1 ($function) must be a valid callback, cannot access private method foo::bar()
-Call to private method foo::bar() from context ''
+Call to private method foo::bar() from global scope
bool(false)
bool(false)
-Fatal error: Uncaught Error: Class 'B' not found in %s:%d
+Fatal error: Uncaught Error: Class "B" not found in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
Expecting fatal error:
-Fatal error: Uncaught Error: Undefined class constant 'C::c19' in %s:%d
+Fatal error: Uncaught Error: Undefined constant C::c19 in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
$a = new C();
?>
--EXPECTF--
-Fatal error: Uncaught Error: Class 'D' not found in %s:%d
+Fatal error: Uncaught Error: Class "D" not found in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
--EXPECT--
string(14) "protectedConst"
string(14) "protectedConst"
-Cannot access protected const A::protectedConst
+Cannot access protected constant A::protectedConst
--EXPECT--
string(12) "privateConst"
string(12) "privateConst"
-Cannot access private const A::privateConst
+Cannot access private constant A::privateConst
int(1)
int(2)
-Fatal error: Uncaught Error: Undefined class constant 'B::Z' in %s:11
+Fatal error: Uncaught Error: Undefined constant B::Z in %s:%d
Stack trace:
#0 %s(15): B::checkConstants()
#1 {main}
?>
--EXPECTF--
-Fatal error: Uncaught Error: Cannot access private const A::privateConst in %s:6
+Fatal error: Uncaught Error: Cannot access private constant A::privateConst in %s:6
Stack trace:
#0 {main}
thrown in %s on line 6
?>
--EXPECTF--
-Fatal error: Uncaught Error: Cannot access protected const A::protectedConst in %s:6
+Fatal error: Uncaught Error: Cannot access protected constant A::protectedConst in %s:6
Stack trace:
#0 {main}
thrown in %s on line 6
?>
===DONE===
--EXPECTF--
-Fatal error: Uncaught Error: Call to private Derived::__destruct() from context '' in %sdestructor_visibility_001.php:%d
+Fatal error: Uncaught Error: Call to private Derived::__destruct() from global scope in %s:%d
Stack trace:
#0 {main}
thrown in %sdestructor_visibility_001.php on line %d
?>
===DONE===
---EXPECTF--
+--EXPECT--
===DONE===
-Warning: Call to private Derived::__destruct() from context '' during shutdown ignored in Unknown on line %d
+Warning: Call to private Derived::__destruct() from global scope during shutdown ignored in Unknown on line 0
int(1)
Done
-Warning: Call to protected test::__destruct() from context '' during shutdown ignored in Unknown on line 0
+Warning: Call to protected test::__destruct() from global scope during shutdown ignored in Unknown on line 0
echo "Done\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Call to protected test::__construct() from invalid context in %s:%d
+Fatal error: Uncaught Error: Call to protected test::__construct() from global scope in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
echo "Done\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Call to private test::__construct() from invalid context in %s:%d
+Fatal error: Uncaught Error: Call to private test::__construct() from global scope in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
echo "Done\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Call to protected test::__destruct() from context '' in %sfactory_and_singleton_005.php:%d
+Fatal error: Uncaught Error: Call to protected test::__destruct() from global scope in %s:%d
Stack trace:
#0 {main}
thrown in %sfactory_and_singleton_005.php on line %d
echo "Done\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Call to private test::__destruct() from context '' in %sfactory_and_singleton_006.php:%d
+Fatal error: Uncaught Error: Call to private test::__destruct() from global scope in %s:%d
Stack trace:
#0 {main}
thrown in %sfactory_and_singleton_006.php on line %d
echo "Done\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Call to protected test::__clone() from context '' in %s:%d
+Fatal error: Uncaught Error: Call to protected test::__clone() from global scope in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
echo "Done\n";
?>
--EXPECTF--
-Fatal error: Uncaught Error: Call to private test::__clone() from context '' in %s:%d
+Fatal error: Uncaught Error: Call to private test::__clone() from global scope in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
--EXPECT--
===DONE===
-Warning: Call to protected test::__destruct() from context '' during shutdown ignored in Unknown on line 0
+Warning: Call to protected test::__destruct() from global scope during shutdown ignored in Unknown on line 0
--EXPECT--
===DONE===
-Warning: Call to private test::__destruct() from context '' during shutdown ignored in Unknown on line 0
+Warning: Call to private test::__destruct() from global scope during shutdown ignored in Unknown on line 0
--EXPECTF--
Call show()
-Fatal error: Uncaught Error: Call to private method pass::show() from context '' in %s:%d
+Fatal error: Uncaught Error: Call to private method pass::show() from global scope in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
Call pass::show()
Call fail::show()
-Fatal error: Uncaught Error: Call to private method pass::show() from context 'fail' in %s:%d
+Fatal error: Uncaught Error: Call to private method pass::show() from scope fail in %s:%d
Stack trace:
#0 %s(%d): fail::show()
#1 {main}
--EXPECTF--
Call show()
-Fatal error: Uncaught Error: Call to private method pass::show() from context 'fail' in %s:%d
+Fatal error: Uncaught Error: Call to private method pass::show() from scope fail in %s:%d
Stack trace:
#0 %s(%d): fail::not_ok()
#1 {main}
--EXPECTF--
Call show()
-Fatal error: Uncaught Error: Call to private method pass::show() from context 'fail' in %s:%d
+Fatal error: Uncaught Error: Call to private method pass::show() from scope fail in %s:%d
Stack trace:
#0 %s(%d): fail->not_ok()
#1 {main}
--EXPECTF--
Call show()
-Fatal error: Uncaught Error: Call to private method pass::show() from context 'fail' in %s:%d
+Fatal error: Uncaught Error: Call to private method pass::show() from scope fail in %s:%d
Stack trace:
#0 %s(%d): fail::do_show()
#1 {main}
--EXPECTF--
Call show()
-Fatal error: Uncaught Error: Call to private method pass::show() from context 'fail' in %s:%d
+Fatal error: Uncaught Error: Call to private method pass::show() from scope fail in %s:%d
Stack trace:
#0 %s(%d): fail->do_show()
#1 {main}
--EXPECTF--
Call show()
-Fatal error: Uncaught Error: Call to private method pass::show() from context 'fail' in %s:%d
+Fatal error: Uncaught Error: Call to private method pass::show() from scope fail in %s:%d
Stack trace:
#0 %s(%d): fail::do_show()
#1 {main}
derived
base
-Fatal error: Uncaught Error: Call to private method base::show() from context 'derived' in %s:%d
+Fatal error: Uncaught Error: Call to private method base::show() from scope derived in %s:%d
Stack trace:
#0 %s(%d): derived->test()
#1 {main}
--EXPECTF--
Call fail()
-Fatal error: Uncaught Error: Call to protected method pass::fail() from context '' in %s:%d
+Fatal error: Uncaught Error: Call to protected method pass::fail() from global scope in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
--EXPECTF--
Call fail()
-Fatal error: Uncaught Error: Call to protected method pass::fail() from context '' in %s:%d
+Fatal error: Uncaught Error: Call to protected method pass::fail() from global scope in %s:%d
Stack trace:
#0 {main}
thrown in %s on line %d
Call pass::show()
Call fail::show()
-Fatal error: Uncaught Error: Call to protected method pass::show() from context 'fail' in %s:%d
+Fatal error: Uncaught Error: Call to protected method pass::show() from scope fail in %s:%d
Stack trace:
#0 %s(%d): fail::show()
#1 {main}
C::$p = 1;
?>
--EXPECTF--
-Fatal error: Uncaught Error: Access to undeclared static property: C::$p in %s:3
+Fatal error: Uncaught Error: Access to undeclared static property C::$p in %s:%d
Stack trace:
#0 {main}
thrown in %s on line 3
C::$p += 1;
?>
--EXPECTF--
-Fatal error: Uncaught Error: Access to undeclared static property: C::$p in %s:3
+Fatal error: Uncaught Error: Access to undeclared static property C::$p in %s:%d
Stack trace:
#0 {main}
thrown in %s on line 3
C::$p =& $a;
?>
--EXPECTF--
-Fatal error: Uncaught Error: Access to undeclared static property: C::$p in %s:4
+Fatal error: Uncaught Error: Access to undeclared static property C::$p in %s:%d
Stack trace:
#0 {main}
thrown in %s on line 4
C::$p++;
?>
--EXPECTF--
-Fatal error: Uncaught Error: Access to undeclared static property: C::$p in %s:3
+Fatal error: Uncaught Error: Access to undeclared static property C::$p in %s:%d
Stack trace:
#0 {main}
thrown in %s on line 3
echo C::$p;
?>
--EXPECTF--
-Fatal error: Uncaught Error: Access to undeclared static property: C::$p in %s:3
+Fatal error: Uncaught Error: Access to undeclared static property C::$p in %s:%d
Stack trace:
#0 {main}
thrown in %s on line 3
--EXPECTF--
foo
-Fatal error: Uncaught Error: Class 'B' not found in %s041.php:%d
+Fatal error: Uncaught Error: Class "B" not found in %s:%d
Stack trace:
#0 {main}
thrown in %s041.php on line %d
--EXPECTF--
foo
-Fatal error: Uncaught Error: Class 'B' not found in %s042.php:%d
+Fatal error: Uncaught Error: Class "B" not found in %s:%d
Stack trace:
#0 {main}
thrown in %s042.php on line %d
--EXPECTF--
foo
-Fatal error: Uncaught Error: Class 'B' not found in %s043.php:%d
+Fatal error: Uncaught Error: Class "B" not found in %s:%d
Stack trace:
#0 {main}
thrown in %s043.php on line %d
--EXPECTF--
foo
-Fatal error: Uncaught Error: Class 'B' not found in %s044.php:%d
+Fatal error: Uncaught Error: Class "B" not found in %s:%d
Stack trace:
#0 {main}
thrown in %s044.php on line %d
echo "Done";
?>
--EXPECT--
-handler(Undefined index: foo)
+handler(Undefined array key "foo")
Array
(
[foo] => 1
}
?>
--EXPECTF--
-Warning: Illegal string offset 'nosuchkey' in %sbug29566.php on line %d
+Warning: Illegal string offset "nosuchkey" in %s on line %d
Warning: foreach() argument must be of type array|object, string given in %sbug29566.php on line %d
--EXPECTF--
Warning: Class constants cannot be defined or redefined in %s on line %d
-Fatal error: Class '' not found in %s on line %d
+Fatal error: Class "" not found in %s on line %d
O= and P=
10 20 40 50 60 70 80
-Notice: Undefined offset: 0 in %s on line %d
+Notice: Undefined array key 0 in %s on line %d
-Notice: Undefined offset: 1 in %s on line %d
+Notice: Undefined array key 1 in %s on line %d
Y=,Z=
-Notice: Undefined offset: 1 in %s on line %d
+Notice: Undefined array key 1 in %s on line %d
AA=10
CC=10 DD=30
Array
--> MealIterator::valid (3)
--> MealIterator::next (3)
-Notice: Undefined offset: 3 in %s on line %d
+Notice: Undefined array key 3 in %s on line %d
--> MealIterator::valid (4)
(
)
-Warning: ob_start(): class 'f' not found in %s on line %d
+Warning: ob_start(): class "f" not found in %s on line %d
Notice: ob_start(): Failed to create buffer in %s on line %d
bool(false)
echo "done"
?>
--EXPECTF--
-Warning: ob_start(): class 'nonExistent' not found in %s on line %d
+Warning: ob_start(): class "nonExistent" not found in %s on line %d
Notice: ob_start(): Failed to create buffer in %s on line %d
bool(false)
-Warning: ob_start(): class 'C' does not have a method 'nonExistent' in %s on line %d
+Warning: ob_start(): class C does not have a method "nonExistent" in %s on line %d
Notice: ob_start(): Failed to create buffer in %s on line 13
bool(false)
-Warning: ob_start(): class 'C' does not have a method 'no' in %s on line %d
+Warning: ob_start(): class C does not have a method "no" in %s on line %d
Notice: ob_start(): Failed to create buffer in %s on line 14
bool(false)
-Warning: ob_start(): function 'no' not found or invalid function name in %s on line %d
+Warning: ob_start(): function "no" not found or invalid function name in %s on line %d
Notice: ob_start(): Failed to create buffer in %s on line 15
bool(false)
echo "done"
?>
--EXPECTF--
-Warning: ob_start(): class 'C' does not have a method 'f' in %s on line %d
+Warning: ob_start(): class C does not have a method "f" in %s on line %d
Notice: ob_start(): Failed to create buffer in %s on line %d
bool(false)
string(6) "foobar"
bool(false)
-Warning: Illegal string offset 'foo' in %soffsets_chaining_5.php on line %d
+Warning: Illegal string offset "foo" in %s on line %d
string(1) "f"
bool(false)
-Warning: Illegal string offset 'foo' in %soffsets_chaining_5.php on line %d
+Warning: Illegal string offset "foo" in %s on line %d
-Warning: Illegal string offset 'bar' in %soffsets_chaining_5.php on line %d
+Warning: Illegal string offset "bar" in %s on line %d
string(1) "f"
bool(true)
bool(true)
-Warning: Illegal string offset 'foo' in %s line %d
+Warning: Illegal string offset "foo" in %s on line %d
string(1) "f"
bool(false)