(method: string)
| 322 | ) |
| 323 | |
| 324 | const nodeWriteFactory = (method: string) => { |
| 325 | const write = effectify( |
| 326 | NFS.write, |
| 327 | handleErrnoException("FileSystem", method), |
| 328 | handleBadArgument(method) |
| 329 | ) |
| 330 | // Bun ignores `position` unless `offset` and `length` are given explicitly. |
| 331 | return (fd: number, buffer: Uint8Array, position: number | undefined) => |
| 332 | write(fd, buffer, 0, buffer.length, position) |
| 333 | } |
| 334 | const nodeWrite = nodeWriteFactory("write") |
| 335 | const nodeWriteAll = nodeWriteFactory("writeAll") |
| 336 |
no test coverage detected