@abaplint/cli 2.113.246 → 2.114.0

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 +164 -41
  2. package/package.json +2 -2
package/build/cli.js CHANGED
@@ -6034,7 +6034,6 @@ __exportStar(__webpack_require__(/*! ./sql_arithmetic_operator */ "./node_module
6034
6034
  __exportStar(__webpack_require__(/*! ./sql_arithmetics */ "./node_modules/@abaplint/core/build/src/abap/2_statements/expressions/sql_arithmetics.js"), exports);
6035
6035
  __exportStar(__webpack_require__(/*! ./sql_as_name */ "./node_modules/@abaplint/core/build/src/abap/2_statements/expressions/sql_as_name.js"), exports);
6036
6036
  __exportStar(__webpack_require__(/*! ./sql_case */ "./node_modules/@abaplint/core/build/src/abap/2_statements/expressions/sql_case.js"), exports);
6037
- __exportStar(__webpack_require__(/*! ./sql_cast */ "./node_modules/@abaplint/core/build/src/abap/2_statements/expressions/sql_cast.js"), exports);
6038
6037
  __exportStar(__webpack_require__(/*! ./sql_cds_parameters */ "./node_modules/@abaplint/core/build/src/abap/2_statements/expressions/sql_cds_parameters.js"), exports);
6039
6038
  __exportStar(__webpack_require__(/*! ./sql_client */ "./node_modules/@abaplint/core/build/src/abap/2_statements/expressions/sql_client.js"), exports);
6040
6039
  __exportStar(__webpack_require__(/*! ./sql_compare_operator */ "./node_modules/@abaplint/core/build/src/abap/2_statements/expressions/sql_compare_operator.js"), exports);
@@ -8185,33 +8184,6 @@ exports.SQLCase = SQLCase;
8185
8184
 
8186
8185
  /***/ }),
8187
8186
 
8188
- /***/ "./node_modules/@abaplint/core/build/src/abap/2_statements/expressions/sql_cast.js":
8189
- /*!*****************************************************************************************!*\
8190
- !*** ./node_modules/@abaplint/core/build/src/abap/2_statements/expressions/sql_cast.js ***!
8191
- \*****************************************************************************************/
8192
- /***/ ((__unused_webpack_module, exports, __webpack_require__) => {
8193
-
8194
- "use strict";
8195
-
8196
- Object.defineProperty(exports, "__esModule", ({ value: true }));
8197
- exports.SQLCast = void 0;
8198
- const _1 = __webpack_require__(/*! . */ "./node_modules/@abaplint/core/build/src/abap/2_statements/expressions/index.js");
8199
- const version_1 = __webpack_require__(/*! ../../../version */ "./node_modules/@abaplint/core/build/src/version.js");
8200
- const tokens_1 = __webpack_require__(/*! ../../1_lexer/tokens */ "./node_modules/@abaplint/core/build/src/abap/1_lexer/tokens/index.js");
8201
- const combi_1 = __webpack_require__(/*! ../combi */ "./node_modules/@abaplint/core/build/src/abap/2_statements/combi.js");
8202
- const sql_field_name_1 = __webpack_require__(/*! ./sql_field_name */ "./node_modules/@abaplint/core/build/src/abap/2_statements/expressions/sql_field_name.js");
8203
- class SQLCast extends combi_1.Expression {
8204
- getRunnable() {
8205
- const abap = (0, combi_1.ver)(version_1.Version.v740sp05, (0, combi_1.seq)((0, combi_1.tok)(tokens_1.WAt), _1.SimpleFieldChain2), version_1.Version.OpenABAP);
8206
- // todo: from version something
8207
- return (0, combi_1.seq)("CAST", "(", (0, combi_1.opt)((0, combi_1.altPrio)(sql_field_name_1.SQLFieldName, abap)), "AS", sql_field_name_1.SQLFieldName, ")");
8208
- }
8209
- }
8210
- exports.SQLCast = SQLCast;
8211
- //# sourceMappingURL=sql_cast.js.map
8212
-
8213
- /***/ }),
8214
-
8215
8187
  /***/ "./node_modules/@abaplint/core/build/src/abap/2_statements/expressions/sql_cds_parameters.js":
8216
8188
  /*!***************************************************************************************************!*\
8217
8189
  !*** ./node_modules/@abaplint/core/build/src/abap/2_statements/expressions/sql_cds_parameters.js ***!
@@ -8367,7 +8339,7 @@ class SQLField extends combi_1.Expression {
8367
8339
  const abap = (0, combi_1.ver)(version_1.Version.v740sp05, (0, combi_1.seq)((0, combi_1.tok)(tokens_1.WAt), _1.SimpleFieldChain2), version_1.Version.OpenABAP);
8368
8340
  const as = (0, combi_1.seq)("AS", _1.SQLAsName);
8369
8341
  const parenFieldName = (0, combi_1.seq)((0, combi_1.tok)(tokens_1.WParenLeftW), _1.SQLFieldName, (0, combi_1.altPrio)((0, combi_1.tok)(tokens_1.WParenRightW), (0, combi_1.tok)(tokens_1.WParenRight)));
8370
- const field = (0, combi_1.altPrio)(_1.SQLAggregation, _1.SQLCase, _1.SQLCast, sql_function_1.SQLFunction, sql_path_1.SQLPath, _1.SQLFieldName, abap, _1.Constant, parenFieldName);
8342
+ const field = (0, combi_1.altPrio)(_1.SQLAggregation, _1.SQLCase, sql_function_1.SQLFunction, sql_path_1.SQLPath, _1.SQLFieldName, abap, _1.Constant, parenFieldName);
8371
8343
  const parenField = (0, combi_1.seq)((0, combi_1.tok)(tokens_1.WParenLeftW), field, (0, combi_1.tok)(tokens_1.WParenRightW));
8372
8344
  const sub = (0, combi_1.plusPrio)((0, combi_1.seq)((0, combi_1.altPrio)("+", "-", "*", "/", "&&"), (0, combi_1.altPrio)(parenField, field)));
8373
8345
  const arith = (0, combi_1.ver)(version_1.Version.v740sp05, sub);
@@ -8633,10 +8605,11 @@ const integer_1 = __webpack_require__(/*! ./integer */ "./node_modules/@abaplint
8633
8605
  const sql_function_input_1 = __webpack_require__(/*! ./sql_function_input */ "./node_modules/@abaplint/core/build/src/abap/2_statements/expressions/sql_function_input.js");
8634
8606
  class SQLFunction extends combi_1.Expression {
8635
8607
  getRunnable() {
8636
- const castTypes = (0, combi_1.altPrio)((0, combi_1.seq)("CHAR", (0, combi_1.optPrio)((0, combi_1.seq)((0, combi_1.tok)(tokens_1.ParenLeftW), integer_1.Integer, (0, combi_1.tok)(tokens_1.WParenRightW)))), (0, combi_1.seq)("DEC", (0, combi_1.tok)(tokens_1.ParenLeftW), integer_1.Integer, ",", integer_1.Integer, (0, combi_1.tok)(tokens_1.WParenRightW)), (0, combi_1.seq)("NUMC", (0, combi_1.optPrio)((0, combi_1.seq)((0, combi_1.tok)(tokens_1.ParenLeftW), integer_1.Integer, (0, combi_1.tok)(tokens_1.WParenRightW)))), "FLTP", "INT2", "INT4", "INT8");
8608
+ const castTypes = (0, combi_1.altPrio)((0, combi_1.seq)("CHAR", (0, combi_1.optPrio)((0, combi_1.seq)((0, combi_1.tok)(tokens_1.ParenLeftW), integer_1.Integer, (0, combi_1.tok)(tokens_1.WParenRightW)))), (0, combi_1.seq)("DEC", (0, combi_1.tok)(tokens_1.ParenLeftW), integer_1.Integer, ",", integer_1.Integer, (0, combi_1.tok)(tokens_1.WParenRightW)), (0, combi_1.seq)("NUMC", (0, combi_1.optPrio)((0, combi_1.seq)((0, combi_1.tok)(tokens_1.ParenLeftW), integer_1.Integer, (0, combi_1.tok)(tokens_1.WParenRightW)))), "DATS", "FLTP", "INT2", "INT4", "INT8");
8637
8609
  const commaParam = (0, combi_1.seq)(",", sql_function_input_1.SQLFunctionInput);
8638
8610
  // note: the function names are not keywords, they are usually in lower case
8639
8611
  const abs = (0, combi_1.ver)(version_1.Version.v740sp05, (0, combi_1.seq)((0, combi_1.regex)(/^abs$/i), (0, combi_1.tok)(tokens_1.ParenLeftW), sql_function_input_1.SQLFunctionInput, (0, combi_1.tok)(tokens_1.WParenRightW)));
8612
+ // yea, 750 is correct, but it also works technically in version v740sp05
8640
8613
  const cast = (0, combi_1.ver)(version_1.Version.v750, (0, combi_1.seq)((0, combi_1.regex)(/^cast$/i), (0, combi_1.tok)(tokens_1.ParenLeftW), sql_function_input_1.SQLFunctionInput, "AS", castTypes, (0, combi_1.tok)(tokens_1.WParenRightW)));
8641
8614
  const ceil = (0, combi_1.ver)(version_1.Version.v740sp05, (0, combi_1.seq)((0, combi_1.regex)(/^ceil$/i), (0, combi_1.tok)(tokens_1.ParenLeftW), sql_function_input_1.SQLFunctionInput, (0, combi_1.tok)(tokens_1.WParenRightW)));
8642
8615
  const coalesce = (0, combi_1.ver)(version_1.Version.v740sp05, (0, combi_1.seq)((0, combi_1.regex)(/^coalesce$/i), (0, combi_1.tok)(tokens_1.ParenLeftW), sql_function_input_1.SQLFunctionInput, commaParam, (0, combi_1.optPrio)(commaParam), (0, combi_1.tok)(tokens_1.WParenRightW)));
@@ -28053,7 +28026,7 @@ const _syntax_input_1 = __webpack_require__(/*! ../_syntax_input */ "./node_modu
28053
28026
  const isSimple = /^\w+$/;
28054
28027
  class Select {
28055
28028
  static runSyntax(node, input, skipImplicitInto = false) {
28056
- var _a, _b;
28029
+ var _a;
28057
28030
  const token = node.getFirstToken();
28058
28031
  let from = node.findDirectExpression(Expressions.SQLFrom);
28059
28032
  if (from === undefined) {
@@ -28074,10 +28047,8 @@ class Select {
28074
28047
  input.issues.push((0, _syntax_input_1.syntaxIssue)(input, node.getFirstToken(), message));
28075
28048
  return;
28076
28049
  }
28077
- const isSingle = ((_a = node.getChildren()[1]) === null || _a === void 0 ? void 0 : _a.concatTokens().toUpperCase()) === "SINGLE"
28078
- || node.get() instanceof Expressions.SelectLoop;
28079
28050
  this.checkFields(fields, dbSources, input, node);
28080
- this.handleInto(node, input, fields, dbSources, isSingle);
28051
+ const intoExpression = this.handleInto(node, input, fields, dbSources);
28081
28052
  const fae = node.findDirectExpression(Expressions.SQLForAllEntries);
28082
28053
  if (fae) {
28083
28054
  input.scope.push(_scope_type_1.ScopeType.OpenSQL, "SELECT", token.getStart(), input.filename);
@@ -28091,7 +28062,7 @@ class Select {
28091
28062
  && node.findDirectExpression(Expressions.SQLIntoTable) === undefined
28092
28063
  && node.findDirectExpression(Expressions.SQLIntoList) === undefined
28093
28064
  && node.findDirectExpression(Expressions.SQLIntoStructure) === undefined) {
28094
- const fields = (_b = node.findFirstExpression(Expressions.SQLAggregation)) === null || _b === void 0 ? void 0 : _b.concatTokens();
28065
+ const fields = (_a = node.findFirstExpression(Expressions.SQLAggregation)) === null || _a === void 0 ? void 0 : _a.concatTokens();
28095
28066
  const c = new RegExp(/^count\(\s*\*\s*\)$/, "i");
28096
28067
  if (fields === undefined || c.test(fields) === false) {
28097
28068
  const nameToken = from === null || from === void 0 ? void 0 : from.findDirectExpression(Expressions.SQLFromSource);
@@ -28125,8 +28096,18 @@ class Select {
28125
28096
  for (const s of node.findAllExpressions(Expressions.SQLCompare)) {
28126
28097
  sql_compare_1.SQLCompare.runSyntax(s, input, dbSources);
28127
28098
  }
28128
- for (const s of node.findDirectExpressions(Expressions.SQLOrderBy)) {
28129
- sql_order_by_1.SQLOrderBy.runSyntax(s, input);
28099
+ const orderBy = node.findDirectExpression(Expressions.SQLOrderBy);
28100
+ if (orderBy) {
28101
+ sql_order_by_1.SQLOrderBy.runSyntax(orderBy, input);
28102
+ const where = node.findDirectExpression(Expressions.SQLCond);
28103
+ if (intoExpression
28104
+ && where
28105
+ && intoExpression.getFirstToken().getStart().isBefore(orderBy.getFirstToken().getStart())
28106
+ && where.getFirstToken().getStart().isBefore(orderBy.getFirstToken().getStart())
28107
+ && where.getFirstToken().getStart().isBefore(intoExpression.getFirstToken().getStart())) {
28108
+ const message = `ORDER BY must be before INTO, after WHERE`;
28109
+ input.issues.push((0, _syntax_input_1.syntaxIssue)(input, orderBy.getFirstToken(), message));
28110
+ }
28130
28111
  }
28131
28112
  if (this.isStrictMode(node)) {
28132
28113
  this.strictModeChecks(node, input);
@@ -28177,13 +28158,14 @@ class Select {
28177
28158
  input.issues.push((0, _syntax_input_1.syntaxIssue)(input, node.getFirstToken(), message));
28178
28159
  }
28179
28160
  }
28180
- static handleInto(node, input, fields, dbSources, _isSingle) {
28161
+ static handleInto(node, input, fields, dbSources) {
28181
28162
  const intoTable = node.findDirectExpression(Expressions.SQLIntoTable);
28182
28163
  if (intoTable) {
28183
28164
  const inline = intoTable.findFirstExpression(Expressions.InlineData);
28184
28165
  if (inline) {
28185
28166
  inline_data_1.InlineData.runSyntax(inline, input, this.buildTableType(fields, dbSources, input.scope));
28186
28167
  }
28168
+ return intoTable;
28187
28169
  }
28188
28170
  const intoStructure = node.findDirectExpression(Expressions.SQLIntoStructure);
28189
28171
  if (intoStructure) {
@@ -28197,6 +28179,7 @@ class Select {
28197
28179
  inline_data_1.InlineData.runSyntax(inline, input, basic_1.VoidType.get("SELECT_todo1"));
28198
28180
  }
28199
28181
  }
28182
+ return intoStructure;
28200
28183
  }
28201
28184
  const intoList = node.findDirectExpression(Expressions.SQLIntoList);
28202
28185
  if (intoList) {
@@ -28236,7 +28219,9 @@ class Select {
28236
28219
  inline_data_1.InlineData.runSyntax(inline, input, type);
28237
28220
  }
28238
28221
  }
28222
+ return intoList;
28239
28223
  }
28224
+ return undefined;
28240
28225
  }
28241
28226
  static checkFields(fields, dbSources, input, node) {
28242
28227
  if (dbSources.length > 1) {
@@ -46362,6 +46347,7 @@ class ABAPObject extends _abstract_object_1.AbstractObject {
46362
46347
  setDirty() {
46363
46348
  this.syntaxResult = undefined;
46364
46349
  this.texts = undefined;
46350
+ this.parsed = [];
46365
46351
  super.setDirty();
46366
46352
  }
46367
46353
  getABAPFiles() {
@@ -46456,6 +46442,7 @@ class AbstractObject {
46456
46442
  return this.name;
46457
46443
  }
46458
46444
  setDirty() {
46445
+ this.old = [];
46459
46446
  this.dirty = true;
46460
46447
  }
46461
46448
  addFile(file) {
@@ -48903,6 +48890,37 @@ exports.EcattTestScript = EcattTestScript;
48903
48890
 
48904
48891
  /***/ }),
48905
48892
 
48893
+ /***/ "./node_modules/@abaplint/core/build/src/objects/email_template.js":
48894
+ /*!*************************************************************************!*\
48895
+ !*** ./node_modules/@abaplint/core/build/src/objects/email_template.js ***!
48896
+ \*************************************************************************/
48897
+ /***/ ((__unused_webpack_module, exports, __webpack_require__) => {
48898
+
48899
+ "use strict";
48900
+
48901
+ Object.defineProperty(exports, "__esModule", ({ value: true }));
48902
+ exports.EmailTemplate = void 0;
48903
+ const _abstract_object_1 = __webpack_require__(/*! ./_abstract_object */ "./node_modules/@abaplint/core/build/src/objects/_abstract_object.js");
48904
+ class EmailTemplate extends _abstract_object_1.AbstractObject {
48905
+ getType() {
48906
+ return "SMTG";
48907
+ }
48908
+ getAllowedNaming() {
48909
+ return {
48910
+ maxLength: 60, // todo
48911
+ allowNamespace: true,
48912
+ };
48913
+ }
48914
+ getDescription() {
48915
+ // todo
48916
+ return undefined;
48917
+ }
48918
+ }
48919
+ exports.EmailTemplate = EmailTemplate;
48920
+ //# sourceMappingURL=email_template.js.map
48921
+
48922
+ /***/ }),
48923
+
48906
48924
  /***/ "./node_modules/@abaplint/core/build/src/objects/enhancement_implementation.js":
48907
48925
  /*!*************************************************************************************!*\
48908
48926
  !*** ./node_modules/@abaplint/core/build/src/objects/enhancement_implementation.js ***!
@@ -50192,7 +50210,6 @@ __exportStar(__webpack_require__(/*! ./behavior_definition */ "./node_modules/@a
50192
50210
  __exportStar(__webpack_require__(/*! ./brf_plus_system_application */ "./node_modules/@abaplint/core/build/src/objects/brf_plus_system_application.js"), exports);
50193
50211
  __exportStar(__webpack_require__(/*! ./bsp_application */ "./node_modules/@abaplint/core/build/src/objects/bsp_application.js"), exports);
50194
50212
  __exportStar(__webpack_require__(/*! ./business_add_in_implementation */ "./node_modules/@abaplint/core/build/src/objects/business_add_in_implementation.js"), exports);
50195
- __exportStar(__webpack_require__(/*! ./cds_entity_buffer */ "./node_modules/@abaplint/core/build/src/objects/cds_entity_buffer.js"), exports);
50196
50213
  __exportStar(__webpack_require__(/*! ./business_catalog_app_assignment */ "./node_modules/@abaplint/core/build/src/objects/business_catalog_app_assignment.js"), exports);
50197
50214
  __exportStar(__webpack_require__(/*! ./business_catalog */ "./node_modules/@abaplint/core/build/src/objects/business_catalog.js"), exports);
50198
50215
  __exportStar(__webpack_require__(/*! ./business_configuration_maintenance_object */ "./node_modules/@abaplint/core/build/src/objects/business_configuration_maintenance_object.js"), exports);
@@ -50201,6 +50218,7 @@ __exportStar(__webpack_require__(/*! ./business_function_assignment */ "./node_m
50201
50218
  __exportStar(__webpack_require__(/*! ./business_function_set_assignment */ "./node_modules/@abaplint/core/build/src/objects/business_function_set_assignment.js"), exports);
50202
50219
  __exportStar(__webpack_require__(/*! ./business_object_model */ "./node_modules/@abaplint/core/build/src/objects/business_object_model.js"), exports);
50203
50220
  __exportStar(__webpack_require__(/*! ./business_object_type */ "./node_modules/@abaplint/core/build/src/objects/business_object_type.js"), exports);
50221
+ __exportStar(__webpack_require__(/*! ./cds_entity_buffer */ "./node_modules/@abaplint/core/build/src/objects/cds_entity_buffer.js"), exports);
50204
50222
  __exportStar(__webpack_require__(/*! ./cds_metadata_extension */ "./node_modules/@abaplint/core/build/src/objects/cds_metadata_extension.js"), exports);
50205
50223
  __exportStar(__webpack_require__(/*! ./cds_type */ "./node_modules/@abaplint/core/build/src/objects/cds_type.js"), exports);
50206
50224
  __exportStar(__webpack_require__(/*! ./change_document */ "./node_modules/@abaplint/core/build/src/objects/change_document.js"), exports);
@@ -50226,6 +50244,7 @@ __exportStar(__webpack_require__(/*! ./domain */ "./node_modules/@abaplint/core/
50226
50244
  __exportStar(__webpack_require__(/*! ./ecatt_test_configuration */ "./node_modules/@abaplint/core/build/src/objects/ecatt_test_configuration.js"), exports);
50227
50245
  __exportStar(__webpack_require__(/*! ./ecatt_test_data_container */ "./node_modules/@abaplint/core/build/src/objects/ecatt_test_data_container.js"), exports);
50228
50246
  __exportStar(__webpack_require__(/*! ./ecatt_test_script */ "./node_modules/@abaplint/core/build/src/objects/ecatt_test_script.js"), exports);
50247
+ __exportStar(__webpack_require__(/*! ./email_template */ "./node_modules/@abaplint/core/build/src/objects/email_template.js"), exports);
50229
50248
  __exportStar(__webpack_require__(/*! ./enhancement_implementation */ "./node_modules/@abaplint/core/build/src/objects/enhancement_implementation.js"), exports);
50230
50249
  __exportStar(__webpack_require__(/*! ./enhancement_spot */ "./node_modules/@abaplint/core/build/src/objects/enhancement_spot.js"), exports);
50231
50250
  __exportStar(__webpack_require__(/*! ./entity_type */ "./node_modules/@abaplint/core/build/src/objects/entity_type.js"), exports);
@@ -53281,6 +53300,13 @@ class Table extends _abstract_object_1.AbstractObject {
53281
53300
  }
53282
53301
  return (_a = this.parsedData) === null || _a === void 0 ? void 0 : _a.description;
53283
53302
  }
53303
+ getSecondaryIndexes() {
53304
+ var _a;
53305
+ if (this.parsedData === undefined) {
53306
+ this.parseXML();
53307
+ }
53308
+ return (_a = this.parsedData) === null || _a === void 0 ? void 0 : _a.secondaryIndexes;
53309
+ }
53284
53310
  getAllowedNaming() {
53285
53311
  let length = 30;
53286
53312
  const regex = /^((\/[A-Z_\d]{3,8}\/)|[a-zA-Z0-9]{3}|CI_)\w+$/;
@@ -53508,7 +53534,7 @@ class Table extends _abstract_object_1.AbstractObject {
53508
53534
  }
53509
53535
  ///////////////
53510
53536
  parseXML() {
53511
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
53537
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
53512
53538
  const parsed = super.parseRaw2();
53513
53539
  if (parsed === undefined) {
53514
53540
  return;
@@ -53547,6 +53573,25 @@ class Table extends _abstract_object_1.AbstractObject {
53547
53573
  DDTEXT: field.DDTEXT,
53548
53574
  });
53549
53575
  }
53576
+ // secondary indexes
53577
+ const indexes = (_m = parsed.abapGit["asx:abap"]["asx:values"]) === null || _m === void 0 ? void 0 : _m.DD12V;
53578
+ ;
53579
+ this.parsedData.secondaryIndexes = [];
53580
+ for (const index of (0, xml_utils_1.xmlToArray)(indexes === null || indexes === void 0 ? void 0 : indexes.DD12V)) {
53581
+ const indexName = index.INDEXNAME;
53582
+ const indexFields = [];
53583
+ const indexFieldsXml = (_o = parsed.abapGit["asx:abap"]["asx:values"]) === null || _o === void 0 ? void 0 : _o.DD17V;
53584
+ for (const indexField of (0, xml_utils_1.xmlToArray)(indexFieldsXml === null || indexFieldsXml === void 0 ? void 0 : indexFieldsXml.DD17V)) {
53585
+ if (indexField.INDEXNAME === indexName) {
53586
+ // assumption: fields are listed by POSITION in the xml
53587
+ indexFields.push(indexField.FIELDNAME);
53588
+ }
53589
+ }
53590
+ this.parsedData.secondaryIndexes.push({
53591
+ name: indexName,
53592
+ fields: indexFields,
53593
+ });
53594
+ }
53550
53595
  }
53551
53596
  }
53552
53597
  exports.Table = Table;
@@ -54904,7 +54949,7 @@ class Registry {
54904
54949
  }
54905
54950
  static abaplintVersion() {
54906
54951
  // magic, see build script "version.sh"
54907
- return "2.113.246";
54952
+ return "2.114.0";
54908
54953
  }
54909
54954
  getDDICReferences() {
54910
54955
  return this.ddicReferences;
@@ -66264,6 +66309,7 @@ __exportStar(__webpack_require__(/*! ./implement_methods */ "./node_modules/@aba
66264
66309
  __exportStar(__webpack_require__(/*! ./implicit_start_of_selection */ "./node_modules/@abaplint/core/build/src/rules/implicit_start_of_selection.js"), exports);
66265
66310
  __exportStar(__webpack_require__(/*! ./in_statement_indentation */ "./node_modules/@abaplint/core/build/src/rules/in_statement_indentation.js"), exports);
66266
66311
  __exportStar(__webpack_require__(/*! ./indentation */ "./node_modules/@abaplint/core/build/src/rules/indentation.js"), exports);
66312
+ __exportStar(__webpack_require__(/*! ./index_completely_contained */ "./node_modules/@abaplint/core/build/src/rules/index_completely_contained.js"), exports);
66267
66313
  __exportStar(__webpack_require__(/*! ./inline_data_old_versions */ "./node_modules/@abaplint/core/build/src/rules/inline_data_old_versions.js"), exports);
66268
66314
  __exportStar(__webpack_require__(/*! ./intf_referencing_clas */ "./node_modules/@abaplint/core/build/src/rules/intf_referencing_clas.js"), exports);
66269
66315
  __exportStar(__webpack_require__(/*! ./invalid_table_index */ "./node_modules/@abaplint/core/build/src/rules/invalid_table_index.js"), exports);
@@ -66370,6 +66416,83 @@ __exportStar(__webpack_require__(/*! ./xml_consistency */ "./node_modules/@abapl
66370
66416
 
66371
66417
  /***/ }),
66372
66418
 
66419
+ /***/ "./node_modules/@abaplint/core/build/src/rules/index_completely_contained.js":
66420
+ /*!***********************************************************************************!*\
66421
+ !*** ./node_modules/@abaplint/core/build/src/rules/index_completely_contained.js ***!
66422
+ \***********************************************************************************/
66423
+ /***/ ((__unused_webpack_module, exports, __webpack_require__) => {
66424
+
66425
+ "use strict";
66426
+
66427
+ Object.defineProperty(exports, "__esModule", ({ value: true }));
66428
+ exports.IndexCompletelyContained = exports.IndexCompletelyContainedConf = void 0;
66429
+ const _basic_rule_config_1 = __webpack_require__(/*! ./_basic_rule_config */ "./node_modules/@abaplint/core/build/src/rules/_basic_rule_config.js");
66430
+ const _irule_1 = __webpack_require__(/*! ./_irule */ "./node_modules/@abaplint/core/build/src/rules/_irule.js");
66431
+ const issue_1 = __webpack_require__(/*! ../issue */ "./node_modules/@abaplint/core/build/src/issue.js");
66432
+ const position_1 = __webpack_require__(/*! ../position */ "./node_modules/@abaplint/core/build/src/position.js");
66433
+ const Objects = __webpack_require__(/*! ../objects */ "./node_modules/@abaplint/core/build/src/objects/index.js");
66434
+ class IndexCompletelyContainedConf extends _basic_rule_config_1.BasicRuleConfig {
66435
+ }
66436
+ exports.IndexCompletelyContainedConf = IndexCompletelyContainedConf;
66437
+ class IndexCompletelyContained {
66438
+ constructor() {
66439
+ this.conf = new IndexCompletelyContainedConf();
66440
+ }
66441
+ getMetadata() {
66442
+ return {
66443
+ key: "index_completely_contained",
66444
+ title: "Check if database table indexes are completely contained",
66445
+ shortDescription: `If indexes are completely contained in other indexes, they can be removed to improve performance.`,
66446
+ tags: [_irule_1.RuleTag.Performance],
66447
+ };
66448
+ }
66449
+ initialize() {
66450
+ return this;
66451
+ }
66452
+ getConfig() {
66453
+ return this.conf;
66454
+ }
66455
+ setConfig(conf) {
66456
+ this.conf = conf;
66457
+ }
66458
+ run(obj) {
66459
+ if (!(obj instanceof Objects.Table)) {
66460
+ return [];
66461
+ }
66462
+ const indexes = obj.getSecondaryIndexes();
66463
+ if (indexes === undefined || indexes.length === 0) {
66464
+ return [];
66465
+ }
66466
+ const issues = [];
66467
+ for (let i = 0; i < indexes.length; i++) {
66468
+ const indexA = indexes[i];
66469
+ for (let j = 0; j < indexes.length; j++) {
66470
+ if (i === j) {
66471
+ continue;
66472
+ }
66473
+ const indexB = indexes[j];
66474
+ let contained = true;
66475
+ for (const field of indexA.fields) {
66476
+ if (indexB.fields.indexOf(field) === -1) {
66477
+ contained = false;
66478
+ break;
66479
+ }
66480
+ }
66481
+ if (contained) {
66482
+ const position = new position_1.Position(1, 1);
66483
+ const message = `Index "${indexA.name}" is completely contained in index "${indexB.name}"`;
66484
+ issues.push(issue_1.Issue.atPosition(obj.getFiles()[0], position, message, this.getMetadata().key, this.conf.severity));
66485
+ }
66486
+ }
66487
+ }
66488
+ return issues;
66489
+ }
66490
+ }
66491
+ exports.IndexCompletelyContained = IndexCompletelyContained;
66492
+ //# sourceMappingURL=index_completely_contained.js.map
66493
+
66494
+ /***/ }),
66495
+
66373
66496
  /***/ "./node_modules/@abaplint/core/build/src/rules/inline_data_old_versions.js":
66374
66497
  /*!*********************************************************************************!*\
66375
66498
  !*** ./node_modules/@abaplint/core/build/src/rules/inline_data_old_versions.js ***!
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@abaplint/cli",
3
- "version": "2.113.246",
3
+ "version": "2.114.0",
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.113.246",
41
+ "@abaplint/core": "^2.114.0",
42
42
  "@types/chai": "^4.3.20",
43
43
  "@types/minimist": "^1.2.5",
44
44
  "@types/mocha": "^10.0.10",