Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'runtime/queries/rust/highlights.scm')
-rw-r--r--runtime/queries/rust/highlights.scm49
1 files changed, 49 insertions, 0 deletions
diff --git a/runtime/queries/rust/highlights.scm b/runtime/queries/rust/highlights.scm
index 7997c5ea..2981075f 100644
--- a/runtime/queries/rust/highlights.scm
+++ b/runtime/queries/rust/highlights.scm
@@ -56,6 +56,55 @@
(identifier) @label)
; ---
+; Prelude
+; ---
+
+((identifier) @type.enum.variant.builtin
+ (#any-of? @type.enum.variant.builtin "Some" "None" "Ok" "Err"))
+
+
+
+((type_identifier) @type.builtin
+ (#any-of?
+ @type.builtin
+ "Send"
+ "Sized"
+ "Sync"
+ "Unpin"
+ "Drop"
+ "Fn"
+ "FnMut"
+ "FnOnce"
+ "AsMut"
+ "AsRef"
+ "From"
+ "Into"
+ "DoubleEndedIterator"
+ "ExactSizeIterator"
+ "Extend"
+ "IntoIterator"
+ "Iterator"
+ "Option"
+ "Result"
+ "Clone"
+ "Copy"
+ "Debug"
+ "Default"
+ "Eq"
+ "Hash"
+ "Ord"
+ "PartialEq"
+ "PartialOrd"
+ "ToOwned"
+ "Box"
+ "String"
+ "ToString"
+ "Vec"
+ "FromIterator"
+ "TryFrom"
+ "TryInto"))
+
+; ---
; Punctuation
; ---