mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-31 21:29:06 +00:00
LibJS: Remove GlobalObject parameter from native functions
This commit is contained in:
parent
7b990c27a1
commit
b465f46e00
Notes:
sideshowbarker
2024-07-17 07:53:01 +09:00
Author: https://github.com/linusg
Commit: b465f46e00
Pull-request: https://github.com/SerenityOS/serenity/pull/14973
Reviewed-by: https://github.com/davidot ✅
77 changed files with 240 additions and 215 deletions
|
@ -21,10 +21,10 @@ ThrowCompletionOr<Value> AsyncFunctionDriverWrapper::create(Realm& realm, Genera
|
|||
AsyncFunctionDriverWrapper::AsyncFunctionDriverWrapper(Realm& realm, GeneratorObject* generator_object)
|
||||
: Promise(*realm.global_object().promise_prototype())
|
||||
, m_generator_object(generator_object)
|
||||
, m_on_fulfillment(NativeFunction::create(realm, "async.on_fulfillment"sv, [this](VM& vm, GlobalObject&) {
|
||||
, m_on_fulfillment(NativeFunction::create(realm, "async.on_fulfillment"sv, [this](VM& vm) {
|
||||
return react_to_async_task_completion(vm, vm.argument(0), true);
|
||||
}))
|
||||
, m_on_rejection(NativeFunction::create(realm, "async.on_rejection"sv, [this](VM& vm, GlobalObject&) {
|
||||
, m_on_rejection(NativeFunction::create(realm, "async.on_rejection"sv, [this](VM& vm) {
|
||||
return react_to_async_task_completion(vm, vm.argument(0), false);
|
||||
}))
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue