@abaplint/core 2.85.17 → 2.85.21
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/build/abaplint.d.ts +8 -0
- package/build/src/abap/2_statements/expressions/cond_body.js +1 -1
- package/build/src/abap/2_statements/expressions/reduce_next.js +2 -1
- package/build/src/abap/2_statements/expressions/select.js +1 -1
- package/build/src/abap/2_statements/expressions/type_table.js +1 -1
- package/build/src/abap/2_statements/statements/select.js +1 -1
- package/build/src/abap/5_syntax/_builtin.js +2 -1
- package/build/src/abap/5_syntax/_current_scope.js +6 -6
- package/build/src/abap/5_syntax/_type_utils.js +99 -3
- package/build/src/abap/5_syntax/expressions/cast.js +21 -9
- package/build/src/abap/5_syntax/expressions/method_call_param.js +1 -1
- package/build/src/abap/5_syntax/expressions/method_parameters.js +4 -4
- package/build/src/abap/5_syntax/expressions/raise_with.js +14 -0
- package/build/src/abap/5_syntax/statements/move.js +6 -1
- package/build/src/abap/5_syntax/statements/raise.js +4 -0
- package/build/src/abap/5_syntax/statements/read_table.js +3 -3
- package/build/src/abap/5_syntax/statements/shift.js +2 -2
- package/build/src/abap/5_syntax/statements/write.js +2 -2
- package/build/src/objects/number_range.js +36 -2
- package/build/src/registry.js +1 -1
- package/build/src/rules/downport.js +87 -22
- package/build/src/rules/function_module_recommendations.js +3 -1
- package/build/src/version.js +1 -1
- package/package.json +6 -6
package/build/abaplint.d.ts
CHANGED
|
@@ -3824,11 +3824,19 @@ declare class Normal implements IStructure {
|
|
|
3824
3824
|
}
|
|
3825
3825
|
|
|
3826
3826
|
declare class NumberRange extends AbstractObject {
|
|
3827
|
+
private parsedXML;
|
|
3827
3828
|
getType(): string;
|
|
3828
3829
|
getAllowedNaming(): {
|
|
3829
3830
|
maxLength: number;
|
|
3830
3831
|
allowNamespace: boolean;
|
|
3831
3832
|
};
|
|
3833
|
+
getDomain(): string | undefined;
|
|
3834
|
+
getPercentage(): number | undefined;
|
|
3835
|
+
setDirty(): void;
|
|
3836
|
+
parse(): {
|
|
3837
|
+
updated: boolean;
|
|
3838
|
+
runtime: number;
|
|
3839
|
+
};
|
|
3832
3840
|
getDescription(): string | undefined;
|
|
3833
3841
|
}
|
|
3834
3842
|
|
|
@@ -5,7 +5,7 @@ const combi_1 = require("../combi");
|
|
|
5
5
|
const _1 = require(".");
|
|
6
6
|
class CondBody extends combi_1.Expression {
|
|
7
7
|
getRunnable() {
|
|
8
|
-
const when = (0, combi_1.seq)("WHEN", _1.Cond, "THEN", (0, combi_1.alt)(_1.Source, _1.Throw));
|
|
8
|
+
const when = (0, combi_1.seq)("WHEN", (0, combi_1.alt)(_1.Cond, _1.Source), "THEN", (0, combi_1.alt)(_1.Source, _1.Throw));
|
|
9
9
|
const elsee = (0, combi_1.seq)("ELSE", (0, combi_1.alt)(_1.Source, _1.Throw));
|
|
10
10
|
return (0, combi_1.seq)((0, combi_1.opt)(_1.Let), (0, combi_1.plus)(when), (0, combi_1.opt)(elsee));
|
|
11
11
|
}
|
|
@@ -3,9 +3,10 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.ReduceNext = void 0;
|
|
4
4
|
const combi_1 = require("../combi");
|
|
5
5
|
const _1 = require(".");
|
|
6
|
+
const tokens_1 = require("../../1_lexer/tokens");
|
|
6
7
|
class ReduceNext extends combi_1.Expression {
|
|
7
8
|
getRunnable() {
|
|
8
|
-
const fields = (0, combi_1.seq)(_1.Field, "=", _1.Source);
|
|
9
|
+
const fields = (0, combi_1.seq)(_1.Field, (0, combi_1.altPrio)("=", (0, combi_1.seq)((0, combi_1.tok)(tokens_1.WPlus), "=")), _1.Source);
|
|
9
10
|
return (0, combi_1.seq)("NEXT", (0, combi_1.plus)(fields));
|
|
10
11
|
}
|
|
11
12
|
}
|
|
@@ -19,7 +19,7 @@ class Select extends combi_1.Expression {
|
|
|
19
19
|
const fields = (0, combi_1.seq)("FIELDS", _1.SQLFieldList);
|
|
20
20
|
const perm = (0, combi_1.per)(_1.SQLFrom, into, _1.SQLForAllEntries, where, _1.SQLOrderBy, up, offset, client, _1.SQLHaving, bypass, sql_group_by_1.SQLGroupBy, fields, _1.DatabaseConnection);
|
|
21
21
|
const paren = (0, combi_1.seq)((0, combi_1.tok)(tokens_1.WParenLeftW), sql_field_name_1.SQLFieldName, (0, combi_1.tok)(tokens_1.WParenRightW));
|
|
22
|
-
const ret = (0, combi_1.seq)("SELECT", (0, combi_1.altPrio)("DISTINCT", (0, combi_1.optPrio)((0, combi_1.seq)("SINGLE", (0, combi_1.optPrio)("FOR UPDATE")))), (0, combi_1.optPrio)((0, combi_1.altPrio)(_1.SQLFieldList, paren)), perm);
|
|
22
|
+
const ret = (0, combi_1.seq)("SELECT", (0, combi_1.altPrio)("DISTINCT", (0, combi_1.optPrio)((0, combi_1.seq)("SINGLE", (0, combi_1.optPrio)("FOR UPDATE")))), (0, combi_1.optPrio)((0, combi_1.altPrio)(_1.SQLFieldList, paren)), perm, (0, combi_1.optPrio)(_1.SQLHints));
|
|
23
23
|
return ret;
|
|
24
24
|
}
|
|
25
25
|
}
|
|
@@ -13,7 +13,7 @@ class TypeTable extends combi_1.Expression {
|
|
|
13
13
|
const likeType = (0, combi_1.seq)((0, combi_1.opt)((0, combi_1.alt)("STANDARD", "HASHED", "INDEX", "SORTED", "ANY")), "TABLE OF", (0, combi_1.optPrio)("REF TO"), (0, combi_1.opt)(field_chain_1.FieldChain), (0, combi_1.opt)((0, combi_1.per)(header, initial, (0, combi_1.plusPrio)(type_table_key_1.TypeTableKey))));
|
|
14
14
|
const rangeType = (0, combi_1.seq)("RANGE OF", _1.TypeName, (0, combi_1.opt)(header), (0, combi_1.opt)(initial));
|
|
15
15
|
const rangeLike = (0, combi_1.seq)("RANGE OF", _1.SimpleFieldChain, (0, combi_1.opt)(header), (0, combi_1.opt)(initial));
|
|
16
|
-
const typetable = (0, combi_1.seq)(normal1, (0, combi_1.opt)((0, combi_1.per)(header, initial, (0, combi_1.plusPrio)(type_table_key_1.TypeTableKey))));
|
|
16
|
+
const typetable = (0, combi_1.seq)(normal1, (0, combi_1.alt)((0, combi_1.opt)((0, combi_1.per)(header, initial, (0, combi_1.plusPrio)(type_table_key_1.TypeTableKey))), (0, combi_1.seq)((0, combi_1.plus)(type_table_key_1.TypeTableKey), (0, combi_1.optPrio)(initial))));
|
|
17
17
|
const occurs = (0, combi_1.seq)("OCCURS", _1.Integer);
|
|
18
18
|
const oldType = (0, combi_1.seq)((0, combi_1.opt)("REF TO"), _1.TypeName, (0, combi_1.alt)((0, combi_1.seq)(occurs, (0, combi_1.opt)(header)), header));
|
|
19
19
|
const oldLike = (0, combi_1.seq)((0, combi_1.opt)("REF TO"), field_chain_1.FieldChain, (0, combi_1.alt)((0, combi_1.seq)(occurs, (0, combi_1.opt)(header)), header));
|
|
@@ -7,7 +7,7 @@ const version_1 = require("../../../version");
|
|
|
7
7
|
class Select {
|
|
8
8
|
getMatcher() {
|
|
9
9
|
const union = (0, combi_1.ver)(version_1.Version.v750, (0, combi_1.seq)("UNION", (0, combi_1.optPrio)((0, combi_1.altPrio)("DISTINCT", "ALL")), expressions_1.Select));
|
|
10
|
-
return (0, combi_1.seq)(expressions_1.Select, (0, combi_1.starPrio)(union)
|
|
10
|
+
return (0, combi_1.seq)(expressions_1.Select, (0, combi_1.starPrio)(union));
|
|
11
11
|
}
|
|
12
12
|
}
|
|
13
13
|
exports.Select = Select;
|
|
@@ -169,9 +169,9 @@ class BuiltIn {
|
|
|
169
169
|
components.push({ name: "folen", type: new basic_1.IntegerType() });
|
|
170
170
|
components.push({ name: "host", type: new basic_1.CharacterType(32, "sy-host") });
|
|
171
171
|
components.push({ name: "index", type: new basic_1.IntegerType() });
|
|
172
|
+
components.push({ name: "input", type: new basic_1.CharacterType(1, "sy-input") });
|
|
172
173
|
components.push({ name: "langu", type: new basic_1.CharacterType(1, "sy-langu") });
|
|
173
174
|
components.push({ name: "ldbpg", type: new basic_1.CharacterType(40, "sy-ldbpg") });
|
|
174
|
-
components.push({ name: "pdest", type: new basic_1.CharacterType(4, "sy-pdest") });
|
|
175
175
|
components.push({ name: "lilli", type: new basic_1.IntegerType() });
|
|
176
176
|
components.push({ name: "linct", type: new basic_1.IntegerType() });
|
|
177
177
|
components.push({ name: "linno", type: new basic_1.IntegerType() });
|
|
@@ -194,6 +194,7 @@ class BuiltIn {
|
|
|
194
194
|
components.push({ name: "msgv4", type: new basic_1.CharacterType(50, "sy-msgv4") });
|
|
195
195
|
components.push({ name: "opsys", type: new basic_1.CharacterType(10, "sy-opsys") });
|
|
196
196
|
components.push({ name: "pagno", type: new basic_1.IntegerType() });
|
|
197
|
+
components.push({ name: "pdest", type: new basic_1.CharacterType(4, "sy-pdest") });
|
|
197
198
|
components.push({ name: "pfkey", type: new basic_1.CharacterType(20, "sy-pfkey") });
|
|
198
199
|
components.push({ name: "repid", type: new basic_1.CharacterType(40, "sy-repid") });
|
|
199
200
|
components.push({ name: "saprl", type: new basic_1.CharacterType(4, "sy-saprl") });
|
|
@@ -166,11 +166,7 @@ class CurrentScope {
|
|
|
166
166
|
if (name === undefined) {
|
|
167
167
|
return { found: false };
|
|
168
168
|
}
|
|
169
|
-
const
|
|
170
|
-
if (def !== undefined) {
|
|
171
|
-
return { found: true, id: def };
|
|
172
|
-
}
|
|
173
|
-
const findLocalClass = (_b = this.current) === null || _b === void 0 ? void 0 : _b.findClassDefinition(name);
|
|
169
|
+
const findLocalClass = (_a = this.current) === null || _a === void 0 ? void 0 : _a.findClassDefinition(name);
|
|
174
170
|
if (findLocalClass) {
|
|
175
171
|
return { found: true, id: findLocalClass, type: _reference_1.ReferenceType.ObjectOrientedReference, ooType: "CLAS" };
|
|
176
172
|
}
|
|
@@ -178,7 +174,7 @@ class CurrentScope {
|
|
|
178
174
|
if (globalClas) {
|
|
179
175
|
return { found: true, id: globalClas.getIdentifier(), type: _reference_1.ReferenceType.ObjectOrientedReference, ooType: "CLAS" };
|
|
180
176
|
}
|
|
181
|
-
const findLocalInterface = (
|
|
177
|
+
const findLocalInterface = (_b = this.current) === null || _b === void 0 ? void 0 : _b.findInterfaceDefinition(name);
|
|
182
178
|
if (findLocalInterface) {
|
|
183
179
|
return { found: true, id: findLocalInterface, type: _reference_1.ReferenceType.ObjectOrientedReference, ooType: "INTF" };
|
|
184
180
|
}
|
|
@@ -186,6 +182,10 @@ class CurrentScope {
|
|
|
186
182
|
if (globalIntf) {
|
|
187
183
|
return { found: true, id: globalIntf.getIdentifier(), type: _reference_1.ReferenceType.ObjectOrientedReference, ooType: "INTF" };
|
|
188
184
|
}
|
|
185
|
+
const def = (_c = this.current) === null || _c === void 0 ? void 0 : _c.findDeferred(name);
|
|
186
|
+
if (def !== undefined) {
|
|
187
|
+
return { found: true, id: def };
|
|
188
|
+
}
|
|
189
189
|
return { found: false };
|
|
190
190
|
}
|
|
191
191
|
///////////////////////////
|
|
@@ -1,9 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.TypeUtils = void 0;
|
|
4
|
+
const types_1 = require("../types");
|
|
4
5
|
const basic_1 = require("../types/basic");
|
|
5
6
|
class TypeUtils {
|
|
6
|
-
|
|
7
|
+
constructor(scope) {
|
|
8
|
+
this.scope = scope;
|
|
9
|
+
}
|
|
10
|
+
isCharLike(type) {
|
|
7
11
|
if (type === undefined) {
|
|
8
12
|
return false;
|
|
9
13
|
}
|
|
@@ -40,7 +44,7 @@ class TypeUtils {
|
|
|
40
44
|
}
|
|
41
45
|
return false;
|
|
42
46
|
}
|
|
43
|
-
|
|
47
|
+
isHexLike(type) {
|
|
44
48
|
if (type === undefined) {
|
|
45
49
|
return false;
|
|
46
50
|
}
|
|
@@ -61,7 +65,96 @@ class TypeUtils {
|
|
|
61
65
|
}
|
|
62
66
|
return false;
|
|
63
67
|
}
|
|
64
|
-
|
|
68
|
+
isOOAssignable(source, target) {
|
|
69
|
+
let sid = source.getIdentifier();
|
|
70
|
+
if (!(sid instanceof types_1.ClassDefinition || sid instanceof types_1.InterfaceDefinition)) {
|
|
71
|
+
const found = this.scope.findObjectDefinition(sid.getName());
|
|
72
|
+
if (found) {
|
|
73
|
+
sid = found;
|
|
74
|
+
}
|
|
75
|
+
else {
|
|
76
|
+
return false;
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
let tid = target.getIdentifier();
|
|
80
|
+
if (!(tid instanceof types_1.ClassDefinition || tid instanceof types_1.InterfaceDefinition)) {
|
|
81
|
+
const found = this.scope.findObjectDefinition(tid.getName());
|
|
82
|
+
if (found) {
|
|
83
|
+
tid = found;
|
|
84
|
+
}
|
|
85
|
+
else {
|
|
86
|
+
return false;
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
const tname = tid.getName().toUpperCase();
|
|
90
|
+
if (sid instanceof types_1.ClassDefinition && tid instanceof types_1.ClassDefinition) {
|
|
91
|
+
if (sid.getName().toUpperCase() === tname) {
|
|
92
|
+
return true;
|
|
93
|
+
}
|
|
94
|
+
const slist = this.listAllSupers(sid);
|
|
95
|
+
if (slist.indexOf(tname) >= 0) {
|
|
96
|
+
return true;
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
else if (sid instanceof types_1.ClassDefinition && tid instanceof types_1.InterfaceDefinition) {
|
|
100
|
+
if (sid.getImplementing().some(i => i.name === tname)) {
|
|
101
|
+
return true;
|
|
102
|
+
}
|
|
103
|
+
const slist = this.listAllInterfaces(sid);
|
|
104
|
+
if (slist.indexOf(tname) >= 0) {
|
|
105
|
+
return true;
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
else if (sid instanceof types_1.InterfaceDefinition && tid instanceof types_1.InterfaceDefinition) {
|
|
109
|
+
if (sid.getName().toUpperCase() === tname) {
|
|
110
|
+
return true;
|
|
111
|
+
}
|
|
112
|
+
if (sid.getImplementing().some(i => i.name === tname)) {
|
|
113
|
+
return true;
|
|
114
|
+
}
|
|
115
|
+
const slist = this.listAllInterfaces(sid);
|
|
116
|
+
if (slist.indexOf(tname) >= 0) {
|
|
117
|
+
return true;
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
return false;
|
|
121
|
+
}
|
|
122
|
+
listAllInterfaces(cdef) {
|
|
123
|
+
var _a;
|
|
124
|
+
const ret = new Set();
|
|
125
|
+
const stack = [];
|
|
126
|
+
// initialize
|
|
127
|
+
cdef.getImplementing().forEach(i => stack.push(i.name));
|
|
128
|
+
if (cdef instanceof types_1.ClassDefinition) {
|
|
129
|
+
const supers = this.listAllSupers(cdef);
|
|
130
|
+
for (const s of supers) {
|
|
131
|
+
(_a = this.scope.findClassDefinition(s)) === null || _a === void 0 ? void 0 : _a.getImplementing().forEach(i => stack.push(i.name));
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
// main loop
|
|
135
|
+
while (stack.length > 0) {
|
|
136
|
+
const intf = stack.pop().toUpperCase();
|
|
137
|
+
ret.add(intf);
|
|
138
|
+
const idef = this.scope.findInterfaceDefinition(intf);
|
|
139
|
+
idef === null || idef === void 0 ? void 0 : idef.getImplementing().forEach(i => stack.push(i.name));
|
|
140
|
+
}
|
|
141
|
+
return Array.from(ret.values());
|
|
142
|
+
}
|
|
143
|
+
listAllSupers(cdef) {
|
|
144
|
+
var _a, _b;
|
|
145
|
+
const ret = [];
|
|
146
|
+
let sup = cdef.getSuperClass();
|
|
147
|
+
while (sup !== undefined) {
|
|
148
|
+
ret.push(sup === null || sup === void 0 ? void 0 : sup.toUpperCase());
|
|
149
|
+
sup = (_b = (_a = this.scope.findClassDefinition(sup)) === null || _a === void 0 ? void 0 : _a.getSuperClass()) === null || _b === void 0 ? void 0 : _b.toUpperCase();
|
|
150
|
+
}
|
|
151
|
+
return ret;
|
|
152
|
+
}
|
|
153
|
+
isCastable(_source, _target) {
|
|
154
|
+
// todo
|
|
155
|
+
return true;
|
|
156
|
+
}
|
|
157
|
+
isAssignable(source, target) {
|
|
65
158
|
/*
|
|
66
159
|
console.dir(source);
|
|
67
160
|
console.dir(target);
|
|
@@ -78,6 +171,9 @@ class TypeUtils {
|
|
|
78
171
|
}
|
|
79
172
|
return false;
|
|
80
173
|
}
|
|
174
|
+
else if (target instanceof basic_1.ObjectReferenceType && source instanceof basic_1.ObjectReferenceType) {
|
|
175
|
+
return this.isOOAssignable(source, target);
|
|
176
|
+
}
|
|
81
177
|
else if (target instanceof basic_1.ObjectReferenceType
|
|
82
178
|
|| target instanceof basic_1.GenericObjectReferenceType) {
|
|
83
179
|
if (source instanceof basic_1.ObjectReferenceType
|
|
@@ -4,30 +4,42 @@ exports.Cast = void 0;
|
|
|
4
4
|
const basic_1 = require("../../types/basic");
|
|
5
5
|
const Expressions = require("../../2_statements/expressions");
|
|
6
6
|
const source_1 = require("./source");
|
|
7
|
+
const _type_utils_1 = require("../_type_utils");
|
|
7
8
|
class Cast {
|
|
8
9
|
runSyntax(node, scope, targetType, filename) {
|
|
9
10
|
var _a;
|
|
10
|
-
|
|
11
|
-
|
|
11
|
+
const sourceNode = node.findDirectExpression(Expressions.Source);
|
|
12
|
+
if (sourceNode === undefined) {
|
|
13
|
+
throw new Error("Cast, source node not found");
|
|
12
14
|
}
|
|
15
|
+
const sourceType = new source_1.Source().runSyntax(sourceNode, scope, filename);
|
|
16
|
+
let tt = undefined;
|
|
13
17
|
const typeName = (_a = node.findDirectExpression(Expressions.TypeNameOrInfer)) === null || _a === void 0 ? void 0 : _a.getFirstToken().getStr();
|
|
14
18
|
if (typeName === undefined) {
|
|
15
19
|
throw new Error("Cast, child TypeNameOrInfer not found");
|
|
16
20
|
}
|
|
17
21
|
else if (typeName === "#" && targetType) {
|
|
18
|
-
|
|
22
|
+
tt = targetType;
|
|
19
23
|
}
|
|
20
24
|
else if (typeName === "#") {
|
|
21
25
|
throw new Error("Cast, todo, infer type");
|
|
22
26
|
}
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
27
|
+
if (tt === undefined) {
|
|
28
|
+
const found = scope.findObjectDefinition(typeName);
|
|
29
|
+
if (found === undefined && scope.getDDIC().inErrorNamespace(typeName) === false) {
|
|
30
|
+
tt = new basic_1.VoidType(typeName);
|
|
31
|
+
}
|
|
32
|
+
else if (found === undefined) {
|
|
33
|
+
throw new Error("Type \"" + typeName + "\" not found in scope, Cast");
|
|
34
|
+
}
|
|
35
|
+
else {
|
|
36
|
+
tt = new basic_1.ObjectReferenceType(found);
|
|
37
|
+
}
|
|
26
38
|
}
|
|
27
|
-
|
|
28
|
-
throw new Error("
|
|
39
|
+
if (new _type_utils_1.TypeUtils(scope).isCastable(sourceType, tt) === false) {
|
|
40
|
+
throw new Error("Cast, incompatible types");
|
|
29
41
|
}
|
|
30
|
-
return
|
|
42
|
+
return tt;
|
|
31
43
|
}
|
|
32
44
|
}
|
|
33
45
|
exports.Cast = Cast;
|
|
@@ -50,7 +50,7 @@ class MethodCallParam {
|
|
|
50
50
|
if (sourceType === undefined) {
|
|
51
51
|
throw new Error("No source type determined, method source");
|
|
52
52
|
}
|
|
53
|
-
else if (_type_utils_1.TypeUtils.isAssignable(sourceType, targetType) === false) {
|
|
53
|
+
else if (new _type_utils_1.TypeUtils(scope).isAssignable(sourceType, targetType) === false) {
|
|
54
54
|
throw new Error("Method parameter type not compatible");
|
|
55
55
|
}
|
|
56
56
|
}
|
|
@@ -65,7 +65,7 @@ class MethodParameters {
|
|
|
65
65
|
}
|
|
66
66
|
else if (target) {
|
|
67
67
|
const targetType = new target_1.Target().runSyntax(target, scope, filename);
|
|
68
|
-
if (targetType && _type_utils_1.TypeUtils.isAssignable(type, targetType) === false) {
|
|
68
|
+
if (targetType && new _type_utils_1.TypeUtils(scope).isAssignable(type, targetType) === false) {
|
|
69
69
|
throw new Error("Method returning value not type compatible");
|
|
70
70
|
}
|
|
71
71
|
}
|
|
@@ -90,7 +90,7 @@ class MethodParameters {
|
|
|
90
90
|
else if (item.targetType === undefined) {
|
|
91
91
|
throw new Error("Could not determine target type");
|
|
92
92
|
}
|
|
93
|
-
else if (item.targetType && _type_utils_1.TypeUtils.isAssignable(parameterType, item.targetType) === false) {
|
|
93
|
+
else if (item.targetType && new _type_utils_1.TypeUtils(scope).isAssignable(parameterType, item.targetType) === false) {
|
|
94
94
|
throw new Error("Method parameter type not compatible, " + item.name);
|
|
95
95
|
}
|
|
96
96
|
}
|
|
@@ -109,7 +109,7 @@ class MethodParameters {
|
|
|
109
109
|
}
|
|
110
110
|
parameterType = parameter.getType();
|
|
111
111
|
}
|
|
112
|
-
if (item.targetType && _type_utils_1.TypeUtils.isAssignable(parameterType, item.targetType) === false) {
|
|
112
|
+
if (item.targetType && new _type_utils_1.TypeUtils(scope).isAssignable(parameterType, item.targetType) === false) {
|
|
113
113
|
throw new Error("Method parameter type not compatible, " + item.name);
|
|
114
114
|
}
|
|
115
115
|
(_a = this.requiredParameters) === null || _a === void 0 ? void 0 : _a.delete(item.name);
|
|
@@ -129,7 +129,7 @@ class MethodParameters {
|
|
|
129
129
|
if (parameter === undefined) {
|
|
130
130
|
throw new Error("Method importing parameter \"" + item.name + "\" does not exist");
|
|
131
131
|
}
|
|
132
|
-
else if (_type_utils_1.TypeUtils.isAssignable(parameter.getType()
|
|
132
|
+
else if (new _type_utils_1.TypeUtils(scope).isAssignable(item.sourceType, parameter.getType()) === false) {
|
|
133
133
|
throw new Error("Method parameter type not compatible, " + item.name);
|
|
134
134
|
}
|
|
135
135
|
this.requiredParameters.delete(item.name);
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.RaiseWith = void 0;
|
|
4
|
+
const Expressions = require("../../2_statements/expressions");
|
|
5
|
+
const source_1 = require("./source");
|
|
6
|
+
class RaiseWith {
|
|
7
|
+
runSyntax(node, scope, filename) {
|
|
8
|
+
for (const f of node.findDirectExpressions(Expressions.Source)) {
|
|
9
|
+
new source_1.Source().runSyntax(f, scope, filename);
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
exports.RaiseWith = RaiseWith;
|
|
14
|
+
//# sourceMappingURL=raise_with.js.map
|
|
@@ -30,7 +30,12 @@ class Move {
|
|
|
30
30
|
new inline_data_1.InlineData().runSyntax(inline, scope, filename, sourceType);
|
|
31
31
|
targetType = sourceType;
|
|
32
32
|
}
|
|
33
|
-
if (
|
|
33
|
+
if (node.findDirectTokenByText("?=")) {
|
|
34
|
+
if (new _type_utils_1.TypeUtils(scope).isCastable(sourceType, targetType) === false) {
|
|
35
|
+
throw new Error("Incompatible types");
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
else if (new _type_utils_1.TypeUtils(scope).isAssignable(sourceType, targetType) === false) {
|
|
34
39
|
throw new Error("Incompatible types");
|
|
35
40
|
}
|
|
36
41
|
}
|
|
@@ -7,6 +7,7 @@ const source_1 = require("../expressions/source");
|
|
|
7
7
|
const _reference_1 = require("../_reference");
|
|
8
8
|
const basic_1 = require("../../types/basic");
|
|
9
9
|
const message_source_1 = require("../expressions/message_source");
|
|
10
|
+
const raise_with_1 = require("../expressions/raise_with");
|
|
10
11
|
class Raise {
|
|
11
12
|
runSyntax(node, scope, filename) {
|
|
12
13
|
// todo
|
|
@@ -47,6 +48,9 @@ class Raise {
|
|
|
47
48
|
new source_1.Source().runSyntax(s, scope, filename);
|
|
48
49
|
}
|
|
49
50
|
}
|
|
51
|
+
for (const s of node.findDirectExpressions(Expressions.RaiseWith)) {
|
|
52
|
+
new raise_with_1.RaiseWith().runSyntax(s, scope, filename);
|
|
53
|
+
}
|
|
50
54
|
for (const s of node.findDirectExpressions(Expressions.Source)) {
|
|
51
55
|
new source_1.Source().runSyntax(s, scope, filename);
|
|
52
56
|
}
|
|
@@ -35,14 +35,14 @@ class ReadTable {
|
|
|
35
35
|
const indexSource = node.findExpressionAfterToken("INDEX");
|
|
36
36
|
if (indexSource) {
|
|
37
37
|
const indexType = new source_1.Source().runSyntax(indexSource, scope, filename);
|
|
38
|
-
if (_type_utils_1.TypeUtils.isAssignable(indexType, new basic_1.IntegerType()) === false) {
|
|
38
|
+
if (new _type_utils_1.TypeUtils(scope).isAssignable(indexType, new basic_1.IntegerType()) === false) {
|
|
39
39
|
throw new Error("READ TABLE, INDEX must be simple");
|
|
40
40
|
}
|
|
41
41
|
}
|
|
42
42
|
const fromSource = node.findExpressionAfterToken("FROM");
|
|
43
43
|
if (fromSource) {
|
|
44
44
|
const fromType = new source_1.Source().runSyntax(fromSource, scope, filename);
|
|
45
|
-
if (_type_utils_1.TypeUtils.isAssignable(fromType, new basic_1.IntegerType()) === false) {
|
|
45
|
+
if (new _type_utils_1.TypeUtils(scope).isAssignable(fromType, new basic_1.IntegerType()) === false) {
|
|
46
46
|
throw new Error("READ TABLE, FROM must be simple");
|
|
47
47
|
}
|
|
48
48
|
}
|
|
@@ -77,7 +77,7 @@ class ReadTable {
|
|
|
77
77
|
const t = target.findFirstExpression(Expressions.Target);
|
|
78
78
|
if (t) {
|
|
79
79
|
const targetType = new target_1.Target().runSyntax(t, scope, filename);
|
|
80
|
-
if (_type_utils_1.TypeUtils.isAssignable(rowType, targetType) === false) {
|
|
80
|
+
if (new _type_utils_1.TypeUtils(scope).isAssignable(rowType, targetType) === false) {
|
|
81
81
|
throw new Error("Incompatible types");
|
|
82
82
|
}
|
|
83
83
|
return;
|
|
@@ -16,12 +16,12 @@ class Shift {
|
|
|
16
16
|
}
|
|
17
17
|
const targetType = new target_1.Target().runSyntax(target, scope, filename);
|
|
18
18
|
if (node.concatTokens().toUpperCase().includes(" IN BYTE MODE")) {
|
|
19
|
-
if (_type_utils_1.TypeUtils.isHexLike(targetType) === false) {
|
|
19
|
+
if (new _type_utils_1.TypeUtils(scope).isHexLike(targetType) === false) {
|
|
20
20
|
throw new Error("Shift, Target not hex like");
|
|
21
21
|
}
|
|
22
22
|
}
|
|
23
23
|
else {
|
|
24
|
-
if (_type_utils_1.TypeUtils.isCharLike(targetType) === false) {
|
|
24
|
+
if (new _type_utils_1.TypeUtils(scope).isCharLike(targetType) === false) {
|
|
25
25
|
throw new Error("Shift, Target not char like");
|
|
26
26
|
}
|
|
27
27
|
}
|
|
@@ -13,8 +13,8 @@ class Write {
|
|
|
13
13
|
for (const s of node.findAllExpressions(Expressions.Source)) {
|
|
14
14
|
const type = new source_1.Source().runSyntax(s, scope, filename);
|
|
15
15
|
if (s === second
|
|
16
|
-
&& _type_utils_1.TypeUtils.isCharLike(type) === false
|
|
17
|
-
&& _type_utils_1.TypeUtils.isHexLike(type) === false) {
|
|
16
|
+
&& new _type_utils_1.TypeUtils(scope).isCharLike(type) === false
|
|
17
|
+
&& new _type_utils_1.TypeUtils(scope).isHexLike(type) === false) {
|
|
18
18
|
throw new Error("Source not character like");
|
|
19
19
|
}
|
|
20
20
|
}
|
|
@@ -12,9 +12,43 @@ class NumberRange extends _abstract_object_1.AbstractObject {
|
|
|
12
12
|
allowNamespace: true,
|
|
13
13
|
};
|
|
14
14
|
}
|
|
15
|
+
getDomain() {
|
|
16
|
+
var _a;
|
|
17
|
+
this.parse();
|
|
18
|
+
return (_a = this.parsedXML) === null || _a === void 0 ? void 0 : _a.domain;
|
|
19
|
+
}
|
|
20
|
+
getPercentage() {
|
|
21
|
+
var _a;
|
|
22
|
+
this.parse();
|
|
23
|
+
return (_a = this.parsedXML) === null || _a === void 0 ? void 0 : _a.percentage;
|
|
24
|
+
}
|
|
25
|
+
setDirty() {
|
|
26
|
+
this.parsedXML = undefined;
|
|
27
|
+
super.setDirty();
|
|
28
|
+
}
|
|
29
|
+
parse() {
|
|
30
|
+
var _a, _b, _c, _d, _e, _f;
|
|
31
|
+
if (this.parsedXML) {
|
|
32
|
+
return { updated: false, runtime: 0 };
|
|
33
|
+
}
|
|
34
|
+
const start = Date.now();
|
|
35
|
+
this.parsedXML = {};
|
|
36
|
+
const parsed = super.parseRaw2();
|
|
37
|
+
if (parsed === undefined) {
|
|
38
|
+
return { updated: false, runtime: 0 };
|
|
39
|
+
}
|
|
40
|
+
const text = (_c = (_b = (_a = parsed.abapGit) === null || _a === void 0 ? void 0 : _a["asx:abap"]) === null || _b === void 0 ? void 0 : _b["asx:values"]) === null || _c === void 0 ? void 0 : _c.TEXT;
|
|
41
|
+
this.parsedXML.description = text === null || text === void 0 ? void 0 : text.TXT;
|
|
42
|
+
const attributes = (_f = (_e = (_d = parsed.abapGit) === null || _d === void 0 ? void 0 : _d["asx:abap"]) === null || _e === void 0 ? void 0 : _e["asx:values"]) === null || _f === void 0 ? void 0 : _f.ATTRIBUTES;
|
|
43
|
+
this.parsedXML.domain = attributes === null || attributes === void 0 ? void 0 : attributes.DOMLEN;
|
|
44
|
+
this.parsedXML.percentage = parseFloat((attributes === null || attributes === void 0 ? void 0 : attributes.PERCENTAGE) || "");
|
|
45
|
+
const end = Date.now();
|
|
46
|
+
return { updated: true, runtime: end - start };
|
|
47
|
+
}
|
|
15
48
|
getDescription() {
|
|
16
|
-
|
|
17
|
-
|
|
49
|
+
var _a;
|
|
50
|
+
this.parse();
|
|
51
|
+
return (_a = this.parsedXML) === null || _a === void 0 ? void 0 : _a.description;
|
|
18
52
|
}
|
|
19
53
|
}
|
|
20
54
|
exports.NumberRange = NumberRange;
|
package/build/src/registry.js
CHANGED
|
@@ -56,6 +56,7 @@ Current rules:
|
|
|
56
56
|
* PARTIALLY IMPLEMENTED removed, it can be quick fixed via rule implement_methods
|
|
57
57
|
* RAISE EXCEPTION ... MESSAGE
|
|
58
58
|
* APPEND expression is outlined
|
|
59
|
+
* Moving with +=, -=, /=, *=, &&=
|
|
59
60
|
|
|
60
61
|
Only one transformation is applied to a statement at a time, so multiple steps might be required to do the full downport.`,
|
|
61
62
|
tags: [_irule_1.RuleTag.Experimental, _irule_1.RuleTag.Downport, _irule_1.RuleTag.Quickfix],
|
|
@@ -163,6 +164,10 @@ Only one transformation is applied to a statement at a time, so multiple steps m
|
|
|
163
164
|
if (found) {
|
|
164
165
|
return found;
|
|
165
166
|
}
|
|
167
|
+
found = this.moveWithOperator(high, lowFile);
|
|
168
|
+
if (found) {
|
|
169
|
+
return found;
|
|
170
|
+
}
|
|
166
171
|
found = this.downportSelectInline(low, high, lowFile, highSyntax);
|
|
167
172
|
if (found) {
|
|
168
173
|
return found;
|
|
@@ -560,6 +565,48 @@ ${indentation}RAISE EXCEPTION ${uniqueName2}.`;
|
|
|
560
565
|
}
|
|
561
566
|
return undefined;
|
|
562
567
|
}
|
|
568
|
+
moveWithOperator(high, lowFile) {
|
|
569
|
+
var _a, _b, _c;
|
|
570
|
+
if (!(high.get() instanceof Statements.Move)) {
|
|
571
|
+
return undefined;
|
|
572
|
+
}
|
|
573
|
+
const children = high.getChildren();
|
|
574
|
+
const secondChild = children[1];
|
|
575
|
+
if (secondChild === undefined) {
|
|
576
|
+
return undefined;
|
|
577
|
+
}
|
|
578
|
+
const op = secondChild.getFirstToken();
|
|
579
|
+
let operator = "";
|
|
580
|
+
switch (op.getStr()) {
|
|
581
|
+
case "+":
|
|
582
|
+
operator = " + ";
|
|
583
|
+
break;
|
|
584
|
+
case "-":
|
|
585
|
+
operator = " - ";
|
|
586
|
+
break;
|
|
587
|
+
case "/=":
|
|
588
|
+
operator = " / ";
|
|
589
|
+
break;
|
|
590
|
+
case "*=":
|
|
591
|
+
operator = " * ";
|
|
592
|
+
break;
|
|
593
|
+
case "&&=":
|
|
594
|
+
operator = " && ";
|
|
595
|
+
break;
|
|
596
|
+
default:
|
|
597
|
+
return undefined;
|
|
598
|
+
}
|
|
599
|
+
const target = (_a = high.findDirectExpression(Expressions.Target)) === null || _a === void 0 ? void 0 : _a.concatTokens();
|
|
600
|
+
if (target === undefined) {
|
|
601
|
+
return;
|
|
602
|
+
}
|
|
603
|
+
const sourceStart = (_c = (_b = high.findDirectExpression(Expressions.Source)) === null || _b === void 0 ? void 0 : _b.getFirstChild()) === null || _c === void 0 ? void 0 : _c.getFirstToken().getStart();
|
|
604
|
+
if (sourceStart === undefined) {
|
|
605
|
+
return;
|
|
606
|
+
}
|
|
607
|
+
const fix = edit_helper_1.EditHelper.replaceRange(lowFile, op.getStart(), sourceStart, "= " + target + operator);
|
|
608
|
+
return issue_1.Issue.atToken(lowFile, high.getFirstToken(), "Expand operator", this.getMetadata().key, this.conf.severity, fix);
|
|
609
|
+
}
|
|
563
610
|
// must be very simple string templates, like "|{ ls_line-no ALPHA = IN }|"
|
|
564
611
|
stringTemplateAlpha(node, lowFile) {
|
|
565
612
|
var _a, _b, _c;
|
|
@@ -659,8 +706,34 @@ ${indentation} output = ${topTarget}.`;
|
|
|
659
706
|
}
|
|
660
707
|
return undefined;
|
|
661
708
|
}
|
|
709
|
+
outlineFor(forLoop, indentation) {
|
|
710
|
+
var _a, _b, _c, _d, _e, _f;
|
|
711
|
+
let body = "";
|
|
712
|
+
let end = "";
|
|
713
|
+
const loopSource = (_a = forLoop.findFirstExpression(Expressions.Source)) === null || _a === void 0 ? void 0 : _a.concatTokens();
|
|
714
|
+
const loopTargetField = (_b = forLoop.findFirstExpression(Expressions.TargetField)) === null || _b === void 0 ? void 0 : _b.concatTokens();
|
|
715
|
+
if (forLoop.findDirectTokenByText("UNTIL")) {
|
|
716
|
+
const name = (_c = forLoop.findFirstExpression(Expressions.Field)) === null || _c === void 0 ? void 0 : _c.concatTokens();
|
|
717
|
+
body += indentation + "DATA " + name + " TYPE i.\n";
|
|
718
|
+
const cond = forLoop.findFirstExpression(Expressions.Cond);
|
|
719
|
+
body += indentation + `WHILE NOT ${cond === null || cond === void 0 ? void 0 : cond.concatTokens()}.\n`;
|
|
720
|
+
const field = (_e = (_d = forLoop.findDirectExpression(Expressions.InlineFieldDefinition)) === null || _d === void 0 ? void 0 : _d.findFirstExpression(Expressions.Field)) === null || _e === void 0 ? void 0 : _e.concatTokens();
|
|
721
|
+
body += indentation + ` ${field} = ${field} + 1.\n`;
|
|
722
|
+
end = "ENDWHILE";
|
|
723
|
+
}
|
|
724
|
+
else if (loopTargetField) {
|
|
725
|
+
body += indentation + `LOOP AT ${loopSource} INTO DATA(${loopTargetField}).\n`;
|
|
726
|
+
end = "ENDLOOP";
|
|
727
|
+
}
|
|
728
|
+
else if (loopTargetField === undefined) {
|
|
729
|
+
const loopTargetFieldSymbol = (_f = forLoop.findFirstExpression(Expressions.TargetFieldSymbol)) === null || _f === void 0 ? void 0 : _f.concatTokens();
|
|
730
|
+
body += indentation + `LOOP AT ${loopSource} ASSIGNING FIELD-SYMBOL(${loopTargetFieldSymbol}).\n`;
|
|
731
|
+
end = "ENDLOOP";
|
|
732
|
+
}
|
|
733
|
+
return { body, end };
|
|
734
|
+
}
|
|
662
735
|
outlineReduce(node, lowFile, highSyntax) {
|
|
663
|
-
var _a
|
|
736
|
+
var _a;
|
|
664
737
|
for (const i of node.findAllExpressionsRecursive(Expressions.Source)) {
|
|
665
738
|
const firstToken = i.getFirstToken();
|
|
666
739
|
if (firstToken.getStr().toUpperCase() !== "REDUCE") {
|
|
@@ -682,19 +755,12 @@ ${indentation} output = ${topTarget}.`;
|
|
|
682
755
|
name = init.getFirstToken().getStr();
|
|
683
756
|
body += indentation + `DATA(${name}) = ${(_a = reduceBody.findFirstExpression(Expressions.Source)) === null || _a === void 0 ? void 0 : _a.concatTokens()}.\n`;
|
|
684
757
|
}
|
|
685
|
-
const
|
|
686
|
-
if (
|
|
758
|
+
const forLoop = reduceBody.findDirectExpression(Expressions.For);
|
|
759
|
+
if (forLoop === undefined) {
|
|
687
760
|
continue;
|
|
688
761
|
}
|
|
689
|
-
const
|
|
690
|
-
|
|
691
|
-
if (loopTargetField) {
|
|
692
|
-
body += indentation + `LOOP AT ${loopSource} INTO DATA(${loopTargetField}).\n`;
|
|
693
|
-
}
|
|
694
|
-
if (loopTargetField === undefined) {
|
|
695
|
-
const loopTargetFieldSymbol = (_d = loop.findFirstExpression(Expressions.TargetFieldSymbol)) === null || _d === void 0 ? void 0 : _d.concatTokens();
|
|
696
|
-
body += indentation + `LOOP AT ${loopSource} ASSIGNING FIELD-SYMBOL(${loopTargetFieldSymbol}).\n`;
|
|
697
|
-
}
|
|
762
|
+
const outlineFor = this.outlineFor(forLoop, indentation);
|
|
763
|
+
body += outlineFor.body;
|
|
698
764
|
const next = reduceBody.findDirectExpression(Expressions.ReduceNext);
|
|
699
765
|
if (next === undefined) {
|
|
700
766
|
continue;
|
|
@@ -713,7 +779,7 @@ ${indentation} output = ${topTarget}.`;
|
|
|
713
779
|
body += n.concatTokens() + ".\n";
|
|
714
780
|
}
|
|
715
781
|
}
|
|
716
|
-
body += indentation +
|
|
782
|
+
body += indentation + outlineFor.end + `.\n`;
|
|
717
783
|
body += indentation + `${uniqueName} = ${name}.\n`;
|
|
718
784
|
const abap = `DATA ${uniqueName} TYPE ${type}.\n` +
|
|
719
785
|
body +
|
|
@@ -726,7 +792,6 @@ ${indentation} output = ${topTarget}.`;
|
|
|
726
792
|
return undefined;
|
|
727
793
|
}
|
|
728
794
|
outlineValue(node, lowFile, highSyntax) {
|
|
729
|
-
var _a, _b;
|
|
730
795
|
const allSources = node.findAllExpressionsRecursive(Expressions.Source);
|
|
731
796
|
for (const i of allSources) {
|
|
732
797
|
const firstToken = i.getFirstToken();
|
|
@@ -741,11 +806,11 @@ ${indentation} output = ${topTarget}.`;
|
|
|
741
806
|
const uniqueName = this.uniqueName(firstToken.getStart(), lowFile.getFilename(), highSyntax);
|
|
742
807
|
let indentation = " ".repeat(node.getFirstToken().getStart().getCol() - 1);
|
|
743
808
|
let body = "";
|
|
744
|
-
const
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
body +=
|
|
809
|
+
const forLoop = valueBody === null || valueBody === void 0 ? void 0 : valueBody.findDirectExpression(Expressions.For);
|
|
810
|
+
let outlineFor = { body: "", end: "" };
|
|
811
|
+
if (forLoop !== undefined) {
|
|
812
|
+
outlineFor = this.outlineFor(forLoop, indentation);
|
|
813
|
+
body += outlineFor.body;
|
|
749
814
|
indentation += " ";
|
|
750
815
|
}
|
|
751
816
|
let structureName = uniqueName;
|
|
@@ -773,9 +838,9 @@ ${indentation} output = ${topTarget}.`;
|
|
|
773
838
|
body += indentation + `APPEND ${structureName} TO ${uniqueName}.\n`;
|
|
774
839
|
}
|
|
775
840
|
}
|
|
776
|
-
if (
|
|
777
|
-
indentation = indentation.
|
|
778
|
-
body += indentation +
|
|
841
|
+
if (forLoop !== undefined) {
|
|
842
|
+
indentation = indentation.substring(2);
|
|
843
|
+
body += indentation + outlineFor.end + `.\n`;
|
|
779
844
|
}
|
|
780
845
|
const abap = `DATA ${uniqueName} TYPE ${type}.\n` +
|
|
781
846
|
body +
|
|
@@ -32,6 +32,8 @@ class FunctionModuleRecommendationsConf extends _basic_rule_config_1.BasicRuleCo
|
|
|
32
32
|
{ name: "REUSE_ALV_GRID_DISPLAY", replace: "use CL_SALV_TABLE=>FACTORY or CL_GUI_ALV_GRID" },
|
|
33
33
|
{ name: "CALCULATE_HASH_FOR_RAW", replace: "use CL_ABAP_HMAC" },
|
|
34
34
|
{ name: "FUNCTION_EXISTS", replace: "surround with try-catch CX_SY_DYN_CALL_ILLEGAL_METHOD instead" },
|
|
35
|
+
{ name: "IGN_TIMESTAMP_DIFFERENCE", replace: "use CL_ABAP_TSTMP" },
|
|
36
|
+
{ name: "IGN_TIMESTAMP_PLUSMINUS", replace: "use CL_ABAP_TSTMP" },
|
|
35
37
|
];
|
|
36
38
|
}
|
|
37
39
|
}
|
|
@@ -45,7 +47,7 @@ class FunctionModuleRecommendations extends _abap_rule_1.ABAPRule {
|
|
|
45
47
|
return {
|
|
46
48
|
key: "function_module_recommendations",
|
|
47
49
|
title: "Function Module Recommendations",
|
|
48
|
-
shortDescription: `
|
|
50
|
+
shortDescription: `Suggests replacements for various function modules`,
|
|
49
51
|
extendedInformation: `https://docs.abapopenchecks.org/checks/53/`,
|
|
50
52
|
tags: [_irule_1.RuleTag.SingleFile],
|
|
51
53
|
};
|
package/build/src/version.js
CHANGED
|
@@ -18,7 +18,7 @@ var Version;
|
|
|
18
18
|
Version["v756"] = "v756";
|
|
19
19
|
Version["Cloud"] = "Cloud";
|
|
20
20
|
})(Version = exports.Version || (exports.Version = {}));
|
|
21
|
-
exports.defaultVersion = Version.
|
|
21
|
+
exports.defaultVersion = Version.v756;
|
|
22
22
|
function getPreviousVersion(v) {
|
|
23
23
|
if (v === Version.OpenABAP) {
|
|
24
24
|
return Version.v702;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@abaplint/core",
|
|
3
|
-
"version": "2.85.
|
|
3
|
+
"version": "2.85.21",
|
|
4
4
|
"description": "abaplint - Core API",
|
|
5
5
|
"main": "build/src/index.js",
|
|
6
6
|
"typings": "build/abaplint.d.ts",
|
|
@@ -48,17 +48,17 @@
|
|
|
48
48
|
"@microsoft/api-extractor": "^7.19.4",
|
|
49
49
|
"@types/chai": "^4.3.0",
|
|
50
50
|
"@types/mocha": "^9.1.0",
|
|
51
|
-
"@types/node": "^17.0.
|
|
51
|
+
"@types/node": "^17.0.19",
|
|
52
52
|
"chai": "^4.3.6",
|
|
53
|
-
"eslint": "^8.
|
|
54
|
-
"mocha": "^9.2.
|
|
53
|
+
"eslint": "^8.9.0",
|
|
54
|
+
"mocha": "^9.2.1",
|
|
55
55
|
"c8": "^7.11.0",
|
|
56
56
|
"source-map-support": "^0.5.21",
|
|
57
|
-
"ts-json-schema-generator": "^0.
|
|
57
|
+
"ts-json-schema-generator": "^0.98.0",
|
|
58
58
|
"typescript": "^4.5.5"
|
|
59
59
|
},
|
|
60
60
|
"dependencies": {
|
|
61
|
-
"fast-xml-parser": "^4.0.
|
|
61
|
+
"fast-xml-parser": "^4.0.3",
|
|
62
62
|
"json5": "^2.2.0",
|
|
63
63
|
"vscode-languageserver-protocol": "^3.16.0",
|
|
64
64
|
"vscode-languageserver-types": "^3.16.0"
|