Skip to content

Commit 7db1006

Browse files
authored
fix: Generalize TypedArray#set (#2388)
1 parent 6ca63c7 commit 7db1006

File tree

5 files changed

+3381
-3532
lines changed

5 files changed

+3381
-3532
lines changed

std/assembly/index.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1666,7 +1666,7 @@ declare abstract class TypedArray<T> implements ArrayBufferView {
16661666
/** The join() method joins all elements of an array into a string. This method has the same algorithm as Array.prototype.join(). */
16671667
join(separator?: string): string;
16681668
/** The set() method stores multiple values in the typed array, reading input values from a specified array. */
1669-
set<U extends ArrayBufferView>(source: U, offset?: i32): void
1669+
set<U extends ArrayLike<number>>(source: U, offset?: i32): void
16701670
/** The toString() method returns a string representing the specified array and its elements. This method has the same algorithm as Array.prototype.toString() */
16711671
toString(): string;
16721672
}

0 commit comments

Comments
 (0)