-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathAdept.sublime-syntax
More file actions
52 lines (51 loc) · 2.1 KB
/
Adept.sublime-syntax
File metadata and controls
52 lines (51 loc) · 2.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
%YAML 1.2
---
name: Adept
file_extensions: [adept]
scope: source.adept
contexts:
main:
- match: \b(POD|alias|and|as|at|break|case|cast|continue|def|default|defer|delete|each|else|enum|external|fallthrough|for|foreign|func|funcptr|global|if|import|in|inout|new|or|out|packed|private|public|repeat|return|sizeof|static|stdcall|struct|switch|typeinfo|unless|until|while|va_start|va_end|va_copy|va_arg|verbatim|void|union|exhaustive|const|define|namespace|using|implicit|pragma|elif|llvm_asm|thread_local|typenameof|embed|alignof|record|constructor|class|virtual|override|extends|assert)\b
scope: keyword.control.adept
- match: \b(true|false|null|undef|this|it|idx)\b
scope: constant.language.adept
- match: \b([A-Z_][A-Z0-9_]*)\b
scope: entity.name.function.preprocessor.adept
- match: \$(~)?[a-zA-Z_][a-zA-Z0-9_]*(\~[a-zA-Z_][a-zA-Z0-9_]*)?\b
scope: support.type.polymorphic.adept
- match: \$#[a-zA-Z_][a-zA-Z0-9_]*\b
scope: constant.numeric.adept
- match: \b(bool|ptr|byte|ubyte|short|ushort|int|uint|long|ulong|usize|double|float|String|List|Array|Matrix4f|Vector3f|FILE|va_list|successful)\b
scope: support.type.adept
- match: \#[a-zA-Z_]*\b
scope: keyword.control.meta-directive.adept
- match: \"
push: double_quote_string
- match: \'
push: single_quote_string
- match: \'(\\\\)?.\'ub
scope: string.quoted.character.adept
- match: \b((0x[0-9A-Fa-f]+)|([0-9]+(\\.[0-9]+)?))(u|s|ub|sb|us|ss|ui|si|ul|sl|uz|f|d)?\b
scope: constant.numeric.adept
- match: //.*\n?$
scope: comment.line.double-slash.adept
- match: /\*
push: multiline_comment
double_quote_string:
- meta_scope: string.quoted.double.adept
- match: \\.
scope: constant.character.escape.adept
- match: '"'
pop: true
single_quote_string:
- meta_scope: string.quoted.single.adept
- match: \\.
scope: constant.character.escape.adept
- match: \'(ub)?
pop: true
multiline_comment:
- meta_scope: comment.block.adept
- match: \\.
scope: comment.line.block.adept
- match: \*/
pop: true