@abaplint/transpiler 2.5.49 → 2.5.50

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.
@@ -2,9 +2,20 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.SQLSourceTranspiler = void 0;
4
4
  const abaplint = require("@abaplint/core");
5
+ const chunk_1 = require("../chunk");
5
6
  class SQLSourceTranspiler {
6
7
  transpile(node, traversal) {
7
8
  let s = node.findDirectExpression(abaplint.Expressions.Source);
9
+ if ((s === null || s === void 0 ? void 0 : s.getChildren().length) === 1 && s.getChildren()[0].get() instanceof abaplint.Expressions.SQLAliasField) {
10
+ const chunk = new chunk_1.Chunk();
11
+ let concat = s.concatTokens();
12
+ if (concat.includes("~") && concat.split("~")[0].includes("/")) {
13
+ concat = "'" + concat.replace("~", "'~");
14
+ }
15
+ concat = concat.replace("~", ".");
16
+ chunk.appendString(concat);
17
+ return chunk;
18
+ }
8
19
  if (s === undefined) {
9
20
  s = node.findDirectExpression(abaplint.Expressions.SimpleSource3);
10
21
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@abaplint/transpiler",
3
- "version": "2.5.49",
3
+ "version": "2.5.50",
4
4
  "description": "Transpiler",
5
5
  "main": "build/src/index.js",
6
6
  "typings": "build/src/index.d.ts",