mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 17:58:12 +00:00
LibJS: Implement Promise.any on the Promise constructor
This commit is contained in:
parent
98d8a858cd
commit
4dffa40a8d
4 changed files with 243 additions and 2 deletions
|
@ -74,4 +74,18 @@ private:
|
|||
virtual Value resolve_element() override;
|
||||
};
|
||||
|
||||
// 27.2.4.3.2 Promise.any Reject Element Functions, https://tc39.es/ecma262/#sec-promise.any-reject-element-functions
|
||||
class PromiseAnyRejectElementFunction final : public PromiseResolvingElementFunction {
|
||||
JS_OBJECT(PromiseResolvingFunction, NativeFunction);
|
||||
|
||||
public:
|
||||
static PromiseAnyRejectElementFunction* create(GlobalObject&, size_t, PromiseValueList&, PromiseCapability, RemainingElements&);
|
||||
|
||||
explicit PromiseAnyRejectElementFunction(size_t, PromiseValueList&, PromiseCapability, RemainingElements&, Object& prototype);
|
||||
virtual ~PromiseAnyRejectElementFunction() override = default;
|
||||
|
||||
private:
|
||||
virtual Value resolve_element() override;
|
||||
};
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue