mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-27 10:07:15 +02:00
LibWeb: Implement the WebAssembly Memory object and Memory imports
This commit is contained in:
committed by
Ali Mohammad Pur
parent
eb5c92d4e2
commit
5c90c389c3
Notes:
sideshowbarker
2024-07-18 11:57:06 +09:00
Author: https://github.com/alimpfard Commit: https://github.com/SerenityOS/serenity/commit/5c90c389c3c Pull-request: https://github.com/SerenityOS/serenity/pull/8180 Reviewed-by: https://github.com/linusg
@@ -0,0 +1,28 @@
|
||||
/*
|
||||
* Copyright (c) 2021, Ali Mohammad Pur <mpfard@serenityos.org>
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <LibJS/Runtime/NativeFunction.h>
|
||||
|
||||
namespace Web::Bindings {
|
||||
|
||||
class WebAssemblyMemoryConstructor : public JS::NativeFunction {
|
||||
JS_OBJECT(WebAssemblyMemoryConstructor, JS::NativeFunction);
|
||||
|
||||
public:
|
||||
explicit WebAssemblyMemoryConstructor(JS::GlobalObject&);
|
||||
virtual void initialize(JS::GlobalObject&) override;
|
||||
virtual ~WebAssemblyMemoryConstructor() override;
|
||||
|
||||
virtual JS::Value call() override;
|
||||
virtual JS::Value construct(JS::Function& new_target) override;
|
||||
|
||||
private:
|
||||
virtual bool has_constructor() const override { return true; }
|
||||
};
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user