Skip to content

Commit

Permalink
feat(parser): support spaces and tabs ahead of single line comment (#289
Browse files Browse the repository at this point in the history
)

fixes #288

Signed-off-by: Xavier Coulon <[email protected]>
  • Loading branch information
xcoulon authored Feb 11, 2019
1 parent f7ee178 commit 061eb82
Show file tree
Hide file tree
Showing 3 changed files with 10,347 additions and 10,150 deletions.
2 changes: 1 addition & 1 deletion pkg/parser/asciidoc-grammar.peg
Original file line number Diff line number Diff line change
Expand Up @@ -1166,7 +1166,7 @@ CommentBlockLine <- (Alphanums / Spaces / (!CommentBlockDelimiter !EOL .){
return string(c.text), nil
}

SingleLineComment <- !CommentBlockDelimiter "//" content:(SingleLineCommentContent) EOL {
SingleLineComment <- !CommentBlockDelimiter WS* "//" content:(SingleLineCommentContent) EOL {
return types.NewSingleLineComment(content.(string))
}

Expand Down
Loading

0 comments on commit 061eb82

Please sign in to comment.