@abaplint/core 2.113.243 → 2.113.245

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,11 +11,14 @@ class SQLField extends combi_1.Expression {
11
11
  getRunnable() {
12
12
  const abap = (0, combi_1.ver)(version_1.Version.v740sp05, (0, combi_1.seq)((0, combi_1.tok)(tokens_1.WAt), _1.SimpleFieldChain2), version_1.Version.OpenABAP);
13
13
  const as = (0, combi_1.seq)("AS", _1.SQLAsName);
14
- const paren = (0, combi_1.seq)((0, combi_1.tok)(tokens_1.WParenLeftW), _1.SQLFieldName, (0, combi_1.altPrio)((0, combi_1.tok)(tokens_1.WParenRightW), (0, combi_1.tok)(tokens_1.WParenRight)));
15
- const field = (0, combi_1.altPrio)(_1.SQLAggregation, _1.SQLCase, _1.SQLCast, sql_function_1.SQLFunction, sql_path_1.SQLPath, _1.SQLFieldName, abap, _1.Constant, paren);
16
- const sub = (0, combi_1.plusPrio)((0, combi_1.seq)((0, combi_1.altPrio)("+", "-", "*", "/", "&&"), (0, combi_1.optPrio)((0, combi_1.tok)(tokens_1.WParenLeftW)), field, (0, combi_1.optPrio)((0, combi_1.tok)(tokens_1.WParenRightW))));
14
+ const parenFieldName = (0, combi_1.seq)((0, combi_1.tok)(tokens_1.WParenLeftW), _1.SQLFieldName, (0, combi_1.altPrio)((0, combi_1.tok)(tokens_1.WParenRightW), (0, combi_1.tok)(tokens_1.WParenRight)));
15
+ const field = (0, combi_1.altPrio)(_1.SQLAggregation, _1.SQLCase, _1.SQLCast, sql_function_1.SQLFunction, sql_path_1.SQLPath, _1.SQLFieldName, abap, _1.Constant, parenFieldName);
16
+ const parenField = (0, combi_1.seq)((0, combi_1.tok)(tokens_1.WParenLeftW), field, (0, combi_1.tok)(tokens_1.WParenRightW));
17
+ const sub = (0, combi_1.plusPrio)((0, combi_1.seq)((0, combi_1.altPrio)("+", "-", "*", "/", "&&"), (0, combi_1.altPrio)(parenField, field)));
17
18
  const arith = (0, combi_1.ver)(version_1.Version.v740sp05, sub);
18
- return (0, combi_1.seq)(field, (0, combi_1.optPrio)(arith), (0, combi_1.optPrio)(as));
19
+ const arithSequence = (0, combi_1.seq)(field, (0, combi_1.optPrio)(arith));
20
+ const parenArithSequence = (0, combi_1.seq)((0, combi_1.tok)(tokens_1.WParenLeftW), arithSequence, (0, combi_1.tok)(tokens_1.WParenRightW));
21
+ return (0, combi_1.seq)((0, combi_1.altPrio)(parenArithSequence, arithSequence), (0, combi_1.optPrio)(as));
19
22
  }
20
23
  }
21
24
  exports.SQLField = SQLField;
@@ -95,7 +95,6 @@ class BasicTypes {
95
95
  return undefined;
96
96
  }
97
97
  resolveLikeName(node, headerLogic = true) {
98
- var _a;
99
98
  if (node === undefined) {
100
99
  return undefined;
101
100
  }
@@ -141,7 +140,12 @@ class BasicTypes {
141
140
  this.input.scope.addReference(chain === null || chain === void 0 ? void 0 : chain.getFirstToken(), found, _reference_1.ReferenceType.TypeReference, this.input.filename);
142
141
  }
143
142
  if (type === undefined) {
144
- type = (_a = this.input.scope.getDDIC().lookupNoVoid(name)) === null || _a === void 0 ? void 0 : _a.type;
143
+ const found = this.input.scope.getDDIC().lookupNoVoid(name);
144
+ if (found !== undefined) {
145
+ const using = { filename: this.input.filename, token: chain.getFirstToken(), object: found.object };
146
+ this.input.scope.getDDICReferences().addUsing(this.input.scope.getParentObj(), using);
147
+ }
148
+ type = found === null || found === void 0 ? void 0 : found.type;
145
149
  }
146
150
  if (type === undefined && this.input.scope.isAnyOO() === false && this.input.scope.getDDIC().inErrorNamespace(name) === false) {
147
151
  this.input.scope.addReference(chain.getChildren()[0].getFirstToken(), undefined, _reference_1.ReferenceType.VoidType, this.input.filename);
@@ -13,7 +13,7 @@ class SQLForAllEntries {
13
13
  }
14
14
  if (s) {
15
15
  const type = source_1.Source.runSyntax(s, input);
16
- if (type instanceof basic_1.VoidType) {
16
+ if (type instanceof basic_1.VoidType || type instanceof basic_1.UnknownType) {
17
17
  return;
18
18
  }
19
19
  if (!(type instanceof basic_1.TableType)) {
@@ -21,6 +21,9 @@ class ReadTable {
21
21
  input.issues.push((0, _syntax_input_1.syntaxIssue)(input, node.getFirstToken(), message));
22
22
  return;
23
23
  }
24
+ else if (sourceType instanceof basic_1.UnknownType) {
25
+ // do nothing, ok
26
+ }
24
27
  else if (!(sourceType instanceof basic_1.TableType) && !(sourceType instanceof basic_1.VoidType)) {
25
28
  const message = "Read table, not a table type";
26
29
  input.issues.push((0, _syntax_input_1.syntaxIssue)(input, node.getFirstToken(), message));
@@ -74,7 +74,7 @@ class Registry {
74
74
  }
75
75
  static abaplintVersion() {
76
76
  // magic, see build script "version.sh"
77
- return "2.113.243";
77
+ return "2.113.245";
78
78
  }
79
79
  getDDICReferences() {
80
80
  return this.ddicReferences;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@abaplint/core",
3
- "version": "2.113.243",
3
+ "version": "2.113.245",
4
4
  "description": "abaplint - Core API",
5
5
  "main": "build/src/index.js",
6
6
  "typings": "build/abaplint.d.ts",
@@ -50,7 +50,7 @@
50
50
  },
51
51
  "homepage": "https://abaplint.org",
52
52
  "devDependencies": {
53
- "@microsoft/api-extractor": "^7.55.0",
53
+ "@microsoft/api-extractor": "^7.55.1",
54
54
  "@types/chai": "^4.3.20",
55
55
  "@types/mocha": "^10.0.10",
56
56
  "@types/node": "^24.10.1",