Parser exception on incomplete "search" keyword
btheado opened this issue · comments
Code block with typo on the search keyword:
searc
results in parser exception:
Cannot read property 'length' of undefined
Yep! Turns out the problem had the same underlying cause. For a class of errors that rendered the rest of the document unparsable, there was no token after to use for position information, which let NaN's into the system that generally wreaked havoc on error reporting. I added sanity checks in #848 to turn that case into "mark the whole block as the error".