@abaplint/core 2.93.40 → 2.93.42

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.
@@ -24,16 +24,20 @@ class MethodSource {
24
24
  if (!(id instanceof types_1.ClassDefinition)) {
25
25
  id = scope.findObjectDefinition(id.getName());
26
26
  }
27
- if (id instanceof types_1.ClassDefinition) { // todo || id instanceof InterfaceDefinition) {
27
+ if (id instanceof types_1.ClassDefinition || id instanceof types_1.InterfaceDefinition) {
28
28
  const methodName = last.concatTokens().toUpperCase();
29
29
  const helper = new _object_oriented_1.ObjectOriented(scope);
30
30
  const { method: foundMethod } = helper.searchMethodName(id, methodName);
31
31
  if (foundMethod === undefined && methodName !== "CONSTRUCTOR") {
32
+ if (node.getChildren().length !== 3) {
33
+ // todo
34
+ return undefined;
35
+ }
32
36
  throw new Error(`MethodSource, method not found \"${methodName}\"`);
33
37
  }
34
38
  const extra = {
35
39
  ooName: id.getName(),
36
- ooType: "CLAS"
40
+ ooType: id instanceof types_1.ClassDefinition ? "CLAS" : "INTF"
37
41
  };
38
42
  scope.addReference(last.getFirstToken(), foundMethod, _reference_1.ReferenceType.MethodReference, filename, extra);
39
43
  return foundMethod;
@@ -72,7 +72,7 @@ class DumpScope {
72
72
  }
73
73
  ret = ret + "<br>";
74
74
  }
75
- ret += sident + node.getData().cdefs.length + " class definitions<br>";
75
+ ret += sident + Object.keys(node.getData().cdefs).length + " class definitions<br>";
76
76
  ret += sident + node.getData().idefs.length + " interface definitions<br>";
77
77
  ret += sident + node.getData().forms.length + " form definitions<br>";
78
78
  ret += sident + node.getData().references.length + " references<br>";
@@ -63,7 +63,7 @@ class Registry {
63
63
  }
64
64
  static abaplintVersion() {
65
65
  // magic, see build script "version.sh"
66
- return "2.93.40";
66
+ return "2.93.42";
67
67
  }
68
68
  getDDICReferences() {
69
69
  return this.references;
@@ -46,7 +46,6 @@ class KeepSingleParameterCallsOnOneLine extends _abap_rule_1.ABAPRule {
46
46
  return [];
47
47
  }
48
48
  for (const s of file.getStatements()) {
49
- // todo, add length as configurable setting
50
49
  if (this.isMultiLine(s) === false
51
50
  || this.calcStatementLength(s) > this.getConfig().length
52
51
  || this.containsNewLineValue(s)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@abaplint/core",
3
- "version": "2.93.40",
3
+ "version": "2.93.42",
4
4
  "description": "abaplint - Core API",
5
5
  "main": "build/src/index.js",
6
6
  "typings": "build/abaplint.d.ts",
@@ -46,13 +46,13 @@
46
46
  },
47
47
  "homepage": "https://abaplint.org",
48
48
  "devDependencies": {
49
- "@microsoft/api-extractor": "^7.32.0",
49
+ "@microsoft/api-extractor": "^7.33.2",
50
50
  "@types/chai": "^4.3.3",
51
51
  "@types/mocha": "^10.0.0",
52
- "@types/node": "^18.8.3",
52
+ "@types/node": "^18.11.0",
53
53
  "chai": "^4.3.6",
54
54
  "eslint": "^8.25.0",
55
- "mocha": "^10.0.0",
55
+ "mocha": "^10.1.0",
56
56
  "c8": "^7.12.0",
57
57
  "source-map-support": "^0.5.21",
58
58
  "ts-json-schema-generator": "^1.1.2",