repochecker/grammalecte: Write new line only on paragraph exit

This commit is contained in:
nemunaire 2022-11-24 15:39:36 +01:00
parent ea02fa4617
commit ccc2c5d1d7

View file

@ -37,7 +37,10 @@ func (r *VoidRenderer) Errors() []error {
} }
func (r *VoidRenderer) renderParagraph(w util.BufWriter, source []byte, n ast.Node, entering bool) (ast.WalkStatus, error) { func (r *VoidRenderer) renderParagraph(w util.BufWriter, source []byte, n ast.Node, entering bool) (ast.WalkStatus, error) {
if !entering {
_, _ = w.WriteString("\n") _, _ = w.WriteString("\n")
}
return ast.WalkContinue, nil return ast.WalkContinue, nil
} }