This is required for Auto Format compatibility because it has the undesirable effect of indenting only unindented contents of multi-lline comments, thus altering the relative indentation of the text.
The exception is the Max/MSP patches as I did not know whether indentation would break them.
In the example is stated that the function is run between one loop and the next, but actually the call to the function was missing.
The comment also state that the response can be delayed using a delay in the loop,so I think that the way it should be is so by only
adding a call to the function serialEvent as first operation in the loop. I so added this call.