abl-tmlanguage 1.1.3 → 1.2.0
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 +4 -0
- package/README.md +12 -0
- package/abl.tmLanguage.json +2736 -216
- package/azure-pipelines.yml +3 -2
- package/package.json +7 -6
- package/spec/analyze-suspend-resume/analyze-suspend-resume.spec.js +10 -10
- package/spec/array-extent/issue#5.spec.js +18 -18
- package/spec/define-buffer/simple-single-line.spec.js +138 -0
- package/spec/define-parameter/simple-single-line.spec.js +100 -100
- package/spec/define-stream/simple-single-line.spec.js +32 -31
- package/spec/define-variable/extent.spec.js +228 -0
- package/spec/define-variable/issue#6.spec.js +256 -198
- package/spec/define-variable/issue#9.spec.js +38 -32
- package/spec/define-variable/simple-single-line.spec.js +87 -87
- package/spec/define-variable/single-line-with-a-comment-at-the-end.spec.js +62 -62
- package/spec/define-variable/single-line-with-a-space-and-a-comment-at-the-end.spec.js +56 -56
- package/spec/define-variable/tm-issue#2.spec.js +20 -20
- package/spec/do/do-blocks.spec.js +89 -0
- package/spec/do/issue#3.spec.js +67 -60
- package/spec/function-call/vscode-abl-issue#19.spec.js +110 -107
- package/spec/global-scoped-define/global-define.spec.js +11 -11
- package/spec/global-scoped-define/scoped-define-with-procedure-keyword.spec.js +26 -26
- package/spec/include/abl-tmlanguage-issues#5.spec.js +44 -44
- package/spec/include/vscode-abl-issue#45.spec.js +14 -14
- package/spec/include/vscode-abl-issue#80.spec.js +26 -26
- package/spec/method-definition/constructor.spec.js +174 -0
- package/spec/method-definition/method.spec.js +185 -0
- package/spec/procedure-definition/empty-proc.spec.js +20 -18
- package/spec/procedure-definition/vscode-abl-issue#22.spec.js +46 -42
- package/spec/procedure-definition/vscode-abl-issue#26.spec.js +23 -16
- package/spec/procedure-definition/vscode-abl-issue#62.spec.js +36 -0
- package/spec/shared.js +84 -42
- package/spec/strings/vscode-abl-issue#11.spec.js +110 -114
- package/spec/strings/vscode-abl-issue#28.spec.js +27 -27
- package/spec/type-name/argument.spec.js +209 -0
- package/spec/type-name/cast.spec.js +165 -0
- package/spec/type-name/define-class.spec.js +471 -0
- package/spec/type-name/define-enum.spec.js +44 -0
- package/spec/type-name/define-interface.spec.js +159 -0
- package/spec/type-name/define-property.spec.js +301 -0
- package/spec/type-name/define-temp-table.spec.js +434 -0
- package/spec/type-name/define-type-spec.js +435 -0
- package/spec/type-name/define-variable-property.spec.js +264 -0
- package/spec/type-name/define-variable.spec.js +504 -0
- package/spec/type-name/get-class.spec.js +91 -0
- package/spec/type-name/new.spec.js +126 -0
- package/spec/type-name/parameter-as.spec.js +838 -0
- package/spec/type-name/type-name-spec.js +587 -0
- package/spec/type-name/using.spec.js +115 -0
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
const { assert, expect } = require('chai');
|
|
2
|
+
const shared = require('../shared.js');
|
|
3
|
+
|
|
4
|
+
describe('', () => {
|
|
5
|
+
let statement = `GET-CLASS(foo.bar.baz) `;
|
|
6
|
+
|
|
7
|
+
let expectedTokens = [
|
|
8
|
+
{ "startIndex": 0, "endIndex": 9, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.function.abl"] },
|
|
9
|
+
{ "startIndex": 9, "endIndex": 10, "scopes": ["source.abl", "meta.function-call.abl", "meta.brace.round.js"] },
|
|
10
|
+
{ "startIndex": 10, "endIndex": 21, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.type.abl"] },
|
|
11
|
+
{ "startIndex": 21, "endIndex": 22, "scopes": ["source.abl", "meta.function-call.abl", "meta.brace.round.js"] },
|
|
12
|
+
{ "startIndex": 22, "endIndex": 24, "scopes": ["source.abl"] }
|
|
13
|
+
];
|
|
14
|
+
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
15
|
+
})
|
|
16
|
+
|
|
17
|
+
describe('', () => {
|
|
18
|
+
let statement = `GET-CLASS ( foo.bar.baz ) `;
|
|
19
|
+
|
|
20
|
+
let expectedTokens = [
|
|
21
|
+
{ "startIndex": 0, "endIndex": 9, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.function.abl"] },
|
|
22
|
+
{ "startIndex": 9, "endIndex": 10, "scopes": ["source.abl", "meta.function-call.abl"] },
|
|
23
|
+
{ "startIndex": 10, "endIndex": 11, "scopes": ["source.abl", "meta.function-call.abl", "meta.brace.round.js"] },
|
|
24
|
+
{ "startIndex": 11, "endIndex": 12, "scopes": ["source.abl", "meta.function-call.abl"] },
|
|
25
|
+
{ "startIndex": 12, "endIndex": 23, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.type.abl"] },
|
|
26
|
+
{ "startIndex": 23, "endIndex": 24, "scopes": ["source.abl", "meta.function-call.abl"] },
|
|
27
|
+
{ "startIndex": 24, "endIndex": 25, "scopes": ["source.abl", "meta.function-call.abl", "meta.brace.round.js"] },
|
|
28
|
+
{ "startIndex": 25, "endIndex": 27, "scopes": ["source.abl"] }
|
|
29
|
+
];
|
|
30
|
+
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
31
|
+
})
|
|
32
|
+
|
|
33
|
+
describe('', () => {
|
|
34
|
+
let statement = `GET-CLASS ( List<foo.bar.baz> ) `;
|
|
35
|
+
|
|
36
|
+
let expectedTokens = [
|
|
37
|
+
{ "startIndex": 0, "endIndex": 9, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.function.abl"] }, // 'GET-CLASS'
|
|
38
|
+
{ "startIndex": 9, "endIndex": 10, "scopes": ["source.abl", "meta.function-call.abl"] }, // ' '
|
|
39
|
+
{ "startIndex": 10, "endIndex": 11, "scopes": ["source.abl", "meta.function-call.abl", "meta.brace.round.js"] }, // '('
|
|
40
|
+
{ "startIndex": 11, "endIndex": 12, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.type.generic.abl"] }, // ' '
|
|
41
|
+
{ "startIndex": 12, "endIndex": 16, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.type.generic.abl", "entity.name.type.abl"] }, // 'List'
|
|
42
|
+
{ "startIndex": 16, "endIndex": 17, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.type.generic.abl"] }, // '<'
|
|
43
|
+
{ "startIndex": 17, "endIndex": 28, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.type.generic.abl", "entity.name.type.abl"] }, // 'foo.bar.baz'
|
|
44
|
+
{ "startIndex": 28, "endIndex": 29, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.type.generic.abl"] }, // '>'
|
|
45
|
+
{ "startIndex": 29, "endIndex": 30, "scopes": ["source.abl", "meta.function-call.abl"] }, // ' '
|
|
46
|
+
{ "startIndex": 30, "endIndex": 31, "scopes": ["source.abl", "meta.function-call.abl", "meta.brace.round.js"] }, // ')'
|
|
47
|
+
{ "startIndex": 31, "endIndex": 33, "scopes": ["source.abl"] } // ' '
|
|
48
|
+
];
|
|
49
|
+
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
50
|
+
})
|
|
51
|
+
|
|
52
|
+
describe('', () => {
|
|
53
|
+
let statement = `GET-CLASS ( Progress.Collections.List<foo.bar.baz> ) `;
|
|
54
|
+
|
|
55
|
+
let expectedTokens = [
|
|
56
|
+
{ "startIndex": 0, "endIndex": 9, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.function.abl"] }, // 'GET-CLASS'
|
|
57
|
+
{ "startIndex": 9, "endIndex": 10, "scopes": ["source.abl", "meta.function-call.abl"] }, // ' '
|
|
58
|
+
{ "startIndex": 10, "endIndex": 11, "scopes": ["source.abl", "meta.function-call.abl", "meta.brace.round.js"] }, // '('
|
|
59
|
+
{ "startIndex": 11, "endIndex": 12, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.type.generic.abl"] }, // ' '
|
|
60
|
+
{ "startIndex": 12, "endIndex": 37, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.type.generic.abl", "entity.name.type.abl"] }, // 'Progress.Collections.List'
|
|
61
|
+
{ "startIndex": 37, "endIndex": 38, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.type.generic.abl"] }, // '<'
|
|
62
|
+
{ "startIndex": 38, "endIndex": 49, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.type.generic.abl", "entity.name.type.abl"] }, // 'foo.bar.baz'
|
|
63
|
+
{ "startIndex": 49, "endIndex": 50, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.type.generic.abl"] }, // '>'
|
|
64
|
+
{ "startIndex": 50, "endIndex": 51, "scopes": ["source.abl", "meta.function-call.abl"] }, // ' '
|
|
65
|
+
{ "startIndex": 51, "endIndex": 52, "scopes": ["source.abl", "meta.function-call.abl", "meta.brace.round.js"] }, // ')'
|
|
66
|
+
{ "startIndex": 52, "endIndex": 54, "scopes": ["source.abl"] } // ' '
|
|
67
|
+
];
|
|
68
|
+
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
69
|
+
})
|
|
70
|
+
|
|
71
|
+
describe('', () => {
|
|
72
|
+
let statement = `GET-CLASS ( Dictionary<foo.bar, boo.baz> ) `;
|
|
73
|
+
|
|
74
|
+
let expectedTokens = [
|
|
75
|
+
{ "startIndex": 0, "endIndex": 9, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.function.abl"] }, // 'GET-CLASS'
|
|
76
|
+
{ "startIndex": 9, "endIndex": 10, "scopes": ["source.abl", "meta.function-call.abl"] }, // ' '
|
|
77
|
+
{ "startIndex": 10, "endIndex": 11, "scopes": ["source.abl", "meta.function-call.abl", "meta.brace.round.js"] }, // '('
|
|
78
|
+
{ "startIndex": 11, "endIndex": 12, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.type.generic.abl"] }, // ' '
|
|
79
|
+
{ "startIndex": 12, "endIndex": 22, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.type.generic.abl", "entity.name.type.abl"] }, // 'Dictionary'
|
|
80
|
+
{ "startIndex": 22, "endIndex": 23, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.type.generic.abl"] }, // '<'
|
|
81
|
+
{ "startIndex": 23, "endIndex": 30, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.type.generic.abl", "entity.name.type.abl"] }, // 'foo.bar'
|
|
82
|
+
{ "startIndex": 30, "endIndex": 31, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.type.generic.abl", "punctuation.separator.comma.abl"] }, // ','
|
|
83
|
+
{ "startIndex": 31, "endIndex": 32, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.type.generic.abl"] }, // ' '
|
|
84
|
+
{ "startIndex": 32, "endIndex": 39, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.type.generic.abl", "entity.name.type.abl"] }, // 'boo.baz'
|
|
85
|
+
{ "startIndex": 39, "endIndex": 40, "scopes": ["source.abl", "meta.function-call.abl", "entity.name.type.generic.abl"] }, // '>'
|
|
86
|
+
{ "startIndex": 40, "endIndex": 41, "scopes": ["source.abl", "meta.function-call.abl"] }, // ' '
|
|
87
|
+
{ "startIndex": 41, "endIndex": 42, "scopes": ["source.abl", "meta.function-call.abl", "meta.brace.round.js"] }, // ')'
|
|
88
|
+
{ "startIndex": 42, "endIndex": 44, "scopes": ["source.abl"] } // ' '
|
|
89
|
+
];
|
|
90
|
+
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
91
|
+
})
|
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
const { assert, expect } = require('chai');
|
|
2
|
+
const shared = require('../shared.js');
|
|
3
|
+
|
|
4
|
+
describe('', () => {
|
|
5
|
+
let statement = `ASSIGN x = NEW foo.bar.baz()`;
|
|
6
|
+
|
|
7
|
+
let expectedTokens = [
|
|
8
|
+
{ "startIndex": 0, "endIndex": 6, "scopes": ["source.abl", "keyword.other.abl"] }, // 'ASSIGN'
|
|
9
|
+
{ "startIndex": 6, "endIndex": 7, "scopes": ["source.abl"] }, // ' '
|
|
10
|
+
{ "startIndex": 7, "endIndex": 8, "scopes": ["source.abl", "variable.other.abl"] }, // 'x'
|
|
11
|
+
{ "startIndex": 8, "endIndex": 9, "scopes": ["source.abl"] }, // ' '
|
|
12
|
+
{ "startIndex": 9, "endIndex": 10, "scopes": ["source.abl", "keyword.operator.source.abl"] }, // '='
|
|
13
|
+
{ "startIndex": 10, "endIndex": 11, "scopes": ["source.abl"] }, // ' '
|
|
14
|
+
{ "startIndex": 11, "endIndex": 14, "scopes": ["source.abl", "keyword.other.abl"] }, // 'NEW'
|
|
15
|
+
{ "startIndex": 14, "endIndex": 15, "scopes": ["source.abl"] }, // ' '
|
|
16
|
+
{ "startIndex": 15, "endIndex": 26, "scopes": ["source.abl", "entity.name.type.abl"] }, // 'foo.bar.baz'
|
|
17
|
+
{ "startIndex": 26, "endIndex": 27, "scopes": ["source.abl", "meta.function.arguments.abl", "meta.brace.round.js"] }, // '('
|
|
18
|
+
{ "startIndex": 27, "endIndex": 28, "scopes": ["source.abl", "meta.brace.round.js"] } // ')'
|
|
19
|
+
];
|
|
20
|
+
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
21
|
+
})
|
|
22
|
+
|
|
23
|
+
describe('', () => {
|
|
24
|
+
let statement = `ASSIGN x = NEW foo.bar.baz(true, ?)`;
|
|
25
|
+
|
|
26
|
+
let expectedTokens = [
|
|
27
|
+
{ "startIndex": 0, "endIndex": 6, "scopes": ["source.abl", "keyword.other.abl"] }, // 'ASSIGN'
|
|
28
|
+
{ "startIndex": 6, "endIndex": 7, "scopes": ["source.abl"] }, // ' '
|
|
29
|
+
{ "startIndex": 7, "endIndex": 8, "scopes": ["source.abl", "variable.other.abl"] }, // 'x'
|
|
30
|
+
{ "startIndex": 8, "endIndex": 9, "scopes": ["source.abl"] }, // ' '
|
|
31
|
+
{ "startIndex": 9, "endIndex": 10, "scopes": ["source.abl", "keyword.operator.source.abl"] }, // '='
|
|
32
|
+
{ "startIndex": 10, "endIndex": 11, "scopes": ["source.abl"] }, // ' '
|
|
33
|
+
{ "startIndex": 11, "endIndex": 14, "scopes": ["source.abl", "keyword.other.abl"] }, // 'NEW'
|
|
34
|
+
{ "startIndex": 14, "endIndex": 15, "scopes": ["source.abl"] }, // ' '
|
|
35
|
+
{ "startIndex": 15, "endIndex": 26, "scopes": ["source.abl", "entity.name.type.abl"] }, // 'foo.bar.baz'
|
|
36
|
+
{ "startIndex": 26, "endIndex": 27, "scopes": ["source.abl", "meta.function.arguments.abl", "meta.brace.round.js"] }, // '('
|
|
37
|
+
{ "startIndex": 27, "endIndex": 31, "scopes": ["source.abl", "meta.function.arguments.abl", "constant.language.abl"] }, // 'true'
|
|
38
|
+
{ "startIndex": 31, "endIndex": 32, "scopes": ["source.abl", "meta.function.arguments.abl", "punctuation.separator.comma.abl"] }, // ','
|
|
39
|
+
{ "startIndex": 32, "endIndex": 33, "scopes": ["source.abl", "meta.function.arguments.abl"] }, // ' '
|
|
40
|
+
{ "startIndex": 33, "endIndex": 34, "scopes": ["source.abl", "meta.function.arguments.abl", "constant.language.abl"] }, // '?'
|
|
41
|
+
{ "startIndex": 34, "endIndex": 35, "scopes": ["source.abl", "meta.brace.round.js"] } // ')'
|
|
42
|
+
];
|
|
43
|
+
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
44
|
+
})
|
|
45
|
+
|
|
46
|
+
describe('', () => {
|
|
47
|
+
let statement = `ASSIGN oVar = NEW "foo.bar.baz" (true, ?)`;
|
|
48
|
+
|
|
49
|
+
let expectedTokens = [
|
|
50
|
+
{ "startIndex": 0, "endIndex": 6, "scopes": ["source.abl", "keyword.other.abl"] }, // 'ASSIGN'
|
|
51
|
+
{ "startIndex": 6, "endIndex": 7, "scopes": ["source.abl"] }, // ' '
|
|
52
|
+
{ "startIndex": 7, "endIndex": 11, "scopes": ["source.abl", "variable.other.abl"] }, // 'oVar'
|
|
53
|
+
{ "startIndex": 11, "endIndex": 12, "scopes": ["source.abl"] }, // ' '
|
|
54
|
+
{ "startIndex": 12, "endIndex": 13, "scopes": ["source.abl", "keyword.operator.source.abl"] }, // '='
|
|
55
|
+
{ "startIndex": 13, "endIndex": 14, "scopes": ["source.abl"] }, // ' '
|
|
56
|
+
{ "startIndex": 14, "endIndex": 17, "scopes": ["source.abl", "keyword.other.abl"] }, // 'NEW'
|
|
57
|
+
{ "startIndex": 17, "endIndex": 18, "scopes": ["source.abl"] }, // ' '
|
|
58
|
+
{ "startIndex": 18, "endIndex": 19, "scopes": ["source.abl", "string.double.complex.abl", "punctuation.definition.string.begin.abl"] }, // '"'
|
|
59
|
+
{ "startIndex": 19, "endIndex": 30, "scopes": ["source.abl", "string.double.complex.abl"] }, // 'foo.bar.baz'
|
|
60
|
+
{ "startIndex": 30, "endIndex": 31, "scopes": ["source.abl", "string.double.complex.abl", "punctuation.definition.string.end.abl"] }, // '"'
|
|
61
|
+
{ "startIndex": 31, "endIndex": 32, "scopes": ["source.abl"] }, // ' '
|
|
62
|
+
{ "startIndex": 32, "endIndex": 33, "scopes": ["source.abl", "meta.function.arguments.abl", "meta.brace.round.js"] }, // '('
|
|
63
|
+
{ "startIndex": 33, "endIndex": 37, "scopes": ["source.abl", "meta.function.arguments.abl", "constant.language.abl"] }, // 'true'
|
|
64
|
+
{ "startIndex": 37, "endIndex": 38, "scopes": ["source.abl", "meta.function.arguments.abl", "punctuation.separator.comma.abl"] }, // ','
|
|
65
|
+
{ "startIndex": 38, "endIndex": 39, "scopes": ["source.abl", "meta.function.arguments.abl"] }, // ' '
|
|
66
|
+
{ "startIndex": 39, "endIndex": 40, "scopes": ["source.abl", "meta.function.arguments.abl", "constant.language.abl"] }, // '?'
|
|
67
|
+
{ "startIndex": 40, "endIndex": 41, "scopes": ["source.abl", "meta.brace.round.js"] } // ')'
|
|
68
|
+
];
|
|
69
|
+
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
70
|
+
})
|
|
71
|
+
|
|
72
|
+
|
|
73
|
+
describe('', () => {
|
|
74
|
+
let statement = `ASSIGN oVar = NEW List <Object>(true, ?)`;
|
|
75
|
+
|
|
76
|
+
let expectedTokens = [
|
|
77
|
+
{ "startIndex": 0, "endIndex": 6, "scopes": ["source.abl", "keyword.other.abl"] }, // 'ASSIGN'
|
|
78
|
+
{ "startIndex": 6, "endIndex": 7, "scopes": ["source.abl"] }, // ' '
|
|
79
|
+
{ "startIndex": 7, "endIndex": 11, "scopes": ["source.abl", "variable.other.abl"] }, // 'oVar'
|
|
80
|
+
{ "startIndex": 11, "endIndex": 12, "scopes": ["source.abl"] }, // ' '
|
|
81
|
+
{ "startIndex": 12, "endIndex": 13, "scopes": ["source.abl", "keyword.operator.source.abl"] }, // '='
|
|
82
|
+
{ "startIndex": 13, "endIndex": 14, "scopes": ["source.abl"] }, // ' '
|
|
83
|
+
{ "startIndex": 14, "endIndex": 17, "scopes": ["source.abl", "keyword.other.abl"] }, // 'NEW'
|
|
84
|
+
{ "startIndex": 17, "endIndex": 18, "scopes": ["source.abl"] }, // ' '
|
|
85
|
+
{ "startIndex": 18, "endIndex": 23, "scopes": ["source.abl", "entity.name.type.generic.abl", "entity.name.type.abl"] }, // 'List '
|
|
86
|
+
{ "startIndex": 23, "endIndex": 24, "scopes": ["source.abl", "entity.name.type.generic.abl"] }, // '<'
|
|
87
|
+
{ "startIndex": 24, "endIndex": 30, "scopes": ["source.abl", "entity.name.type.generic.abl", "entity.name.type.abl"] }, // 'Object'
|
|
88
|
+
{ "startIndex": 30, "endIndex": 31, "scopes": ["source.abl", "entity.name.type.generic.abl"] }, // '>'
|
|
89
|
+
{ "startIndex": 31, "endIndex": 32, "scopes": ["source.abl", "meta.function.arguments.abl", "meta.brace.round.js"] }, // '('
|
|
90
|
+
{ "startIndex": 32, "endIndex": 36, "scopes": ["source.abl", "meta.function.arguments.abl", "constant.language.abl"] }, // 'true'
|
|
91
|
+
{ "startIndex": 36, "endIndex": 37, "scopes": ["source.abl", "meta.function.arguments.abl", "punctuation.separator.comma.abl"] }, // ','
|
|
92
|
+
{ "startIndex": 37, "endIndex": 38, "scopes": ["source.abl", "meta.function.arguments.abl"] }, // ' '
|
|
93
|
+
{ "startIndex": 38, "endIndex": 39, "scopes": ["source.abl", "meta.function.arguments.abl", "constant.language.abl"] }, // '?'
|
|
94
|
+
{ "startIndex": 39, "endIndex": 40, "scopes": ["source.abl", "meta.brace.round.js"] } // ')'
|
|
95
|
+
];
|
|
96
|
+
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
97
|
+
})
|
|
98
|
+
|
|
99
|
+
|
|
100
|
+
describe('', () => {
|
|
101
|
+
let statement = `ASSIGN oVar = NEW Progress.Collections.List<String> (new Comparer())`;
|
|
102
|
+
|
|
103
|
+
let expectedTokens = [
|
|
104
|
+
{ "startIndex": 0, "endIndex": 6, "scopes": ["source.abl", "keyword.other.abl"] }, // 'ASSIGN'
|
|
105
|
+
{ "startIndex": 6, "endIndex": 7, "scopes": ["source.abl"] }, // ' '
|
|
106
|
+
{ "startIndex": 7, "endIndex": 11, "scopes": ["source.abl", "variable.other.abl"] }, // 'oVar'
|
|
107
|
+
{ "startIndex": 11, "endIndex": 12, "scopes": ["source.abl"] }, // ' '
|
|
108
|
+
{ "startIndex": 12, "endIndex": 13, "scopes": ["source.abl", "keyword.operator.source.abl"] }, // '='
|
|
109
|
+
{ "startIndex": 13, "endIndex": 14, "scopes": ["source.abl"] }, // ' '
|
|
110
|
+
{ "startIndex": 14, "endIndex": 17, "scopes": ["source.abl", "keyword.other.abl"] }, // 'NEW'
|
|
111
|
+
{ "startIndex": 17, "endIndex": 18, "scopes": ["source.abl"] }, // ' '
|
|
112
|
+
{ "startIndex": 18, "endIndex": 43, "scopes": ["source.abl", "entity.name.type.generic.abl", "entity.name.type.abl"] }, // 'Progress.Collections.List'
|
|
113
|
+
{ "startIndex": 43, "endIndex": 44, "scopes": ["source.abl", "entity.name.type.generic.abl"] }, // '<'
|
|
114
|
+
{ "startIndex": 44, "endIndex": 50, "scopes": ["source.abl", "entity.name.type.generic.abl", "entity.name.type.abl"] }, // 'String'
|
|
115
|
+
{ "startIndex": 50, "endIndex": 51, "scopes": ["source.abl", "entity.name.type.generic.abl"] }, // '>'
|
|
116
|
+
{ "startIndex": 51, "endIndex": 52, "scopes": ["source.abl"] }, // ' '
|
|
117
|
+
{ "startIndex": 52, "endIndex": 53, "scopes": ["source.abl", "meta.function.arguments.abl", "meta.brace.round.js"] }, // '('
|
|
118
|
+
{ "startIndex": 53, "endIndex": 56, "scopes": ["source.abl", "meta.function.arguments.abl", "keyword.other.abl"] }, // 'new'
|
|
119
|
+
{ "startIndex": 56, "endIndex": 57, "scopes": ["source.abl", "meta.function.arguments.abl"] }, // ' '
|
|
120
|
+
{ "startIndex": 57, "endIndex": 65, "scopes": ["source.abl", "meta.function.arguments.abl", "entity.name.type.abl"] }, // 'Comparer'
|
|
121
|
+
{ "startIndex": 65, "endIndex": 66, "scopes": ["source.abl", "meta.function.arguments.abl", "meta.brace.round.js"] }, // '('
|
|
122
|
+
{ "startIndex": 66, "endIndex": 67, "scopes": ["source.abl", "meta.brace.round.js"] }, // ')'
|
|
123
|
+
{ "startIndex": 67, "endIndex": 68, "scopes": ["source.abl", "meta.brace.round.js"] } // ')'
|
|
124
|
+
];
|
|
125
|
+
shared.itShouldMatchExpectedScopes(statement, expectedTokens);
|
|
126
|
+
})
|