@abaplint/cli 2.106.2 → 2.106.4

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 +112 -37
  2. package/package.json +7 -7
package/build/cli.js CHANGED
@@ -9233,10 +9233,10 @@ class TypeTable extends combi_1.Expression {
9233
9233
  const header = "WITH HEADER LINE";
9234
9234
  const initial = (0, combi_1.seq)("INITIAL SIZE", _1.Constant);
9235
9235
  const generic = (0, combi_1.seq)((0, combi_1.opt)((0, combi_1.alt)("STANDARD", "HASHED", "INDEX", "SORTED", "ANY")), "TABLE");
9236
- const normal1 = (0, combi_1.seq)((0, combi_1.opt)((0, combi_1.alt)("STANDARD", "HASHED", "INDEX", "SORTED", "ANY")), "TABLE OF", (0, combi_1.opt)("REF TO"), (0, combi_1.opt)(_1.TypeName));
9236
+ const normal1 = (0, combi_1.seq)((0, combi_1.opt)((0, combi_1.alt)("STANDARD", "HASHED", "INDEX", "SORTED", "ANY")), "TABLE OF", (0, combi_1.optPrio)("REF TO"), _1.TypeName);
9237
9237
  const likeType = (0, combi_1.seq)((0, combi_1.opt)((0, combi_1.alt)("STANDARD", "HASHED", "INDEX", "SORTED", "ANY")), "TABLE OF", (0, combi_1.optPrio)("REF TO"), (0, combi_1.opt)(field_chain_1.FieldChain), (0, combi_1.opt)((0, combi_1.per)(header, initial, (0, combi_1.plusPrio)(type_table_key_1.TypeTableKey))));
9238
- const rangeType = (0, combi_1.seq)("RANGE OF", _1.TypeName, (0, combi_1.opt)(header), (0, combi_1.opt)(initial));
9239
- const rangeLike = (0, combi_1.seq)("RANGE OF", _1.SimpleFieldChain, (0, combi_1.opt)(header), (0, combi_1.opt)(initial));
9238
+ const rangeType = (0, combi_1.seq)("RANGE OF", _1.TypeName, (0, combi_1.optPrio)(header), (0, combi_1.optPrio)(initial));
9239
+ const rangeLike = (0, combi_1.seq)("RANGE OF", _1.SimpleFieldChain, (0, combi_1.optPrio)(header), (0, combi_1.optPrio)(initial));
9240
9240
  // a maximum of 15 secondary table keys can be defined
9241
9241
  // "WITH" is not allowed as a field name in keys
9242
9242
  const typetable = (0, combi_1.alt)(generic, (0, combi_1.seq)(normal1, (0, combi_1.alt)((0, combi_1.opt)((0, combi_1.per)(header, initial, (0, combi_1.plusPrio)(type_table_key_1.TypeTableKey))), (0, combi_1.seq)((0, combi_1.plus)(type_table_key_1.TypeTableKey), (0, combi_1.optPrio)(initial)))));
@@ -15789,9 +15789,11 @@ exports.Retry = Retry;
15789
15789
  Object.defineProperty(exports, "__esModule", ({ value: true }));
15790
15790
  exports.Return = void 0;
15791
15791
  const combi_1 = __webpack_require__(/*! ../combi */ "./node_modules/@abaplint/core/build/src/abap/2_statements/combi.js");
15792
+ const version_1 = __webpack_require__(/*! ../../../version */ "./node_modules/@abaplint/core/build/src/version.js");
15793
+ const expressions_1 = __webpack_require__(/*! ../expressions */ "./node_modules/@abaplint/core/build/src/abap/2_statements/expressions/index.js");
15792
15794
  class Return {
15793
15795
  getMatcher() {
15794
- return (0, combi_1.str)("RETURN");
15796
+ return (0, combi_1.seq)((0, combi_1.str)("RETURN"), (0, combi_1.optPrio)((0, combi_1.ver)(version_1.Version.v758, expressions_1.Source)));
15795
15797
  }
15796
15798
  }
15797
15799
  exports.Return = Return;
@@ -22425,6 +22427,10 @@ class TypeUtils {
22425
22427
  if (tname === sname) {
22426
22428
  return true;
22427
22429
  }
22430
+ /*
22431
+ console.dir(sid);
22432
+ console.dir(tid);
22433
+ */
22428
22434
  if (!(sid instanceof types_1.ClassDefinition || sid instanceof types_1.InterfaceDefinition)) {
22429
22435
  const found = this.scope.findObjectDefinition(sid.getName());
22430
22436
  if (found) {
@@ -22644,7 +22650,11 @@ class TypeUtils {
22644
22650
  }
22645
22651
  }
22646
22652
  else if (source instanceof basic_1.GenericObjectReferenceType) {
22647
- if (target instanceof basic_1.ObjectReferenceType) {
22653
+ if (target instanceof basic_1.ObjectReferenceType
22654
+ || target instanceof basic_1.StringType
22655
+ || target instanceof basic_1.CharacterType
22656
+ || target instanceof basic_1.TableType
22657
+ || target instanceof basic_1.CLikeType) {
22648
22658
  return false;
22649
22659
  }
22650
22660
  }
@@ -24122,6 +24132,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
24122
24132
  exports.ComponentCompareSimple = void 0;
24123
24133
  const Expressions = __webpack_require__(/*! ../../2_statements/expressions */ "./node_modules/@abaplint/core/build/src/abap/2_statements/expressions/index.js");
24124
24134
  const nodes_1 = __webpack_require__(/*! ../../nodes */ "./node_modules/@abaplint/core/build/src/abap/nodes/index.js");
24135
+ const _type_utils_1 = __webpack_require__(/*! ../_type_utils */ "./node_modules/@abaplint/core/build/src/abap/5_syntax/_type_utils.js");
24125
24136
  const component_chain_1 = __webpack_require__(/*! ./component_chain */ "./node_modules/@abaplint/core/build/src/abap/5_syntax/expressions/component_chain.js");
24126
24137
  const source_1 = __webpack_require__(/*! ./source */ "./node_modules/@abaplint/core/build/src/abap/5_syntax/expressions/source.js");
24127
24138
  class ComponentCompareSimple {
@@ -24136,7 +24147,10 @@ class ComponentCompareSimple {
24136
24147
  targetType = undefined;
24137
24148
  }
24138
24149
  else if (c.get() instanceof Expressions.Source) {
24139
- new source_1.Source().runSyntax(c, scope, filename, targetType);
24150
+ const sourceType = new source_1.Source().runSyntax(c, scope, filename, targetType);
24151
+ if (targetType && new _type_utils_1.TypeUtils(scope).isAssignable(sourceType, targetType) === false) {
24152
+ throw new Error("ComponentCompareSimple, incompatible types");
24153
+ }
24140
24154
  }
24141
24155
  else {
24142
24156
  throw "ComponentCompareSimple, unexpected node";
@@ -25898,6 +25912,9 @@ class MethodParameters {
25898
25912
  checkChanging(node, scope, method, filename) {
25899
25913
  var _a;
25900
25914
  for (const item of this.parameterListT(node, scope, filename)) {
25915
+ if (item.target.findFirstExpression(Expressions.InlineData) !== undefined) {
25916
+ throw new Error("CHANGING cannot be inlined");
25917
+ }
25901
25918
  let parameterType = undefined;
25902
25919
  if (method instanceof basic_1.VoidType) {
25903
25920
  parameterType = method;
@@ -27684,6 +27701,7 @@ const field_assignment_1 = __webpack_require__(/*! ./field_assignment */ "./node
27684
27701
  const basic_1 = __webpack_require__(/*! ../../types/basic */ "./node_modules/@abaplint/core/build/src/abap/types/basic/index.js");
27685
27702
  class ValueBody {
27686
27703
  runSyntax(node, scope, filename, targetType) {
27704
+ var _a;
27687
27705
  if (node === undefined) {
27688
27706
  return targetType;
27689
27707
  }
@@ -27699,8 +27717,16 @@ class ValueBody {
27699
27717
  forScopes++;
27700
27718
  }
27701
27719
  }
27720
+ const fields = new Set();
27702
27721
  for (const s of node.findDirectExpressions(Expressions.FieldAssignment)) {
27703
27722
  new field_assignment_1.FieldAssignment().runSyntax(s, scope, filename, targetType);
27723
+ const fieldname = (_a = s.findDirectExpression(Expressions.FieldSub)) === null || _a === void 0 ? void 0 : _a.concatTokens().toUpperCase();
27724
+ if (fieldname) {
27725
+ if (fields.has(fieldname)) {
27726
+ throw new Error("Duplicate field assignment");
27727
+ }
27728
+ fields.add(fieldname);
27729
+ }
27704
27730
  }
27705
27731
  let type = undefined; // todo, this is only correct if there is a single source in the body
27706
27732
  for (const s of node.findDirectExpressions(Expressions.Source)) {
@@ -29833,11 +29859,21 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
29833
29859
  exports.Do = void 0;
29834
29860
  const Expressions = __webpack_require__(/*! ../../2_statements/expressions */ "./node_modules/@abaplint/core/build/src/abap/2_statements/expressions/index.js");
29835
29861
  const source_1 = __webpack_require__(/*! ../expressions/source */ "./node_modules/@abaplint/core/build/src/abap/5_syntax/expressions/source.js");
29862
+ const target_1 = __webpack_require__(/*! ../expressions/target */ "./node_modules/@abaplint/core/build/src/abap/5_syntax/expressions/target.js");
29863
+ const _type_utils_1 = __webpack_require__(/*! ../_type_utils */ "./node_modules/@abaplint/core/build/src/abap/5_syntax/_type_utils.js");
29864
+ const basic_1 = __webpack_require__(/*! ../../types/basic */ "./node_modules/@abaplint/core/build/src/abap/types/basic/index.js");
29836
29865
  class Do {
29837
29866
  runSyntax(node, scope, filename) {
29838
- // just recurse
29867
+ const afterDo = node.findExpressionAfterToken("DO");
29839
29868
  for (const s of node.findDirectExpressions(Expressions.Source)) {
29840
- new source_1.Source().runSyntax(s, scope, filename);
29869
+ const type = new source_1.Source().runSyntax(s, scope, filename);
29870
+ if (s === afterDo
29871
+ && new _type_utils_1.TypeUtils(scope).isAssignable(type, basic_1.IntegerType.get()) === false) {
29872
+ throw new Error("DO TIMES must be numeric");
29873
+ }
29874
+ }
29875
+ for (const t of node.findDirectExpressions(Expressions.Target)) {
29876
+ new target_1.Target().runSyntax(t, scope, filename);
29841
29877
  }
29842
29878
  }
29843
29879
  }
@@ -30599,7 +30635,13 @@ class InsertInternal {
30599
30635
  if (t) {
30600
30636
  targetType = new target_1.Target().runSyntax(t, scope, filename);
30601
30637
  }
30602
- if (targetType instanceof basic_1.TableType
30638
+ if (!(targetType instanceof basic_1.TableType)
30639
+ && !(targetType instanceof basic_1.VoidType)
30640
+ && !(targetType instanceof basic_1.AnyType)
30641
+ && !(targetType instanceof basic_1.UnknownType)) {
30642
+ throw new Error("INSERT target must be a table");
30643
+ }
30644
+ else if (targetType instanceof basic_1.TableType
30603
30645
  && node.findDirectTokenByText("LINES") === undefined) {
30604
30646
  targetType = targetType.getRowType();
30605
30647
  }
@@ -30618,9 +30660,14 @@ class InsertInternal {
30618
30660
  new fstarget_1.FSTarget().runSyntax(afterAssigning, scope, filename, sourceType);
30619
30661
  }
30620
30662
  }
30621
- if (node.findDirectTokenByText("INITIAL") === undefined
30622
- && new _type_utils_1.TypeUtils(scope).isAssignableStrict(sourceType, targetType) === false) {
30623
- throw new Error("Types not compatible");
30663
+ if (node.findDirectTokenByText("INITIAL") === undefined) {
30664
+ if (new _type_utils_1.TypeUtils(scope).isAssignableStrict(sourceType, targetType) === false) {
30665
+ throw new Error("Types not compatible");
30666
+ }
30667
+ else if (sourceType instanceof basic_1.CharacterType && targetType instanceof basic_1.StringType) {
30668
+ // yea, well, INSERT doesnt convert the values automatically, like everything else?
30669
+ throw new Error("Types not compatible");
30670
+ }
30624
30671
  }
30625
30672
  const afterInto = node.findExpressionAfterToken("INTO");
30626
30673
  if ((afterInto === null || afterInto === void 0 ? void 0 : afterInto.get()) instanceof Expressions.Target && sourceType) {
@@ -31722,11 +31769,17 @@ class ReadTable {
31722
31769
  throw new Error("READ TABLE, FROM must be compatible");
31723
31770
  }
31724
31771
  }
31772
+ const afterKey = node.findExpressionAfterToken("KEY");
31725
31773
  for (const s of sources) {
31726
31774
  if (s === firstSource || s === indexSource || s === fromSource) {
31727
31775
  continue;
31728
31776
  }
31729
- new source_1.Source().runSyntax(s, scope, filename);
31777
+ const type = new source_1.Source().runSyntax(s, scope, filename);
31778
+ if (s === afterKey) {
31779
+ if (type instanceof basic_1.StringType || type instanceof basic_1.TableType || type instanceof basic_1.ObjectReferenceType) {
31780
+ throw new Error("Key cannot be string or table or reference");
31781
+ }
31782
+ }
31730
31783
  }
31731
31784
  const target = node.findDirectExpression(Expressions.ReadTableTarget);
31732
31785
  if (target) {
@@ -51381,7 +51434,7 @@ class Registry {
51381
51434
  }
51382
51435
  static abaplintVersion() {
51383
51436
  // magic, see build script "version.sh"
51384
- return "2.106.2";
51437
+ return "2.106.4";
51385
51438
  }
51386
51439
  getDDICReferences() {
51387
51440
  return this.ddicReferences;
@@ -52800,6 +52853,7 @@ const _basic_rule_config_1 = __webpack_require__(/*! ./_basic_rule_config */ "./
52800
52853
  const Structures = __webpack_require__(/*! ../abap/3_structures/structures */ "./node_modules/@abaplint/core/build/src/abap/3_structures/structures/index.js");
52801
52854
  const Expressions = __webpack_require__(/*! ../abap/2_statements/expressions */ "./node_modules/@abaplint/core/build/src/abap/2_statements/expressions/index.js");
52802
52855
  const Statements = __webpack_require__(/*! ../abap/2_statements/statements */ "./node_modules/@abaplint/core/build/src/abap/2_statements/statements/index.js");
52856
+ const _statement_1 = __webpack_require__(/*! ../abap/2_statements/statements/_statement */ "./node_modules/@abaplint/core/build/src/abap/2_statements/statements/_statement.js");
52803
52857
  const _irule_1 = __webpack_require__(/*! ./_irule */ "./node_modules/@abaplint/core/build/src/rules/_irule.js");
52804
52858
  const edit_helper_1 = __webpack_require__(/*! ../edit_helper */ "./node_modules/@abaplint/core/build/src/edit_helper.js");
52805
52859
  class BeginEndNamesConf extends _basic_rule_config_1.BasicRuleConfig {
@@ -52836,6 +52890,10 @@ class BeginEndNames extends _abap_rule_1.ABAPRule {
52836
52890
  if (struc === undefined) {
52837
52891
  return [];
52838
52892
  }
52893
+ const containsUnknown = file.getStatements().some(s => s.get() instanceof _statement_1.Unknown);
52894
+ if (containsUnknown === true) {
52895
+ return [];
52896
+ }
52839
52897
  output.push(...this.test(struc, Structures.Data, Statements.DataBegin, Statements.DataEnd, file));
52840
52898
  output.push(...this.test(struc, Structures.ClassData, Statements.ClassDataBegin, Statements.ClassDataEnd, file));
52841
52899
  output.push(...this.test(struc, Structures.Constants, Statements.ConstantBegin, Statements.ConstantEnd, file));
@@ -65091,17 +65149,17 @@ class NoPrefixesConf extends _basic_rule_config_1.BasicRuleConfig {
65091
65149
  constructor() {
65092
65150
  super(...arguments);
65093
65151
  /** DATA, CLASS-DATA, DATA BEGIN OF, CLASS-DATA BEGIN OF, FINAL(), DATA(), case insensitive regex */
65094
- this.data = "^[lg].?_";
65152
+ this.data = "^[LGM].?_";
65095
65153
  /** STATICS, STATICS BEGIN OF, case insensitive regex */
65096
- this.statics = "";
65154
+ this.statics = "^S.?_";
65097
65155
  /** FIELD-SYMBOLS and inline FIELD-SYMBOLS(), case insensitive regex */
65098
- this.fieldSymbols = "^<l.?_";
65156
+ this.fieldSymbols = "^<[LGM].?_";
65099
65157
  /** CONSTANTS, CONSTANTS BEGIN OF, case insensitive regex */
65100
- this.constants = "^[lg]c_";
65158
+ this.constants = "^[LGM]?C.?_";
65101
65159
  /** TYPES, ENUM, MESH, case insensitive regex */
65102
- this.types = "^ty_";
65160
+ this.types = "^TY_";
65103
65161
  /** importing, exporting, returning and changing parameters, case insensitive regex */
65104
- this.methodParameters = "^[ierc].?_";
65162
+ this.methodParameters = "^[ICER].?_";
65105
65163
  // todo, public localClass: string = "";
65106
65164
  // todo, public localInterface: string = "";
65107
65165
  // todo, public functionModuleParameters: string = "";
@@ -71037,6 +71095,7 @@ const _abap_rule_1 = __webpack_require__(/*! ./_abap_rule */ "./node_modules/@ab
71037
71095
  const _basic_rule_config_1 = __webpack_require__(/*! ./_basic_rule_config */ "./node_modules/@abaplint/core/build/src/rules/_basic_rule_config.js");
71038
71096
  const _statement_1 = __webpack_require__(/*! ../abap/2_statements/statements/_statement */ "./node_modules/@abaplint/core/build/src/abap/2_statements/statements/_statement.js");
71039
71097
  const _irule_1 = __webpack_require__(/*! ./_irule */ "./node_modules/@abaplint/core/build/src/rules/_irule.js");
71098
+ const edit_helper_1 = __webpack_require__(/*! ../edit_helper */ "./node_modules/@abaplint/core/build/src/edit_helper.js");
71040
71099
  class UnnecessaryPragmaConf extends _basic_rule_config_1.BasicRuleConfig {
71041
71100
  constructor() {
71042
71101
  super(...arguments);
@@ -71151,7 +71210,8 @@ DATA: BEGIN OF blah ##NEEDED,
71151
71210
  if (statement.findFirstExpression(Expressions.ConstantString) === undefined
71152
71211
  && statement.findFirstExpression(Expressions.StringTemplate) === undefined) {
71153
71212
  const message = "There is no text, NO_TEXT can be removed";
71154
- return [issue_1.Issue.atToken(file, p, message, this.getMetadata().key, this.getConfig().severity)];
71213
+ const fix = edit_helper_1.EditHelper.deleteToken(file, p);
71214
+ return [issue_1.Issue.atToken(file, p, message, this.getMetadata().key, this.getConfig().severity, fix)];
71155
71215
  }
71156
71216
  return [];
71157
71217
  }
@@ -71163,7 +71223,8 @@ DATA: BEGIN OF blah ##NEEDED,
71163
71223
  const concat = next.concatTokens().toUpperCase();
71164
71224
  if (concat.includes(" SY-SUBRC")) {
71165
71225
  const message = "SUBRC_OK can be removed as sy-subrc is checked";
71166
- return [issue_1.Issue.atToken(file, p, message, this.getMetadata().key, this.getConfig().severity)];
71226
+ const fix = edit_helper_1.EditHelper.deleteToken(file, p);
71227
+ return [issue_1.Issue.atToken(file, p, message, this.getMetadata().key, this.getConfig().severity, fix)];
71167
71228
  }
71168
71229
  return [];
71169
71230
  }
@@ -71190,7 +71251,8 @@ DATA: BEGIN OF blah ##NEEDED,
71190
71251
  && !(statement.get() instanceof Statements.MethodDef)
71191
71252
  && statement.findFirstExpression(Expressions.InlineFS) === undefined) {
71192
71253
  const message = "There is no data definition, NEEDED can be removed";
71193
- return [issue_1.Issue.atToken(file, p, message, this.getMetadata().key, this.getConfig().severity)];
71254
+ const fix = edit_helper_1.EditHelper.deleteToken(file, p);
71255
+ return [issue_1.Issue.atToken(file, p, message, this.getMetadata().key, this.getConfig().severity, fix)];
71194
71256
  }
71195
71257
  return [];
71196
71258
  }
@@ -72720,16 +72782,15 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
72720
72782
  exports.WhitespaceEnd = exports.WhitespaceEndConf = void 0;
72721
72783
  const issue_1 = __webpack_require__(/*! ../issue */ "./node_modules/@abaplint/core/build/src/issue.js");
72722
72784
  const position_1 = __webpack_require__(/*! ../position */ "./node_modules/@abaplint/core/build/src/position.js");
72723
- const _abap_rule_1 = __webpack_require__(/*! ./_abap_rule */ "./node_modules/@abaplint/core/build/src/rules/_abap_rule.js");
72724
72785
  const _basic_rule_config_1 = __webpack_require__(/*! ./_basic_rule_config */ "./node_modules/@abaplint/core/build/src/rules/_basic_rule_config.js");
72725
72786
  const edit_helper_1 = __webpack_require__(/*! ../edit_helper */ "./node_modules/@abaplint/core/build/src/edit_helper.js");
72726
72787
  const _irule_1 = __webpack_require__(/*! ./_irule */ "./node_modules/@abaplint/core/build/src/rules/_irule.js");
72788
+ const objects_1 = __webpack_require__(/*! ../objects */ "./node_modules/@abaplint/core/build/src/objects/index.js");
72727
72789
  class WhitespaceEndConf extends _basic_rule_config_1.BasicRuleConfig {
72728
72790
  }
72729
72791
  exports.WhitespaceEndConf = WhitespaceEndConf;
72730
- class WhitespaceEnd extends _abap_rule_1.ABAPRule {
72792
+ class WhitespaceEnd {
72731
72793
  constructor() {
72732
- super(...arguments);
72733
72794
  this.conf = new WhitespaceEndConf();
72734
72795
  }
72735
72796
  getMetadata() {
@@ -72737,7 +72798,10 @@ class WhitespaceEnd extends _abap_rule_1.ABAPRule {
72737
72798
  key: "whitespace_end",
72738
72799
  title: "Whitespace at end of line",
72739
72800
  shortDescription: `Checks for redundant whitespace at the end of each line.`,
72801
+ extendedInformation: `SMIM and W3MI files are not checked.`,
72740
72802
  tags: [_irule_1.RuleTag.Whitespace, _irule_1.RuleTag.Quickfix, _irule_1.RuleTag.SingleFile],
72803
+ badExample: `WRITE 'hello'. `,
72804
+ goodExample: `WRITE 'hello'.`,
72741
72805
  };
72742
72806
  }
72743
72807
  getMessage() {
@@ -72749,17 +72813,25 @@ class WhitespaceEnd extends _abap_rule_1.ABAPRule {
72749
72813
  setConfig(conf) {
72750
72814
  this.conf = conf;
72751
72815
  }
72752
- runParsed(file) {
72816
+ initialize(_reg) {
72817
+ return this;
72818
+ }
72819
+ run(obj) {
72753
72820
  const issues = [];
72754
- const rows = file.getRawRows();
72755
- for (let i = 0; i < rows.length; i++) {
72756
- if (rows[i].endsWith(" ") || rows[i].endsWith(" \r")) {
72757
- const match = / +\r?$/.exec(rows[i]);
72758
- const start = new position_1.Position(i + 1, match.index + 1);
72759
- const end = new position_1.Position(i + 1, rows[i].length + 1);
72760
- const fix = edit_helper_1.EditHelper.deleteRange(file, start, end);
72761
- const issue = issue_1.Issue.atRange(file, start, end, this.getMessage(), this.getMetadata().key, this.conf.severity, fix);
72762
- issues.push(issue);
72821
+ for (const file of obj.getFiles()) {
72822
+ if (obj instanceof objects_1.MIMEObject || obj instanceof objects_1.WebMIME) {
72823
+ continue;
72824
+ }
72825
+ const rows = file.getRawRows();
72826
+ for (let i = 0; i < rows.length; i++) {
72827
+ if (rows[i].endsWith(" ") || rows[i].endsWith(" \r")) {
72828
+ const match = / +\r?$/.exec(rows[i]);
72829
+ const start = new position_1.Position(i + 1, match.index + 1);
72830
+ const end = new position_1.Position(i + 1, rows[i].length + 1);
72831
+ const fix = edit_helper_1.EditHelper.deleteRange(file, start, end);
72832
+ const issue = issue_1.Issue.atRange(file, start, end, this.getMessage(), this.getMetadata().key, this.conf.severity, fix);
72833
+ issues.push(issue);
72834
+ }
72763
72835
  }
72764
72836
  }
72765
72837
  return issues;
@@ -73648,9 +73720,10 @@ var Version;
73648
73720
  Version["v755"] = "v755";
73649
73721
  Version["v756"] = "v756";
73650
73722
  Version["v757"] = "v757";
73723
+ Version["v758"] = "v758";
73651
73724
  Version["Cloud"] = "Cloud";
73652
73725
  })(Version || (exports.Version = Version = {}));
73653
- exports.defaultVersion = Version.v757;
73726
+ exports.defaultVersion = Version.v758;
73654
73727
  function getPreviousVersion(v) {
73655
73728
  if (v === Version.OpenABAP) {
73656
73729
  return Version.v702;
@@ -75275,6 +75348,8 @@ class OrderedObjParser{
75275
75348
  "copyright" : { regex: /&(copy|#169);/g, val: "©" },
75276
75349
  "reg" : { regex: /&(reg|#174);/g, val: "®" },
75277
75350
  "inr" : { regex: /&(inr|#8377);/g, val: "₹" },
75351
+ "num_dec": { regex: /&#([0-9]{1,7});/g, val : (_, str) => String.fromCharCode(Number.parseInt(str, 10)) },
75352
+ "num_hex": { regex: /&#x([0-9a-fA-F]{1,6});/g, val : (_, str) => String.fromCharCode(Number.parseInt(str, 16)) },
75278
75353
  };
75279
75354
  this.addExternalEntities = addExternalEntities;
75280
75355
  this.parseXml = parseXml;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@abaplint/cli",
3
- "version": "2.106.2",
3
+ "version": "2.106.4",
4
4
  "description": "abaplint - Command Line Interface",
5
5
  "funding": "https://github.com/sponsors/larshp",
6
6
  "bin": {
@@ -38,24 +38,24 @@
38
38
  },
39
39
  "homepage": "https://abaplint.org",
40
40
  "devDependencies": {
41
- "@abaplint/core": "^2.106.2",
42
- "@types/chai": "^4.3.12",
41
+ "@abaplint/core": "^2.106.4",
42
+ "@types/chai": "^4.3.14",
43
43
  "@types/glob": "^8.1.0",
44
44
  "@types/minimist": "^1.2.5",
45
45
  "@types/mocha": "^10.0.6",
46
- "@types/node": "^20.11.25",
46
+ "@types/node": "^20.11.30",
47
47
  "@types/progress": "^2.0.7",
48
48
  "chai": "^4.4.1",
49
49
  "chalk": "^5.3.0",
50
50
  "eslint": "^8.57.0",
51
51
  "glob": "^7.2.3",
52
52
  "json5": "^2.2.3",
53
- "memfs": "^4.7.7",
53
+ "memfs": "^4.8.0",
54
54
  "minimist": "^1.2.8",
55
55
  "mocha": "^10.3.0",
56
56
  "progress": "^2.0.3",
57
- "typescript": "^5.4.2",
58
- "webpack": "^5.90.3",
57
+ "typescript": "^5.4.3",
58
+ "webpack": "^5.91.0",
59
59
  "webpack-cli": "^5.1.4",
60
60
  "xml-js": "^1.6.11"
61
61
  },