outputStream.count == 1, but outputStream.count - 1 == 0, thus resulting in a range error where the starting value is 1 and the ending value of the range is 0.
See line 1074
Repro:
In Ink story, use a function in your story, call it via a choice and watch the values of functionStartPoint and outputStream.count equal each other, resulting in a) range error after outputStream.count - 1 or b) index out of range error on next line (hit by removing the minus one operation on outputStream.count).