@abaplint/transpiler 2.6.26 → 2.6.27
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/src/transpile_types.js +11 -12
- package/build/src/traversal.js +2 -8
- package/package.json +2 -2
|
@@ -17,15 +17,14 @@ class TranspileTypes {
|
|
|
17
17
|
return pre + t.getName().toLowerCase() + " = " + code + ";\n";
|
|
18
18
|
}
|
|
19
19
|
toType(type) {
|
|
20
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
20
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
21
21
|
let resolved = "";
|
|
22
22
|
let extra = "";
|
|
23
23
|
if (type instanceof abaplint.BasicTypes.ObjectReferenceType
|
|
24
24
|
|| type instanceof abaplint.BasicTypes.GenericObjectReferenceType) {
|
|
25
25
|
resolved = "ABAPObject";
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
}
|
|
26
|
+
extra = "{qualifiedName: " + JSON.stringify((_a = type.getQualifiedName()) === null || _a === void 0 ? void 0 : _a.toUpperCase()) +
|
|
27
|
+
", RTTIName: " + JSON.stringify((_b = type.getRTTIName()) === null || _b === void 0 ? void 0 : _b.toUpperCase()) + "}";
|
|
29
28
|
}
|
|
30
29
|
else if (type instanceof abaplint.BasicTypes.TableType) {
|
|
31
30
|
resolved = "Table";
|
|
@@ -39,31 +38,31 @@ class TranspileTypes {
|
|
|
39
38
|
else if (type instanceof abaplint.BasicTypes.IntegerType) {
|
|
40
39
|
resolved = "Integer";
|
|
41
40
|
if (type.getQualifiedName() !== undefined) {
|
|
42
|
-
extra = "{qualifiedName: \"" + ((
|
|
41
|
+
extra = "{qualifiedName: \"" + ((_c = type.getQualifiedName()) === null || _c === void 0 ? void 0 : _c.toUpperCase()) + "\"}";
|
|
43
42
|
}
|
|
44
43
|
}
|
|
45
44
|
else if (type instanceof abaplint.BasicTypes.StringType) {
|
|
46
45
|
resolved = "String";
|
|
47
46
|
if (type.getQualifiedName() !== undefined) {
|
|
48
|
-
extra = "{qualifiedName: \"" + ((
|
|
47
|
+
extra = "{qualifiedName: \"" + ((_d = type.getQualifiedName()) === null || _d === void 0 ? void 0 : _d.toUpperCase()) + "\"}";
|
|
49
48
|
}
|
|
50
49
|
}
|
|
51
50
|
else if (type instanceof abaplint.BasicTypes.UTCLongType) {
|
|
52
51
|
resolved = "UTCLong";
|
|
53
52
|
if (type.getQualifiedName() !== undefined) {
|
|
54
|
-
extra = "{qualifiedName: \"" + ((
|
|
53
|
+
extra = "{qualifiedName: \"" + ((_e = type.getQualifiedName()) === null || _e === void 0 ? void 0 : _e.toUpperCase()) + "\"}";
|
|
55
54
|
}
|
|
56
55
|
}
|
|
57
56
|
else if (type instanceof abaplint.BasicTypes.DateType) {
|
|
58
57
|
resolved = "Date";
|
|
59
58
|
if (type.getQualifiedName() !== undefined) {
|
|
60
|
-
extra = "{qualifiedName: \"" + ((
|
|
59
|
+
extra = "{qualifiedName: \"" + ((_f = type.getQualifiedName()) === null || _f === void 0 ? void 0 : _f.toUpperCase()) + "\"}";
|
|
61
60
|
}
|
|
62
61
|
}
|
|
63
62
|
else if (type instanceof abaplint.BasicTypes.TimeType) {
|
|
64
63
|
resolved = "Time";
|
|
65
64
|
if (type.getQualifiedName() !== undefined) {
|
|
66
|
-
extra = "{qualifiedName: \"" + ((
|
|
65
|
+
extra = "{qualifiedName: \"" + ((_g = type.getQualifiedName()) === null || _g === void 0 ? void 0 : _g.toUpperCase()) + "\"}";
|
|
67
66
|
}
|
|
68
67
|
}
|
|
69
68
|
else if (type instanceof abaplint.BasicTypes.DataReference) {
|
|
@@ -134,7 +133,7 @@ class TranspileTypes {
|
|
|
134
133
|
else if (type instanceof abaplint.BasicTypes.XStringType) {
|
|
135
134
|
resolved = "XString";
|
|
136
135
|
if (type.getQualifiedName() !== undefined) {
|
|
137
|
-
extra = "{qualifiedName: \"" + ((
|
|
136
|
+
extra = "{qualifiedName: \"" + ((_h = type.getQualifiedName()) === null || _h === void 0 ? void 0 : _h.toUpperCase()) + "\"}";
|
|
138
137
|
}
|
|
139
138
|
}
|
|
140
139
|
else if (type instanceof abaplint.BasicTypes.XSequenceType) {
|
|
@@ -150,13 +149,13 @@ class TranspileTypes {
|
|
|
150
149
|
else if (type instanceof abaplint.BasicTypes.FloatType) {
|
|
151
150
|
resolved = "Float";
|
|
152
151
|
if (type.getQualifiedName() !== undefined) {
|
|
153
|
-
extra = "{qualifiedName: \"" + ((
|
|
152
|
+
extra = "{qualifiedName: \"" + ((_j = type.getQualifiedName()) === null || _j === void 0 ? void 0 : _j.toUpperCase()) + "\"}";
|
|
154
153
|
}
|
|
155
154
|
}
|
|
156
155
|
else if (type instanceof abaplint.BasicTypes.FloatingPointType) {
|
|
157
156
|
resolved = "Float";
|
|
158
157
|
if (type.getQualifiedName() !== undefined) {
|
|
159
|
-
extra = "{qualifiedName: \"" + ((
|
|
158
|
+
extra = "{qualifiedName: \"" + ((_k = type.getQualifiedName()) === null || _k === void 0 ? void 0 : _k.toUpperCase()) + "\"}";
|
|
160
159
|
}
|
|
161
160
|
}
|
|
162
161
|
else if (type instanceof abaplint.BasicTypes.DecFloat34Type) {
|
package/build/src/traversal.js
CHANGED
|
@@ -479,14 +479,8 @@ class Traversal {
|
|
|
479
479
|
if (def === undefined) {
|
|
480
480
|
return "";
|
|
481
481
|
}
|
|
482
|
-
const name = def.getName();
|
|
483
|
-
|
|
484
|
-
const prefix = this.buildPrefix();
|
|
485
|
-
return `abap.Classes['${prefix}-${name.toUpperCase()}'] = ${Traversal.escapeNamespace(name.toLowerCase())};`;
|
|
486
|
-
}
|
|
487
|
-
else {
|
|
488
|
-
return `abap.Classes['${name.toUpperCase()}'] = ${Traversal.escapeNamespace(name.toLowerCase())};`;
|
|
489
|
-
}
|
|
482
|
+
const name = this.buildInternalName(def.getName(), def);
|
|
483
|
+
return `abap.Classes['${name}'] = ${Traversal.escapeNamespace(def.getName().toLowerCase())};`;
|
|
490
484
|
}
|
|
491
485
|
setValues(identifier, name) {
|
|
492
486
|
return Traversal.setValues(identifier, name);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@abaplint/transpiler",
|
|
3
|
-
"version": "2.6.
|
|
3
|
+
"version": "2.6.27",
|
|
4
4
|
"description": "Transpiler",
|
|
5
5
|
"main": "build/src/index.js",
|
|
6
6
|
"typings": "build/src/index.d.ts",
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
"author": "abaplint",
|
|
29
29
|
"license": "MIT",
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@abaplint/core": "^2.97.
|
|
31
|
+
"@abaplint/core": "^2.97.16",
|
|
32
32
|
"source-map": "^0.7.4"
|
|
33
33
|
},
|
|
34
34
|
"devDependencies": {
|