summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibWeb/WebAssembly
diff options
context:
space:
mode:
authorLinus Groh <mail@linusgroh.de>2021-07-05 12:33:29 +0100
committerLinus Groh <mail@linusgroh.de>2021-07-05 12:33:29 +0100
commitb5da87681792856a3d2e4c66834359eb0e372ae1 (patch)
tree2e841b90eae8a2fed8dda5934692b5dffc0f51c8 /Userland/Libraries/LibWeb/WebAssembly
parentb73b6fbd4cc7e506a83e4f62412132e88fe219de (diff)
downloadserenity-b5da87681792856a3d2e4c66834359eb0e372ae1.zip
LibWeb: Make WebAssembly.Memory.prototype.buffer an accessor property
Diffstat (limited to 'Userland/Libraries/LibWeb/WebAssembly')
-rw-r--r--Userland/Libraries/LibWeb/WebAssembly/WebAssemblyMemoryPrototype.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyMemoryPrototype.cpp b/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyMemoryPrototype.cpp
index 28cb46d635..d98b384636 100644
--- a/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyMemoryPrototype.cpp
+++ b/Userland/Libraries/LibWeb/WebAssembly/WebAssemblyMemoryPrototype.cpp
@@ -13,7 +13,7 @@ namespace Web::Bindings {
void WebAssemblyMemoryPrototype::initialize(JS::GlobalObject& global_object)
{
Object::initialize(global_object);
- define_native_property("buffer", buffer_getter, nullptr);
+ define_native_accessor("buffer", buffer_getter, {});
define_native_function("grow", grow);
}
@@ -42,7 +42,7 @@ JS_DEFINE_NATIVE_FUNCTION(WebAssemblyMemoryPrototype::grow)
return JS::Value(static_cast<u32>(previous_size));
}
-JS_DEFINE_NATIVE_GETTER(WebAssemblyMemoryPrototype::buffer_getter)
+JS_DEFINE_NATIVE_FUNCTION(WebAssemblyMemoryPrototype::buffer_getter)
{
auto* this_object = vm.this_value(global_object).to_object(global_object);
if (!this_object || !is<WebAssemblyMemoryObject>(this_object)) {