Skip to content

Preserve newlines in between comments from #326#327

Merged
JohnnyMorganz merged 3 commits into
masterfrom
table-comments-2
Jan 1, 2022
Merged

Preserve newlines in between comments from #326#327
JohnnyMorganz merged 3 commits into
masterfrom
table-comments-2

Conversation

@JohnnyMorganz
Copy link
Copy Markdown
Owner

Continued from #326

I tested this in a real-world project and realised that the change would stop preserving newlines in between comments, which is an issue as some comment groups may be unrelated.

This fixes this, by not doing anything special to the leading trivia, and only working with the trailing trivia. As a bonus, it greatly simplifies the code!

@JohnnyMorganz JohnnyMorganz merged commit 8d3c7df into master Jan 1, 2022
@JohnnyMorganz JohnnyMorganz deleted the table-comments-2 branch January 1, 2022 22:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant