@abaplint/cli 2.120.8 → 2.120.9
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.
- package/build/cli.js +176 -44
- package/package.json +2 -2
package/build/cli.js
CHANGED
|
@@ -3818,7 +3818,7 @@ class Compare extends combi_1.Expression {
|
|
|
3818
3818
|
const inn = (0, combi_1.seq)((0, combi_1.optPrio)("NOT"), "IN", (0, combi_1.altPrio)(_1.Source, list));
|
|
3819
3819
|
const sopt = (0, combi_1.seq)("IS", (0, combi_1.optPrio)("NOT"), (0, combi_1.altPrio)("SUPPLIED", "BOUND", (0, combi_1.ver)(version_1.Release.v750, (0, combi_1.seq)("INSTANCE OF", _1.ClassName), { also: combi_1.AlsoIn.OpenABAP }), "REQUESTED", "INITIAL"));
|
|
3820
3820
|
const between = (0, combi_1.seq)((0, combi_1.optPrio)("NOT"), "BETWEEN", _1.Source, "AND", _1.Source);
|
|
3821
|
-
// https://help.sap.com/doc/
|
|
3821
|
+
// https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-us/abennews-740_sp08-expressions.html
|
|
3822
3822
|
// but also seems to work in v740sp05, blah
|
|
3823
3823
|
const predicate = (0, combi_1.ver)(version_1.Release.v740sp08, _1.MethodCallChain, { also: combi_1.AlsoIn.OpenABAP });
|
|
3824
3824
|
const rett = (0, combi_1.seq)(_1.Source, (0, combi_1.altPrio)((0, combi_1.seq)(_1.CompareOperator, _1.Source), inn, between, sopt));
|
|
@@ -10344,7 +10344,7 @@ const version_1 = __webpack_require__(/*! ../../../version */ "../core/build/src
|
|
|
10344
10344
|
const dynamic_1 = __webpack_require__(/*! ./dynamic */ "../core/build/src/abap/2_statements/expressions/dynamic.js");
|
|
10345
10345
|
class StringTemplateFormatting extends combi_1.Expression {
|
|
10346
10346
|
getRunnable() {
|
|
10347
|
-
// https://help.sap.com/doc/
|
|
10347
|
+
// https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-us/abapcompute_string_format_options.html
|
|
10348
10348
|
const alphaOptions = (0, combi_1.altPrio)("OUT", "RAW", "IN", _1.Source);
|
|
10349
10349
|
const alignOptions = (0, combi_1.altPrio)("LEFT", "RIGHT", "CENTER", _1.Source, dynamic_1.Dynamic);
|
|
10350
10350
|
const dateTimeOptions = (0, combi_1.altPrio)("RAW", "ISO", "USER", "ENVIRONMENT", _1.Source, dynamic_1.Dynamic);
|
|
@@ -25098,7 +25098,7 @@ class BuiltIn {
|
|
|
25098
25098
|
const sy = new _typed_identifier_1.TypedIdentifier(id1, BuiltIn.filename, type, ["read_only" /* IdentifierMeta.ReadOnly */, "built-in" /* IdentifierMeta.BuiltIn */]);
|
|
25099
25099
|
const id2 = new tokens_1.Identifier(new position_1.Position(this.row++, 1), "syst");
|
|
25100
25100
|
const syst = new _typed_identifier_1.TypedIdentifier(id2, BuiltIn.filename, type, ["read_only" /* IdentifierMeta.ReadOnly */, "built-in" /* IdentifierMeta.BuiltIn */]);
|
|
25101
|
-
// https://help.sap.com/doc/
|
|
25101
|
+
// https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-us/abennews-610-system.html
|
|
25102
25102
|
const id3 = new tokens_1.Identifier(new position_1.Position(this.row++, 1), "sy-repid");
|
|
25103
25103
|
const syrepid = new _typed_identifier_1.TypedIdentifier(id3, BuiltIn.filename, new basic_1.CharacterType(40, { qualifiedName: "sy-repid" }), ["read_only" /* IdentifierMeta.ReadOnly */, "built-in" /* IdentifierMeta.BuiltIn */]);
|
|
25104
25104
|
const id4 = new tokens_1.Identifier(new position_1.Position(this.row++, 1), "syst-repid");
|
|
@@ -27709,7 +27709,7 @@ class TypeUtils {
|
|
|
27709
27709
|
}
|
|
27710
27710
|
}
|
|
27711
27711
|
else if (source instanceof basic_1.IntegerType) {
|
|
27712
|
-
if (target instanceof basic_1.StringType) {
|
|
27712
|
+
if (target instanceof basic_1.StringType || target instanceof basic_1.DateType) {
|
|
27713
27713
|
return false;
|
|
27714
27714
|
}
|
|
27715
27715
|
else if (target instanceof basic_1.Integer8Type || target instanceof basic_1.PackedType) {
|
|
@@ -43420,10 +43420,15 @@ const Expressions = __importStar(__webpack_require__(/*! ../../2_statements/expr
|
|
|
43420
43420
|
const _typed_identifier_1 = __webpack_require__(/*! ../../types/_typed_identifier */ "../core/build/src/abap/types/_typed_identifier.js");
|
|
43421
43421
|
const basic_1 = __webpack_require__(/*! ../../types/basic */ "../core/build/src/abap/types/basic/index.js");
|
|
43422
43422
|
const basic_types_1 = __webpack_require__(/*! ../basic_types */ "../core/build/src/abap/5_syntax/basic_types.js");
|
|
43423
|
+
const _syntax_input_1 = __webpack_require__(/*! ../_syntax_input */ "../core/build/src/abap/5_syntax/_syntax_input.js");
|
|
43423
43424
|
const assert_error_1 = __webpack_require__(/*! ../assert_error */ "../core/build/src/abap/5_syntax/assert_error.js");
|
|
43424
43425
|
class Ranges {
|
|
43425
43426
|
runSyntax(node, input) {
|
|
43426
43427
|
var _a;
|
|
43428
|
+
if (input.scope.isAnyOO()) {
|
|
43429
|
+
const message = "RANGES is not allowed within classes";
|
|
43430
|
+
input.issues.push((0, _syntax_input_1.syntaxIssue)(input, node.getFirstToken(), message));
|
|
43431
|
+
}
|
|
43427
43432
|
const nameToken = (_a = node.findFirstExpression(Expressions.DefinitionName)) === null || _a === void 0 ? void 0 : _a.getFirstToken();
|
|
43428
43433
|
const typeExpression = node.findFirstExpression(Expressions.SimpleFieldChain2);
|
|
43429
43434
|
if (typeExpression === undefined) {
|
|
@@ -47205,6 +47210,117 @@ exports.TypeEnum = TypeEnum;
|
|
|
47205
47210
|
|
|
47206
47211
|
/***/ },
|
|
47207
47212
|
|
|
47213
|
+
/***/ "../core/build/src/abap/5_syntax/structures/type_mesh.js"
|
|
47214
|
+
/*!***************************************************************!*\
|
|
47215
|
+
!*** ../core/build/src/abap/5_syntax/structures/type_mesh.js ***!
|
|
47216
|
+
\***************************************************************/
|
|
47217
|
+
(__unused_webpack_module, exports, __webpack_require__) {
|
|
47218
|
+
|
|
47219
|
+
"use strict";
|
|
47220
|
+
|
|
47221
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
47222
|
+
if (k2 === undefined) k2 = k;
|
|
47223
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
47224
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
47225
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
47226
|
+
}
|
|
47227
|
+
Object.defineProperty(o, k2, desc);
|
|
47228
|
+
}) : (function(o, m, k, k2) {
|
|
47229
|
+
if (k2 === undefined) k2 = k;
|
|
47230
|
+
o[k2] = m[k];
|
|
47231
|
+
}));
|
|
47232
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
47233
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
47234
|
+
}) : function(o, v) {
|
|
47235
|
+
o["default"] = v;
|
|
47236
|
+
});
|
|
47237
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
47238
|
+
var ownKeys = function(o) {
|
|
47239
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
47240
|
+
var ar = [];
|
|
47241
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
47242
|
+
return ar;
|
|
47243
|
+
};
|
|
47244
|
+
return ownKeys(o);
|
|
47245
|
+
};
|
|
47246
|
+
return function (mod) {
|
|
47247
|
+
if (mod && mod.__esModule) return mod;
|
|
47248
|
+
var result = {};
|
|
47249
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
47250
|
+
__setModuleDefault(result, mod);
|
|
47251
|
+
return result;
|
|
47252
|
+
};
|
|
47253
|
+
})();
|
|
47254
|
+
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
47255
|
+
exports.TypeMesh = void 0;
|
|
47256
|
+
const Expressions = __importStar(__webpack_require__(/*! ../../2_statements/expressions */ "../core/build/src/abap/2_statements/expressions/index.js"));
|
|
47257
|
+
const Statements = __importStar(__webpack_require__(/*! ../../2_statements/statements */ "../core/build/src/abap/2_statements/statements/index.js"));
|
|
47258
|
+
const nodes_1 = __webpack_require__(/*! ../../nodes */ "../core/build/src/abap/nodes/index.js");
|
|
47259
|
+
const _typed_identifier_1 = __webpack_require__(/*! ../../types/_typed_identifier */ "../core/build/src/abap/types/_typed_identifier.js");
|
|
47260
|
+
const Basic = __importStar(__webpack_require__(/*! ../../types/basic */ "../core/build/src/abap/types/basic/index.js"));
|
|
47261
|
+
const basic_types_1 = __webpack_require__(/*! ../basic_types */ "../core/build/src/abap/5_syntax/basic_types.js");
|
|
47262
|
+
const type_1 = __webpack_require__(/*! ../statements/type */ "../core/build/src/abap/5_syntax/statements/type.js");
|
|
47263
|
+
const _scope_type_1 = __webpack_require__(/*! ../_scope_type */ "../core/build/src/abap/5_syntax/_scope_type.js");
|
|
47264
|
+
class TypeMesh {
|
|
47265
|
+
runSyntax(node, input) {
|
|
47266
|
+
var _a;
|
|
47267
|
+
const begin = node.findDirectStatement(Statements.TypeMeshBegin);
|
|
47268
|
+
if (begin === undefined) {
|
|
47269
|
+
return undefined;
|
|
47270
|
+
}
|
|
47271
|
+
const name = (_a = begin.findFirstExpression(Expressions.NamespaceSimpleName)) === null || _a === void 0 ? void 0 : _a.getFirstToken();
|
|
47272
|
+
if (name === undefined) {
|
|
47273
|
+
return undefined;
|
|
47274
|
+
}
|
|
47275
|
+
const components = [];
|
|
47276
|
+
for (const c of node.getChildren()) {
|
|
47277
|
+
if (!(c instanceof nodes_1.StatementNode)) {
|
|
47278
|
+
continue;
|
|
47279
|
+
}
|
|
47280
|
+
const ctyp = c.get();
|
|
47281
|
+
if (ctyp instanceof Statements.Type) {
|
|
47282
|
+
const found = new type_1.Type().runSyntax(c, input, name.getStr() + "-");
|
|
47283
|
+
if (found) {
|
|
47284
|
+
components.push({ name: found.getName(), type: found.getType() });
|
|
47285
|
+
}
|
|
47286
|
+
}
|
|
47287
|
+
else if (ctyp instanceof Statements.TypeMesh) {
|
|
47288
|
+
const found = this.runMeshNode(c, input);
|
|
47289
|
+
if (found) {
|
|
47290
|
+
components.push({ name: found.getName(), type: found.getType() });
|
|
47291
|
+
}
|
|
47292
|
+
}
|
|
47293
|
+
}
|
|
47294
|
+
let qualifiedName = name.getStr();
|
|
47295
|
+
if (input.scope.getType() === _scope_type_1.ScopeType.ClassDefinition
|
|
47296
|
+
|| input.scope.getType() === _scope_type_1.ScopeType.Interface) {
|
|
47297
|
+
qualifiedName = input.scope.getName() + "=>" + qualifiedName;
|
|
47298
|
+
}
|
|
47299
|
+
return new _typed_identifier_1.TypedIdentifier(name, input.filename, new Basic.StructureType(components, qualifiedName));
|
|
47300
|
+
}
|
|
47301
|
+
////////////////////
|
|
47302
|
+
runMeshNode(node, input) {
|
|
47303
|
+
var _a;
|
|
47304
|
+
const nameToken = (_a = node.findFirstExpression(Expressions.NamespaceSimpleName)) === null || _a === void 0 ? void 0 : _a.getFirstToken();
|
|
47305
|
+
if (nameToken === undefined) {
|
|
47306
|
+
return undefined;
|
|
47307
|
+
}
|
|
47308
|
+
const typeName = node.findFirstExpression(Expressions.TypeName);
|
|
47309
|
+
let type = new basic_types_1.BasicTypes(input).resolveTypeName(typeName);
|
|
47310
|
+
if (type === undefined) {
|
|
47311
|
+
type = new Basic.UnknownType("Mesh node, unknown type " + (typeName === null || typeName === void 0 ? void 0 : typeName.concatTokens()));
|
|
47312
|
+
}
|
|
47313
|
+
else if (node.concatTokens().toUpperCase().includes(" TYPE REF TO ")) {
|
|
47314
|
+
type = new Basic.DataReference(type);
|
|
47315
|
+
}
|
|
47316
|
+
return new _typed_identifier_1.TypedIdentifier(nameToken, input.filename, type);
|
|
47317
|
+
}
|
|
47318
|
+
}
|
|
47319
|
+
exports.TypeMesh = TypeMesh;
|
|
47320
|
+
//# sourceMappingURL=type_mesh.js.map
|
|
47321
|
+
|
|
47322
|
+
/***/ },
|
|
47323
|
+
|
|
47208
47324
|
/***/ "../core/build/src/abap/5_syntax/structures/types.js"
|
|
47209
47325
|
/*!***********************************************************!*\
|
|
47210
47326
|
!*** ../core/build/src/abap/5_syntax/structures/types.js ***!
|
|
@@ -47366,6 +47482,7 @@ const objects_1 = __webpack_require__(/*! ../../objects */ "../core/build/src/ob
|
|
|
47366
47482
|
const position_1 = __webpack_require__(/*! ../../position */ "../core/build/src/position.js");
|
|
47367
47483
|
const data_1 = __webpack_require__(/*! ./structures/data */ "../core/build/src/abap/5_syntax/structures/data.js");
|
|
47368
47484
|
const type_enum_1 = __webpack_require__(/*! ./structures/type_enum */ "../core/build/src/abap/5_syntax/structures/type_enum.js");
|
|
47485
|
+
const type_mesh_1 = __webpack_require__(/*! ./structures/type_mesh */ "../core/build/src/abap/5_syntax/structures/type_mesh.js");
|
|
47369
47486
|
const types_1 = __webpack_require__(/*! ./structures/types */ "../core/build/src/abap/5_syntax/structures/types.js");
|
|
47370
47487
|
const statics_1 = __webpack_require__(/*! ./structures/statics */ "../core/build/src/abap/5_syntax/structures/statics.js");
|
|
47371
47488
|
const constants_1 = __webpack_require__(/*! ./structures/constants */ "../core/build/src/abap/5_syntax/structures/constants.js");
|
|
@@ -47800,6 +47917,13 @@ class SyntaxLogic {
|
|
|
47800
47917
|
this.scope.addIdentifier(new statics_1.Statics().runSyntax(node, input));
|
|
47801
47918
|
return true;
|
|
47802
47919
|
}
|
|
47920
|
+
else if (stru instanceof Structures.TypeMesh) {
|
|
47921
|
+
const found = new type_mesh_1.TypeMesh().runSyntax(node, input);
|
|
47922
|
+
if (found) {
|
|
47923
|
+
this.scope.addType(found);
|
|
47924
|
+
}
|
|
47925
|
+
return true;
|
|
47926
|
+
}
|
|
47803
47927
|
else if (stru instanceof Structures.TypeEnum) {
|
|
47804
47928
|
const values = new type_enum_1.TypeEnum().runSyntax(node, input).values;
|
|
47805
47929
|
this.scope.addList(values);
|
|
@@ -50938,6 +51062,7 @@ const data_1 = __webpack_require__(/*! ../5_syntax/statements/data */ "../core/b
|
|
|
50938
51062
|
const constant_1 = __webpack_require__(/*! ../5_syntax/statements/constant */ "../core/build/src/abap/5_syntax/statements/constant.js");
|
|
50939
51063
|
const data_2 = __webpack_require__(/*! ../5_syntax/structures/data */ "../core/build/src/abap/5_syntax/structures/data.js");
|
|
50940
51064
|
const type_enum_1 = __webpack_require__(/*! ../5_syntax/structures/type_enum */ "../core/build/src/abap/5_syntax/structures/type_enum.js");
|
|
51065
|
+
const type_mesh_1 = __webpack_require__(/*! ../5_syntax/structures/type_mesh */ "../core/build/src/abap/5_syntax/structures/type_mesh.js");
|
|
50941
51066
|
const constants_1 = __webpack_require__(/*! ../5_syntax/structures/constants */ "../core/build/src/abap/5_syntax/structures/constants.js");
|
|
50942
51067
|
const type_definitions_1 = __webpack_require__(/*! ./type_definitions */ "../core/build/src/abap/types/type_definitions.js");
|
|
50943
51068
|
const types_1 = __webpack_require__(/*! ../5_syntax/structures/types */ "../core/build/src/abap/5_syntax/structures/types.js");
|
|
@@ -51098,6 +51223,13 @@ class Attributes {
|
|
|
51098
51223
|
// scope.addIdentifier(attr);
|
|
51099
51224
|
}
|
|
51100
51225
|
}
|
|
51226
|
+
else if (ctyp instanceof Structures.TypeMesh) {
|
|
51227
|
+
const res = new type_mesh_1.TypeMesh().runSyntax(c, input);
|
|
51228
|
+
if (res) {
|
|
51229
|
+
input.scope.addType(res);
|
|
51230
|
+
this.tlist.push({ type: res, visibility });
|
|
51231
|
+
}
|
|
51232
|
+
}
|
|
51101
51233
|
else if (ctyp instanceof Structures.Types) {
|
|
51102
51234
|
const res = new types_1.Types().runSyntax(c, input);
|
|
51103
51235
|
if (res) {
|
|
@@ -69165,7 +69297,7 @@ class Registry {
|
|
|
69165
69297
|
}
|
|
69166
69298
|
static abaplintVersion() {
|
|
69167
69299
|
// magic, see build script "version.js"
|
|
69168
|
-
return "2.120.
|
|
69300
|
+
return "2.120.9";
|
|
69169
69301
|
}
|
|
69170
69302
|
getDDICReferences() {
|
|
69171
69303
|
return this.ddicReferences;
|
|
@@ -69509,7 +69641,7 @@ class SevenBitAscii {
|
|
|
69509
69641
|
shortDescription: `Only allow characters from the 7bit ASCII set.`,
|
|
69510
69642
|
extendedInformation: `https://docs.abapopenchecks.org/checks/05/
|
|
69511
69643
|
|
|
69512
|
-
https://help.sap.com/doc/
|
|
69644
|
+
https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abencharacter_set_guidl.html
|
|
69513
69645
|
|
|
69514
69646
|
Checkes files with extensions ".abap" and ".asddls"`,
|
|
69515
69647
|
tags: [_irule_1.RuleTag.SingleFile],
|
|
@@ -71127,7 +71259,7 @@ class AvoidUse extends _abap_rule_1.ABAPRule {
|
|
|
71127
71259
|
shortDescription: `Detects usage of certain statements.`,
|
|
71128
71260
|
extendedInformation: `DEFAULT KEY: https://github.com/SAP/styleguides/blob/main/clean-abap/CleanABAP.md#avoid-default-key
|
|
71129
71261
|
|
|
71130
|
-
Macros: https://help.sap.com/doc/
|
|
71262
|
+
Macros: https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abenmacros_guidl.html
|
|
71131
71263
|
|
|
71132
71264
|
STATICS: use CLASS-DATA instead
|
|
71133
71265
|
|
|
@@ -71861,7 +71993,7 @@ class CDSCommentStyle {
|
|
|
71861
71993
|
|
|
71862
71994
|
Comments starting with "--" are considered obsolete
|
|
71863
71995
|
|
|
71864
|
-
https://help.sap.com/doc/
|
|
71996
|
+
https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-us/abencds_general_syntax_rules.html`,
|
|
71865
71997
|
tags: [_irule_1.RuleTag.SingleFile],
|
|
71866
71998
|
badExample: "-- this is a comment",
|
|
71867
71999
|
goodExample: "// this is a comment",
|
|
@@ -72390,7 +72522,7 @@ class ChainMainlyDeclarations extends _abap_rule_1.ABAPRule {
|
|
|
72390
72522
|
extendedInformation: `
|
|
72391
72523
|
https://docs.abapopenchecks.org/checks/23/
|
|
72392
72524
|
|
|
72393
|
-
https://help.sap.com/doc/
|
|
72525
|
+
https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abenchained_statements_guidl.html
|
|
72394
72526
|
`,
|
|
72395
72527
|
tags: [_irule_1.RuleTag.SingleFile, _irule_1.RuleTag.Quickfix],
|
|
72396
72528
|
badExample: `CALL METHOD: bar.`,
|
|
@@ -73914,7 +74046,7 @@ before reading it, so a leftover value is not accidentally used.
|
|
|
73914
74046
|
|
|
73915
74047
|
https://github.com/SAP/styleguides/blob/main/clean-abap/CleanABAP.md#clear-or-overwrite-exporting-reference-parameters
|
|
73916
74048
|
|
|
73917
|
-
https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abenref_transf_output_param_guidl.
|
|
74049
|
+
https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abenref_transf_output_param_guidl.html
|
|
73918
74050
|
|
|
73919
74051
|
Note: EXPORTING parameters passed by VALUE are always initialized and are therefore not reported.
|
|
73920
74052
|
Reading and writing the parameter in the same statement (e.g. "ev_result = ev_result + 1") is reported,
|
|
@@ -74613,7 +74745,7 @@ class ConstructorVisibilityPublic {
|
|
|
74613
74745
|
This only applies to global classes.
|
|
74614
74746
|
|
|
74615
74747
|
https://github.com/SAP/styleguides/blob/main/clean-abap/CleanABAP.md#if-your-global-class-is-create-private-leave-the-constructor-public
|
|
74616
|
-
https://help.sap.com/doc/
|
|
74748
|
+
https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abeninstance_constructor_guidl.html`,
|
|
74617
74749
|
tags: [_irule_1.RuleTag.Styleguide, _irule_1.RuleTag.SingleFile],
|
|
74618
74750
|
badExample: `CLASS zcl_foo DEFINITION PUBLIC CREATE PRIVATE.
|
|
74619
74751
|
PRIVATE SECTION.
|
|
@@ -79648,8 +79780,8 @@ class ExitOrCheck extends _abap_rule_1.ABAPRule {
|
|
|
79648
79780
|
title: "Find EXIT or CHECK outside loops",
|
|
79649
79781
|
shortDescription: `Detects usages of EXIT or CHECK statements outside of loops.
|
|
79650
79782
|
Use RETURN to leave procesing blocks instead.`,
|
|
79651
|
-
extendedInformation: `https://help.sap.com/doc/
|
|
79652
|
-
https://help.sap.com/doc/
|
|
79783
|
+
extendedInformation: `https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abenleave_processing_blocks.html
|
|
79784
|
+
https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abapcheck_processing_blocks.html
|
|
79653
79785
|
https://github.com/SAP/styleguides/blob/main/clean-abap/CleanABAP.md#check-vs-return`,
|
|
79654
79786
|
tags: [_irule_1.RuleTag.Styleguide, _irule_1.RuleTag.SingleFile, _irule_1.RuleTag.Quickfix],
|
|
79655
79787
|
badExample: `CHECK is_valid = abap_true.
|
|
@@ -79739,7 +79871,7 @@ class ExpandMacros extends _abap_rule_1.ABAPRule {
|
|
|
79739
79871
|
key: "expand_macros",
|
|
79740
79872
|
title: "Expand Macros",
|
|
79741
79873
|
shortDescription: `Allows expanding macro calls with quick fixes`,
|
|
79742
|
-
extendedInformation: `Macros: https://help.sap.com/doc/
|
|
79874
|
+
extendedInformation: `Macros: https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abenmacros_guidl.html
|
|
79743
79875
|
|
|
79744
79876
|
Note that macros/DEFINE cannot be used in the ABAP Cloud programming model`,
|
|
79745
79877
|
badExample: `DEFINE _hello.
|
|
@@ -79953,7 +80085,7 @@ class FMGlobalParametersObsolete {
|
|
|
79953
80085
|
key: "fm_global_parameters_obsolete",
|
|
79954
80086
|
title: "FM Global Parameters Obsolete",
|
|
79955
80087
|
shortDescription: `Check for function modules with global parameters`,
|
|
79956
|
-
extendedInformation: `https://help.sap.com/doc/
|
|
80088
|
+
extendedInformation: `https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abenglobal_parameters_obsolete.html`,
|
|
79957
80089
|
tags: [],
|
|
79958
80090
|
};
|
|
79959
80091
|
}
|
|
@@ -80438,7 +80570,7 @@ class FormTablesObsolete extends _abap_rule_1.ABAPRule {
|
|
|
80438
80570
|
key: "form_tables_obsolete",
|
|
80439
80571
|
title: "TABLES parameters are obsolete",
|
|
80440
80572
|
shortDescription: `Checks for TABLES parameters in forms.`,
|
|
80441
|
-
extendedInformation: `https://help.sap.com/doc/
|
|
80573
|
+
extendedInformation: `https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abapform_tables.html`,
|
|
80442
80574
|
tags: [_irule_1.RuleTag.SingleFile],
|
|
80443
80575
|
badExample: `FORM update_items TABLES items.
|
|
80444
80576
|
ENDFORM.`,
|
|
@@ -82399,7 +82531,7 @@ class ImplicitStartOfSelection extends _abap_rule_1.ABAPRule {
|
|
|
82399
82531
|
shortDescription: `Add explicit selection screen event handling`,
|
|
82400
82532
|
extendedInformation: `Only runs for executable programs
|
|
82401
82533
|
|
|
82402
|
-
https://help.sap.com/doc/
|
|
82534
|
+
https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-us/abapstart-of-selection.html`,
|
|
82403
82535
|
tags: [_irule_1.RuleTag.SingleFile],
|
|
82404
82536
|
badExample: `REPORT zfoo.
|
|
82405
82537
|
WRITE 'hello'.`,
|
|
@@ -85840,7 +85972,7 @@ class MethodOverwritesBuiltIn extends _abap_rule_1.ABAPRule {
|
|
|
85840
85972
|
key: "method_overwrites_builtin",
|
|
85841
85973
|
title: "Method name overwrites builtin function",
|
|
85842
85974
|
shortDescription: `Checks Method names that overwrite builtin SAP functions`,
|
|
85843
|
-
extendedInformation: `https://help.sap.com/doc/
|
|
85975
|
+
extendedInformation: `https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-us/abenbuilt_in_functions_overview.html
|
|
85844
85976
|
|
|
85845
85977
|
https://github.com/SAP/styleguides/blob/main/clean-abap/CleanABAP.md#avoid-obscuring-built-in-functions
|
|
85846
85978
|
|
|
@@ -86082,7 +86214,7 @@ class MixReturning extends _abap_rule_1.ABAPRule {
|
|
|
86082
86214
|
shortDescription: `Checks that methods don't have a mixture of returning and exporting/changing parameters`,
|
|
86083
86215
|
extendedInformation: `https://github.com/SAP/styleguides/blob/main/clean-abap/CleanABAP.md#use-either-returning-or-exporting-or-changing-but-not-a-combination
|
|
86084
86216
|
|
|
86085
|
-
This syntax is not allowed on versions earlier than 740sp02, https://help.sap.com/doc/
|
|
86217
|
+
This syntax is not allowed on versions earlier than 740sp02, https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-us/abennews-740-abap_objects.html#!ABAP_MODIFICATION_1@1@`,
|
|
86086
86218
|
tags: [_irule_1.RuleTag.Styleguide, _irule_1.RuleTag.SingleFile, _irule_1.RuleTag.Syntax],
|
|
86087
86219
|
badExample: `CLASS lcl DEFINITION.
|
|
86088
86220
|
PUBLIC SECTION.
|
|
@@ -87413,7 +87545,7 @@ class NoMacros extends _abap_rule_1.ABAPRule {
|
|
|
87413
87545
|
shortDescription: `Checks that macros are not used`,
|
|
87414
87546
|
extendedInformation: `Macros reduce readability and are difficult to debug, use methods or form routines instead.
|
|
87415
87547
|
|
|
87416
|
-
https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abenmacros_guidl.
|
|
87548
|
+
https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abenmacros_guidl.html`,
|
|
87417
87549
|
tags: [_irule_1.RuleTag.SingleFile],
|
|
87418
87550
|
badExample: `DEFINE _macro.
|
|
87419
87551
|
WRITE 'hello'.
|
|
@@ -88337,44 +88469,44 @@ https://github.com/SAP/styleguides/blob/main/clean-abap/CleanABAP.md#prefer-func
|
|
|
88337
88469
|
|
|
88338
88470
|
https://github.com/SAP/styleguides/blob/main/clean-abap/CleanABAP.md#avoid-obsolete-language-elements
|
|
88339
88471
|
|
|
88340
|
-
SET EXTENDED CHECK: https://help.sap.com/doc/
|
|
88472
|
+
SET EXTENDED CHECK: https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-us/abapset_extended_check.html
|
|
88341
88473
|
|
|
88342
|
-
IS REQUESTED: https://help.sap.com/doc/
|
|
88474
|
+
IS REQUESTED: https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abenlogexp_requested.html
|
|
88343
88475
|
|
|
88344
|
-
WITH HEADER LINE: https://help.sap.com/doc/
|
|
88476
|
+
WITH HEADER LINE: https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abapdata_header_line.html
|
|
88345
88477
|
|
|
88346
|
-
FIELD-SYMBOLS STRUCTURE: https://help.sap.com/doc/
|
|
88478
|
+
FIELD-SYMBOLS STRUCTURE: https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-us/abapfield-symbols_obsolete_typing.html
|
|
88347
88479
|
|
|
88348
|
-
TYPE-POOLS: from 702, https://help.sap.com/doc/
|
|
88480
|
+
TYPE-POOLS: from 702, https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abennews-71-program_load.html
|
|
88349
88481
|
|
|
88350
|
-
LOAD addition: from 702, https://help.sap.com/doc/
|
|
88482
|
+
LOAD addition: from 702, https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abennews-71-program_load.html
|
|
88351
88483
|
|
|
88352
|
-
COMMUICATION: https://help.sap.com/doc/
|
|
88484
|
+
COMMUICATION: https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-us/abapcommunication.html
|
|
88353
88485
|
|
|
88354
|
-
OCCURS: https://help.sap.com/doc/
|
|
88486
|
+
OCCURS: https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-us/abapdata_occurs.html
|
|
88355
88487
|
|
|
88356
|
-
PARAMETER: https://help.sap.com/doc/
|
|
88488
|
+
PARAMETER: https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abapparameter.html
|
|
88357
88489
|
|
|
88358
|
-
RANGES: https://help.sap.com/doc/
|
|
88490
|
+
RANGES: https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abapranges.html
|
|
88359
88491
|
|
|
88360
|
-
PACK: https://help.sap.com/doc/
|
|
88492
|
+
PACK: https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-us/abappack.html
|
|
88361
88493
|
|
|
88362
|
-
MOVE: https://help.sap.com/doc/
|
|
88494
|
+
MOVE: https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-us/abapmove_obs.html
|
|
88363
88495
|
|
|
88364
|
-
SELECT without INTO: https://help.sap.com/doc/
|
|
88496
|
+
SELECT without INTO: https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abapselect_obsolete.html
|
|
88365
88497
|
SELECT COUNT(*) is considered okay
|
|
88366
88498
|
|
|
88367
|
-
FREE MEMORY: https://help.sap.com/doc/
|
|
88499
|
+
FREE MEMORY: https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-us/abapfree_mem_id_obsolete.html
|
|
88368
88500
|
|
|
88369
|
-
SORT BY FS: https://help.sap.com/doc/
|
|
88501
|
+
SORT BY FS: https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abapsort_itab_obsolete.html
|
|
88370
88502
|
|
|
88371
|
-
CALL TRANSFORMATION OBJECTS: https://help.sap.com/doc/
|
|
88503
|
+
CALL TRANSFORMATION OBJECTS: https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abapcall_transformation_objects.html
|
|
88372
88504
|
|
|
88373
|
-
POSIX REGEX: https://help.sap.com/doc/
|
|
88505
|
+
POSIX REGEX: https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/ABENREGEX_MIGRATING_POSIX.html
|
|
88374
88506
|
|
|
88375
88507
|
OCCURENCES: check for OCCURENCES vs OCCURRENCES
|
|
88376
88508
|
|
|
88377
|
-
CLIENT SPECIFIED, from 754: https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/
|
|
88509
|
+
CLIENT SPECIFIED, from 754: https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abapselect_client_obsolete.html`,
|
|
88378
88510
|
badExample: `REFRESH itab.
|
|
88379
88511
|
|
|
88380
88512
|
COMPUTE foo = 2 + 2.
|
|
@@ -89823,7 +89955,7 @@ class PragmaStyle extends _abap_rule_1.ABAPRule {
|
|
|
89823
89955
|
title: "Pragma Style",
|
|
89824
89956
|
shortDescription: `Check pragmas placement and case`,
|
|
89825
89957
|
tags: [_irule_1.RuleTag.SingleFile],
|
|
89826
|
-
extendedInformation: `https://help.sap.com/doc/
|
|
89958
|
+
extendedInformation: `https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/ABENPRAGMA.html`,
|
|
89827
89959
|
badExample: `DATA field ##NO_TEXT TYPE i.`,
|
|
89828
89960
|
goodExample: `DATA field TYPE i ##NO_TEXT.`,
|
|
89829
89961
|
};
|
|
@@ -92061,7 +92193,7 @@ class RFCErrorHandling extends _abap_rule_1.ABAPRule {
|
|
|
92061
92193
|
title: "RFC error handling",
|
|
92062
92194
|
tags: [_irule_1.RuleTag.SingleFile],
|
|
92063
92195
|
shortDescription: `Checks that exceptions 'system_failure' and 'communication_failure' are handled in RFC calls`,
|
|
92064
|
-
extendedInformation: `https://help.sap.com/doc/
|
|
92196
|
+
extendedInformation: `https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abenrfc_exception.html`,
|
|
92065
92197
|
badExample: `CALL FUNCTION 'ZRFC'
|
|
92066
92198
|
DESTINATION lv_rfc.`,
|
|
92067
92199
|
goodExample: `CALL FUNCTION 'ZRFC'
|
|
@@ -94055,9 +94187,9 @@ class StrictSQL extends _abap_rule_1.ABAPRule {
|
|
|
94055
94187
|
key: "strict_sql",
|
|
94056
94188
|
title: "Strict SQL",
|
|
94057
94189
|
shortDescription: `Strict SQL`,
|
|
94058
|
-
extendedInformation: `https://help.sap.com/doc/
|
|
94190
|
+
extendedInformation: `https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abapinto_clause.html
|
|
94059
94191
|
|
|
94060
|
-
https://help.sap.com/doc/
|
|
94192
|
+
https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/ABENABAP_SQL_STRICT_MODES.html
|
|
94061
94193
|
|
|
94062
94194
|
Also see separate rule sql_escape_host_variables
|
|
94063
94195
|
|
|
@@ -94445,7 +94577,7 @@ class SyModification extends _abap_rule_1.ABAPRule {
|
|
|
94445
94577
|
key: "sy_modification",
|
|
94446
94578
|
title: "Modification of SY fields",
|
|
94447
94579
|
shortDescription: `Finds modification of sy fields`,
|
|
94448
|
-
extendedInformation: `https://help.sap.com/doc/
|
|
94580
|
+
extendedInformation: `https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-US/abensystem_fields.html
|
|
94449
94581
|
|
|
94450
94582
|
Changes to SY-TVAR* fields are not reported
|
|
94451
94583
|
|
|
@@ -94773,7 +94905,7 @@ class TablesDeclaredLocally extends _abap_rule_1.ABAPRule {
|
|
|
94773
94905
|
key: "tables_declared_locally",
|
|
94774
94906
|
title: "Check for locally declared TABLES",
|
|
94775
94907
|
shortDescription: `TABLES are always global, so declare them globally`,
|
|
94776
|
-
extendedInformation: `https://help.sap.com/doc/
|
|
94908
|
+
extendedInformation: `https://help.sap.com/doc/abapdocu_latest_index_htm/latest/en-us/abaptables.html`,
|
|
94777
94909
|
tags: [_irule_1.RuleTag.SingleFile],
|
|
94778
94910
|
badExample: `FORM foo.
|
|
94779
94911
|
TABLES t100.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@abaplint/cli",
|
|
3
|
-
"version": "2.120.
|
|
3
|
+
"version": "2.120.9",
|
|
4
4
|
"description": "abaplint - Command Line Interface",
|
|
5
5
|
"funding": "https://github.com/sponsors/larshp",
|
|
6
6
|
"bin": {
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
},
|
|
40
40
|
"homepage": "https://abaplint.org",
|
|
41
41
|
"devDependencies": {
|
|
42
|
-
"@abaplint/core": "^2.120.
|
|
42
|
+
"@abaplint/core": "^2.120.9",
|
|
43
43
|
"@types/chai": "^4.3.20",
|
|
44
44
|
"@types/minimist": "^1.2.5",
|
|
45
45
|
"@types/mocha": "^10.0.10",
|