Skip to content
Snippets Groups Projects
Commit c6025498 authored by Jeremy Manson's avatar Jeremy Manson Committed by CQ bot account: commit-bot@chromium.org
Browse files

[fidlfmt] Fix bug in deleting blank lines.

Prior to this fix, if there were multiple blank lines following a
comment, the first one would get deleted because it needed to be
coalesced with the subsequent lines, and the subsequent lines would get
deleted because they were not next to a comment.  This would leave no
blank lines after a comment.

This was not caught by tests because we were only exercising it in the
case of an EOF.  In the EOF case, we don't want trailing newlines, so it
was the correct behavior.  The other cases where we had trailing newlines
after a comment (e.g., before const and enum) were special-cased to do the
right thing.

Change-Id: Ibba0e1ef7834cbe5a6e5af9c4e6faef837e724ea
parent d957d81b
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment