mirror of
https://github.com/phpv8/v8js.git
synced 2024-11-13 08:28:42 +00:00
21 lines
404 B
Plaintext
21 lines
404 B
Plaintext
|
--TEST--
|
||
|
Test empty() : Segmentation fault caused by 'empty' check on a V8Function object
|
||
|
--SKIPIF--
|
||
|
<?php require_once(dirname(__FILE__) . '/skipif.inc'); ?>
|
||
|
--FILE--
|
||
|
<?php
|
||
|
$v = new \V8Js();
|
||
|
$r = $v->executeString('
|
||
|
a = {
|
||
|
main: function() {}
|
||
|
};
|
||
|
', null, V8Js::FLAG_FORCE_ARRAY | V8Js::FLAG_PROPAGATE_PHP_EXCEPTIONS);
|
||
|
|
||
|
if (!empty($r['main'])) {
|
||
|
echo 'Ok' . PHP_EOL;
|
||
|
}
|
||
|
?>
|
||
|
--EXPECTF--
|
||
|
Ok
|
||
|
|