updatePosition
Moves the write cursor, for the caller that has to go back and rewrite something it already emitted.
Nothing is cleared, so moving backwards leaves the bytes beyond newPosition in the buffer to be overwritten or abandoned.
Parameters
newPosition
The offset to continue writing at.