@abaplint/core 2.118.1 → 2.118.3
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/src/abap/2_statements/statements/method_def.js +1 -1
- package/build/src/abap/2_statements/statements/type_enum.js +1 -1
- package/build/src/abap/2_statements/statements/type_enum_begin.js +1 -1
- package/build/src/abap/2_statements/statements/type_enum_end.js +1 -1
- package/build/src/abap/5_syntax/expressions/database_table.js +3 -1
- package/build/src/abap/5_syntax/expressions/field_chain.js +3 -1
- package/build/src/registry.js +1 -1
- package/build/src/rules/abapdoc.js +2 -2
- package/package.json +1 -1
|
@@ -6,7 +6,7 @@ const combi_1 = require("../combi");
|
|
|
6
6
|
const expressions_1 = require("../expressions");
|
|
7
7
|
class MethodDef {
|
|
8
8
|
getMatcher() {
|
|
9
|
-
const def = (0, combi_1.ver)(version_1.Version.v740sp08, (0, combi_1.seq)("DEFAULT", (0, combi_1.altPrio)("FAIL", "IGNORE")));
|
|
9
|
+
const def = (0, combi_1.ver)(version_1.Version.v740sp08, (0, combi_1.seq)("DEFAULT", (0, combi_1.altPrio)("FAIL", "IGNORE")), version_1.Version.OpenABAP);
|
|
10
10
|
const parameters = (0, combi_1.seq)((0, combi_1.optPrio)((0, combi_1.altPrio)("FINAL", def, expressions_1.Abstract)), (0, combi_1.optPrio)(expressions_1.MethodDefImporting), (0, combi_1.optPrio)(expressions_1.MethodDefExporting), (0, combi_1.optPrio)(expressions_1.MethodDefChanging), (0, combi_1.optPrio)(expressions_1.MethodDefReturning), (0, combi_1.optPrio)((0, combi_1.altPrio)(expressions_1.MethodDefRaising, expressions_1.MethodDefExceptions)));
|
|
11
11
|
const testing = (0, combi_1.seq)((0, combi_1.optPrio)(expressions_1.Abstract), "FOR TESTING", (0, combi_1.optPrio)((0, combi_1.altPrio)(expressions_1.MethodDefRaising, expressions_1.MethodDefExceptions)));
|
|
12
12
|
const result = (0, combi_1.seq)("RESULT", expressions_1.MethodParamName);
|
|
@@ -7,7 +7,7 @@ const version_1 = require("../../../version");
|
|
|
7
7
|
class TypeEnum {
|
|
8
8
|
getMatcher() {
|
|
9
9
|
// it is also possible to define without Value, this is covered by normal type
|
|
10
|
-
const ret = (0, combi_1.ver)(version_1.Version.v751, (0, combi_1.seq)("TYPES", expressions_1.NamespaceSimpleName, expressions_1.Value));
|
|
10
|
+
const ret = (0, combi_1.ver)(version_1.Version.v751, (0, combi_1.seq)("TYPES", expressions_1.NamespaceSimpleName, expressions_1.Value), version_1.Version.OpenABAP);
|
|
11
11
|
return ret;
|
|
12
12
|
}
|
|
13
13
|
}
|
|
@@ -9,7 +9,7 @@ class TypeEnumBegin {
|
|
|
9
9
|
const structure = (0, combi_1.seq)("STRUCTURE", expressions_1.NamespaceSimpleName);
|
|
10
10
|
const base = (0, combi_1.seq)("BASE TYPE", expressions_1.NamespaceSimpleName);
|
|
11
11
|
const em = (0, combi_1.seq)("ENUM", expressions_1.NamespaceSimpleName, (0, combi_1.opt)(structure), (0, combi_1.opt)(base));
|
|
12
|
-
const ret = (0, combi_1.ver)(version_1.Version.v751, (0, combi_1.seq)("TYPES", "BEGIN OF", em));
|
|
12
|
+
const ret = (0, combi_1.ver)(version_1.Version.v751, (0, combi_1.seq)("TYPES", "BEGIN OF", em), version_1.Version.OpenABAP);
|
|
13
13
|
return ret;
|
|
14
14
|
}
|
|
15
15
|
}
|
|
@@ -7,7 +7,7 @@ const version_1 = require("../../../version");
|
|
|
7
7
|
class TypeEnumEnd {
|
|
8
8
|
getMatcher() {
|
|
9
9
|
const structure = (0, combi_1.seq)("STRUCTURE", expressions_1.NamespaceSimpleName);
|
|
10
|
-
const ret = (0, combi_1.ver)(version_1.Version.v751, (0, combi_1.seq)("TYPES", "END OF", "ENUM", expressions_1.NamespaceSimpleName, (0, combi_1.opt)(structure)));
|
|
10
|
+
const ret = (0, combi_1.ver)(version_1.Version.v751, (0, combi_1.seq)("TYPES", "END OF", "ENUM", expressions_1.NamespaceSimpleName, (0, combi_1.opt)(structure)), version_1.Version.OpenABAP);
|
|
11
11
|
return ret;
|
|
12
12
|
}
|
|
13
13
|
}
|
|
@@ -6,7 +6,9 @@ const _syntax_input_1 = require("../_syntax_input");
|
|
|
6
6
|
class DatabaseTable {
|
|
7
7
|
static runSyntax(node, input) {
|
|
8
8
|
const token = node.getFirstToken();
|
|
9
|
-
const
|
|
9
|
+
const rawName = token.getStr();
|
|
10
|
+
const starPrefixed = rawName.startsWith("*");
|
|
11
|
+
const name = starPrefixed ? rawName.substring(1) : rawName;
|
|
10
12
|
if (name === "(") {
|
|
11
13
|
// dynamic
|
|
12
14
|
return undefined;
|
|
@@ -38,6 +38,7 @@ class FieldChain {
|
|
|
38
38
|
let context = undefined;
|
|
39
39
|
const children = node.getChildren();
|
|
40
40
|
context = this.findTop(children[0], input, refType);
|
|
41
|
+
let prev = children[0].concatTokens();
|
|
41
42
|
for (let i = 1; i < children.length; i++) {
|
|
42
43
|
const current = children[i];
|
|
43
44
|
if (current === undefined) {
|
|
@@ -78,7 +79,7 @@ class FieldChain {
|
|
|
78
79
|
}
|
|
79
80
|
}
|
|
80
81
|
else {
|
|
81
|
-
const message = "
|
|
82
|
+
const message = prev.toUpperCase() + " is not structured (" + (context === null || context === void 0 ? void 0 : context.constructor.name) + ")";
|
|
82
83
|
input.issues.push((0, _syntax_input_1.syntaxIssue)(input, current.getFirstToken(), message));
|
|
83
84
|
return basic_1.VoidType.get(_syntax_input_1.CheckSyntaxKey);
|
|
84
85
|
}
|
|
@@ -145,6 +146,7 @@ class FieldChain {
|
|
|
145
146
|
}
|
|
146
147
|
}
|
|
147
148
|
}
|
|
149
|
+
prev = current.concatTokens();
|
|
148
150
|
}
|
|
149
151
|
return context;
|
|
150
152
|
}
|
package/build/src/registry.js
CHANGED
|
@@ -96,12 +96,12 @@ https://github.com/SAP/styleguides/blob/main/clean-abap/CleanABAP.md#abap-doc-on
|
|
|
96
96
|
issues.push(issue);
|
|
97
97
|
}
|
|
98
98
|
if (rowText.trim().match(regexEmptyAbapdoc) === null && previousRowsTexts.indexOf(rowText) === previousRowsTexts.length - 1) {
|
|
99
|
-
const message = "Missing ABAP Doc for method " + method.identifier.getToken().getStr()
|
|
99
|
+
const message = "Missing ABAP Doc for method " + method.identifier.getToken().getStr();
|
|
100
100
|
const issue = issue_1.Issue.atIdentifier(method.identifier, message, this.getMetadata().key, this.conf.severity);
|
|
101
101
|
issues.push(issue);
|
|
102
102
|
}
|
|
103
103
|
if (rowText.trim().match(regexEmptyParameterName) !== null) {
|
|
104
|
-
const message = "Missing ABAP Doc parameter name for method " + method.identifier.getToken().getStr()
|
|
104
|
+
const message = "Missing ABAP Doc parameter name for method " + method.identifier.getToken().getStr();
|
|
105
105
|
const issue = issue_1.Issue.atIdentifier(method.identifier, message, this.getMetadata().key, this.conf.severity);
|
|
106
106
|
issues.push(issue);
|
|
107
107
|
}
|