@abaplint/core 2.115.10 → 2.115.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.
@@ -2870,8 +2870,10 @@ declare class FunctionModuleDefinition {
2870
2870
  private name;
2871
2871
  private description;
2872
2872
  private parameters;
2873
+ private moduleType;
2873
2874
  constructor(data: any);
2874
2875
  getParameters(): readonly IFunctionModuleParameter[];
2876
+ getModuleType(): FunctionModuleType | undefined;
2875
2877
  getDescription(): string | undefined;
2876
2878
  getName(): string;
2877
2879
  private parse;
@@ -2884,6 +2886,12 @@ declare enum FunctionModuleParameterDirection {
2884
2886
  tables = "tables"
2885
2887
  }
2886
2888
 
2889
+ declare enum FunctionModuleType {
2890
+ regular = "regular",
2891
+ remote = "remoteEnabled",
2892
+ update = "update"
2893
+ }
2894
+
2887
2895
  declare class FunctionName extends Expression {
2888
2896
  getRunnable(): IStatementRunnable;
2889
2897
  }
@@ -7401,6 +7409,7 @@ declare namespace Types {
7401
7409
  FormDefinition_2 as FormDefinition,
7402
7410
  FunctionModuleParameterDirection,
7403
7411
  IFunctionModuleParameter,
7412
+ FunctionModuleType,
7404
7413
  FunctionModuleDefinition,
7405
7414
  InterfaceDefinition,
7406
7415
  MethodDefinition,
@@ -14,7 +14,7 @@ class SQLCompare extends combi_1.Expression {
14
14
  const nul = (0, combi_1.seq)("IS", (0, combi_1.optPrio)("NOT"), (0, combi_1.altPrio)("NULL", (0, combi_1.ver)(version_1.Version.v753, "INITIAL")));
15
15
  const source = new _1.SQLSource();
16
16
  const sub = (0, combi_1.seq)((0, combi_1.optPrio)((0, combi_1.altPrio)("ALL", "ANY", "SOME")), (0, combi_1.altPrio)(subSelect, subSelectDouble));
17
- const arith = (0, combi_1.ver)(version_1.Version.v750, (0, combi_1.plusPrio)((0, combi_1.seq)((0, combi_1.altPrio)("+", "-", "*", "/"), _1.SQLFieldName)));
17
+ const arith = (0, combi_1.ver)(version_1.Version.v750, (0, combi_1.plusPrio)((0, combi_1.seq)((0, combi_1.altPrio)("+", "-", "*", "/"), _1.SQLFieldName)), version_1.Version.OpenABAP);
18
18
  const paren = (0, combi_1.seq)((0, combi_1.tok)(tokens_1.ParenLeftW), _1.Source, (0, combi_1.tok)(tokens_1.WParenRightW));
19
19
  const at = (0, combi_1.ver)(version_1.Version.v740sp05, (0, combi_1.seq)((0, combi_1.tok)(tokens_1.WAt), (0, combi_1.altPrio)(_1.SimpleSource3, paren)), version_1.Version.OpenABAP);
20
20
  const rett = (0, combi_1.seq)((0, combi_1.altPrio)(_1.SQLFunction, _1.ConstantString, (0, combi_1.seq)((0, combi_1.altPrio)(_1.SQLPath, _1.SQLFieldName), (0, combi_1.optPrio)(arith)), at), (0, combi_1.altPrio)((0, combi_1.seq)(_1.SQLCompareOperator, (0, combi_1.altPrio)(sub, source)), (0, combi_1.seq)((0, combi_1.optPrio)("NOT"), (0, combi_1.altPrio)(_1.SQLIn, like, between)), nul));
@@ -47,8 +47,9 @@ class CreateObject {
47
47
  target_1.Target.runSyntax(t, input);
48
48
  }
49
49
  const t = node.findDirectExpression(Expressions.Target);
50
+ let found = undefined;
50
51
  if (t) {
51
- const found = target_1.Target.runSyntax(t, input);
52
+ found = target_1.Target.runSyntax(t, input);
52
53
  if (found instanceof basic_1.VoidType) {
53
54
  // do nothing
54
55
  }
@@ -100,7 +101,11 @@ class CreateObject {
100
101
  for (const t of node.findDirectExpressions(Expressions.Dynamic)) {
101
102
  dynamic_1.Dynamic.runSyntax(t, input);
102
103
  }
103
- input.scope.addReference(t === null || t === void 0 ? void 0 : t.getFirstToken(), cdef, _reference_1.ReferenceType.ConstructorReference, input.filename, { ooName: cdef === null || cdef === void 0 ? void 0 : cdef.getName() });
104
+ let ooName = cdef === null || cdef === void 0 ? void 0 : cdef.getName();
105
+ if (ooName === undefined && found instanceof basic_1.VoidType) {
106
+ ooName = found.getVoided();
107
+ }
108
+ input.scope.addReference(t === null || t === void 0 ? void 0 : t.getFirstToken(), cdef, _reference_1.ReferenceType.ConstructorReference, input.filename, { ooName: ooName });
104
109
  this.validateParameters(cdef, node, input);
105
110
  }
106
111
  validateParameters(cdef, node, input) {
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.FunctionModuleDefinition = exports.FunctionModuleParameterDirection = void 0;
3
+ exports.FunctionModuleDefinition = exports.FunctionModuleType = exports.FunctionModuleParameterDirection = void 0;
4
4
  const xml_utils_1 = require("../../xml_utils");
5
5
  var FunctionModuleParameterDirection;
6
6
  (function (FunctionModuleParameterDirection) {
@@ -9,6 +9,12 @@ var FunctionModuleParameterDirection;
9
9
  FunctionModuleParameterDirection["changing"] = "changing";
10
10
  FunctionModuleParameterDirection["tables"] = "tables";
11
11
  })(FunctionModuleParameterDirection || (exports.FunctionModuleParameterDirection = FunctionModuleParameterDirection = {}));
12
+ var FunctionModuleType;
13
+ (function (FunctionModuleType) {
14
+ FunctionModuleType["regular"] = "regular";
15
+ FunctionModuleType["remote"] = "remoteEnabled";
16
+ FunctionModuleType["update"] = "update";
17
+ })(FunctionModuleType || (exports.FunctionModuleType = FunctionModuleType = {}));
12
18
  class FunctionModuleDefinition {
13
19
  constructor(data) {
14
20
  this.parse(data);
@@ -16,6 +22,9 @@ class FunctionModuleDefinition {
16
22
  getParameters() {
17
23
  return this.parameters;
18
24
  }
25
+ getModuleType() {
26
+ return this.moduleType;
27
+ }
19
28
  getDescription() {
20
29
  return this.description;
21
30
  }
@@ -30,6 +39,13 @@ class FunctionModuleDefinition {
30
39
  this.name = data.FUNCNAME;
31
40
  this.description = data.SHORT_TEXT;
32
41
  this.parameters = [];
42
+ this.moduleType = FunctionModuleType.regular;
43
+ if (data.REMOTE_CALL === "R") {
44
+ this.moduleType = FunctionModuleType.remote;
45
+ }
46
+ else if (data.UPDATE_TASK !== undefined) {
47
+ this.moduleType = FunctionModuleType.update;
48
+ }
33
49
  if (data.IMPORT) {
34
50
  for (const param of (0, xml_utils_1.xmlToArray)(data.IMPORT.RSIMP)) {
35
51
  if (param.PARAMETER === undefined) {
@@ -74,7 +74,7 @@ class Registry {
74
74
  }
75
75
  static abaplintVersion() {
76
76
  // magic, see build script "version.sh"
77
- return "2.115.10";
77
+ return "2.115.12";
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.115.10",
3
+ "version": "2.115.12",
4
4
  "description": "abaplint - Core API",
5
5
  "main": "build/src/index.js",
6
6
  "typings": "build/abaplint.d.ts",