@abaplint/core 2.113.57 → 2.113.58
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/abaplint.d.ts +5 -0
- package/build/src/abap/2_statements/expressions/index.js +1 -0
- package/build/src/abap/2_statements/expressions/provide_field_name.js +12 -0
- package/build/src/abap/2_statements/statements/provide.js +5 -3
- package/build/src/registry.js +1 -1
- package/package.json +1 -1
package/build/abaplint.d.ts
CHANGED
|
@@ -2339,6 +2339,7 @@ declare namespace Expressions {
|
|
|
2339
2339
|
SQLForAllEntries,
|
|
2340
2340
|
SQLFromSource,
|
|
2341
2341
|
SQLFrom,
|
|
2342
|
+
ProvideFieldName,
|
|
2342
2343
|
SQLFunctionInput,
|
|
2343
2344
|
SQLFunction,
|
|
2344
2345
|
SQLGroupBy,
|
|
@@ -5251,6 +5252,10 @@ declare class Provide_2 implements IStatement {
|
|
|
5251
5252
|
getMatcher(): IStatementRunnable;
|
|
5252
5253
|
}
|
|
5253
5254
|
|
|
5255
|
+
declare class ProvideFieldName extends Expression {
|
|
5256
|
+
getRunnable(): IStatementRunnable;
|
|
5257
|
+
}
|
|
5258
|
+
|
|
5254
5259
|
declare class ProxyObject extends AbstractObject {
|
|
5255
5260
|
getType(): string;
|
|
5256
5261
|
getAllowedNaming(): {
|
|
@@ -189,6 +189,7 @@ __exportStar(require("./sql_fields"), exports);
|
|
|
189
189
|
__exportStar(require("./sql_for_all_entries"), exports);
|
|
190
190
|
__exportStar(require("./sql_from_source"), exports);
|
|
191
191
|
__exportStar(require("./sql_from"), exports);
|
|
192
|
+
__exportStar(require("./provide_field_name"), exports);
|
|
192
193
|
__exportStar(require("./sql_function_input"), exports);
|
|
193
194
|
__exportStar(require("./sql_function"), exports);
|
|
194
195
|
__exportStar(require("./sql_group_by"), exports);
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ProvideFieldName = void 0;
|
|
4
|
+
const tokens_1 = require("../../1_lexer/tokens");
|
|
5
|
+
const combi_1 = require("../combi");
|
|
6
|
+
class ProvideFieldName extends combi_1.Expression {
|
|
7
|
+
getRunnable() {
|
|
8
|
+
return (0, combi_1.seq)((0, combi_1.regex)(/^(?!(?:FROM|BETWEEN|WHERE)$)(\/\w+\/)?(\w+~(\w+|\*)|\w+)$/i), (0, combi_1.optPrio)((0, combi_1.seq)((0, combi_1.tok)(tokens_1.Dash), (0, combi_1.regex)(/^\w+$/i))));
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
exports.ProvideFieldName = ProvideFieldName;
|
|
12
|
+
//# sourceMappingURL=provide_field_name.js.map
|
|
@@ -6,11 +6,13 @@ const expressions_1 = require("../expressions");
|
|
|
6
6
|
const version_1 = require("../../../version");
|
|
7
7
|
class Provide {
|
|
8
8
|
getMatcher() {
|
|
9
|
-
const list = (0, combi_1.
|
|
9
|
+
const list = (0, combi_1.plusPrio)((0, combi_1.altPrio)("*", expressions_1.ProvideFieldName));
|
|
10
10
|
const fields = (0, combi_1.seq)("FIELDS", list, "FROM", expressions_1.Source, "INTO", expressions_1.Target, "VALID", expressions_1.Field, "BOUNDS", expressions_1.Field, "AND", expressions_1.Field);
|
|
11
|
-
const
|
|
11
|
+
const from = (0, combi_1.seq)("FROM", expressions_1.Source);
|
|
12
|
+
const fieldList = (0, combi_1.seq)((0, combi_1.plus)(list), from);
|
|
12
13
|
const where = (0, combi_1.seq)("WHERE", expressions_1.Cond);
|
|
13
|
-
const
|
|
14
|
+
const between = (0, combi_1.seq)("BETWEEN", expressions_1.SimpleSource3, "AND", expressions_1.SimpleSource3);
|
|
15
|
+
const ret = (0, combi_1.seq)("PROVIDE", (0, combi_1.altPrio)((0, combi_1.plusPrio)(fields), (0, combi_1.plusPrio)(fieldList)), (0, combi_1.opt)((0, combi_1.per)(between, where)));
|
|
14
16
|
return (0, combi_1.verNot)(version_1.Version.Cloud, ret);
|
|
15
17
|
}
|
|
16
18
|
}
|
package/build/src/registry.js
CHANGED