Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PHP 8.4 #541

Merged
merged 2 commits into from
Jan 9, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions tests/commonjs_exception_001.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,13 @@ $v8->executeString($JS, 'module.js', V8Js::FLAG_PROPAGATE_PHP_EXCEPTIONS);
--EXPECTF--
Fatal error: Uncaught Exception: some exception in %s%ecommonjs_exception_001.php:9
Stack trace:
#0 [internal function]: {closure}('test')
#0 [internal function]: {closur%s}('test')
#1 %s%ecommonjs_exception_001.php(12): V8Js->executeString('var foo = requi...', 'module.js', 4)
#2 {main}

Next V8JsScriptException: module.js:1: Exception: some exception in %s%ecommonjs_exception_001.php:9
Stack trace:
#0 [internal function]: {closure}('test')
#0 [internal function]: {closur%s}('test')
#1 %s%ecommonjs_exception_001.php(12): V8Js->executeString('var foo = requi...', 'module.js', 4)
#2 {main} in %s%ecommonjs_exception_001.php:12
Stack trace:
Expand Down
4 changes: 2 additions & 2 deletions tests/commonjs_exception_002.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,13 @@ $v8->executeString($JS, 'module.js', V8Js::FLAG_PROPAGATE_PHP_EXCEPTIONS);
--EXPECTF--
Fatal error: Uncaught Exception: some exception in %s%ecommonjs_exception_002.php:9
Stack trace:
#0 [internal function]: {closure}('', './test')
#0 [internal function]: {closur%s}('', './test')
#1 %s%ecommonjs_exception_002.php(15): V8Js->executeString('var foo = requi...', 'module.js', 4)
#2 {main}

Next V8JsScriptException: module.js:1: Exception: some exception in %s%ecommonjs_exception_002.php:9
Stack trace:
#0 [internal function]: {closure}('', './test')
#0 [internal function]: {closur%s}('', './test')
#1 %s%ecommonjs_exception_002.php(15): V8Js->executeString('var foo = requi...', 'module.js', 4)
#2 {main} in %s%ecommonjs_exception_002.php:15
Stack trace:
Expand Down
2 changes: 1 addition & 1 deletion tests/commonjs_fatal_error.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Test V8Js::setModuleLoader : Handle fatal errors gracefully
$v8 = new V8Js();

$v8->setModuleLoader(function() {
trigger_error('some fatal error', E_USER_ERROR);
@trigger_error('some fatal error', E_USER_ERROR);
});

$v8->executeString(' require("foo"); ');
Expand Down
2 changes: 1 addition & 1 deletion tests/fatal_error_no_uninstall_inner_frame.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ nothing.

Fatal error: Uncaught Error: Call to a member function foo() on null in %s%efatal_error_no_uninstall_inner_frame.php:15
Stack trace:
#0 [internal function]: {closure}()
#0 [internal function]: {closur%s}()
#1 [internal function]: Closure->__invoke()
#2 %s%efatal_error_no_uninstall_inner_frame.php(18): V8Js->executeString('PHP.foo();')
#3 {main}
Expand Down
6 changes: 3 additions & 3 deletions tests/fatal_error_recursive.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,13 @@ foo

Fatal error: Uncaught Error: Call to a member function bar() on null in %s%efatal_error_recursive.php:7
Stack trace:
#0 [internal function]: {closure}()
#0 [internal function]: {closur%s}()
#1 [internal function]: Closure->__invoke()
#2 %s%efatal_error_recursive.php(12): V8Js->executeString('PHP.baz();')
#3 [internal function]: {closure}()
#3 [internal function]: {closur%s}()
#4 [internal function]: Closure->__invoke()
#5 %s%efatal_error_recursive.php(17): V8Js->executeString('PHP.bar();')
#6 [internal function]: {closure}()
#6 [internal function]: {closur%s}()
#7 [internal function]: Closure->__invoke()
#8 %s%efatal_error_recursive.php(25): V8Js->executeString('PHP.nofail(); P...')
#9 {main}
Expand Down
2 changes: 1 addition & 1 deletion tests/fatal_error_rethrow.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ $js->executeString($script);
--EXPECTF--
Fatal error: Uncaught Error: Call to a member function bar() on %s in %s%efatal_error_rethrow.php:7
Stack trace:
#0 [internal function]: {closure}()
#0 [internal function]: {closur%s}()
#1 [internal function]: Closure->__invoke()
#2 %s%efatal_error_rethrow.php(16): V8Js->executeString(%s)
#3 {main}
Expand Down
2 changes: 1 addition & 1 deletion tests/generators_from_v8_008.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ int(23)

Fatal error: Uncaught Exception: this shall not work in %s
Stack trace:
#0 [internal function]: {closure}()
#0 [internal function]: {closur%s}()
#1 [internal function]: Closure->__invoke()
#2 %s: V8Generator->next()
#3 {main}
Expand Down
2 changes: 1 addition & 1 deletion tests/generators_from_v8_009.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ EOJS;

$v8 = new V8Js();
$v8->getValue = function() {
trigger_error("you're gonna fail now", E_USER_ERROR);
@trigger_error("you're gonna fail now", E_USER_ERROR);
};
$gen = $v8->executeString($js);

Expand Down
Loading
Loading