1 ##############################################################################
2 # Swift syntax highlighting for Nano.
3 ##############################################################################
5 syntax "Swift" "\.swift$"
11 color yellow "[.:;,+*|=!?\%]" "<" ">" "/" "-" "&"
14 color magenta "(class|import|let|var|struct|enum|func|if|else|switch|case|default|for|in|internal|external|unowned|private|public|throws)\ "
15 color magenta "(prefix|postfix|operator|extension|lazy|get|set|self|willSet|didSet|override|super|convenience|weak|strong|mutating|return|guard)\ "
19 color magenta "(init)"
25 color brightmagenta "\ ((U)?Int(8|16|32|64))"
26 color brightmagenta "(true|false|nil)"
27 color brightmagenta "\ (Double|String|Float|Boolean|Dictionary|Array|Int)"
28 color magenta "\ (AnyObject)"
35 color brightgreen "///.*"
36 color green "(?s)/\*\*.*?\*/"
40 color ,green "[[:space:]]+$"