Skip to content

Commit

Permalink
Second try to fix #20
Browse files Browse the repository at this point in the history
Nested comments break syntax highlighting
  • Loading branch information
jacob-carlborg committed Nov 11, 2020
1 parent 9e9aa3d commit e031d03
Showing 1 changed file with 31 additions and 21 deletions.
52 changes: 31 additions & 21 deletions Syntaxes/D.tmLanguage
Original file line number Diff line number Diff line change
Expand Up @@ -1150,27 +1150,8 @@
<string>comment.block.d</string>
</dict>
<dict>
<key>begin</key>
<string>/\+</string>
<key>captures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>punctuation.definition.comment.d</string>
</dict>
</dict>
<key>end</key>
<string>\+/</string>
<key>name</key>
<string>comment.block.nested.d</string>
<key>patterns</key>
<array>
<dict>
<key>include</key>
<string>$self</string>
</dict>
</array>
<key>include</key>
<string>#nested_comment</string>
</dict>
<dict>
<key>begin</key>
Expand Down Expand Up @@ -1264,6 +1245,35 @@
<key>name</key>
<string>meta.modifier.d</string>
</dict>
<key>nested_comment</key>
<dict>
<key>patterns</key>
<array>
<dict>
<key>begin</key>
<string>/\+</string>
<key>captures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>punctuation.definition.comment.d</string>
</dict>
</dict>
<key>end</key>
<string>\+/</string>
<key>name</key>
<string>comment.block.nested.d</string>
<key>patterns</key>
<array>
<dict>
<key>include</key>
<string>#nested_comment</string>
</dict>
</array>
</dict>
</array>
</dict>
<key>regular_expressions</key>
<dict>
<key>comment</key>
Expand Down

0 comments on commit e031d03

Please sign in to comment.