Improved handling of trailing document comments

This commit is contained in:
Mike Farah
2022-05-25 10:54:03 +10:00
parent dee592eb3b
commit 6bce23d9c2
9 changed files with 89 additions and 10 deletions
+4
View File
@@ -134,6 +134,10 @@ func (p *resultsPrinter) PrintResults(matchingNodes *list.List) error {
return err
}
if err := p.encoder.PrintLeadingContent(writer, mappedDoc.TrailingContent); err != nil {
return err
}
p.previousDocIndex = mappedDoc.Document
if err := writer.Flush(); err != nil {
return err