Permalink
Browse files

Minor enhancement, signature grammar: comments in signatures and gene…

…ral sigexp

git-svn-id: http://svn.textmate.org/trunk/Bundles/Standard ML.tmbundle@7845 dfb7d73b-c2ec-0310-8fea-fb051d288c6d
  • Loading branch information...
1 parent 3e62033 commit 88351a7a2008573031c6bd8c4f665a2fec22df0c @commonlisp commonlisp committed Jul 28, 2007
Showing with 81 additions and 24 deletions.
  1. +81 −24 Syntaxes/Standard ML.plist
View
@@ -29,7 +29,7 @@
</dict>
<dict>
<key>include</key>
- <string>#sigdecl</string>
+ <string>#basesig</string>
</dict>
<dict>
<key>match</key>
@@ -188,6 +188,35 @@
</array>
<key>repository</key>
<dict>
+ <key>basesig</key>
+ <dict>
+ <key>begin</key>
+ <string>\b(sig)\b</string>
+ <key>captures</key>
+ <dict>
+ <key>1</key>
+ <dict>
+ <key>name</key>
+ <string>keyword.other.delimiter.ml</string>
+ </dict>
+ <key>2</key>
+ <dict>
+ <key>name</key>
+ <string>keyword.other.delimiter.ml</string>
+ </dict>
+ </dict>
+ <key>end</key>
+ <string>\b(end)\b</string>
+ <key>name</key>
+ <string>meta.module.sigdec.ml</string>
+ <key>patterns</key>
+ <array>
+ <dict>
+ <key>include</key>
+ <string>#spec</string>
+ </dict>
+ </array>
+ </dict>
<key>comments</key>
<dict>
<key>patterns</key>
@@ -217,32 +246,27 @@
</dict>
</array>
</dict>
- <key>sigdecl</key>
+ <key>sigexp</key>
<dict>
- <key>begin</key>
- <string>\b(sig)\b</string>
- <key>captures</key>
- <dict>
- <key>1</key>
- <dict>
- <key>name</key>
- <string>keyword.other.delimiter.ml</string>
- </dict>
- <key>2</key>
+ <key>patterns</key>
+ <array>
<dict>
+ <key>captures</key>
+ <dict>
+ <key>1</key>
+ <dict>
+ <key>name</key>
+ <string>keyword.other.ml</string>
+ </dict>
+ </dict>
+ <key>match</key>
+ <string>\b(where type)\b</string>
<key>name</key>
- <string>keyword.other.delimiter.ml</string>
+ <string>meta.module.sigexp.ml</string>
</dict>
- </dict>
- <key>end</key>
- <string>\b(end)\b</string>
- <key>name</key>
- <string>meta.module.sigdec.ml</string>
- <key>patterns</key>
- <array>
<dict>
<key>include</key>
- <string>#spec</string>
+ <string>#basesig</string>
</dict>
</array>
</dict>
@@ -346,6 +370,10 @@
<string>meta.spec.ml.datatype</string>
<key>patterns</key>
<array>
+ <dict>
+ <key>include</key>
+ <string>#comments</string>
+ </dict>
<dict>
<key>captures</key>
<dict>
@@ -463,17 +491,35 @@
<array>
<dict>
<key>include</key>
- <string>#sigdecl</string>
+ <string>#comments</string>
+ </dict>
+ <dict>
+ <key>include</key>
+ <string>#basesig</string>
</dict>
<dict>
<key>match</key>
<string>\b(sharing)\b</string>
<key>name</key>
<string>keyword.other.ml</string>
</dict>
+ <dict>
+ <key>match</key>
+ <string>\b(where)\b</string>
+ <key>name</key>
+ <string>keyword.other.ml</string>
+ </dict>
+ <dict>
+ <key>match</key>
+ <string>\b(and)\b</string>
+ <key>name</key>
+ <string>keyword.other.ml</string>
+ </dict>
</array>
</dict>
<dict>
+ <key>begin</key>
+ <string>\b(include)\b</string>
<key>captures</key>
<dict>
<key>1</key>
@@ -482,10 +528,21 @@
<string>keyword.other.ml</string>
</dict>
</dict>
- <key>match</key>
- <string>\b(include)\b</string>
+ <key>end</key>
+ <string>(?=val|type|eqtype|datatype|structure|include|exception)</string>
<key>name</key>
<string>meta.spec.ml.include</string>
+ <key>patterns</key>
+ <array>
+ <dict>
+ <key>include</key>
+ <string>#sigexp</string>
+ </dict>
+ <dict>
+ <key>include</key>
+ <string>#comments</string>
+ </dict>
+ </array>
</dict>
<dict>
<key>include</key>

0 comments on commit 88351a7

Please sign in to comment.