aboutsummaryrefslogtreecommitdiff
path: root/plugins/language_wren.lua
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/language_wren.lua')
-rw-r--r--plugins/language_wren.lua34
1 files changed, 18 insertions, 16 deletions
diff --git a/plugins/language_wren.lua b/plugins/language_wren.lua
index 593cd46..35b8b8a 100644
--- a/plugins/language_wren.lua
+++ b/plugins/language_wren.lua
@@ -7,23 +7,25 @@ syntax.add {
comment = "//",
block_comment = {"/*", "*/"},
patterns = {
- { pattern = "//.-\n", type = "comment" },
- { pattern = { "/%*", "%*/" }, type = "comment" },
- { pattern = { '"', '"', '\\' }, type = "string" },
- { pattern = "%d+%.%d+[Ee]%d+", type = "number" },
- { pattern = "%d+%.%d+", type = "number" },
- { pattern = "%d+[Ee]%d+", type = "number" },
- { pattern = "0x%x+", type = "number" },
- { pattern = "%d+", type = "number" },
- { pattern = "%.%.%.?", type = "operator" },
- { pattern = "[<>!=]=", type = "operator" },
- { pattern = "|[^|]+|%s+", type = "string" },
- { pattern = "[%+%-=/%*%^%%<>!~|&?:]", type = "operator" },
- { pattern = "_[%w_]*", type = "keyword2" },
+ { pattern = "//.-\n", type = "comment" },
+ { pattern = { "/%*", "%*/" }, type = "comment" },
+ { pattern = { '"', '"', '\\' }, type = "string" },
+ { pattern = "%d+%.%d+[Ee]%d+", type = "number" },
+ { pattern = "%d+%.%d+", type = "number" },
+ { pattern = "%d+[Ee]%d+", type = "number" },
+ { pattern = "0x%x+", type = "number" },
+ { pattern = "%d+", type = "number" },
+ { pattern = "%.%.%.?", type = "operator" },
+ { pattern = "[<>!=]=", type = "operator" },
+ { pattern = "|[^|]+|%s+", type = "string" },
+ { pattern = "[%+%-=/%*%^%%<>!~|&?:]", type = "operator" },
+ { pattern = "_[%w_]*", type = "keyword2" },
+ { regex = [[\bFn.new\b]], type = "literal" },
+ { pattern = "#!?%a[%w_]*%s*%(?[%w _,\"=]*%)?", type = "comment" },
{ pattern = "%a[%w_]*()%s+()is()%s+%a[%w_]*%s*%f[{]", type = {"function", "normal", "keyword", "normal"}},
- { pattern = "%a[%w_]*%s*=()%s*%f[(]", type = {"function", "normal"} },
- { pattern = "%a[%w_]*()%s*%f[({]", type = {"function", "normal"} },
- { pattern = "%a[%w_]+", type = "symbol" },
+ { pattern = "%a[%w_]*%s*=()%s*%f[(]", type = {"function", "normal"} },
+ { pattern = "%a[%w_]*()%s*%f[({]", type = {"function", "normal"} },
+ { pattern = "%a[%w_]+", type = "symbol" },
},
symbols = {
["break"] = "keyword",