@abaplint/core 2.113.142 → 2.113.144
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/expressions/sql_path.js +4 -1
- package/build/src/abap/2_statements/statements/read_entities.js +1 -1
- package/build/src/abap/5_syntax/expressions/field_chain.js +1 -1
- package/build/src/abap/5_syntax/expressions/target.js +1 -1
- package/build/src/abap/5_syntax/statements/insert_internal.js +6 -1
- package/build/src/abap/types/method_parameters.js +3 -0
- package/build/src/cds/expressions/cds_define_projection.js +1 -1
- package/build/src/cds/expressions/cds_element.js +3 -1
- package/build/src/registry.js +1 -1
- package/package.json +3 -3
|
@@ -3,10 +3,13 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.SQLPath = void 0;
|
|
4
4
|
const combi_1 = require("../combi");
|
|
5
5
|
const tokens_1 = require("../../1_lexer/tokens");
|
|
6
|
+
const association_name_1 = require("./association_name");
|
|
7
|
+
const sql_cond_1 = require("./sql_cond");
|
|
6
8
|
class SQLPath extends combi_1.Expression {
|
|
7
9
|
getRunnable() {
|
|
8
10
|
// todo, only from version?
|
|
9
|
-
const
|
|
11
|
+
const condition = (0, combi_1.seq)((0, combi_1.tok)(tokens_1.BracketLeftW), "ONE TO ONE WHERE", sql_cond_1.SQLCond, (0, combi_1.tok)(tokens_1.WBracketRight));
|
|
12
|
+
const ret = (0, combi_1.seq)(association_name_1.AssociationName, (0, combi_1.optPrio)(condition), (0, combi_1.tok)(tokens_1.Dash), (0, combi_1.regex)(/\w+/));
|
|
10
13
|
return ret;
|
|
11
14
|
}
|
|
12
15
|
}
|
|
@@ -10,7 +10,7 @@ class ReadEntities {
|
|
|
10
10
|
const from = (0, combi_1.seq)("FROM", expressions_1.Source);
|
|
11
11
|
const fields = (0, combi_1.seq)("FIELDS", (0, combi_1.tok)(tokens_1.WParenLeftW), (0, combi_1.plus)(expressions_1.SimpleName), (0, combi_1.tok)(tokens_1.WParenRightW), "WITH", expressions_1.Source);
|
|
12
12
|
const all = (0, combi_1.seq)("ALL FIELDS WITH", expressions_1.Source);
|
|
13
|
-
const entity = (0, combi_1.seq)("ENTITY", expressions_1.
|
|
13
|
+
const entity = (0, combi_1.seq)("ENTITY", expressions_1.NamespaceSimpleName, (0, combi_1.opt)((0, combi_1.seq)("BY", expressions_1.AssociationName)), (0, combi_1.alt)(fields, from, all), (0, combi_1.optPrio)((0, combi_1.seq)("RESULT", expressions_1.Target)));
|
|
14
14
|
const s = (0, combi_1.seq)("READ ENTITIES OF", expressions_1.NamespaceSimpleName, (0, combi_1.opt)("IN LOCAL MODE"), (0, combi_1.plus)(entity), (0, combi_1.optPrio)((0, combi_1.seq)("LINK", expressions_1.Target)), (0, combi_1.optPrio)((0, combi_1.seq)("FAILED", expressions_1.Target)), (0, combi_1.optPrio)((0, combi_1.seq)("REPORTED", expressions_1.Target)));
|
|
15
15
|
return (0, combi_1.ver)(version_1.Version.v754, s);
|
|
16
16
|
}
|
|
@@ -76,7 +76,7 @@ class FieldChain {
|
|
|
76
76
|
}
|
|
77
77
|
}
|
|
78
78
|
else {
|
|
79
|
-
const message = "Not a structure, FieldChain";
|
|
79
|
+
const message = "Not a structure, FieldChain, " + (context === null || context === void 0 ? void 0 : context.constructor.name) + ", " + current.concatTokens();
|
|
80
80
|
input.issues.push((0, _syntax_input_1.syntaxIssue)(input, current.getFirstToken(), message));
|
|
81
81
|
return basic_1.VoidType.get(_syntax_input_1.CheckSyntaxKey);
|
|
82
82
|
}
|
|
@@ -54,7 +54,7 @@ class Target {
|
|
|
54
54
|
&& !(context instanceof basic_1.TableType && context.isWithHeader() && context.getRowType() instanceof basic_1.StructureType)
|
|
55
55
|
&& !(context instanceof basic_1.TableType && context.isWithHeader() && context.getRowType() instanceof basic_1.VoidType)
|
|
56
56
|
&& !(context instanceof basic_1.VoidType)) {
|
|
57
|
-
const message = "Not a structure, target";
|
|
57
|
+
const message = "Not a structure, target, " + (context === null || context === void 0 ? void 0 : context.constructor.name) + ", " + current.concatTokens();
|
|
58
58
|
input.issues.push((0, _syntax_input_1.syntaxIssue)(input, node.getFirstToken(), message));
|
|
59
59
|
return basic_1.VoidType.get(_syntax_input_1.CheckSyntaxKey);
|
|
60
60
|
}
|
|
@@ -74,7 +74,12 @@ class InsertInternal {
|
|
|
74
74
|
inline_data_1.InlineData.runSyntax(afterInto, input, new basic_1.DataReference(sourceType));
|
|
75
75
|
}
|
|
76
76
|
else {
|
|
77
|
-
target_1.Target.runSyntax(afterInto, input);
|
|
77
|
+
const type = target_1.Target.runSyntax(afterInto, input);
|
|
78
|
+
if (type instanceof basic_1.TableType && type.getAccessType() === basic_1.TableAccessType.hashed) {
|
|
79
|
+
const message = "Implicit or explicit index operation on hashed table is not possible";
|
|
80
|
+
input.issues.push((0, _syntax_input_1.syntaxIssue)(input, node.getFirstToken(), message));
|
|
81
|
+
return;
|
|
82
|
+
}
|
|
78
83
|
}
|
|
79
84
|
}
|
|
80
85
|
for (const s of node.findDirectExpressions(Expressions.Source)) {
|
|
@@ -184,6 +184,9 @@ class MethodParameters {
|
|
|
184
184
|
if (concat.includes(" FOR VALIDATE ")
|
|
185
185
|
|| concat.includes(" FOR BEHAVIOR ")
|
|
186
186
|
|| concat.includes(" FOR FEATURES ")
|
|
187
|
+
|| concat.includes(" FOR INSTANCE FEATURES ")
|
|
188
|
+
|| concat.includes(" FOR READ ")
|
|
189
|
+
|| concat.includes(" FOR LOCK ")
|
|
187
190
|
|| concat.includes(" FOR MODIFY ")) {
|
|
188
191
|
const token = isRap.getFirstToken();
|
|
189
192
|
this.exporting.push(new _typed_identifier_1.TypedIdentifier(new identifier_1.Identifier(token.getStart(), "failed"), input.filename, basic_1.VoidType.get("RapMethodParameter"), ["exporting" /* IdentifierMeta.MethodExporting */]));
|
|
@@ -6,7 +6,7 @@ const __1 = require("../..");
|
|
|
6
6
|
const combi_1 = require("../../abap/2_statements/combi");
|
|
7
7
|
class CDSDefineProjection extends combi_1.Expression {
|
|
8
8
|
getRunnable() {
|
|
9
|
-
return (0, combi_1.seq)((0, combi_1.star)(_1.CDSAnnotation), "DEFINE", (0, combi_1.opt)("ROOT"), "VIEW", (0, combi_1.ver)(__1.Version.v755, (0, combi_1.opt)("ENTITY")), _1.CDSName, (0, combi_1.opt)(_1.CDSProviderContract), "AS PROJECTION ON", _1.CDSName, (0, combi_1.opt)(_1.CDSAs), (0, combi_1.str)("{"), (0, combi_1.plus)(_1.CDSElement), (0, combi_1.star)((0, combi_1.seq)(",", _1.CDSElement)), (0, combi_1.str)("}"), (0, combi_1.opt)(";"));
|
|
9
|
+
return (0, combi_1.seq)((0, combi_1.star)(_1.CDSAnnotation), "DEFINE", (0, combi_1.opt)("ROOT"), "VIEW", (0, combi_1.ver)(__1.Version.v755, (0, combi_1.opt)("ENTITY")), _1.CDSName, (0, combi_1.opt)(_1.CDSProviderContract), "AS PROJECTION ON", _1.CDSName, (0, combi_1.opt)(_1.CDSAs), (0, combi_1.str)("{"), (0, combi_1.plus)(_1.CDSElement), (0, combi_1.star)((0, combi_1.seq)(",", _1.CDSElement)), (0, combi_1.str)("}"), (0, combi_1.opt)(_1.CDSWhere), (0, combi_1.opt)(";"));
|
|
10
10
|
}
|
|
11
11
|
}
|
|
12
12
|
exports.CDSDefineProjection = CDSDefineProjection;
|
|
@@ -7,7 +7,9 @@ const cds_as_1 = require("./cds_as");
|
|
|
7
7
|
const cds_cast_1 = require("./cds_cast");
|
|
8
8
|
class CDSElement extends combi_1.Expression {
|
|
9
9
|
getRunnable() {
|
|
10
|
-
|
|
10
|
+
const redirected = (0, combi_1.seq)(": REDIRECTED TO", (0, combi_1.opt)((0, combi_1.alt)("PARENT", "COMPOSITION CHILD")), _1.CDSName);
|
|
11
|
+
const colonThing = (0, combi_1.seq)(":", _1.CDSName);
|
|
12
|
+
return (0, combi_1.seq)((0, combi_1.starPrio)(_1.CDSAnnotation), (0, combi_1.optPrio)("KEY"), (0, combi_1.altPrio)(_1.CDSAggregate, _1.CDSString, _1.CDSArithmetics, _1.CDSFunction, cds_cast_1.CDSCast, _1.CDSCase, (0, combi_1.seq)("(", _1.CDSCase, ")"), (0, combi_1.seq)(_1.CDSPrefixedName, (0, combi_1.opt)((0, combi_1.alt)(redirected, colonThing))), _1.CDSInteger), (0, combi_1.opt)(cds_as_1.CDSAs));
|
|
11
13
|
}
|
|
12
14
|
}
|
|
13
15
|
exports.CDSElement = CDSElement;
|
package/build/src/registry.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@abaplint/core",
|
|
3
|
-
"version": "2.113.
|
|
3
|
+
"version": "2.113.144",
|
|
4
4
|
"description": "abaplint - Core API",
|
|
5
5
|
"main": "build/src/index.js",
|
|
6
6
|
"typings": "build/abaplint.d.ts",
|
|
@@ -53,9 +53,9 @@
|
|
|
53
53
|
"@microsoft/api-extractor": "^7.52.8",
|
|
54
54
|
"@types/chai": "^4.3.20",
|
|
55
55
|
"@types/mocha": "^10.0.10",
|
|
56
|
-
"@types/node": "^24.0.
|
|
56
|
+
"@types/node": "^24.0.14",
|
|
57
57
|
"chai": "^4.5.0",
|
|
58
|
-
"eslint": "^9.
|
|
58
|
+
"eslint": "^9.31.0",
|
|
59
59
|
"mocha": "^11.7.1",
|
|
60
60
|
"c8": "^10.1.3",
|
|
61
61
|
"source-map-support": "^0.5.21",
|