mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 05:57:44 +00:00
LibJS: Convert ArrayBuffer construction to ThrowCompletionOr
This also allows us to create TypedArrays with an existing buffer thus clearing up an additional FIXME in TextEncoder.
This commit is contained in:
parent
4136cbdb09
commit
de90d54be0
7 changed files with 30 additions and 26 deletions
|
@ -25,7 +25,7 @@ class ArrayBuffer : public Object {
|
|||
JS_OBJECT(ArrayBuffer, Object);
|
||||
|
||||
public:
|
||||
static ArrayBuffer* create(GlobalObject&, size_t);
|
||||
static ThrowCompletionOr<ArrayBuffer*> create(GlobalObject&, size_t);
|
||||
static ArrayBuffer* create(GlobalObject&, ByteBuffer);
|
||||
static ArrayBuffer* create(GlobalObject&, ByteBuffer*);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue