forked from illnr/vscode-fanuc-karel
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcm.tmLanguage.json
72 lines (70 loc) · 1.54 KB
/
cm.tmLanguage.json
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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
{
"name": "CM Visual Studio",
"scopeName": "source.CM",
"fileType": ["CM"],
"patterns": [
{
"comment": "Karel system",
"match": "(?i)\\B(\\${1}\\w+)\\b",
"captures": {
"1": { "name": "system.variable.CM" }
}
},
{
"comment": "Karel program control",
"match": "(?i)\\b(PRINT|DELPC|PCLOAD|RUNPC|DELTP|TPLOAD)\\b",
"captures": {
"1": { "name": "keyword.program.control.CM" }
}
},
{
"comment": "Karel file control",
"match": "(?i)\\b(PCVLOAD|TXPLOAD|ASLOAD|PCCLEAR|DELFR|DEL|VRLOAD|VRCLEAR|FRCOPY|COPY|WR_FILE)\\b",
"captures": {
"1": { "name": "keyword.file.control.CM" }
}
},
{
"comment": "Karel other control",
"match": "(?i)\\b(CLRALMH|DELAY|EXIT|IGALBKUP|SPEP_ON|SPEP_OFF|RE_POWER|ABORT|MKDIR|FRSETPR|FRCLRPR)\\b",
"captures": {
"1": { "name": "keyword.other.control.CM" }
}
},
{
"comment": "KCL Command",
"match": "(?i)\\b(SETVAR|SETIOVAL)\\b",
"captures": {
"1": { "name": "keyword.kcl.command.CM"}
}
},
{
"comment": "CM String",
"match": "(\"([^\"])*\")",
"captures": {
"1": { "name": "type.string.CM"}
}
},
{
"comment": "CM Comment",
"match":"(!.*)$",
"captures": {
"1": { "name": "type.comment.CM"}
}
},
{
"comment": "CM Operator",
"match":"(<|<=|=|<>|>=|>|\\[|\\]|\\(|\\)|\\+)",
"captures": {
"1": { "name": "type.operator.CM"}
}
},
{
"comment": "CM @ Operator",
"match":"(@.*)$",
"captures": {
"1": { "name": "type.operator.callfunction.CM"}
}
}
]
}