abl-tmlanguage 1.3.18 → 1.3.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +12 -0
- package/abl.tmLanguage.json +17 -11
- package/package.json +1 -1
- package/spec/db-table-and-field/find-record.spec.js +67 -0
- package/spec/define-buffer/create-buffer.spec.js +45 -0
- package/spec/define-variable/var-statement.spec.js +33 -0
- package/spec/misc-statements/do-in-name.spec.js +2 -1
- package/spec/type-name/define-class.spec.js +89 -2
- package/spec/type-name/using.spec.js +32 -0
- package/azure-pipelines.yml +0 -28
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,15 @@
|
|
|
1
|
+
1.3.20
|
|
2
|
+
======
|
|
3
|
+
|
|
4
|
+
- 🐛 Fix lookbehinds
|
|
5
|
+
- ✨ Add operator scopes to function arguments
|
|
6
|
+
|
|
7
|
+
1.3.19
|
|
8
|
+
======
|
|
9
|
+
|
|
10
|
+
- ✨ Support comments in USING statements; improve class definition
|
|
11
|
+
- ✨ Improve scoping for CREATE BUFFER statement
|
|
12
|
+
|
|
1
13
|
1.3.18
|
|
2
14
|
======
|
|
3
15
|
|
package/abl.tmLanguage.json
CHANGED
|
@@ -870,7 +870,7 @@
|
|
|
870
870
|
},
|
|
871
871
|
"using": {
|
|
872
872
|
"name": "meta.using.abl",
|
|
873
|
-
"begin": "
|
|
873
|
+
"begin": "\\s*([Uu][Ss][Ii][Nn][Gg])\\s*",
|
|
874
874
|
"beginCaptures": {
|
|
875
875
|
"1": {
|
|
876
876
|
"name": "keyword.other.abl"
|
|
@@ -893,7 +893,7 @@
|
|
|
893
893
|
}
|
|
894
894
|
},
|
|
895
895
|
{
|
|
896
|
-
"match": "
|
|
896
|
+
"match": "\\s*([Ff][Rr][Oo][Mm]|[Pp][Rr][Oo][Pp][Aa][Tt][Hh]|[Aa][Ss][Ss][Ee][Mm][Bb][Ll][Yy])\\s*",
|
|
897
897
|
"captures": {
|
|
898
898
|
"1": {
|
|
899
899
|
"name": "keyword.other.abl"
|
|
@@ -902,6 +902,9 @@
|
|
|
902
902
|
},
|
|
903
903
|
{
|
|
904
904
|
"include": "#type-name"
|
|
905
|
+
},
|
|
906
|
+
{
|
|
907
|
+
"include": "#comment"
|
|
905
908
|
}
|
|
906
909
|
]
|
|
907
910
|
},
|
|
@@ -974,7 +977,7 @@
|
|
|
974
977
|
},
|
|
975
978
|
"patterns": [
|
|
976
979
|
{
|
|
977
|
-
"match": "(?i)\\
|
|
980
|
+
"match": "(?i)\\b(serializable|abstract|final|use-widget-pool|inherits|implements)\\b",
|
|
978
981
|
"captures": {
|
|
979
982
|
"1": {
|
|
980
983
|
"name": "keyword.other.abl"
|
|
@@ -1334,7 +1337,7 @@
|
|
|
1334
1337
|
]
|
|
1335
1338
|
},
|
|
1336
1339
|
"for-each-table": {
|
|
1337
|
-
"begin": "(?i)(?<=\\s
|
|
1340
|
+
"begin": "(?i)(?<=\\s|\\b|^)(for|(presel(?:ect|ec|e)?))[\\s+|$]",
|
|
1338
1341
|
"beginCaptures": {
|
|
1339
1342
|
"1": {
|
|
1340
1343
|
"name": "keyword.other.abl"
|
|
@@ -2345,7 +2348,7 @@
|
|
|
2345
2348
|
},
|
|
2346
2349
|
"create-buffer": {
|
|
2347
2350
|
"comment": "https://docs.progress.com/bundle/abl-reference/page/CREATE-BUFFER-statement.html",
|
|
2348
|
-
"begin": "(
|
|
2351
|
+
"begin": "\\s*([Cc][Rr][Ee][Aa][Tt][Ee])\\s+([Bb][Uu][Ff][Ff][Ee][Rr])\\b",
|
|
2349
2352
|
"beginCaptures": {
|
|
2350
2353
|
"1": {
|
|
2351
2354
|
"name": "keyword.other.abl"
|
|
@@ -2354,7 +2357,7 @@
|
|
|
2354
2357
|
"name": "keyword.other.abl"
|
|
2355
2358
|
}
|
|
2356
2359
|
},
|
|
2357
|
-
"end": "(?i)(
|
|
2360
|
+
"end": "(?i)(((buffer-n(?:ame|am|a)?)|in)\\b)|(?=\\.)",
|
|
2358
2361
|
"endCaptures": {
|
|
2359
2362
|
"1": {
|
|
2360
2363
|
"name": "keyword.other.abl"
|
|
@@ -2362,7 +2365,7 @@
|
|
|
2362
2365
|
},
|
|
2363
2366
|
"patterns": [
|
|
2364
2367
|
{
|
|
2365
|
-
"match": "(?i)\\s*(for|table)\\s*",
|
|
2368
|
+
"match": "(?i)\\s*(for|table|no-error)\\s*",
|
|
2366
2369
|
"captures": {
|
|
2367
2370
|
"1": {
|
|
2368
2371
|
"name": "keyword.other.abl"
|
|
@@ -2381,15 +2384,15 @@
|
|
|
2381
2384
|
{
|
|
2382
2385
|
"include": "#expression"
|
|
2383
2386
|
},
|
|
2384
|
-
{
|
|
2385
|
-
"include": "#keywords"
|
|
2386
|
-
},
|
|
2387
2387
|
{
|
|
2388
2388
|
"include": "#string"
|
|
2389
2389
|
},
|
|
2390
2390
|
{
|
|
2391
2391
|
"include": "#comment"
|
|
2392
2392
|
},
|
|
2393
|
+
{
|
|
2394
|
+
"include": "#preprocessor-reference"
|
|
2395
|
+
},
|
|
2393
2396
|
{
|
|
2394
2397
|
"include": "#handle-attributes"
|
|
2395
2398
|
},
|
|
@@ -3670,6 +3673,9 @@
|
|
|
3670
3673
|
{
|
|
3671
3674
|
"include": "#comment"
|
|
3672
3675
|
},
|
|
3676
|
+
{
|
|
3677
|
+
"include": "#operator"
|
|
3678
|
+
},
|
|
3673
3679
|
{
|
|
3674
3680
|
"include": "#array-literal"
|
|
3675
3681
|
},
|
|
@@ -4098,7 +4104,7 @@
|
|
|
4098
4104
|
}
|
|
4099
4105
|
},
|
|
4100
4106
|
"timestamp-constant": {
|
|
4101
|
-
"match": "(?i)(?<=^|\\s
|
|
4107
|
+
"match": "(?i)(?<=^|\\s|\\b)(today|now)(?!a-zA-Z0-9_\\-#$%|-)",
|
|
4102
4108
|
"comment": "These are constants that can be used in initial values. This excludes MTIME and ETIME",
|
|
4103
4109
|
"name": "constant.language.abl"
|
|
4104
4110
|
},
|
package/package.json
CHANGED
|
@@ -89,3 +89,70 @@ describe('', () => {
|
|
|
89
89
|
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
90
90
|
})
|
|
91
91
|
|
|
92
|
+
describe('', () => {
|
|
93
|
+
let statement = `FIND tt WHERE tt.f1 = "a"
|
|
94
|
+
AND (tt.f2 = "b" OR tt.f2 = "c")
|
|
95
|
+
AND tt.f3 = "d"
|
|
96
|
+
NO-LOCK NO-ERROR.`;
|
|
97
|
+
let expectedTokens = [
|
|
98
|
+
[
|
|
99
|
+
{ "startIndex": 0, "endIndex": 4, "scopes": ["source.abl", "keyword.other.abl"] }, // 'FIND'
|
|
100
|
+
{ "startIndex": 4, "endIndex": 5, "scopes": ["source.abl"] }, // ' '
|
|
101
|
+
{ "startIndex": 5, "endIndex": 7, "scopes": ["source.abl", "storage.data.table.abl"] }, // 'tt'
|
|
102
|
+
{ "startIndex": 7, "endIndex": 8, "scopes": ["source.abl"] }, // ' '
|
|
103
|
+
{ "startIndex": 8, "endIndex": 13, "scopes": ["source.abl", "keyword.other.abl"] }, // 'WHERE'
|
|
104
|
+
{ "startIndex": 13, "endIndex": 14, "scopes": ["source.abl"] }, // ' '
|
|
105
|
+
{ "startIndex": 14, "endIndex": 19, "scopes": ["source.abl", "storage.data.table.abl"] }, // 'tt.f1'
|
|
106
|
+
{ "startIndex": 19, "endIndex": 20, "scopes": ["source.abl"] }, // ' '
|
|
107
|
+
{ "startIndex": 20, "endIndex": 21, "scopes": ["source.abl", "keyword.operator.source.abl"] }, // '='
|
|
108
|
+
{ "startIndex": 21, "endIndex": 22, "scopes": ["source.abl"] }, // ' '
|
|
109
|
+
{ "startIndex": 22, "endIndex": 23, "scopes": ["source.abl", "string.quoted.double.abl", "punctuation.definition.string.begin.abl"] }, // '"'
|
|
110
|
+
{ "startIndex": 23, "endIndex": 24, "scopes": ["source.abl", "string.quoted.double.abl"] }, // 'a'
|
|
111
|
+
{ "startIndex": 24, "endIndex": 25, "scopes": ["source.abl", "string.quoted.double.abl", "punctuation.definition.string.end.abl"] } // '"'
|
|
112
|
+
],
|
|
113
|
+
[
|
|
114
|
+
{ "startIndex": 0, "endIndex": 10, "scopes": ["source.abl"] }, // ' '
|
|
115
|
+
{ "startIndex": 10, "endIndex": 13, "scopes": ["source.abl", "keyword.other.abl"] }, // 'AND'
|
|
116
|
+
{ "startIndex": 13, "endIndex": 14, "scopes": ["source.abl"] }, // ' '
|
|
117
|
+
{ "startIndex": 14, "endIndex": 15, "scopes": ["source.abl", "meta.function.arguments.abl", "meta.brace.round.js"] }, // '('
|
|
118
|
+
{ "startIndex": 15, "endIndex": 20, "scopes": ["source.abl", "meta.function.arguments.abl", "storage.data.table.abl"] }, // 'tt.f2'
|
|
119
|
+
{ "startIndex": 20, "endIndex": 21, "scopes": ["source.abl", "meta.function.arguments.abl"] }, // ' '
|
|
120
|
+
{ "startIndex": 21, "endIndex": 22, "scopes": ["source.abl", "meta.function.arguments.abl", "keyword.operator.source.abl"] }, // '='
|
|
121
|
+
{ "startIndex": 22, "endIndex": 23, "scopes": ["source.abl", "meta.function.arguments.abl"] }, // ' '
|
|
122
|
+
{ "startIndex": 23, "endIndex": 24, "scopes": ["source.abl", "meta.function.arguments.abl", "string.quoted.double.abl", "punctuation.definition.string.begin.abl"] }, // '"'
|
|
123
|
+
{ "startIndex": 24, "endIndex": 25, "scopes": ["source.abl", "meta.function.arguments.abl", "string.quoted.double.abl"] }, // 'b'
|
|
124
|
+
{ "startIndex": 25, "endIndex": 26, "scopes": ["source.abl", "meta.function.arguments.abl", "string.quoted.double.abl", "punctuation.definition.string.end.abl"] }, // '"'
|
|
125
|
+
{ "startIndex": 26, "endIndex": 27, "scopes": ["source.abl", "meta.function.arguments.abl"] }, // ' '
|
|
126
|
+
{ "startIndex": 27, "endIndex": 29, "scopes": ["source.abl", "meta.function.arguments.abl", "keyword.other.abl"] }, // 'OR'
|
|
127
|
+
{ "startIndex": 29, "endIndex": 30, "scopes": ["source.abl", "meta.function.arguments.abl"] }, // ' '
|
|
128
|
+
{ "startIndex": 30, "endIndex": 35, "scopes": ["source.abl", "meta.function.arguments.abl", "storage.data.table.abl"] }, // 'tt.f2'
|
|
129
|
+
{ "startIndex": 35, "endIndex": 36, "scopes": ["source.abl", "meta.function.arguments.abl"] }, // ' '
|
|
130
|
+
{ "startIndex": 36, "endIndex": 37, "scopes": ["source.abl", "meta.function.arguments.abl", "keyword.operator.source.abl"] }, // '='
|
|
131
|
+
{ "startIndex": 37, "endIndex": 38, "scopes": ["source.abl", "meta.function.arguments.abl"] }, // ' '
|
|
132
|
+
{ "startIndex": 38, "endIndex": 39, "scopes": ["source.abl", "meta.function.arguments.abl", "string.quoted.double.abl", "punctuation.definition.string.begin.abl"] }, // '"'
|
|
133
|
+
{ "startIndex": 39, "endIndex": 40, "scopes": ["source.abl", "meta.function.arguments.abl", "string.quoted.double.abl"] }, // 'c'
|
|
134
|
+
{ "startIndex": 40, "endIndex": 41, "scopes": ["source.abl", "meta.function.arguments.abl", "string.quoted.double.abl", "punctuation.definition.string.end.abl"] }, // '"'
|
|
135
|
+
{ "startIndex": 41, "endIndex": 42, "scopes": ["source.abl", "meta.brace.round.js"] } // ')'
|
|
136
|
+
],
|
|
137
|
+
[
|
|
138
|
+
{ "startIndex": 0, "endIndex": 10, "scopes": ["source.abl"] }, // ' '
|
|
139
|
+
{ "startIndex": 10, "endIndex": 13, "scopes": ["source.abl", "keyword.other.abl"] }, // 'AND'
|
|
140
|
+
{ "startIndex": 13, "endIndex": 14, "scopes": ["source.abl"] }, // ' '
|
|
141
|
+
{ "startIndex": 14, "endIndex": 19, "scopes": ["source.abl", "storage.data.table.abl"] }, // 'tt.f3'
|
|
142
|
+
{ "startIndex": 19, "endIndex": 20, "scopes": ["source.abl"] }, // ' '
|
|
143
|
+
{ "startIndex": 20, "endIndex": 21, "scopes": ["source.abl", "keyword.operator.source.abl"] }, // '='
|
|
144
|
+
{ "startIndex": 21, "endIndex": 22, "scopes": ["source.abl"] }, // ' '
|
|
145
|
+
{ "startIndex": 22, "endIndex": 23, "scopes": ["source.abl", "string.quoted.double.abl", "punctuation.definition.string.begin.abl"] }, // '"'
|
|
146
|
+
{ "startIndex": 23, "endIndex": 24, "scopes": ["source.abl", "string.quoted.double.abl"] }, // 'd'
|
|
147
|
+
{ "startIndex": 24, "endIndex": 25, "scopes": ["source.abl", "string.quoted.double.abl", "punctuation.definition.string.end.abl"] } // '"'
|
|
148
|
+
],
|
|
149
|
+
[
|
|
150
|
+
{ "startIndex": 0, "endIndex": 8, "scopes": ["source.abl"] }, // ' '
|
|
151
|
+
{ "startIndex": 8, "endIndex": 15, "scopes": ["source.abl", "keyword.other.abl"] }, // 'NO-LOCK'
|
|
152
|
+
{ "startIndex": 15, "endIndex": 16, "scopes": ["source.abl"] }, // ' '
|
|
153
|
+
{ "startIndex": 16, "endIndex": 24, "scopes": ["source.abl", "keyword.other.abl"] }, // 'NO-ERROR'
|
|
154
|
+
{ "startIndex": 24, "endIndex": 25, "scopes": ["source.abl", "punctuation.terminator.abl"] } // '.'
|
|
155
|
+
]
|
|
156
|
+
];
|
|
157
|
+
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
158
|
+
})
|
|
@@ -108,3 +108,48 @@ describe('', () => {
|
|
|
108
108
|
];
|
|
109
109
|
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
110
110
|
})
|
|
111
|
+
|
|
112
|
+
describe('', () => {
|
|
113
|
+
let statement = `create buffer vBufferHandle for table vTableName no-error.
|
|
114
|
+
|
|
115
|
+
create buffer vBufferHandle for table vTableName no-error.`;
|
|
116
|
+
let expectedTokens = [
|
|
117
|
+
[
|
|
118
|
+
{ "startIndex": 0, "endIndex": 6, "scopes": ["source.abl", "keyword.other.abl"] }, // 'create'
|
|
119
|
+
{ "startIndex": 6, "endIndex": 7, "scopes": ["source.abl"] }, // ' '
|
|
120
|
+
{ "startIndex": 7, "endIndex": 13, "scopes": ["source.abl", "keyword.other.abl"] }, // 'buffer'
|
|
121
|
+
{ "startIndex": 13, "endIndex": 14, "scopes": ["source.abl"] }, // ' '
|
|
122
|
+
{ "startIndex": 14, "endIndex": 27, "scopes": ["source.abl", "variable.other.abl"] }, // 'vBufferHandle'
|
|
123
|
+
{ "startIndex": 27, "endIndex": 28, "scopes": ["source.abl"] }, // ' '
|
|
124
|
+
{ "startIndex": 28, "endIndex": 31, "scopes": ["source.abl", "keyword.other.abl"] }, // 'for'
|
|
125
|
+
{ "startIndex": 31, "endIndex": 32, "scopes": ["source.abl"] }, // ' '
|
|
126
|
+
{ "startIndex": 32, "endIndex": 37, "scopes": ["source.abl", "keyword.other.abl"] }, // 'table'
|
|
127
|
+
{ "startIndex": 37, "endIndex": 38, "scopes": ["source.abl"] }, // ' '
|
|
128
|
+
{ "startIndex": 38, "endIndex": 48, "scopes": ["source.abl", "variable.other.abl"] }, // 'vTableName'
|
|
129
|
+
{ "startIndex": 48, "endIndex": 49, "scopes": ["source.abl"] }, // ' '
|
|
130
|
+
{ "startIndex": 49, "endIndex": 57, "scopes": ["source.abl", "keyword.other.abl"] }, // 'no-error'
|
|
131
|
+
{ "startIndex": 57, "endIndex": 58, "scopes": ["source.abl", "punctuation.terminator.abl"] } // '.'
|
|
132
|
+
],
|
|
133
|
+
[
|
|
134
|
+
{ "startIndex": 0, "endIndex": 1, "scopes": ["source.abl"] } // ''
|
|
135
|
+
],
|
|
136
|
+
[
|
|
137
|
+
{ "startIndex": 0, "endIndex": 4, "scopes": ["source.abl"] }, // ' '
|
|
138
|
+
{ "startIndex": 4, "endIndex": 10, "scopes": ["source.abl", "keyword.other.abl"] }, // 'create'
|
|
139
|
+
{ "startIndex": 10, "endIndex": 11, "scopes": ["source.abl"] }, // ' '
|
|
140
|
+
{ "startIndex": 11, "endIndex": 17, "scopes": ["source.abl", "keyword.other.abl"] }, // 'buffer'
|
|
141
|
+
{ "startIndex": 17, "endIndex": 18, "scopes": ["source.abl"] }, // ' '
|
|
142
|
+
{ "startIndex": 18, "endIndex": 31, "scopes": ["source.abl", "variable.other.abl"] }, // 'vBufferHandle'
|
|
143
|
+
{ "startIndex": 31, "endIndex": 32, "scopes": ["source.abl"] }, // ' '
|
|
144
|
+
{ "startIndex": 32, "endIndex": 35, "scopes": ["source.abl", "keyword.other.abl"] }, // 'for'
|
|
145
|
+
{ "startIndex": 35, "endIndex": 36, "scopes": ["source.abl"] }, // ' '
|
|
146
|
+
{ "startIndex": 36, "endIndex": 41, "scopes": ["source.abl", "keyword.other.abl"] }, // 'table'
|
|
147
|
+
{ "startIndex": 41, "endIndex": 42, "scopes": ["source.abl"] }, // ' '
|
|
148
|
+
{ "startIndex": 42, "endIndex": 52, "scopes": ["source.abl", "variable.other.abl"] }, // 'vTableName'
|
|
149
|
+
{ "startIndex": 52, "endIndex": 53, "scopes": ["source.abl"] }, // ' '
|
|
150
|
+
{ "startIndex": 53, "endIndex": 61, "scopes": ["source.abl", "keyword.other.abl"] }, // 'no-error'
|
|
151
|
+
{ "startIndex": 61, "endIndex": 62, "scopes": ["source.abl", "punctuation.terminator.abl"] } // '.'
|
|
152
|
+
]
|
|
153
|
+
];
|
|
154
|
+
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
155
|
+
})
|
|
@@ -402,3 +402,36 @@ describe('', () => {
|
|
|
402
402
|
]
|
|
403
403
|
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
404
404
|
})
|
|
405
|
+
|
|
406
|
+
describe('', () => {
|
|
407
|
+
let statement = `var datetime[] dtz1 = [now, today, ?, today, now].`
|
|
408
|
+
let expectedTokens = [
|
|
409
|
+
{ "startIndex": 0, "endIndex": 3, "scopes": ["source.abl", "meta.define.abl", "keyword.other.abl"] }, // 'var'
|
|
410
|
+
{ "startIndex": 3, "endIndex": 5, "scopes": ["source.abl", "meta.define.abl"] }, // ' '
|
|
411
|
+
{ "startIndex": 5, "endIndex": 13, "scopes": ["source.abl", "meta.define.abl", "storage.type.abl"] }, // 'datetime'
|
|
412
|
+
{ "startIndex": 13, "endIndex": 14, "scopes": ["source.abl", "meta.define.abl", "meta.array.literal.abl", "punctuation.definition.bracket.square.begin.abl"] }, // '['
|
|
413
|
+
{ "startIndex": 14, "endIndex": 15, "scopes": ["source.abl", "meta.define.abl", "meta.array.literal.abl", "punctuation.definition.bracket.square.end.abl"] }, // ']'
|
|
414
|
+
{ "startIndex": 15, "endIndex": 16, "scopes": ["source.abl", "meta.define.abl"] }, // ' '
|
|
415
|
+
{ "startIndex": 16, "endIndex": 20, "scopes": ["source.abl", "meta.define.abl", "variable.other.abl"] }, // 'dtz1'
|
|
416
|
+
{ "startIndex": 20, "endIndex": 21, "scopes": ["source.abl"] }, // ' '
|
|
417
|
+
{ "startIndex": 21, "endIndex": 22, "scopes": ["source.abl", "keyword.operator.source.abl"] }, // '='
|
|
418
|
+
{ "startIndex": 22, "endIndex": 23, "scopes": ["source.abl"] }, // ' '
|
|
419
|
+
{ "startIndex": 23, "endIndex": 24, "scopes": ["source.abl", "meta.array.literal.abl", "punctuation.definition.bracket.square.begin.abl"] }, // '['
|
|
420
|
+
{ "startIndex": 24, "endIndex": 27, "scopes": ["source.abl", "meta.array.literal.abl", "constant.language.abl"] }, // 'now'
|
|
421
|
+
{ "startIndex": 27, "endIndex": 28, "scopes": ["source.abl", "meta.array.literal.abl", "punctuation.separator.comma.abl"] }, // ','
|
|
422
|
+
{ "startIndex": 28, "endIndex": 29, "scopes": ["source.abl", "meta.array.literal.abl"] }, // ' '
|
|
423
|
+
{ "startIndex": 29, "endIndex": 34, "scopes": ["source.abl", "meta.array.literal.abl", "constant.language.abl"] }, // 'today'
|
|
424
|
+
{ "startIndex": 34, "endIndex": 35, "scopes": ["source.abl", "meta.array.literal.abl", "punctuation.separator.comma.abl"] }, // ','
|
|
425
|
+
{ "startIndex": 35, "endIndex": 36, "scopes": ["source.abl", "meta.array.literal.abl"] }, // ' '
|
|
426
|
+
{ "startIndex": 36, "endIndex": 37, "scopes": ["source.abl", "meta.array.literal.abl", "constant.language.abl"] }, // '?'
|
|
427
|
+
{ "startIndex": 37, "endIndex": 38, "scopes": ["source.abl", "meta.array.literal.abl", "punctuation.separator.comma.abl"] }, // ','
|
|
428
|
+
{ "startIndex": 38, "endIndex": 39, "scopes": ["source.abl", "meta.array.literal.abl"] }, // ' '
|
|
429
|
+
{ "startIndex": 39, "endIndex": 44, "scopes": ["source.abl", "meta.array.literal.abl", "constant.language.abl"] }, // 'today'
|
|
430
|
+
{ "startIndex": 44, "endIndex": 45, "scopes": ["source.abl", "meta.array.literal.abl", "punctuation.separator.comma.abl"] }, // ','
|
|
431
|
+
{ "startIndex": 45, "endIndex": 46, "scopes": ["source.abl", "meta.array.literal.abl"] }, // ' '
|
|
432
|
+
{ "startIndex": 46, "endIndex": 49, "scopes": ["source.abl", "meta.array.literal.abl", "constant.language.abl"] }, // 'now'
|
|
433
|
+
{ "startIndex": 49, "endIndex": 50, "scopes": ["source.abl", "meta.array.literal.abl", "punctuation.definition.bracket.square.end.abl"] }, // ']'
|
|
434
|
+
{ "startIndex": 50, "endIndex": 51, "scopes": ["source.abl", "punctuation.terminator.abl"] } // '.'
|
|
435
|
+
]
|
|
436
|
+
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
437
|
+
})
|
|
@@ -229,7 +229,8 @@ END CASE. `;
|
|
|
229
229
|
{ "startIndex": 22, "endIndex": 23, "scopes": ["source.abl", "meta.function.arguments.abl", "punctuation.separator.comma.abl"] }, // ','
|
|
230
230
|
{ "startIndex": 23, "endIndex": 24, "scopes": ["source.abl", "meta.function.arguments.abl"] }, // ' '
|
|
231
231
|
{ "startIndex": 24, "endIndex": 31, "scopes": ["source.abl", "meta.function.arguments.abl", "variable.other.abl"] }, // 'produit'
|
|
232
|
-
{ "startIndex": 31, "endIndex":
|
|
232
|
+
{ "startIndex": 31, "endIndex": 32, "scopes": ["source.abl", "meta.function.arguments.abl"] }, // ' '
|
|
233
|
+
{ "startIndex": 32, "endIndex": 33, "scopes": ["source.abl", "meta.function.arguments.abl", "keyword.operator.source.abl"] }, // '+'
|
|
233
234
|
{ "startIndex": 33, "endIndex": 34, "scopes": ["source.abl", "meta.function.arguments.abl", "meta.function-call.abl"] }, // ' '
|
|
234
235
|
{ "startIndex": 34, "endIndex": 40, "scopes": ["source.abl", "meta.function.arguments.abl", "meta.function-call.abl", "support.function.abl"] }, // 'string'
|
|
235
236
|
{ "startIndex": 40, "endIndex": 41, "scopes": ["source.abl", "meta.function.arguments.abl", "meta.function-call.abl", "meta.function.arguments.abl", "meta.brace.round.js"] }, // '('
|
|
@@ -141,7 +141,7 @@ describe('', () => {
|
|
|
141
141
|
})
|
|
142
142
|
|
|
143
143
|
describe('', () => {
|
|
144
|
-
let statement = `CLASS foo.bar.baz serializable inherits parent.class implements one.interface,
|
|
144
|
+
let statement = `CLASS foo.bar.baz serializable inherits parent.class implements one.interface,another.iface abstract use-widget-pool:`;
|
|
145
145
|
|
|
146
146
|
let expectedTokens = [
|
|
147
147
|
{ "startIndex": 0, "endIndex": 5, "scopes": ["source.abl", "meta.define.class.abl", "keyword.other.abl"] }, // 'CLASS'
|
|
@@ -158,7 +158,7 @@ describe('', () => {
|
|
|
158
158
|
{ "startIndex": 63, "endIndex": 64, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
159
159
|
{ "startIndex": 64, "endIndex": 77, "scopes": ["source.abl", "meta.define.class.abl", "entity.name.type.abl"] }, // 'one.interface'
|
|
160
160
|
{ "startIndex": 77, "endIndex": 78, "scopes": ["source.abl", "meta.define.class.abl", "punctuation.separator.comma.abl"] }, // ','
|
|
161
|
-
{ "startIndex": 78, "endIndex": 91, "scopes": ["source.abl", "meta.define.class.abl", "entity.name.type.abl"] }, // '
|
|
161
|
+
{ "startIndex": 78, "endIndex": 91, "scopes": ["source.abl", "meta.define.class.abl", "entity.name.type.abl"] }, // 'another.iface'
|
|
162
162
|
{ "startIndex": 91, "endIndex": 92, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
163
163
|
{ "startIndex": 92, "endIndex": 100, "scopes": ["source.abl", "meta.define.class.abl", "keyword.other.abl"] }, // 'abstract'
|
|
164
164
|
{ "startIndex": 100, "endIndex": 101, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
@@ -466,3 +466,90 @@ describe('', () => {
|
|
|
466
466
|
];
|
|
467
467
|
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
468
468
|
})
|
|
469
|
+
|
|
470
|
+
describe('', () => {
|
|
471
|
+
let statement = `class Company.Plugins.ServerPlugin
|
|
472
|
+
inherits AbstractPlugin
|
|
473
|
+
implements IServerPlugin :`;
|
|
474
|
+
|
|
475
|
+
let expectedTokens = [
|
|
476
|
+
[
|
|
477
|
+
{ "startIndex": 0, "endIndex": 5, "scopes": ["source.abl", "meta.define.class.abl", "keyword.other.abl"] }, // 'class'
|
|
478
|
+
{ "startIndex": 5, "endIndex": 6, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
479
|
+
{ "startIndex": 6, "endIndex": 34, "scopes": ["source.abl", "meta.define.class.abl", "entity.name.type.abl"] } // 'Company.Plugins.ServerPlugin'
|
|
480
|
+
],
|
|
481
|
+
[
|
|
482
|
+
{ "startIndex": 0, "endIndex": 4, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
483
|
+
{ "startIndex": 4, "endIndex": 12, "scopes": ["source.abl", "meta.define.class.abl", "keyword.other.abl"] }, // 'inherits'
|
|
484
|
+
{ "startIndex": 12, "endIndex": 13, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
485
|
+
{ "startIndex": 13, "endIndex": 27, "scopes": ["source.abl", "meta.define.class.abl", "entity.name.type.abl"] } // 'AbstractPlugin'
|
|
486
|
+
],
|
|
487
|
+
[
|
|
488
|
+
{ "startIndex": 0, "endIndex": 4, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
489
|
+
{ "startIndex": 4, "endIndex": 14, "scopes": ["source.abl", "meta.define.class.abl", "keyword.other.abl"] }, // 'implements'
|
|
490
|
+
{ "startIndex": 14, "endIndex": 15, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
491
|
+
{ "startIndex": 15, "endIndex": 28, "scopes": ["source.abl", "meta.define.class.abl", "entity.name.type.abl"] }, // 'IServerPlugin'
|
|
492
|
+
{ "startIndex": 28, "endIndex": 29, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
493
|
+
{ "startIndex": 29, "endIndex": 30, "scopes": ["source.abl", "meta.define.class.abl", "punctuation.terminator.abl"] } // ':'
|
|
494
|
+
]
|
|
495
|
+
];
|
|
496
|
+
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
497
|
+
})
|
|
498
|
+
|
|
499
|
+
describe('', () => {
|
|
500
|
+
let statement = `class Company.Plugins.ServerPlugin
|
|
501
|
+
inherits FinalAbstractPlugin
|
|
502
|
+
implements IServerPlugin :`;
|
|
503
|
+
|
|
504
|
+
let expectedTokens = [
|
|
505
|
+
[
|
|
506
|
+
{ "startIndex": 0, "endIndex": 5, "scopes": ["source.abl", "meta.define.class.abl", "keyword.other.abl"] }, // 'class'
|
|
507
|
+
{ "startIndex": 5, "endIndex": 6, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
508
|
+
{ "startIndex": 6, "endIndex": 34, "scopes": ["source.abl", "meta.define.class.abl", "entity.name.type.abl"] } // 'Company.Plugins.ServerPlugin'
|
|
509
|
+
],
|
|
510
|
+
[
|
|
511
|
+
{ "startIndex": 0, "endIndex": 4, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
512
|
+
{ "startIndex": 4, "endIndex": 12, "scopes": ["source.abl", "meta.define.class.abl", "keyword.other.abl"] }, // 'inherits'
|
|
513
|
+
{ "startIndex": 12, "endIndex": 13, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
514
|
+
{ "startIndex": 13, "endIndex": 32, "scopes": ["source.abl", "meta.define.class.abl", "entity.name.type.abl"] } // 'FinalAbstractPlugin'
|
|
515
|
+
],
|
|
516
|
+
[
|
|
517
|
+
{ "startIndex": 0, "endIndex": 4, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
518
|
+
{ "startIndex": 4, "endIndex": 14, "scopes": ["source.abl", "meta.define.class.abl", "keyword.other.abl"] }, // 'implements'
|
|
519
|
+
{ "startIndex": 14, "endIndex": 15, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
520
|
+
{ "startIndex": 15, "endIndex": 28, "scopes": ["source.abl", "meta.define.class.abl", "entity.name.type.abl"] }, // 'IServerPlugin'
|
|
521
|
+
{ "startIndex": 28, "endIndex": 29, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
522
|
+
{ "startIndex": 29, "endIndex": 30, "scopes": ["source.abl", "meta.define.class.abl", "punctuation.terminator.abl"] } // ':'
|
|
523
|
+
]
|
|
524
|
+
];
|
|
525
|
+
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
526
|
+
})
|
|
527
|
+
|
|
528
|
+
describe('', () => {
|
|
529
|
+
let statement = `class Company.Plugins.ServerPlugin
|
|
530
|
+
inherits FinalAbstractPlugin
|
|
531
|
+
implements AbstractServerPlugin :`;
|
|
532
|
+
|
|
533
|
+
let expectedTokens = [
|
|
534
|
+
[
|
|
535
|
+
{ "startIndex": 0, "endIndex": 5, "scopes": ["source.abl", "meta.define.class.abl", "keyword.other.abl"] }, // 'class'
|
|
536
|
+
{ "startIndex": 5, "endIndex": 6, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
537
|
+
{ "startIndex": 6, "endIndex": 34, "scopes": ["source.abl", "meta.define.class.abl", "entity.name.type.abl"] } // 'Company.Plugins.ServerPlugin'
|
|
538
|
+
],
|
|
539
|
+
[
|
|
540
|
+
{ "startIndex": 0, "endIndex": 4, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
541
|
+
{ "startIndex": 4, "endIndex": 12, "scopes": ["source.abl", "meta.define.class.abl", "keyword.other.abl"] }, // 'inherits'
|
|
542
|
+
{ "startIndex": 12, "endIndex": 13, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
543
|
+
{ "startIndex": 13, "endIndex": 32, "scopes": ["source.abl", "meta.define.class.abl", "entity.name.type.abl"] } // 'FinalAbstractPlugin'
|
|
544
|
+
],
|
|
545
|
+
[
|
|
546
|
+
{ "startIndex": 0, "endIndex": 4, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
547
|
+
{ "startIndex": 4, "endIndex": 14, "scopes": ["source.abl", "meta.define.class.abl", "keyword.other.abl"] }, // 'implements'
|
|
548
|
+
{ "startIndex": 14, "endIndex": 15, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
549
|
+
{ "startIndex": 15, "endIndex": 35, "scopes": ["source.abl", "meta.define.class.abl", "entity.name.type.abl"] }, // 'AbstractServerPlugin'
|
|
550
|
+
{ "startIndex": 35, "endIndex": 36, "scopes": ["source.abl", "meta.define.class.abl"] }, // ' '
|
|
551
|
+
{ "startIndex": 36, "endIndex": 37, "scopes": ["source.abl", "meta.define.class.abl", "punctuation.terminator.abl"] } // ':'
|
|
552
|
+
]
|
|
553
|
+
];
|
|
554
|
+
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
555
|
+
})
|
|
@@ -126,3 +126,35 @@ describe('', () => {
|
|
|
126
126
|
];
|
|
127
127
|
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
128
128
|
})
|
|
129
|
+
|
|
130
|
+
describe('', () => {
|
|
131
|
+
let statement = `using foo.bar.* /*from propath*/.`;
|
|
132
|
+
|
|
133
|
+
let expectedTokens = [
|
|
134
|
+
{ "startIndex": 0, "endIndex": 5, "scopes": ["source.abl", "meta.using.abl", "keyword.other.abl"] }, // 'using'
|
|
135
|
+
{ "startIndex": 5, "endIndex": 6, "scopes": ["source.abl", "meta.using.abl"] }, // ' '
|
|
136
|
+
{ "startIndex": 6, "endIndex": 13, "scopes": ["source.abl", "meta.using.abl", "entity.name.package.abl"] }, // 'foo.bar'
|
|
137
|
+
{ "startIndex": 13, "endIndex": 17, "scopes": ["source.abl", "meta.using.abl"] }, // '.* '
|
|
138
|
+
{ "startIndex": 17, "endIndex": 19, "scopes": ["source.abl", "meta.using.abl", "comment.block.source.abl"] }, // '/*'
|
|
139
|
+
{ "startIndex": 19, "endIndex": 31, "scopes": ["source.abl", "meta.using.abl", "comment.block.source.abl", "comment"] }, // 'from propath'
|
|
140
|
+
{ "startIndex": 31, "endIndex": 33, "scopes": ["source.abl", "meta.using.abl", "comment.block.source.abl"] }, // '*/'
|
|
141
|
+
{ "startIndex": 33, "endIndex": 34, "scopes": ["source.abl", "meta.using.abl", "punctuation.terminator.abl"] } // '.'
|
|
142
|
+
];
|
|
143
|
+
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
144
|
+
})
|
|
145
|
+
|
|
146
|
+
describe('', () => {
|
|
147
|
+
let statement = `using foo.bar.baz /*from propath*/.`;
|
|
148
|
+
|
|
149
|
+
let expectedTokens = [
|
|
150
|
+
{ "startIndex": 0, "endIndex": 5, "scopes": ["source.abl", "meta.using.abl", "keyword.other.abl"] }, // 'using'
|
|
151
|
+
{ "startIndex": 5, "endIndex": 6, "scopes": ["source.abl", "meta.using.abl"] }, // ' '
|
|
152
|
+
{ "startIndex": 6, "endIndex": 17, "scopes": ["source.abl", "meta.using.abl", "entity.name.type.abl"] }, // 'foo.bar.baz'
|
|
153
|
+
{ "startIndex": 17, "endIndex": 19, "scopes": ["source.abl", "meta.using.abl"] }, // ' '
|
|
154
|
+
{ "startIndex": 19, "endIndex": 21, "scopes": ["source.abl", "meta.using.abl", "comment.block.source.abl"] }, // '/*'
|
|
155
|
+
{ "startIndex": 21, "endIndex": 33, "scopes": ["source.abl", "meta.using.abl", "comment.block.source.abl", "comment"] }, // 'from propath'
|
|
156
|
+
{ "startIndex": 33, "endIndex": 35, "scopes": ["source.abl", "meta.using.abl", "comment.block.source.abl"] }, // '*/'
|
|
157
|
+
{ "startIndex": 35, "endIndex": 36, "scopes": ["source.abl", "meta.using.abl", "punctuation.terminator.abl"] } // '.'
|
|
158
|
+
];
|
|
159
|
+
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
160
|
+
})
|
package/azure-pipelines.yml
DELETED
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
# Node.js
|
|
2
|
-
# Build a general Node.js project with npm.
|
|
3
|
-
# Add steps that analyze code, save build artifacts, deploy, and more:
|
|
4
|
-
# https://docs.microsoft.com/azure/devops/pipelines/languages/javascript
|
|
5
|
-
|
|
6
|
-
trigger:
|
|
7
|
-
- main
|
|
8
|
-
|
|
9
|
-
pool:
|
|
10
|
-
vmImage: 'ubuntu-22.04'
|
|
11
|
-
|
|
12
|
-
steps:
|
|
13
|
-
- task: NodeTool@0
|
|
14
|
-
inputs:
|
|
15
|
-
versionSpec: '20.x'
|
|
16
|
-
displayName: 'Install Node.js'
|
|
17
|
-
|
|
18
|
-
- script: |
|
|
19
|
-
npm install
|
|
20
|
-
npm run test
|
|
21
|
-
displayName: 'running tests'
|
|
22
|
-
|
|
23
|
-
- task: Npm@1
|
|
24
|
-
condition: eq(variables['Build.SourceBranch'], 'refs/heads/main')
|
|
25
|
-
inputs:
|
|
26
|
-
command: 'publish'
|
|
27
|
-
customRegistry: 'useFeed'
|
|
28
|
-
publishEndpoint: 'npmjs'
|