@abaplint/cli 2.102.28 → 2.102.30

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.
Files changed (2) hide show
  1. package/build/cli.js +16 -5
  2. package/package.json +6 -6
package/build/cli.js CHANGED
@@ -8519,7 +8519,8 @@ class TypeTableKey extends combi_1.Expression {
8519
8519
  const defaultKey = "DEFAULT KEY";
8520
8520
  const emptyKey = (0, combi_1.ver)(version_1.Version.v740sp02, "EMPTY KEY");
8521
8521
  const components = (0, combi_1.plus)((0, combi_1.alt)((0, combi_1.seq)("WITH", (0, combi_1.failStar)()), _1.FieldSub));
8522
- const key = (0, combi_1.seq)("WITH", (0, combi_1.opt)(uniqueness), (0, combi_1.altPrio)(defaultKey, emptyKey, (0, combi_1.seq)((0, combi_1.opt)((0, combi_1.alt)("SORTED", "HASHED")), "KEY", (0, combi_1.alt)((0, combi_1.seq)(_1.Field, "COMPONENTS", components), components))), (0, combi_1.optPrio)("READ-ONLY"));
8522
+ const further = (0, combi_1.seq)((0, combi_1.alt)("WITHOUT", "WITH"), "FURTHER SECONDARY KEYS");
8523
+ const key = (0, combi_1.seq)("WITH", (0, combi_1.opt)(uniqueness), (0, combi_1.altPrio)(defaultKey, emptyKey, (0, combi_1.seq)((0, combi_1.opt)((0, combi_1.alt)("SORTED", "HASHED")), "KEY", (0, combi_1.alt)((0, combi_1.seq)(_1.Field, "COMPONENTS", components), components))), (0, combi_1.optPrio)(further), (0, combi_1.optPrio)("READ-ONLY"));
8523
8524
  return key;
8524
8525
  }
8525
8526
  }
@@ -9612,7 +9613,7 @@ class CallFunction {
9612
9613
  const update = (0, combi_1.verNot)(version_1.Version.Cloud, (0, combi_1.str)("IN UPDATE TASK"));
9613
9614
  const unit = (0, combi_1.seq)("UNIT", expressions_1.Source);
9614
9615
  const background = (0, combi_1.verNot)(version_1.Version.Cloud, (0, combi_1.seq)("IN BACKGROUND", (0, combi_1.altPrio)("TASK", unit)));
9615
- const calling = (0, combi_1.seq)("CALLING", expressions_1.MethodName, "ON END OF TASK");
9616
+ const calling = (0, combi_1.seq)("CALLING", expressions_1.MethodSource, "ON END OF TASK");
9616
9617
  const performing = (0, combi_1.seq)("PERFORMING", expressions_1.FormName, "ON END OF TASK");
9617
9618
  const separate = (0, combi_1.str)("AS SEPARATE UNIT");
9618
9619
  const keeping = (0, combi_1.str)("KEEPING LOGICAL UNIT OF WORK");
@@ -16646,7 +16647,7 @@ class TypeMesh {
16646
16647
  const on = (0, combi_1.seq)("ON", expressions_1.NamespaceSimpleName, "=", expressions_1.NamespaceSimpleName, (0, combi_1.star)((0, combi_1.seq)("AND", expressions_1.NamespaceSimpleName, "=", expressions_1.NamespaceSimpleName)));
16647
16648
  const using = (0, combi_1.seq)("USING KEY", expressions_1.NamespaceSimpleName);
16648
16649
  const association = (0, combi_1.seq)("ASSOCIATION", expressions_1.NamespaceSimpleName, "TO", expressions_1.NamespaceSimpleName, (0, combi_1.plus)(on));
16649
- const ret = (0, combi_1.ver)(version_1.Version.v751, (0, combi_1.seq)("TYPES", expressions_1.NamespaceSimpleName, "TYPE", expressions_1.TypeName, (0, combi_1.plus)(association), (0, combi_1.opt)(using)));
16650
+ const ret = (0, combi_1.ver)(version_1.Version.v751, (0, combi_1.seq)("TYPES", expressions_1.NamespaceSimpleName, "TYPE", (0, combi_1.opt)("REF TO"), expressions_1.TypeName, (0, combi_1.plus)(association), (0, combi_1.opt)(using)));
16650
16651
  return ret;
16651
16652
  }
16652
16653
  }
@@ -20515,6 +20516,9 @@ class CurrentScope {
20515
20516
  if (this.current.getData().types[upper] !== undefined) {
20516
20517
  throw new Error(`Type name "${name}" already defined`);
20517
20518
  }
20519
+ else if (this.isOO() && this.current.getData().vars[upper] !== undefined) {
20520
+ throw new Error(`"${name}" already defined`);
20521
+ }
20518
20522
  this.current.getData().types[upper] = type;
20519
20523
  }
20520
20524
  addExtraLikeType(type) {
@@ -20564,6 +20568,9 @@ class CurrentScope {
20564
20568
  if (this.current.getData().vars[upper] !== undefined) {
20565
20569
  throw new Error(`Variable name "${name}" already defined`);
20566
20570
  }
20571
+ else if (this.isOO() && this.current.getData().types[upper] !== undefined) {
20572
+ throw new Error(`"${name}" already defined`);
20573
+ }
20567
20574
  this.current.getData().vars[upper] = identifier;
20568
20575
  }
20569
20576
  addIdentifier(identifier) {
@@ -20830,7 +20837,7 @@ class CurrentScope {
20830
20837
  while (curr !== undefined) {
20831
20838
  const stype = curr.getIdentifier().stype;
20832
20839
  if (stype === _scope_type_1.ScopeType.ClassDefinition
20833
- || stype === _scope_type_1.ScopeType.ClassImplementation
20840
+ // || stype === ScopeType.ClassImplementation
20834
20841
  || stype === _scope_type_1.ScopeType.Interface) {
20835
20842
  return true;
20836
20843
  }
@@ -30977,6 +30984,7 @@ const dynamic_1 = __webpack_require__(/*! ../expressions/dynamic */ "./node_modu
30977
30984
  const basic_1 = __webpack_require__(/*! ../../types/basic */ "./node_modules/@abaplint/core/build/src/abap/types/basic/index.js");
30978
30985
  class Sort {
30979
30986
  runSyntax(node, scope, filename) {
30987
+ var _a, _b;
30980
30988
  for (const s of node.findDirectExpressions(Expressions.Dynamic)) {
30981
30989
  new dynamic_1.Dynamic().runSyntax(s, scope, filename);
30982
30990
  }
@@ -30984,6 +30992,9 @@ class Sort {
30984
30992
  if (tnode) {
30985
30993
  const ttype = new target_1.Target().runSyntax(tnode, scope, filename);
30986
30994
  if (ttype instanceof basic_1.TableType) {
30995
+ if (((_b = (_a = ttype.getOptions()) === null || _a === void 0 ? void 0 : _a.primaryKey) === null || _b === void 0 ? void 0 : _b.type) === basic_1.TableAccessType.sorted) {
30996
+ throw new Error(`Sorted table, already sorted`);
30997
+ }
30987
30998
  const rowType = ttype.getRowType();
30988
30999
  if (!(rowType instanceof basic_1.VoidType)
30989
31000
  && !(rowType instanceof basic_1.UnknownType)
@@ -48738,7 +48749,7 @@ class Registry {
48738
48749
  }
48739
48750
  static abaplintVersion() {
48740
48751
  // magic, see build script "version.sh"
48741
- return "2.102.28";
48752
+ return "2.102.30";
48742
48753
  }
48743
48754
  getDDICReferences() {
48744
48755
  return this.ddicReferences;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@abaplint/cli",
3
- "version": "2.102.28",
3
+ "version": "2.102.30",
4
4
  "description": "abaplint - Command Line Interface",
5
5
  "funding": "https://github.com/sponsors/larshp",
6
6
  "bin": {
@@ -38,23 +38,23 @@
38
38
  },
39
39
  "homepage": "https://abaplint.org",
40
40
  "devDependencies": {
41
- "@abaplint/core": "^2.102.28",
41
+ "@abaplint/core": "^2.102.30",
42
42
  "@types/chai": "^4.3.5",
43
43
  "@types/glob": "^7.2.0",
44
44
  "@types/minimist": "^1.2.2",
45
45
  "@types/mocha": "^10.0.1",
46
- "@types/node": "^20.5.4",
46
+ "@types/node": "^20.5.7",
47
47
  "@types/progress": "^2.0.5",
48
- "chai": "^4.3.7",
48
+ "chai": "^4.3.8",
49
49
  "chalk": "^5.3.0",
50
- "eslint": "^8.47.0",
50
+ "eslint": "^8.48.0",
51
51
  "glob": "^7.2.3",
52
52
  "json5": "^2.2.3",
53
53
  "memfs": "^4.2.1",
54
54
  "minimist": "^1.2.8",
55
55
  "mocha": "^10.2.0",
56
56
  "progress": "^2.0.3",
57
- "typescript": "^5.1.6",
57
+ "typescript": "^5.2.2",
58
58
  "webpack": "^5.88.2",
59
59
  "webpack-cli": "^5.1.4",
60
60
  "xml-js": "^1.6.11"