mirror of
https://github.com/vercel-labs/scriptc.git
synced 2026-11-10 01:56:15 +08:00
A local initialized from a typed-array field or parameter, such as `const chars = this.chars`, took a reference and released it at the end of its block, like any owned binding. Class instances, records, arrays and strings already borrow such a projection when the rest of the block writes none of the locations it reads, and walk and rebound parameters use the same test. Typed arrays are one plain pointer as well, so they now take the same paths: the field or the caller's binding keeps the array alive while the local reads it, and a block that may replace the field still retains its own reference.