Skip to content

Commit

Permalink
Handle dollar slashy strings, and also interpolations in slashy strings.
Browse files Browse the repository at this point in the history
  • Loading branch information
mparry committed Feb 16, 2018
1 parent 6f903ca commit deb5faa
Showing 1 changed file with 90 additions and 39 deletions.
129 changes: 90 additions & 39 deletions Syntaxes/Groovy.tmLanguage
Original file line number Diff line number Diff line change
Expand Up @@ -1629,6 +1629,47 @@
<key>name</key>
<string>constant.character.escape.groovy</string>
</dict>
<dict>
<key>include</key>
<string>#string-embedded-interpolations</string>
</dict>
</array>
</dict>
<dict>
<key>begin</key>
<string>\$/</string>
<key>beginCaptures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>punctuation.definition.string.regexp.begin.groovy</string>
</dict>
</dict>
<key>end</key>
<string>/\$</string>
<key>endCaptures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>punctuation.definition.string.regexp.end.groovy</string>
</dict>
</dict>
<key>name</key>
<string>string.regexp.dollarslashy.groovy</string>
<key>patterns</key>
<array>
<dict>
<key>match</key>
<string>\$(?:\$|/|\$\$/|/\$\$)</string>
<key>name</key>
<string>constant.character.escape.groovy</string>
</dict>
<dict>
<key>include</key>
<string>#string-embedded-interpolations</string>
</dict>
</array>
</dict>
<dict>
Expand Down Expand Up @@ -1696,48 +1737,10 @@
</dict>
</array>
</dict>
<key>string-quoted-double</key>
<key>string-embedded-interpolations</key>
<dict>
<key>begin</key>
<string>"</string>
<key>beginCaptures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>punctuation.definition.string.begin.groovy</string>
</dict>
</dict>
<key>end</key>
<string>"</string>
<key>endCaptures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>punctuation.definition.string.end.groovy</string>
</dict>
</dict>
<key>name</key>
<string>string.quoted.double.groovy</string>
<key>patterns</key>
<array>
<dict>
<key>include</key>
<string>#string-quoted-double-contents</string>
</dict>
</array>
</dict>
<key>string-quoted-double-contents</key>
<dict>
<key>patterns</key>
<array>
<dict>
<key>match</key>
<string>\\.</string>
<key>name</key>
<string>constant.character.escape.groovy</string>
</dict>
<dict>
<key>applyEndPatternLast</key>
<integer>1</integer>
Expand Down Expand Up @@ -1788,6 +1791,54 @@
</dict>
</array>
</dict>
<key>string-quoted-double</key>
<dict>
<key>begin</key>
<string>"</string>
<key>beginCaptures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>punctuation.definition.string.begin.groovy</string>
</dict>
</dict>
<key>end</key>
<string>"</string>
<key>endCaptures</key>
<dict>
<key>0</key>
<dict>
<key>name</key>
<string>punctuation.definition.string.end.groovy</string>
</dict>
</dict>
<key>name</key>
<string>string.quoted.double.groovy</string>
<key>patterns</key>
<array>
<dict>
<key>include</key>
<string>#string-quoted-double-contents</string>
</dict>
</array>
</dict>
<key>string-quoted-double-contents</key>
<dict>
<key>patterns</key>
<array>
<dict>
<key>match</key>
<string>\\.</string>
<key>name</key>
<string>constant.character.escape.groovy</string>
</dict>
<dict>
<key>include</key>
<string>#string-embedded-interpolations</string>
</dict>
</array>
</dict>
<key>string-quoted-double-multiline</key>
<dict>
<key>begin</key>
Expand Down

0 comments on commit deb5faa

Please sign in to comment.