@abaplint/core 2.113.53 → 2.113.55

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.
@@ -5,7 +5,7 @@ const combi_1 = require("../combi");
5
5
  const tokens_1 = require("../../1_lexer/tokens");
6
6
  class IncludeName extends combi_1.Expression {
7
7
  getRunnable() {
8
- return (0, combi_1.seq)((0, combi_1.regex)(/^<?(\/\w+\/)?[\w%]+(~\w+)?>?$/), (0, combi_1.optPrio)((0, combi_1.seq)((0, combi_1.tok)(tokens_1.Dash), (0, combi_1.regex)(/^\w+$/))));
8
+ return (0, combi_1.seq)((0, combi_1.regex)(/^<?(\/\w+\/)?[\w%#]+(~\w+)?>?$/), (0, combi_1.starPrio)((0, combi_1.seq)((0, combi_1.tok)(tokens_1.Dash), (0, combi_1.optPrio)((0, combi_1.regex)(/^\w+$/)))));
9
9
  }
10
10
  }
11
11
  exports.IncludeName = IncludeName;
@@ -1,11 +1,12 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.MessageClass = void 0;
4
+ const tokens_1 = require("../../1_lexer/tokens");
4
5
  const combi_1 = require("../combi");
5
6
  class MessageClass extends combi_1.Expression {
6
7
  getRunnable() {
7
8
  // "&1" can be used for almost anything(field names, method names etc.) in macros
8
- return (0, combi_1.regex)(/^>?[\w\/]+#?@?\/?!?&?>?\$?$/);
9
+ return (0, combi_1.seq)((0, combi_1.regex)(/^>?[\w\/]+#?@?\/?!?&?>?\$?\??$/), (0, combi_1.starPrio)((0, combi_1.seq)((0, combi_1.tok)(tokens_1.Dash), (0, combi_1.optPrio)((0, combi_1.regex)(/^\w+$/)))), (0, combi_1.optPrio)((0, combi_1.tok)(tokens_1.DashW)));
9
10
  }
10
11
  }
11
12
  exports.MessageClass = MessageClass;
@@ -6,7 +6,9 @@ const _1 = require(".");
6
6
  class RaiseWith extends combi_1.Expression {
7
7
  getRunnable() {
8
8
  const wit = (0, combi_1.seq)("WITH", _1.SimpleSource1, (0, combi_1.opt)(_1.SimpleSource1), (0, combi_1.opt)(_1.SimpleSource1), (0, combi_1.opt)(_1.SimpleSource1));
9
- return wit;
9
+ // todo: I guess this is from version something?
10
+ const witComplex = (0, combi_1.seq)("WITH", _1.Source, (0, combi_1.opt)(_1.Source), (0, combi_1.opt)(_1.Source), (0, combi_1.opt)(_1.Source));
11
+ return (0, combi_1.alt)(wit, witComplex);
10
12
  }
11
13
  }
12
14
  exports.RaiseWith = RaiseWith;
@@ -8,7 +8,7 @@ const dynamic_1 = require("./dynamic");
8
8
  const sql_arithmetics_1 = require("./sql_arithmetics");
9
9
  class SQLAggregation extends combi_1.Expression {
10
10
  getRunnable() {
11
- const f = (0, combi_1.seq)((0, combi_1.optPrio)("DISTINCT"), (0, combi_1.altPrio)(sql_arithmetics_1.SQLArithmetics, dynamic_1.Dynamic, _1.SQLFunction));
11
+ const f = (0, combi_1.seq)((0, combi_1.optPrio)("DISTINCT"), (0, combi_1.altPrio)(sql_arithmetics_1.SQLArithmetics, dynamic_1.Dynamic, _1.SQLFunction, _1.SQLCase));
12
12
  const fparen = (0, combi_1.seq)("(", _1.Field, ")");
13
13
  const count = (0, combi_1.seq)("COUNT", (0, combi_1.altPrio)((0, combi_1.tok)(tokens_1.ParenLeft), (0, combi_1.tok)(tokens_1.ParenLeftW)), (0, combi_1.optPrio)("DISTINCT"), (0, combi_1.altPrio)("*", _1.Field, fparen), ")");
14
14
  const max = (0, combi_1.seq)("MAX", (0, combi_1.altPrio)((0, combi_1.tok)(tokens_1.ParenLeft), (0, combi_1.tok)(tokens_1.ParenLeftW)), f, ")");
@@ -13,8 +13,9 @@ class SQLCase extends combi_1.Expression {
13
13
  getRunnable() {
14
14
  const field = (0, combi_1.altPrio)(_1.SQLAggregation, SQLCase, _1.SQLFunction, _1.SQLPath, sql_field_name_1.SQLFieldName, constant_1.Constant);
15
15
  const sub = (0, combi_1.seq)((0, combi_1.altPrio)("+", "-", "*", "/", "&&"), (0, combi_1.optPrio)((0, combi_1.tok)(tokens_1.WParenLeftW)), field, (0, combi_1.optPrio)((0, combi_1.tok)(tokens_1.WParenRightW)));
16
- const sourc = (0, combi_1.altPrio)(SQLCase, _1.SQLAggregation, _1.SQLFunction, sql_source_1.SQLSource);
17
- const when = (0, combi_1.seq)("WHEN", (0, combi_1.altPrio)(sql_cond_1.SQLCond, constant_1.Constant), "THEN", sourc, (0, combi_1.starPrio)(sub));
16
+ const sourc = (0, combi_1.altPrio)(SQLCase, _1.SQLAggregation, _1.SQLFunction, sql_source_1.SQLSource, constant_1.Constant);
17
+ const val = (0, combi_1.altPrio)(sql_cond_1.SQLCond, constant_1.Constant, (0, combi_1.seq)((0, combi_1.tok)(tokens_1.WAt), _1.SimpleSource3));
18
+ const when = (0, combi_1.seq)("WHEN", val, "THEN", sourc, (0, combi_1.starPrio)(sub));
18
19
  const els = (0, combi_1.seq)("ELSE", sourc);
19
20
  return (0, combi_1.ver)(version_1.Version.v740sp05, (0, combi_1.seq)("CASE", (0, combi_1.opt)(sql_field_name_1.SQLFieldName), (0, combi_1.plusPrio)(when), (0, combi_1.optPrio)(els), "END"));
20
21
  }
@@ -6,8 +6,8 @@ const _1 = require(".");
6
6
  const tokens_1 = require("../../1_lexer/tokens");
7
7
  class Throw extends combi_1.Expression {
8
8
  getRunnable() {
9
- // todo, MESSAGE
10
- return (0, combi_1.seq)("THROW", (0, combi_1.opt)("RESUMABLE"), _1.ClassName, (0, combi_1.altPrio)((0, combi_1.tok)(tokens_1.ParenLeftW), (0, combi_1.tok)(tokens_1.ParenLeft)), (0, combi_1.opt)((0, combi_1.alt)(_1.Source, _1.ParameterListS)), (0, combi_1.altPrio)((0, combi_1.tok)(tokens_1.WParenRightW), (0, combi_1.tok)(tokens_1.ParenRightW)));
9
+ const message = (0, combi_1.seq)("MESSAGE", _1.MessageSource, (0, combi_1.opt)(_1.RaiseWith));
10
+ return (0, combi_1.seq)("THROW", (0, combi_1.opt)("RESUMABLE"), _1.ClassName, (0, combi_1.altPrio)((0, combi_1.tok)(tokens_1.ParenLeftW), (0, combi_1.tok)(tokens_1.ParenLeft)), (0, combi_1.opt)((0, combi_1.alt)(_1.Source, _1.ParameterListS, message)), (0, combi_1.altPrio)((0, combi_1.tok)(tokens_1.WParenRightW), (0, combi_1.tok)(tokens_1.ParenRightW)));
11
11
  }
12
12
  }
13
13
  exports.Throw = Throw;
@@ -14,13 +14,14 @@ class Describe {
14
14
  const field = (0, combi_1.seq)("FIELD", expressions_1.Source, (0, combi_1.per)((0, combi_1.seq)("TYPE", expressions_1.Target), (0, combi_1.seq)("COMPONENTS", expressions_1.Target), (0, combi_1.seq)("LENGTH", expressions_1.Target, (0, combi_1.opt)(mode)), (0, combi_1.seq)("DECIMALS", expressions_1.Target), (0, combi_1.seq)("HELP-ID", expressions_1.Target), (0, combi_1.seq)("OUTPUT-LENGTH", expressions_1.Target), (0, combi_1.seq)("EDIT MASK", expressions_1.Target), (0, combi_1.seq)("INTO", expressions_1.Target)));
15
15
  const distance = (0, combi_1.seq)("DISTANCE BETWEEN", expressions_1.Source, "AND", expressions_1.Source, "INTO", expressions_1.Target, mode);
16
16
  const lines = (0, combi_1.seq)("NUMBER OF LINES", expressions_1.Target);
17
+ const pages = (0, combi_1.seq)("NUMBER OF PAGES", expressions_1.Target);
17
18
  const line = (0, combi_1.seq)("LINE", expressions_1.Source);
18
19
  const page = (0, combi_1.seq)("PAGE", expressions_1.Source);
19
20
  const index = (0, combi_1.seq)("INDEX", expressions_1.Source);
20
21
  const top = (0, combi_1.seq)("TOP-LINES", expressions_1.Target);
21
22
  const lineSize = (0, combi_1.seq)("LINE-SIZE", expressions_1.Target);
22
23
  const first = (0, combi_1.seq)("FIRST-LINE", expressions_1.Target);
23
- const list = (0, combi_1.seq)("LIST", (0, combi_1.per)(lines, index, line, page, top, first, lineSize));
24
+ const list = (0, combi_1.seq)("LIST", (0, combi_1.per)(lines, pages, index, line, page, top, first, lineSize));
24
25
  const ret = (0, combi_1.seq)("DESCRIBE", (0, combi_1.altPrio)(table, field, distance, list));
25
26
  return (0, combi_1.verNot)(version_1.Version.Cloud, ret);
26
27
  }
@@ -8,7 +8,7 @@ class FunctionPool {
8
8
  const message = (0, combi_1.seq)("MESSAGE-ID", expressions_1.MessageClass);
9
9
  const line = (0, combi_1.seq)("LINE-SIZE", expressions_1.Integer);
10
10
  const no = (0, combi_1.str)("NO STANDARD PAGE HEADING");
11
- return (0, combi_1.seq)("FUNCTION-POOL", expressions_1.Field, (0, combi_1.opt)((0, combi_1.per)(message, line, no)));
11
+ return (0, combi_1.seq)("FUNCTION-POOL", expressions_1.IncludeName, (0, combi_1.opt)((0, combi_1.per)(message, line, no)));
12
12
  }
13
13
  }
14
14
  exports.FunctionPool = FunctionPool;
@@ -6,7 +6,7 @@ const expressions_1 = require("../expressions");
6
6
  const version_1 = require("../../../version");
7
7
  class Program {
8
8
  getMatcher() {
9
- const message = (0, combi_1.seq)("MESSAGE-ID", expressions_1.Source);
9
+ const message = (0, combi_1.seq)("MESSAGE-ID", expressions_1.MessageClass);
10
10
  const size = (0, combi_1.seq)("LINE-SIZE", expressions_1.Source);
11
11
  const heading = (0, combi_1.str)("NO STANDARD PAGE HEADING");
12
12
  const line = (0, combi_1.seq)("LINE-COUNT", expressions_1.Source);
@@ -12,7 +12,7 @@ class Submit {
12
12
  const between = (0, combi_1.seq)("BETWEEN", expressions_1.Source, "AND", expressions_1.Source);
13
13
  const selectionTable = (0, combi_1.seq)("WITH SELECTION-TABLE", expressions_1.Source);
14
14
  const awith = (0, combi_1.seq)("WITH", expressions_1.FieldSub, (0, combi_1.alt)(compare, between), (0, combi_1.optPrio)(sign));
15
- const prog = (0, combi_1.alt)(expressions_1.NamespaceSimpleName, expressions_1.Dynamic);
15
+ const prog = (0, combi_1.altPrio)(expressions_1.IncludeName, expressions_1.Dynamic);
16
16
  const job = (0, combi_1.seq)("VIA JOB", expressions_1.Source, "NUMBER", expressions_1.Source);
17
17
  const exporting = (0, combi_1.str)("EXPORTING LIST TO MEMORY");
18
18
  const spool = (0, combi_1.seq)("SPOOL PARAMETERS", expressions_1.Source);
@@ -67,7 +67,7 @@ class Registry {
67
67
  }
68
68
  static abaplintVersion() {
69
69
  // magic, see build script "version.sh"
70
- return "2.113.53";
70
+ return "2.113.55";
71
71
  }
72
72
  getDDICReferences() {
73
73
  return this.ddicReferences;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@abaplint/core",
3
- "version": "2.113.53",
3
+ "version": "2.113.55",
4
4
  "description": "abaplint - Core API",
5
5
  "main": "build/src/index.js",
6
6
  "typings": "build/abaplint.d.ts",