fix a couple of asserts missed in the recent audit
Dependencies
- [2]
G3DLS5OUaudit all asserts - [3]
MP2TBKU6bugfix: crash in Text.up() after return - [4]
LF7BWEG4group all editor globals - [5]
IFTYOERMline.y -> line_cache.starty in a few more places - [6]
QCPXQ2E3add state arg to a few functions - [7]
KKMFQDR4editing source code from within the app - [8]
73OCE2MCafter much struggle, a brute-force undo - [9]
GGWAHCLEminor cleanup and a todo for later - [*]
BULPIBEGbeginnings of a module for the text editor
Change contents
- edit in undo.lua at line 68
print(line.mode) - replacement in text.lua at line 915
print(pos1, #s, s)assert(false, ('Text.offset(%d) called on a string of length %d (byte size %d); this is likely a failure to handle utf8\n\n^%s$\n'):format(pos1, utf8.len(s), #s, s)) - edit in text.lua at line 917
assert(result, "Text.offset returned nil; this is likely a failure to handle utf8") - replacement in source_text.lua at line 977
print(pos1, #s, s)assert(false, ('Text.offset(%d) called on a string of length %d (byte size %d); this is likely a failure to handle utf8\n\n^%s$\n'):format(pos1, utf8.len(s), #s, s)) - edit in source_text.lua at line 979
assert(result, "Text.offset returned nil; this is likely a failure to handle utf8")