@abaplint/cli 2.101.9 → 2.101.10
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 +56 -44
- package/package.json +4 -4
package/build/cli.js
CHANGED
|
@@ -17109,8 +17109,8 @@ class StructureParser {
|
|
|
17109
17109
|
return { issues: [], node: parent };
|
|
17110
17110
|
}
|
|
17111
17111
|
}
|
|
17112
|
-
StructureParser.singletons = {};
|
|
17113
17112
|
exports.StructureParser = StructureParser;
|
|
17113
|
+
StructureParser.singletons = {};
|
|
17114
17114
|
//# sourceMappingURL=structure_parser.js.map
|
|
17115
17115
|
|
|
17116
17116
|
/***/ }),
|
|
@@ -18748,26 +18748,26 @@ var AttributeLevel;
|
|
|
18748
18748
|
AttributeLevel["Instance"] = "instance";
|
|
18749
18749
|
AttributeLevel["Static"] = "static";
|
|
18750
18750
|
AttributeLevel["Constant"] = "constant";
|
|
18751
|
-
})(AttributeLevel
|
|
18751
|
+
})(AttributeLevel || (exports.AttributeLevel = AttributeLevel = {}));
|
|
18752
18752
|
var MethodParameterDirection;
|
|
18753
18753
|
(function (MethodParameterDirection) {
|
|
18754
18754
|
MethodParameterDirection["Importing"] = "importing";
|
|
18755
18755
|
MethodParameterDirection["Exporting"] = "exporting";
|
|
18756
18756
|
MethodParameterDirection["Changing"] = "changing";
|
|
18757
18757
|
MethodParameterDirection["Returning"] = "returning";
|
|
18758
|
-
})(MethodParameterDirection
|
|
18758
|
+
})(MethodParameterDirection || (exports.MethodParameterDirection = MethodParameterDirection = {}));
|
|
18759
18759
|
var Duration;
|
|
18760
18760
|
(function (Duration) {
|
|
18761
18761
|
Duration["short"] = "SHORT";
|
|
18762
18762
|
Duration["medium"] = "MEDIUM";
|
|
18763
18763
|
Duration["long"] = "LONG";
|
|
18764
|
-
})(Duration
|
|
18764
|
+
})(Duration || (exports.Duration = Duration = {}));
|
|
18765
18765
|
var RiskLevel;
|
|
18766
18766
|
(function (RiskLevel) {
|
|
18767
18767
|
RiskLevel["harmless"] = "HARMLESS";
|
|
18768
18768
|
RiskLevel["critical"] = "CRITICAL";
|
|
18769
18769
|
RiskLevel["dangerous"] = "DANGEROUS";
|
|
18770
|
-
})(RiskLevel
|
|
18770
|
+
})(RiskLevel || (exports.RiskLevel = RiskLevel = {}));
|
|
18771
18771
|
//# sourceMappingURL=_abap_file_information.js.map
|
|
18772
18772
|
|
|
18773
18773
|
/***/ }),
|
|
@@ -19218,7 +19218,7 @@ var Visibility;
|
|
|
19218
19218
|
Visibility[Visibility["Private"] = 1] = "Private";
|
|
19219
19219
|
Visibility[Visibility["Protected"] = 2] = "Protected";
|
|
19220
19220
|
Visibility[Visibility["Public"] = 3] = "Public";
|
|
19221
|
-
})(Visibility
|
|
19221
|
+
})(Visibility || (exports.Visibility = Visibility = {}));
|
|
19222
19222
|
//# sourceMappingURL=visibility.js.map
|
|
19223
19223
|
|
|
19224
19224
|
/***/ }),
|
|
@@ -19586,6 +19586,7 @@ class BuiltIn {
|
|
|
19586
19586
|
return new _typed_identifier_1.TypedIdentifier(id, BuiltIn.filename, new basic_1.VoidType(name), ["built-in" /* IdentifierMeta.BuiltIn */]);
|
|
19587
19587
|
}
|
|
19588
19588
|
}
|
|
19589
|
+
exports.BuiltIn = BuiltIn;
|
|
19589
19590
|
BuiltIn.filename = "_builtin.prog.abap";
|
|
19590
19591
|
// todo: "pcre" vs "regex", only one of these parameters are allowed
|
|
19591
19592
|
// todo: "pcre", only possible from 755
|
|
@@ -20409,7 +20410,6 @@ BuiltIn.methods = [
|
|
|
20409
20410
|
return: new basic_1.IntegerType(),
|
|
20410
20411
|
},
|
|
20411
20412
|
];
|
|
20412
|
-
exports.BuiltIn = BuiltIn;
|
|
20413
20413
|
//# sourceMappingURL=_builtin.js.map
|
|
20414
20414
|
|
|
20415
20415
|
/***/ }),
|
|
@@ -21368,7 +21368,7 @@ var ReferenceType;
|
|
|
21368
21368
|
// FormVoidReference = "Form (void)",
|
|
21369
21369
|
ReferenceType["DataReadReference"] = "Read From";
|
|
21370
21370
|
ReferenceType["DataWriteReference"] = "Write To";
|
|
21371
|
-
})(ReferenceType
|
|
21371
|
+
})(ReferenceType || (exports.ReferenceType = ReferenceType = {}));
|
|
21372
21372
|
//# sourceMappingURL=_reference.js.map
|
|
21373
21373
|
|
|
21374
21374
|
/***/ }),
|
|
@@ -21401,7 +21401,7 @@ var ScopeType;
|
|
|
21401
21401
|
ScopeType["For"] = "for";
|
|
21402
21402
|
ScopeType["Let"] = "let";
|
|
21403
21403
|
ScopeType["OpenSQL"] = "open_sql";
|
|
21404
|
-
})(ScopeType
|
|
21404
|
+
})(ScopeType || (exports.ScopeType = ScopeType = {}));
|
|
21405
21405
|
//# sourceMappingURL=_scope_type.js.map
|
|
21406
21406
|
|
|
21407
21407
|
/***/ }),
|
|
@@ -35117,13 +35117,13 @@ var TableAccessType;
|
|
|
35117
35117
|
TableAccessType["hashed"] = "HASHED";
|
|
35118
35118
|
TableAccessType["index"] = "INDEX";
|
|
35119
35119
|
TableAccessType["any"] = "ANY";
|
|
35120
|
-
})(TableAccessType
|
|
35120
|
+
})(TableAccessType || (exports.TableAccessType = TableAccessType = {}));
|
|
35121
35121
|
var TableKeyType;
|
|
35122
35122
|
(function (TableKeyType) {
|
|
35123
35123
|
TableKeyType["default"] = "DEFAULT";
|
|
35124
35124
|
TableKeyType["user"] = "USER";
|
|
35125
35125
|
TableKeyType["empty"] = "EMPTY";
|
|
35126
|
-
})(TableKeyType
|
|
35126
|
+
})(TableKeyType || (exports.TableKeyType = TableKeyType = {}));
|
|
35127
35127
|
class TableType extends _abstract_type_1.AbstractType {
|
|
35128
35128
|
constructor(rowType, options, qualifiedName) {
|
|
35129
35129
|
var _a;
|
|
@@ -36021,7 +36021,7 @@ var FunctionModuleParameterDirection;
|
|
|
36021
36021
|
FunctionModuleParameterDirection["exporting"] = "exporting";
|
|
36022
36022
|
FunctionModuleParameterDirection["changing"] = "changing";
|
|
36023
36023
|
FunctionModuleParameterDirection["tables"] = "tables";
|
|
36024
|
-
})(FunctionModuleParameterDirection
|
|
36024
|
+
})(FunctionModuleParameterDirection || (exports.FunctionModuleParameterDirection = FunctionModuleParameterDirection = {}));
|
|
36025
36025
|
class FunctionModuleDefinition {
|
|
36026
36026
|
constructor(data) {
|
|
36027
36027
|
this.parse(data);
|
|
@@ -38705,7 +38705,7 @@ var DDLKind;
|
|
|
38705
38705
|
(function (DDLKind) {
|
|
38706
38706
|
DDLKind["Structure"] = "structure";
|
|
38707
38707
|
DDLKind["Table"] = "table";
|
|
38708
|
-
})(DDLKind
|
|
38708
|
+
})(DDLKind || (exports.DDLKind = DDLKind = {}));
|
|
38709
38709
|
class DDLParser {
|
|
38710
38710
|
parse(file) {
|
|
38711
38711
|
const tokens = ddl_lexer_1.DDLLexer.run(file);
|
|
@@ -41128,7 +41128,7 @@ var RenameType;
|
|
|
41128
41128
|
RenameType[RenameType["Variable"] = 2] = "Variable";
|
|
41129
41129
|
RenameType[RenameType["GlobalInterface"] = 3] = "GlobalInterface";
|
|
41130
41130
|
RenameType[RenameType["Method"] = 4] = "Method";
|
|
41131
|
-
})(RenameType
|
|
41131
|
+
})(RenameType || (exports.RenameType = RenameType = {}));
|
|
41132
41132
|
class Rename {
|
|
41133
41133
|
constructor(reg) {
|
|
41134
41134
|
this.reg = reg;
|
|
@@ -41147,18 +41147,23 @@ class Rename {
|
|
|
41147
41147
|
return undefined;
|
|
41148
41148
|
}
|
|
41149
41149
|
const range = _lsp_utils_1.LSPUtils.tokenToRange(cursor.token);
|
|
41150
|
+
let placeholder = cursor.token.getStr();
|
|
41151
|
+
if (placeholder.startsWith("!")) {
|
|
41152
|
+
placeholder = placeholder.substring(1);
|
|
41153
|
+
range.start.character += 1;
|
|
41154
|
+
}
|
|
41150
41155
|
const lookup = _lookup_1.LSPLookup.lookup(cursor, this.reg, obj);
|
|
41151
41156
|
if ((lookup === null || lookup === void 0 ? void 0 : lookup.definitionId) instanceof _typed_identifier_1.TypedIdentifier) {
|
|
41152
|
-
return { range, placeholder
|
|
41157
|
+
return { range, placeholder, type: RenameType.Variable, file };
|
|
41153
41158
|
}
|
|
41154
41159
|
else if ((lookup === null || lookup === void 0 ? void 0 : lookup.definitionId) instanceof types_1.ClassDefinition) {
|
|
41155
|
-
return { range, placeholder
|
|
41160
|
+
return { range, placeholder, type: RenameType.GlobalClass, file };
|
|
41156
41161
|
}
|
|
41157
41162
|
else if ((lookup === null || lookup === void 0 ? void 0 : lookup.definitionId) instanceof types_1.InterfaceDefinition) {
|
|
41158
|
-
return { range, placeholder
|
|
41163
|
+
return { range, placeholder, type: RenameType.GlobalInterface, file };
|
|
41159
41164
|
}
|
|
41160
41165
|
else if ((lookup === null || lookup === void 0 ? void 0 : lookup.definitionId) instanceof types_1.MethodDefinition) {
|
|
41161
|
-
return { range, placeholder
|
|
41166
|
+
return { range, placeholder, type: RenameType.Method, file };
|
|
41162
41167
|
}
|
|
41163
41168
|
return undefined;
|
|
41164
41169
|
}
|
|
@@ -41351,8 +41356,8 @@ class SemanticHighlighting {
|
|
|
41351
41356
|
return ret;
|
|
41352
41357
|
}
|
|
41353
41358
|
}
|
|
41354
|
-
SemanticHighlighting.tokenTypes = [];
|
|
41355
41359
|
exports.SemanticHighlighting = SemanticHighlighting;
|
|
41360
|
+
SemanticHighlighting.tokenTypes = [];
|
|
41356
41361
|
//# sourceMappingURL=semantic.js.map
|
|
41357
41362
|
|
|
41358
41363
|
/***/ }),
|
|
@@ -42620,7 +42625,7 @@ var ClassCategory;
|
|
|
42620
42625
|
ClassCategory["PersistentFactory"] = "11";
|
|
42621
42626
|
ClassCategory["Exception"] = "40";
|
|
42622
42627
|
ClassCategory["SharedObject"] = "45";
|
|
42623
|
-
})(ClassCategory
|
|
42628
|
+
})(ClassCategory || (exports.ClassCategory = ClassCategory = {}));
|
|
42624
42629
|
class Class extends _abap_object_1.ABAPObject {
|
|
42625
42630
|
constructor() {
|
|
42626
42631
|
super(...arguments);
|
|
@@ -46680,7 +46685,7 @@ var EnhancementCategory;
|
|
|
46680
46685
|
EnhancementCategory["Character"] = "2";
|
|
46681
46686
|
EnhancementCategory["CharacterOrNumeric"] = "3";
|
|
46682
46687
|
EnhancementCategory["Deep"] = "4";
|
|
46683
|
-
})(EnhancementCategory
|
|
46688
|
+
})(EnhancementCategory || (exports.EnhancementCategory = EnhancementCategory = {}));
|
|
46684
46689
|
var TableCategory;
|
|
46685
46690
|
(function (TableCategory) {
|
|
46686
46691
|
TableCategory["Transparent"] = "TRANSP";
|
|
@@ -46689,7 +46694,7 @@ var TableCategory;
|
|
|
46689
46694
|
TableCategory["Pooled"] = "POOL";
|
|
46690
46695
|
TableCategory["View"] = "VIEW";
|
|
46691
46696
|
TableCategory["Append"] = "APPEND";
|
|
46692
|
-
})(TableCategory
|
|
46697
|
+
})(TableCategory || (exports.TableCategory = TableCategory = {}));
|
|
46693
46698
|
class Table extends _abstract_object_1.AbstractObject {
|
|
46694
46699
|
getType() {
|
|
46695
46700
|
return "TABL";
|
|
@@ -48155,7 +48160,7 @@ class Registry {
|
|
|
48155
48160
|
}
|
|
48156
48161
|
static abaplintVersion() {
|
|
48157
48162
|
// magic, see build script "version.sh"
|
|
48158
|
-
return "2.101.
|
|
48163
|
+
return "2.101.10";
|
|
48159
48164
|
}
|
|
48160
48165
|
getDDICReferences() {
|
|
48161
48166
|
return this.ddicReferences;
|
|
@@ -48607,7 +48612,7 @@ var RuleTag;
|
|
|
48607
48612
|
RuleTag["Styleguide"] = "Styleguide";
|
|
48608
48613
|
/** Single file compatible, the rule gives correct results when having only information about the single file */
|
|
48609
48614
|
RuleTag["SingleFile"] = "SingleFile";
|
|
48610
|
-
})(RuleTag
|
|
48615
|
+
})(RuleTag || (exports.RuleTag = RuleTag = {}));
|
|
48611
48616
|
//# sourceMappingURL=_irule.js.map
|
|
48612
48617
|
|
|
48613
48618
|
/***/ }),
|
|
@@ -55406,9 +55411,16 @@ ${indentation} output = ${topTarget}.`;
|
|
|
55406
55411
|
const data = `DATA ${name} TYPE REF TO ${type}.\n` +
|
|
55407
55412
|
indentation + abap + "\n" +
|
|
55408
55413
|
indentation;
|
|
55409
|
-
|
|
55410
|
-
|
|
55411
|
-
|
|
55414
|
+
if (found.getFirstToken().getStart().equals(high.getFirstToken().getStart())
|
|
55415
|
+
&& found.getLastToken().getEnd().equals(high.getLastToken().getStart())) {
|
|
55416
|
+
// full statement = standalone NEW expression
|
|
55417
|
+
fix = edit_helper_1.EditHelper.replaceRange(lowFile, high.getFirstToken().getStart(), high.getLastToken().getEnd(), abap);
|
|
55418
|
+
}
|
|
55419
|
+
else {
|
|
55420
|
+
const fix1 = edit_helper_1.EditHelper.insertAt(lowFile, high.getFirstToken().getStart(), data);
|
|
55421
|
+
const fix2 = edit_helper_1.EditHelper.replaceRange(lowFile, found.getFirstToken().getStart(), found.getLastToken().getEnd(), name);
|
|
55422
|
+
fix = edit_helper_1.EditHelper.merge(fix2, fix1);
|
|
55423
|
+
}
|
|
55412
55424
|
}
|
|
55413
55425
|
if (fix) {
|
|
55414
55426
|
return issue_1.Issue.atToken(lowFile, high.getFirstToken(), "Use CREATE OBJECT instead of NEW", this.getMetadata().key, this.conf.severity, fix);
|
|
@@ -55774,24 +55786,24 @@ class EmptyStructure extends _abap_rule_1.ABAPRule {
|
|
|
55774
55786
|
}
|
|
55775
55787
|
const candidates = [];
|
|
55776
55788
|
if (this.getConfig().loop === true) {
|
|
55777
|
-
candidates.push(...stru.
|
|
55789
|
+
candidates.push(...stru.findAllStructuresRecursive(Structures.Loop));
|
|
55778
55790
|
}
|
|
55779
55791
|
if (this.getConfig().while === true) {
|
|
55780
|
-
candidates.push(...stru.
|
|
55792
|
+
candidates.push(...stru.findAllStructuresRecursive(Structures.While));
|
|
55781
55793
|
}
|
|
55782
55794
|
if (this.getConfig().case === true) {
|
|
55783
|
-
candidates.push(...stru.
|
|
55795
|
+
candidates.push(...stru.findAllStructuresRecursive(Structures.Case));
|
|
55784
55796
|
}
|
|
55785
55797
|
if (this.getConfig().select === true) {
|
|
55786
|
-
candidates.push(...stru.
|
|
55798
|
+
candidates.push(...stru.findAllStructuresRecursive(Structures.Select));
|
|
55787
55799
|
}
|
|
55788
55800
|
if (this.getConfig().do === true) {
|
|
55789
|
-
candidates.push(...stru.
|
|
55801
|
+
candidates.push(...stru.findAllStructuresRecursive(Structures.Do));
|
|
55790
55802
|
}
|
|
55791
55803
|
if (this.getConfig().at === true) {
|
|
55792
|
-
candidates.push(...stru.
|
|
55793
|
-
candidates.push(...stru.
|
|
55794
|
-
candidates.push(...stru.
|
|
55804
|
+
candidates.push(...stru.findAllStructuresRecursive(Structures.At));
|
|
55805
|
+
candidates.push(...stru.findAllStructuresRecursive(Structures.AtFirst));
|
|
55806
|
+
candidates.push(...stru.findAllStructuresRecursive(Structures.AtLast));
|
|
55795
55807
|
}
|
|
55796
55808
|
for (const l of candidates) {
|
|
55797
55809
|
if (l.getChildren().length === 2) {
|
|
@@ -55801,7 +55813,7 @@ class EmptyStructure extends _abap_rule_1.ABAPRule {
|
|
|
55801
55813
|
}
|
|
55802
55814
|
}
|
|
55803
55815
|
if (this.getConfig().try === true) {
|
|
55804
|
-
const tries = stru.
|
|
55816
|
+
const tries = stru.findAllStructuresRecursive(Structures.Try);
|
|
55805
55817
|
for (const t of tries) {
|
|
55806
55818
|
const normal = t.findDirectStructure(Structures.Body);
|
|
55807
55819
|
if (normal === undefined) {
|
|
@@ -55812,9 +55824,9 @@ class EmptyStructure extends _abap_rule_1.ABAPRule {
|
|
|
55812
55824
|
}
|
|
55813
55825
|
}
|
|
55814
55826
|
if (this.getConfig().if === true) {
|
|
55815
|
-
const tries = stru.
|
|
55816
|
-
.concat(stru.
|
|
55817
|
-
.concat(stru.
|
|
55827
|
+
const tries = stru.findAllStructuresRecursive(Structures.If)
|
|
55828
|
+
.concat(stru.findAllStructuresRecursive(Structures.Else))
|
|
55829
|
+
.concat(stru.findAllStructuresRecursive(Structures.ElseIf));
|
|
55818
55830
|
for (const t of tries) {
|
|
55819
55831
|
const normal = t.findDirectStructure(Structures.Body);
|
|
55820
55832
|
if (normal === undefined) {
|
|
@@ -55825,7 +55837,7 @@ class EmptyStructure extends _abap_rule_1.ABAPRule {
|
|
|
55825
55837
|
}
|
|
55826
55838
|
}
|
|
55827
55839
|
if (this.getConfig().when === true) {
|
|
55828
|
-
const tries = stru.
|
|
55840
|
+
const tries = stru.findAllStructuresRecursive(Structures.When);
|
|
55829
55841
|
for (const t of tries) {
|
|
55830
55842
|
if (t.getChildren().length === 1) {
|
|
55831
55843
|
const token = t.getFirstToken();
|
|
@@ -58645,7 +58657,7 @@ var KeywordCaseStyle;
|
|
|
58645
58657
|
(function (KeywordCaseStyle) {
|
|
58646
58658
|
KeywordCaseStyle["Upper"] = "upper";
|
|
58647
58659
|
KeywordCaseStyle["Lower"] = "lower";
|
|
58648
|
-
})(KeywordCaseStyle
|
|
58660
|
+
})(KeywordCaseStyle || (exports.KeywordCaseStyle = KeywordCaseStyle = {}));
|
|
58649
58661
|
class KeywordCaseConf extends _basic_rule_config_1.BasicRuleConfig {
|
|
58650
58662
|
constructor() {
|
|
58651
58663
|
super(...arguments);
|
|
@@ -60892,7 +60904,7 @@ var NewlineLogic;
|
|
|
60892
60904
|
(function (NewlineLogic) {
|
|
60893
60905
|
NewlineLogic["Exact"] = "exact";
|
|
60894
60906
|
NewlineLogic["Less"] = "less";
|
|
60895
|
-
})(NewlineLogic
|
|
60907
|
+
})(NewlineLogic || (exports.NewlineLogic = NewlineLogic = {}));
|
|
60896
60908
|
class NewlineBetweenMethodsConf extends _basic_rule_config_1.BasicRuleConfig {
|
|
60897
60909
|
constructor() {
|
|
60898
60910
|
super(...arguments);
|
|
@@ -68646,7 +68658,7 @@ var Severity;
|
|
|
68646
68658
|
Severity["Error"] = "Error";
|
|
68647
68659
|
Severity["Warning"] = "Warning";
|
|
68648
68660
|
Severity["Info"] = "Info";
|
|
68649
|
-
})(Severity
|
|
68661
|
+
})(Severity || (exports.Severity = Severity = {}));
|
|
68650
68662
|
//# sourceMappingURL=severity.js.map
|
|
68651
68663
|
|
|
68652
68664
|
/***/ }),
|
|
@@ -69295,7 +69307,7 @@ var Version;
|
|
|
69295
69307
|
Version["v756"] = "v756";
|
|
69296
69308
|
Version["v757"] = "v757";
|
|
69297
69309
|
Version["Cloud"] = "Cloud";
|
|
69298
|
-
})(Version
|
|
69310
|
+
})(Version || (exports.Version = Version = {}));
|
|
69299
69311
|
exports.defaultVersion = Version.v757;
|
|
69300
69312
|
function getPreviousVersion(v) {
|
|
69301
69313
|
if (v === Version.OpenABAP) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@abaplint/cli",
|
|
3
|
-
"version": "2.101.
|
|
3
|
+
"version": "2.101.10",
|
|
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.101.
|
|
41
|
+
"@abaplint/core": "^2.101.10",
|
|
42
42
|
"@types/chai": "^4.3.5",
|
|
43
43
|
"@types/glob": "^7.2.0",
|
|
44
44
|
"@types/minimist": "^1.2.2",
|
|
@@ -54,8 +54,8 @@
|
|
|
54
54
|
"minimist": "^1.2.8",
|
|
55
55
|
"mocha": "^10.2.0",
|
|
56
56
|
"progress": "^2.0.3",
|
|
57
|
-
"typescript": "^5.
|
|
58
|
-
"webpack": "^5.
|
|
57
|
+
"typescript": "^5.1.3",
|
|
58
|
+
"webpack": "^5.85.0",
|
|
59
59
|
"webpack-cli": "^5.1.1",
|
|
60
60
|
"xml-js": "^1.6.11"
|
|
61
61
|
},
|