1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 00:57:45 +00:00

LibJS: Add the WeakSet built-in object

This commit is contained in:
Idan Horowitz 2021-06-09 19:23:04 +03:00 committed by Linus Groh
parent ee9fe288b2
commit 8b6beac5ce
10 changed files with 250 additions and 1 deletions

View file

@ -0,0 +1,28 @@
/*
* Copyright (c) 2021, Idan Horowitz <idan.horowitz@serenityos.org>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
#pragma once
#include <LibJS/Runtime/NativeFunction.h>
namespace JS {
class WeakSetConstructor final : public NativeFunction {
JS_OBJECT(WeakSetConstructor, NativeFunction);
public:
explicit WeakSetConstructor(GlobalObject&);
virtual void initialize(GlobalObject&) override;
virtual ~WeakSetConstructor() override;
virtual Value call() override;
virtual Value construct(Function&) override;
private:
virtual bool has_constructor() const override { return true; }
};
}