]> git.codecow.com Git - nano25519.git/commitdiff
Simplify doc comment.
authorChris Duncan <chris@codecow.com>
Sat, 10 Oct 2026 09:39:42 +0000 (02:39 -0700)
committerChris Duncan <chris@codecow.com>
Sat, 10 Oct 2026 09:39:42 +0000 (02:39 -0700)
src/lib/primordials.ts

index 74daa80eeec171d593fe20ff928397928f4867c5..78bb4938fde1f371c46b22a653502bc40d843c1f 100644 (file)
@@ -128,14 +128,7 @@ export function isBytes (a: unknown): a is Bytes {
 /** Checks system endianness. Returns true if little-endian, else false. */
 export const isLE = new Bytes(getBuffer(new Words([1])))[0] === 1
 
-/**
- * Sets `array[index] = value` as an element the array owns. Assignment, `push`
- * and `fill` all store through the prototype chain when the index is not yet
- * defined, and call any setter found there instead, so an accessor added to
- * `Array.prototype` after load could swallow the write and answer every read.
- * The descriptor has no prototype, so a `get` or `set` added to
- * `Object.prototype` cannot make it look like an accessor.
- */
+/** Sets `array[index] = value`, avoiding prototypes and getters/setters. */
 export function slot<T> (array: T[], index: number, value: T): void {
        const descriptor = ObjectCreate(null)
        descriptor.value = value