aboutsummaryrefslogtreecommitdiff
path: root/plugins/language_rust.lua
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/language_rust.lua')
-rw-r--r--plugins/language_rust.lua2
1 files changed, 2 insertions, 0 deletions
diff --git a/plugins/language_rust.lua b/plugins/language_rust.lua
index ac25305..a8dc017 100644
--- a/plugins/language_rust.lua
+++ b/plugins/language_rust.lua
@@ -2,6 +2,7 @@
local syntax = require "core.syntax"
syntax.add {
+ name = "Rust",
files = { "%.rs$" },
comment = "//",
patterns = {
@@ -15,6 +16,7 @@ syntax.add {
{ pattern = "-?%d+[%d%.eE]*f?", type = "number" },
{ pattern = "-?%.?%d+f?", type = "number" },
{ pattern = "[%+%-=/%*%^%%<>!~|&]", type = "operator" },
+ { pattern = "[%a_][%w_]*!%f[%[(]", type = "function" },
{ pattern = "[%a_][%w_]*%f[(]", type = "function" },
{ pattern = "[%a_][%w_]*", type = "symbol" },
},