php-src/Zend/tests/get_called_class_001.phpt
Nikita Popov 213b666781 Synchronize GET_CLASS/GET_CALLED_CLASS opcodes with functions
These error conditions throw in the function implementations,
make the opcodes match.
2020-09-21 15:06:04 +02:00

15 lines
233 B
PHP

--TEST--
Calling get_called_class() outside a class
--FILE--
<?php
try {
var_dump(get_called_class());
} catch (Error $e) {
echo $e->getMessage(), "\n";
}
?>
--EXPECT--
get_called_class() must be called from within a class