mirror of
https://github.com/vercel-labs/scriptc.git
synced 2026-10-26 06:34:20 +08:00
@types/node types the transform/flush completion callback's data as any and a child stream 'data' chunk as any, and ChildProcess accepts (code: number, signal: string) exit and close listeners through its catch-all overload. None of these compiled: the any-typed completion callback crashed the LLVM emitter, and the child listeners were refused. The completion callback's data parameter is typed Buffer | string | undefined while the option callback lowers. Child stream 'data' listeners with an unknown or any chunk box it as a checked-dynamic value, taking strings when a setEncoding statement on the same stream precedes the listener and Buffers when the function never calls setEncoding on it; other placements are refused. Exit and close listener parameters declared number or string bind as checked-dynamic values, so the body sees the null Node passes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>