Skip to content

Commit a131cac

Browse files
🤖 Pick PR #62351 (Add missing Float16Array constructo...) into release-5.9 (#62426)
Co-authored-by: Greggman <github@greggman.com>
1 parent 0424333 commit a131cac

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

‎src/lib/esnext.float16.d.ts‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -356,6 +356,8 @@ interface Float16ArrayConstructor {
356356
new (length?: number): Float16Array<ArrayBuffer>;
357357
new (array: ArrayLike<number> | Iterable<number>): Float16Array<ArrayBuffer>;
358358
new <TArrayBuffer extends ArrayBufferLike = ArrayBuffer>(buffer: TArrayBuffer, byteOffset?: number, length?: number): Float16Array<TArrayBuffer>;
359+
new (buffer: ArrayBuffer, byteOffset?: number, length?: number): Float16Array<ArrayBuffer>;
360+
new (array: ArrayLike<number> | ArrayBuffer): Float16Array<ArrayBuffer>;
359361

360362
/**
361363
* The size in bytes of each element in the array.

‎tests/cases/compiler/typedArrayConstructorOverloads.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ type TypedArrayConstructor =
1212
| Uint16ArrayConstructor
1313
| Int32ArrayConstructor
1414
| Uint32ArrayConstructor
15+
| Float16ArrayConstructor
1516
| Float32ArrayConstructor
1617
| Float64ArrayConstructor
1718
| BigInt64ArrayConstructor

0 commit comments

Comments
 (0)