TypePHP 编译器
https://swoole.com/aot/
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
420 B
20 lines
420 B
--TEST--
|
|
Exceptions on improper access to string
|
|
--FILE--
|
|
<?php
|
|
$s = "ABC";
|
|
try {
|
|
$s[] = "D";
|
|
} catch (Error $e) {
|
|
echo "\nException: " . $e->getMessage() . " in " , $e->getFile() . " on line " . $e->getLine() . "\n";
|
|
}
|
|
|
|
$s[] = "D";
|
|
?>
|
|
--EXPECTF--
|
|
Exception: [] operator not supported for strings in %s
|
|
|
|
Fatal error: Uncaught Error: [] operator not supported for strings %s
|
|
Stack trace:
|
|
#0 {main}
|
|
thrown in %s
|
|
|