Skip to content

Commit

Permalink
fix: overly loose recognition of comments
Browse files Browse the repository at this point in the history
Closes #9
  • Loading branch information
habamax committed Nov 10, 2021
1 parent d2af442 commit ff3b60d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions syntax/rst.vim
Original file line number Diff line number Diff line change
Expand Up @@ -173,10 +173,10 @@ syn cluster rstDirectives contains=rstFootnote,rstCitation,
\ rstHyperLinkTarget,rstLiteralBlock,rstQuotedLiteralBlock,
\ rstListItem,@rstTables

syn match rstComment /^\s*\.\./
syn match rstComment /^\s*\.\.\ze\s*$/

syn region rstComment
\ start='^\(\z(\s*\)\)\.\.\_s\?\s*\S'
\ start='^\(\z(\s*\)\)\.\.\_s\?\s\+\S'
\ skip='^\ze\z1\s\+\S'
\ end='^\ze\s*\S'
\ keepend
Expand Down

0 comments on commit ff3b60d

Please sign in to comment.