as for workaround there is E.toArrayBuffer so maybe it could work on <64K substring so you could access big string in 64KB chunks as array.
EDIT: I just tested it in RAM, hopefully it will work fine with flash strings too.
s="".padEnd(65536) // 64K of spaces
s=s.padEnd(65540,'a') // pad with few 'a' over 64KB
=new Uint8Array([32, 97, 97, 97, 97]).buffer
>E.toArrayBuffer(s) // this fails due to 64KB limit
=new Uint8Array([32, 32, 32, 32]).buffer
© Espruino, powered by microcosm.
Report a problem