I was about to create a PR for this, but maybe I should ask what people think.
erl_scan creates comment tokens up to a LF character. On Windows, this means that the comment includes a CR character at the end. This requires special handling when the tokens are manipulated outside erlang (by an editor, for example) because Erlang and the editor consider the end of the token to lie on different lines.
Is it meaningful to let erl_scan end comments before both CR and LF? The downside is that there will be an extra whitespace token for the CR between consecutive comments.