diff options
author | Kartik Agaram <vc@akkartik.com> | 2021-11-08 18:49:15 -0800 |
---|---|---|
committer | Kartik Agaram <vc@akkartik.com> | 2021-11-08 18:49:15 -0800 |
commit | 2bac01fb7b4e43a2f7e707b7848d1b925d598cda (patch) | |
tree | ee776cf03a887b5e341d12f250175e55dc148250 /editor/VSCode/syntaxes | |
parent | 11a191c2906fbaa2d80192da833b727984cf8f94 (diff) | |
download | mu-2bac01fb7b4e43a2f7e707b7848d1b925d598cda.tar.gz |
syntax highlighting for Visual Studio Code
Diffstat (limited to 'editor/VSCode/syntaxes')
-rw-r--r-- | editor/VSCode/syntaxes/Mu.tmLanguage | 96 |
1 files changed, 96 insertions, 0 deletions
diff --git a/editor/VSCode/syntaxes/Mu.tmLanguage b/editor/VSCode/syntaxes/Mu.tmLanguage new file mode 100644 index 00000000..64f71320 --- /dev/null +++ b/editor/VSCode/syntaxes/Mu.tmLanguage @@ -0,0 +1,96 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> +<plist version="1.0"> +<dict> + <key>fileTypes</key> + <array> + <string>mu</string> + </array> + <key>name</key> + <string>Mu</string> + <key>patterns</key> + <array> + <dict> + <key>match</key> + <string>#.*</string> + <key>name</key> + <string>comment.line.mu</string> + </dict> + <dict> + <key>match</key> + <string> <- </string> + <key>name</key> + <string>meta.operator.mu</string> + </dict> + <dict> + <key>match</key> + <string>\b(return|break[^ ]*|loop[^ ]*)</string> + <key>name</key> + <string>keyword.control.mu</string> + </dict> + <dict> + <key>match</key> + <string>\b[^ ]*:\b</string> + <key>name</key> + <string>constant.other.label.mu</string> + </dict> + <dict> + <key>match</key> + <string>^fn|->\b</string> + <key>name</key> + <string>meta.function.mu</string> + </dict> + <dict> + <key>match</key> + <string>\bvar\b</string> + <key>name</key> + <string>storage.type.var.mu</string> + </dict> + <dict> + <key>match</key> + <string>\b(addr|array|boolean|byte|code-point|grapheme|handle|int|float|stream|type)\b</string> + <key>name</key> + <string>storage.type.mu</string> + </dict> + <dict> + <key>begin</key> + <string>"</string> + <key>end</key> + <string>"</string> + <key>name</key> + <string>string.quoted.double.mu</string> + <key>patterns</key> + <array> + <dict> + <key>match</key> + <string>\.</string> + <key>name</key> + <string>constant.character.escape</string> + </dict> + </array> + </dict> + <dict> + <key>match</key> + <string>\b(0x\h+|[0-9])\b</string> + <key>name</key> + <string>constant.numeric.integer.mu</string> + </dict> + <dict> + <key>match</key> + <string>\b([0-9][0-9a-f]+)\b</string> + <key>name</key> + <string>invalid.illegal.constant.numeric</string> + </dict> + <dict> + <key>match</key> + <string>\b([0-9a-zA-Z][0-9a-zA-Z])\b</string> + <key>name</key> + <string>invalid.illegal.constant.numeric</string> + </dict> + </array> + <key>scopeName</key> + <string>source.mu</string> + <key>uuid</key> + <string>766C3FEA-ED70-4B61-B17B-79E6ECE54036</string> +</dict> +</plist> |