docgen: improve alignment of comments (still not perfect) (#15506)

* docgen: improve alignment of comments (still not perfect)

* fix error message text in `tunknown_named_parameter`

Co-authored-by: narimiran <narimiran@disroot.org>
This commit is contained in:
Andreas Rumpf 2020-10-07 14:39:13 +02:00 • committed by GitHub
commit 3b901d1e36
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 9 additions and 8 deletions

View file

@ -183,9 +183,9 @@ proc put(g: var TSrcGen, kind: TokType, s: string; sym: PSym = nil) =
addPendingNL(g)
if s.len > 0:
addTok(g, kind, s, sym)
inc(g.lineLen, s.len)
else:
g.pendingWhitespace = s.len
inc(g.lineLen, s.len)
proc putComment(g: var TSrcGen, s: string) =
if s.len == 0: return