v.doc: use the .parse_comments mode, instead of the older .toplevel_comments (the scanner/parser is now more robust)

pull/13389/head
Delyan Angelov 2022-02-06 23:49:21 +02:00
parent 649ecab11f
commit 191e99c248
No known key found for this signature in database
GPG Key ID: 66886C0F12D595ED
1 changed files with 1 additions and 1 deletions

View File

@ -429,7 +429,7 @@ pub fn (mut d Doc) generate() ? {
// parse files // parse files
mut comments_mode := scanner.CommentsMode.skip_comments mut comments_mode := scanner.CommentsMode.skip_comments
if d.with_comments { if d.with_comments {
comments_mode = .toplevel_comments comments_mode = .parse_comments
} }
mut file_asts := []ast.File{} mut file_asts := []ast.File{}
for i, file_path in v_files { for i, file_path in v_files {