mirror of
https://github.com/open-source-parsers/jsoncpp.git
synced 2025-10-14 23:07:55 +02:00
Removed unneeded newlines from parsed comments
Newlines from comments separated by lines are retained when comments are appended, so adding a newline between separate comments for a node is not needed.
This commit is contained in:
@@ -358,8 +358,6 @@ Reader::addComment(Location begin, Location end, CommentPlacement placement) {
|
||||
assert(lastValue_ != 0);
|
||||
lastValue_->setComment(std::string(begin, end), placement);
|
||||
} else {
|
||||
if (!commentsBefore_.empty())
|
||||
commentsBefore_ += "\n";
|
||||
commentsBefore_ += std::string(begin, end);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user