@abaplint/transpiler-cli 2.6.20 → 2.6.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/bundle.js +24 -3
- package/package.json +2 -2
package/build/bundle.js
CHANGED
|
@@ -77714,14 +77714,35 @@ class Traversal {
|
|
|
77714
77714
|
buildAttributes(def) {
|
|
77715
77715
|
var _a, _b;
|
|
77716
77716
|
const attr = [];
|
|
77717
|
-
// TODO: visibility is wrong for classes
|
|
77718
77717
|
for (const a of ((_a = def === null || def === void 0 ? void 0 : def.getAttributes()) === null || _a === void 0 ? void 0 : _a.getAll()) || []) {
|
|
77719
77718
|
const type = new transpile_types_1.TranspileTypes().toType(a.getType());
|
|
77720
|
-
|
|
77719
|
+
let runtime = "";
|
|
77720
|
+
switch (a.getVisibility()) {
|
|
77721
|
+
case abaplint.Visibility.Private:
|
|
77722
|
+
runtime = "I";
|
|
77723
|
+
break;
|
|
77724
|
+
case abaplint.Visibility.Protected:
|
|
77725
|
+
runtime = "O";
|
|
77726
|
+
break;
|
|
77727
|
+
default:
|
|
77728
|
+
runtime = "U";
|
|
77729
|
+
}
|
|
77730
|
+
attr.push(`"${a.getName().toUpperCase()}": {"type": () => {return ${type};}, "visibility": "${runtime}", "is_constant": " "}`);
|
|
77721
77731
|
}
|
|
77722
77732
|
for (const a of ((_b = def === null || def === void 0 ? void 0 : def.getAttributes()) === null || _b === void 0 ? void 0 : _b.getConstants()) || []) {
|
|
77723
77733
|
const type = new transpile_types_1.TranspileTypes().toType(a.getType());
|
|
77724
|
-
|
|
77734
|
+
let runtime = "";
|
|
77735
|
+
switch (a.getVisibility()) {
|
|
77736
|
+
case abaplint.Visibility.Private:
|
|
77737
|
+
runtime = "I";
|
|
77738
|
+
break;
|
|
77739
|
+
case abaplint.Visibility.Protected:
|
|
77740
|
+
runtime = "O";
|
|
77741
|
+
break;
|
|
77742
|
+
default:
|
|
77743
|
+
runtime = "U";
|
|
77744
|
+
}
|
|
77745
|
+
attr.push(`"${a.getName().toUpperCase()}": {"type": () => {return ${type};}, "visibility": "${runtime}", "is_constant": "X"}`);
|
|
77725
77746
|
}
|
|
77726
77747
|
return attr.join(",\n");
|
|
77727
77748
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@abaplint/transpiler-cli",
|
|
3
|
-
"version": "2.6.
|
|
3
|
+
"version": "2.6.21",
|
|
4
4
|
"description": "Transpiler - Command Line Interface",
|
|
5
5
|
"bin": {
|
|
6
6
|
"abap_transpile": "./abap_transpile"
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"author": "abaplint",
|
|
26
26
|
"license": "MIT",
|
|
27
27
|
"devDependencies": {
|
|
28
|
-
"@abaplint/transpiler": "^2.6.
|
|
28
|
+
"@abaplint/transpiler": "^2.6.21",
|
|
29
29
|
"@types/glob": "^7.2.0",
|
|
30
30
|
"glob": "=7.2.0",
|
|
31
31
|
"@types/progress": "^2.0.5",
|