mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
script: Implement Blob::bytes()
(#35151)
* script: Implement Blob.bytes() Signed-off-by: yoseio <98276492+yoseio@users.noreply.github.com> * improve read_all_bytes Signed-off-by: yoseio <98276492+yoseio@users.noreply.github.com> * fix read_all_bytes Signed-off-by: yoseio <98276492+yoseio@users.noreply.github.com> * fix bug Signed-off-by: yoseio <98276492+yoseio@users.noreply.github.com> * something went wrong Signed-off-by: Kousuke Takaki <98276492+yoseio@users.noreply.github.com> * fix read loop Signed-off-by: gterzian <2792687+gterzian@users.noreply.github.com> * add use of can_gc to promise code following rebase Signed-off-by: gterzian <2792687+gterzian@users.noreply.github.com> * fix rooting of fulfillment handler Signed-off-by: gterzian <2792687+gterzian@users.noreply.github.com> * Update test expectations Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com> * use dom for reader in read loop fulfillment handler Signed-off-by: gterzian <2792687+gterzian@users.noreply.github.com> * use the global of the reader in read loop fulfillment handler Signed-off-by: gterzian <2792687+gterzian@users.noreply.github.com> * remove FAIl expectations for blob methods in detached iframe Signed-off-by: gterzian <2792687+gterzian@users.noreply.github.com> --------- Signed-off-by: yoseio <98276492+yoseio@users.noreply.github.com> Signed-off-by: Kousuke Takaki <98276492+yoseio@users.noreply.github.com> Signed-off-by: gterzian <2792687+gterzian@users.noreply.github.com> Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com> Co-authored-by: gterzian <2792687+gterzian@users.noreply.github.com> Co-authored-by: Taym Haddadi <haddadi.taym@gmail.com>
This commit is contained in:
parent
a1ecce5502
commit
8a3f62933b
9 changed files with 205 additions and 80 deletions
|
@ -34,7 +34,8 @@ DOMInterfaces = {
|
|||
|
||||
'Blob': {
|
||||
'weakReferenceable': True,
|
||||
'canGc': ['Slice', 'Text', 'ArrayBuffer', 'Stream'],
|
||||
'canGc': ['Slice', 'Text', 'ArrayBuffer', 'Stream', 'Bytes'],
|
||||
'inRealms': ['Bytes'],
|
||||
},
|
||||
|
||||
'Bluetooth': {
|
||||
|
|
|
@ -20,6 +20,7 @@ interface Blob {
|
|||
[NewObject, Throws] ReadableStream stream();
|
||||
[NewObject] Promise<DOMString> text();
|
||||
[NewObject] Promise<ArrayBuffer> arrayBuffer();
|
||||
[NewObject] Promise<Uint8Array> bytes();
|
||||
};
|
||||
|
||||
dictionary BlobPropertyBag {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue