Improve sublime arm name indexing.

The previous definition included the leading ++ in the
indexed name, which thwarts "Goto Definition". This also
tweaks the pattern to include arms defined with +-.
This commit is contained in:
Dan Haffey 2015-11-14 10:57:43 -08:00 committed by Raymond Pasco
parent 7481ff553a
commit d93489838d
2 changed files with 8 additions and 5 deletions

View File

@ -32,8 +32,9 @@ patterns:
name: constant.character.hoon
match: "[a-z]([a-z0-9-]*[a-z0-9])?/"
- comment: arm
name: entity.name.function.hoon
match: "\\+\\+ [a-z]([a-z0-9-]*[a-z0-9])?"
contentName: entity.name.function.hoon
begin: "\\+[-+] (?=[a-z]([a-z0-9-]*[a-z0-9])?)"
end: "(?![a-z0-9-])"
- comment: cube
name: constant.character.hoon
match: "%[a-z]([a-z0-9-]*[a-z0-9])?"

View File

@ -84,12 +84,14 @@
<string>constant.character.hoon</string>
</dict>
<dict>
<key>begin</key>
<string>\+[-+] (?=[a-z]([a-z0-9-]*[a-z0-9])?)</string>
<key>comment</key>
<string>arm</string>
<key>match</key>
<string>\+\+ [a-z]([a-z0-9-]*[a-z0-9])?</string>
<key>name</key>
<key>contentName</key>
<string>entity.name.function.hoon</string>
<key>end</key>
<string>(?![a-z0-9-])</string>
</dict>
<dict>
<key>comment</key>