@abaplint/cli 2.113.7 → 2.113.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 +34 -12
- package/package.json +5 -5
package/build/cli.js
CHANGED
|
@@ -32045,6 +32045,7 @@ const _typed_identifier_1 = __webpack_require__(/*! ../../types/_typed_identifie
|
|
|
32045
32045
|
const basic_1 = __webpack_require__(/*! ../../types/basic */ "./node_modules/@abaplint/core/build/src/abap/types/basic/index.js");
|
|
32046
32046
|
const basic_types_1 = __webpack_require__(/*! ../basic_types */ "./node_modules/@abaplint/core/build/src/abap/5_syntax/basic_types.js");
|
|
32047
32047
|
const _syntax_input_1 = __webpack_require__(/*! ../_syntax_input */ "./node_modules/@abaplint/core/build/src/abap/5_syntax/_syntax_input.js");
|
|
32048
|
+
const tokens_1 = __webpack_require__(/*! ../../1_lexer/tokens */ "./node_modules/@abaplint/core/build/src/abap/1_lexer/tokens/index.js");
|
|
32048
32049
|
class Parameter {
|
|
32049
32050
|
runSyntax(node, input) {
|
|
32050
32051
|
var _a;
|
|
@@ -32054,19 +32055,24 @@ class Parameter {
|
|
|
32054
32055
|
input.issues.push((0, _syntax_input_1.syntaxIssue)(input, node.getFirstToken(), message));
|
|
32055
32056
|
return;
|
|
32056
32057
|
}
|
|
32058
|
+
else if (nameToken === undefined) {
|
|
32059
|
+
return;
|
|
32060
|
+
}
|
|
32057
32061
|
if (node.findDirectTokenByText("RADIOBUTTON") && node.findDirectTokenByText("LENGTH")) {
|
|
32058
32062
|
const message = "RADIOBUTTON and LENGTH not possible together";
|
|
32059
32063
|
input.issues.push((0, _syntax_input_1.syntaxIssue)(input, node.getFirstToken(), message));
|
|
32060
32064
|
return;
|
|
32061
32065
|
}
|
|
32062
32066
|
const bfound = new basic_types_1.BasicTypes(input).parseType(node);
|
|
32063
|
-
if (
|
|
32067
|
+
if (bfound) {
|
|
32064
32068
|
input.scope.addIdentifier(new _typed_identifier_1.TypedIdentifier(nameToken, input.filename, bfound));
|
|
32065
|
-
return;
|
|
32066
32069
|
}
|
|
32067
|
-
|
|
32070
|
+
else {
|
|
32068
32071
|
input.scope.addIdentifier(new _typed_identifier_1.TypedIdentifier(nameToken, input.filename, new basic_1.UnknownType("Parameter, fallback")));
|
|
32069
32072
|
}
|
|
32073
|
+
const magicName = "%_" + nameToken.getStr() + "_%_app_%";
|
|
32074
|
+
const magicToken = new tokens_1.Identifier(nameToken.getStart(), magicName);
|
|
32075
|
+
input.scope.addIdentifier(new _typed_identifier_1.TypedIdentifier(magicToken, input.filename, new basic_1.VoidType("PARAMETER magic")));
|
|
32070
32076
|
}
|
|
32071
32077
|
}
|
|
32072
32078
|
exports.Parameter = Parameter;
|
|
@@ -32727,12 +32733,18 @@ exports.SelectionScreen = void 0;
|
|
|
32727
32733
|
const Expressions = __webpack_require__(/*! ../../2_statements/expressions */ "./node_modules/@abaplint/core/build/src/abap/2_statements/expressions/index.js");
|
|
32728
32734
|
const _typed_identifier_1 = __webpack_require__(/*! ../../types/_typed_identifier */ "./node_modules/@abaplint/core/build/src/abap/types/_typed_identifier.js");
|
|
32729
32735
|
const basic_1 = __webpack_require__(/*! ../../types/basic */ "./node_modules/@abaplint/core/build/src/abap/types/basic/index.js");
|
|
32736
|
+
const _syntax_input_1 = __webpack_require__(/*! ../_syntax_input */ "./node_modules/@abaplint/core/build/src/abap/5_syntax/_syntax_input.js");
|
|
32730
32737
|
class SelectionScreen {
|
|
32731
32738
|
runSyntax(node, input) {
|
|
32732
32739
|
const field = node.findFirstExpression(Expressions.InlineField);
|
|
32733
32740
|
if (field === undefined) {
|
|
32734
32741
|
return;
|
|
32735
32742
|
}
|
|
32743
|
+
if (field.getFirstToken().getStr().length > 8) {
|
|
32744
|
+
const message = "SELECTION-SCREEN name too long, " + field.getFirstToken().getStr();
|
|
32745
|
+
input.issues.push((0, _syntax_input_1.syntaxIssue)(input, field.getFirstToken(), message));
|
|
32746
|
+
return;
|
|
32747
|
+
}
|
|
32736
32748
|
const name = field.getFirstToken();
|
|
32737
32749
|
const concat = node.concatTokens().toUpperCase();
|
|
32738
32750
|
if (concat.includes("BEGIN OF TABBED BLOCK")) {
|
|
@@ -32772,6 +32784,7 @@ const basic_1 = __webpack_require__(/*! ../../types/basic */ "./node_modules/@ab
|
|
|
32772
32784
|
const basic_types_1 = __webpack_require__(/*! ../basic_types */ "./node_modules/@abaplint/core/build/src/abap/5_syntax/basic_types.js");
|
|
32773
32785
|
const dynamic_1 = __webpack_require__(/*! ../expressions/dynamic */ "./node_modules/@abaplint/core/build/src/abap/5_syntax/expressions/dynamic.js");
|
|
32774
32786
|
const _syntax_input_1 = __webpack_require__(/*! ../_syntax_input */ "./node_modules/@abaplint/core/build/src/abap/5_syntax/_syntax_input.js");
|
|
32787
|
+
const tokens_1 = __webpack_require__(/*! ../../1_lexer/tokens */ "./node_modules/@abaplint/core/build/src/abap/1_lexer/tokens/index.js");
|
|
32775
32788
|
class SelectOption {
|
|
32776
32789
|
runSyntax(node, input) {
|
|
32777
32790
|
var _a;
|
|
@@ -32781,12 +32794,15 @@ class SelectOption {
|
|
|
32781
32794
|
input.issues.push((0, _syntax_input_1.syntaxIssue)(input, nameToken, message));
|
|
32782
32795
|
return;
|
|
32783
32796
|
}
|
|
32797
|
+
else if (nameToken === undefined) {
|
|
32798
|
+
return;
|
|
32799
|
+
}
|
|
32784
32800
|
for (const d of node.findDirectExpressions(Expressions.Dynamic)) {
|
|
32785
32801
|
new dynamic_1.Dynamic().runSyntax(d, input);
|
|
32786
32802
|
}
|
|
32787
32803
|
const nameExpression = node.findFirstExpression(Expressions.FieldChain);
|
|
32788
32804
|
let found = new basic_types_1.BasicTypes(input).resolveLikeName(nameExpression);
|
|
32789
|
-
if (found
|
|
32805
|
+
if (found) {
|
|
32790
32806
|
if (found instanceof basic_1.StructureType) {
|
|
32791
32807
|
let length = 0;
|
|
32792
32808
|
for (const c of found.getComponents()) {
|
|
@@ -32808,11 +32824,13 @@ class SelectOption {
|
|
|
32808
32824
|
{ name: "HIGH", type: found },
|
|
32809
32825
|
]);
|
|
32810
32826
|
input.scope.addIdentifier(new _typed_identifier_1.TypedIdentifier(nameToken, input.filename, new basic_1.TableType(stru, { withHeader: true, keyType: basic_1.TableKeyType.default })));
|
|
32811
|
-
return;
|
|
32812
32827
|
}
|
|
32813
|
-
|
|
32828
|
+
else {
|
|
32814
32829
|
input.scope.addIdentifier(new _typed_identifier_1.TypedIdentifier(nameToken, input.filename, new basic_1.UnknownType("Select option, fallback")));
|
|
32815
32830
|
}
|
|
32831
|
+
const magicName = "%_" + nameToken.getStr() + "_%_app_%";
|
|
32832
|
+
const magicToken = new tokens_1.Identifier(nameToken.getStart(), magicName);
|
|
32833
|
+
input.scope.addIdentifier(new _typed_identifier_1.TypedIdentifier(magicToken, input.filename, new basic_1.VoidType("SELECT-OPTION magic")));
|
|
32816
32834
|
}
|
|
32817
32835
|
}
|
|
32818
32836
|
exports.SelectOption = SelectOption;
|
|
@@ -50142,7 +50160,7 @@ class RenameGlobalClass {
|
|
|
50142
50160
|
}
|
|
50143
50161
|
const main = obj.getMainABAPFile();
|
|
50144
50162
|
if (main === undefined) {
|
|
50145
|
-
throw new Error(
|
|
50163
|
+
throw new Error(`Main file not found, ${obj.getType()} ${obj.getName()}`);
|
|
50146
50164
|
}
|
|
50147
50165
|
let changes = [];
|
|
50148
50166
|
// todo, this is actually the same as "id" ?
|
|
@@ -52714,7 +52732,7 @@ class Registry {
|
|
|
52714
52732
|
}
|
|
52715
52733
|
static abaplintVersion() {
|
|
52716
52734
|
// magic, see build script "version.sh"
|
|
52717
|
-
return "2.113.
|
|
52735
|
+
return "2.113.9";
|
|
52718
52736
|
}
|
|
52719
52737
|
getDDICReferences() {
|
|
52720
52738
|
return this.ddicReferences;
|
|
@@ -54281,8 +54299,9 @@ Only works if the target version is 740sp05 or above`,
|
|
|
54281
54299
|
badExample: `DELETE foo FROM bar.
|
|
54282
54300
|
MODIFY foo FROM bar.`,
|
|
54283
54301
|
goodExample: `DELETE foo FROM @bar.
|
|
54284
|
-
|
|
54285
|
-
MODIFY zfoo FROM @wa
|
|
54302
|
+
DELETE TABLE itab FROM 2.
|
|
54303
|
+
MODIFY zfoo FROM @wa.
|
|
54304
|
+
MODIFY TABLE foo FROM bar.`,
|
|
54286
54305
|
};
|
|
54287
54306
|
}
|
|
54288
54307
|
getMessage() {
|
|
@@ -64894,7 +64913,7 @@ https://docs.abapopenchecks.org/checks/16/`,
|
|
|
64894
64913
|
const position = new position_1.Position(i + 1, column);
|
|
64895
64914
|
// merge punc into previous row
|
|
64896
64915
|
let rowContent = rows[i].trim();
|
|
64897
|
-
// if reported row contains
|
|
64916
|
+
// if reported row contains parentheses, prefix with space if needed
|
|
64898
64917
|
if (rowContent.length > 1 && !rows[i - 1].endsWith(" ") && !rows[i - 1].endsWith(" \r")) {
|
|
64899
64918
|
rowContent = " " + rowContent;
|
|
64900
64919
|
}
|
|
@@ -64904,7 +64923,10 @@ https://docs.abapopenchecks.org/checks/16/`,
|
|
|
64904
64923
|
}
|
|
64905
64924
|
const startPos = new position_1.Position(i, rows[i - 1].length + 1 + offset);
|
|
64906
64925
|
const endPos = new position_1.Position(i + 1, rows[i].length + 1);
|
|
64907
|
-
|
|
64926
|
+
let fix = edit_helper_1.EditHelper.replaceRange(file, startPos, endPos, rowContent);
|
|
64927
|
+
if (rows[i - 1] === undefined || rows[i - 1].indexOf("*") === 0 || rows[i - 1].includes(`"`)) {
|
|
64928
|
+
fix = undefined;
|
|
64929
|
+
}
|
|
64908
64930
|
const issue = issue_1.Issue.atPosition(file, position, this.getMessage(), this.getMetadata().key, this.conf.severity, fix);
|
|
64909
64931
|
issues.push(issue);
|
|
64910
64932
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@abaplint/cli",
|
|
3
|
-
"version": "2.113.
|
|
3
|
+
"version": "2.113.9",
|
|
4
4
|
"description": "abaplint - Command Line Interface",
|
|
5
5
|
"funding": "https://github.com/sponsors/larshp",
|
|
6
6
|
"bin": {
|
|
@@ -38,12 +38,12 @@
|
|
|
38
38
|
},
|
|
39
39
|
"homepage": "https://abaplint.org",
|
|
40
40
|
"devDependencies": {
|
|
41
|
-
"@abaplint/core": "^2.113.
|
|
41
|
+
"@abaplint/core": "^2.113.9",
|
|
42
42
|
"@types/chai": "^4.3.19",
|
|
43
43
|
"@types/glob": "^8.1.0",
|
|
44
44
|
"@types/minimist": "^1.2.5",
|
|
45
|
-
"@types/mocha": "^10.0.
|
|
46
|
-
"@types/node": "^22.5.
|
|
45
|
+
"@types/mocha": "^10.0.8",
|
|
46
|
+
"@types/node": "^22.5.5",
|
|
47
47
|
"@types/progress": "^2.0.7",
|
|
48
48
|
"chai": "^4.5.0",
|
|
49
49
|
"chalk": "^5.3.0",
|
|
@@ -54,7 +54,7 @@
|
|
|
54
54
|
"minimist": "^1.2.8",
|
|
55
55
|
"mocha": "^10.7.3",
|
|
56
56
|
"progress": "^2.0.3",
|
|
57
|
-
"typescript": "^5.
|
|
57
|
+
"typescript": "^5.6.2",
|
|
58
58
|
"webpack": "^5.94.0",
|
|
59
59
|
"webpack-cli": "^5.1.4",
|
|
60
60
|
"xml-js": "^1.6.11"
|