@abaplint/core 2.113.15 → 2.113.16

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.
@@ -67,7 +67,7 @@ class Registry {
67
67
  }
68
68
  static abaplintVersion() {
69
69
  // magic, see build script "version.sh"
70
- return "2.113.15";
70
+ return "2.113.16";
71
71
  }
72
72
  getDDICReferences() {
73
73
  return this.ddicReferences;
@@ -745,7 +745,7 @@ ${indentation}`);
745
745
  return issue_1.Issue.atToken(lowFile, inlineData.getFirstToken(), "Outline SELECT @DATA", this.getMetadata().key, this.conf.severity, fix);
746
746
  }
747
747
  downportSelectTableInline(low, high, lowFile, highSyntax) {
748
- var _a, _b, _c;
748
+ var _a, _b, _c, _d, _e;
749
749
  if (!(low.get() instanceof _statement_1.Unknown)) {
750
750
  return undefined;
751
751
  }
@@ -771,17 +771,22 @@ ${indentation}`);
771
771
  return undefined;
772
772
  }
773
773
  let fieldDefinitions = "";
774
- for (const f of fieldList.findAllExpressions(Expressions.SQLFieldName)) {
775
- let fieldName = f.concatTokens();
774
+ for (const f of fieldList.findAllExpressions(Expressions.SQLField)) {
775
+ let fieldName = (_c = f.findFirstExpression(Expressions.SQLFieldName)) === null || _c === void 0 ? void 0 : _c.concatTokens();
776
+ if (fieldName === undefined) {
777
+ continue;
778
+ }
776
779
  if (fieldName.includes("~")) {
777
780
  const split = fieldName.split("~");
778
781
  tableName = split[0];
779
782
  fieldName = split[1];
780
783
  }
781
- fieldDefinitions += indentation + " " + fieldName + " TYPE " + tableName + "-" + fieldName + ",\n";
784
+ const typeName = tableName + "-" + fieldName;
785
+ fieldName = ((_d = f.findFirstExpression(Expressions.SQLAsName)) === null || _d === void 0 ? void 0 : _d.concatTokens()) || fieldName;
786
+ fieldDefinitions += indentation + " " + fieldName + " TYPE " + typeName + ",\n";
782
787
  }
783
788
  const uniqueName = this.uniqueName(high.getFirstToken().getStart(), lowFile.getFilename(), highSyntax);
784
- const name = ((_c = inlineData.findFirstExpression(Expressions.TargetField)) === null || _c === void 0 ? void 0 : _c.concatTokens()) || "error";
789
+ const name = ((_e = inlineData.findFirstExpression(Expressions.TargetField)) === null || _e === void 0 ? void 0 : _e.concatTokens()) || "error";
785
790
  let fix1 = edit_helper_1.EditHelper.insertAt(lowFile, high.getStart(), `TYPES: BEGIN OF ${uniqueName},
786
791
  ${fieldDefinitions}${indentation} END OF ${uniqueName}.
787
792
  ${indentation}DATA ${name} TYPE STANDARD TABLE OF ${uniqueName} WITH DEFAULT KEY.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@abaplint/core",
3
- "version": "2.113.15",
3
+ "version": "2.113.16",
4
4
  "description": "abaplint - Core API",
5
5
  "main": "build/src/index.js",
6
6
  "typings": "build/abaplint.d.ts",
@@ -51,9 +51,9 @@
51
51
  "homepage": "https://abaplint.org",
52
52
  "devDependencies": {
53
53
  "@microsoft/api-extractor": "^7.47.9",
54
- "@types/chai": "^4.3.19",
54
+ "@types/chai": "^4.3.20",
55
55
  "@types/mocha": "^10.0.8",
56
- "@types/node": "^22.7.0",
56
+ "@types/node": "^22.7.3",
57
57
  "chai": "^4.5.0",
58
58
  "eslint": "^9.11.1",
59
59
  "mocha": "^10.7.3",