@abaplint/cli 2.102.31 → 2.102.33

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 +14 -6
  2. package/package.json +2 -2
package/build/cli.js CHANGED
@@ -21688,7 +21688,7 @@ class TypeUtils {
21688
21688
  return false;
21689
21689
  }
21690
21690
  isAssignableStrict(source, target, calculated = false) {
21691
- var _a, _b, _c, _d, _e, _f, _g;
21691
+ var _a, _b, _c, _d, _e, _f, _g, _h;
21692
21692
  /*
21693
21693
  console.dir(source);
21694
21694
  console.dir(target);
@@ -21777,7 +21777,13 @@ class TypeUtils {
21777
21777
  }
21778
21778
  }
21779
21779
  else if (source instanceof basic_1.IntegerType) {
21780
- if (target instanceof basic_1.StringType || target instanceof basic_1.Integer8Type) {
21780
+ if (target instanceof basic_1.StringType) {
21781
+ return false;
21782
+ }
21783
+ else if (target instanceof basic_1.Integer8Type) {
21784
+ if (((_h = source.getAbstractTypeData()) === null || _h === void 0 ? void 0 : _h.derivedFromConstant) === true) {
21785
+ return true;
21786
+ }
21781
21787
  return false;
21782
21788
  }
21783
21789
  }
@@ -23436,7 +23442,7 @@ class Constant {
23436
23442
  runSyntax(node) {
23437
23443
  // todo: ConcatenatedConstant is not used?
23438
23444
  if (node.findDirectExpression(expressions_1.Integer)) {
23439
- return basic_1.IntegerType.get();
23445
+ return basic_1.IntegerType.get({ derivedFromConstant: true });
23440
23446
  }
23441
23447
  else if (node.getFirstToken().getStr().startsWith("'")) {
23442
23448
  let len = node.getFirstToken().getStr().length - 2;
@@ -29335,7 +29341,8 @@ class InsertInternal {
29335
29341
  if (t) {
29336
29342
  targetType = new target_1.Target().runSyntax(t, scope, filename);
29337
29343
  }
29338
- if (targetType instanceof basic_1.TableType && node.findDirectTokenByText("LINES") === undefined) {
29344
+ if (targetType instanceof basic_1.TableType
29345
+ && node.findDirectTokenByText("LINES") === undefined) {
29339
29346
  targetType = targetType.getRowType();
29340
29347
  }
29341
29348
  let source = node.findDirectExpression(Expressions.SimpleSource4);
@@ -29353,7 +29360,8 @@ class InsertInternal {
29353
29360
  new fstarget_1.FSTarget().runSyntax(afterAssigning, scope, filename, sourceType);
29354
29361
  }
29355
29362
  }
29356
- if (new _type_utils_1.TypeUtils(scope).isAssignableStrict(sourceType, targetType) === false) {
29363
+ if (afterAssigning === undefined
29364
+ && new _type_utils_1.TypeUtils(scope).isAssignableStrict(sourceType, targetType) === false) {
29357
29365
  throw new Error("Types not compatible");
29358
29366
  }
29359
29367
  const afterInto = node.findExpressionAfterToken("INTO");
@@ -48759,7 +48767,7 @@ class Registry {
48759
48767
  }
48760
48768
  static abaplintVersion() {
48761
48769
  // magic, see build script "version.sh"
48762
- return "2.102.31";
48770
+ return "2.102.33";
48763
48771
  }
48764
48772
  getDDICReferences() {
48765
48773
  return this.ddicReferences;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@abaplint/cli",
3
- "version": "2.102.31",
3
+ "version": "2.102.33",
4
4
  "description": "abaplint - Command Line Interface",
5
5
  "funding": "https://github.com/sponsors/larshp",
6
6
  "bin": {
@@ -38,7 +38,7 @@
38
38
  },
39
39
  "homepage": "https://abaplint.org",
40
40
  "devDependencies": {
41
- "@abaplint/core": "^2.102.31",
41
+ "@abaplint/core": "^2.102.33",
42
42
  "@types/chai": "^4.3.5",
43
43
  "@types/glob": "^7.2.0",
44
44
  "@types/minimist": "^1.2.2",