@abaplint/transpiler 2.7.10 → 2.7.12
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.
|
@@ -11,9 +11,11 @@ class MethodCallBodyTranspiler {
|
|
|
11
11
|
}
|
|
12
12
|
transpile(node, traversal) {
|
|
13
13
|
const ret = new chunk_1.Chunk();
|
|
14
|
+
let pt = false;
|
|
14
15
|
for (const c of node.getChildren()) {
|
|
15
16
|
if (c instanceof core_1.Nodes.TokenNode) {
|
|
16
17
|
// PARAMETER-TABLE
|
|
18
|
+
pt = true;
|
|
17
19
|
continue;
|
|
18
20
|
}
|
|
19
21
|
else if (c.get() instanceof abaplint.Expressions.MethodCallParam) {
|
|
@@ -21,6 +23,9 @@ class MethodCallBodyTranspiler {
|
|
|
21
23
|
}
|
|
22
24
|
else {
|
|
23
25
|
ret.appendChunk(traversal.traverse(c));
|
|
26
|
+
if (pt === true) {
|
|
27
|
+
ret.appendString(".array().reduce((a, v) => ({ ...a, [v.get().name.get().toLowerCase().trimEnd()]: v.get().value.dereference()}), {})");
|
|
28
|
+
}
|
|
24
29
|
}
|
|
25
30
|
}
|
|
26
31
|
return ret;
|