@abaplint/core 2.113.47 → 2.113.48

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.
@@ -6,7 +6,7 @@ class Field extends combi_1.Expression {
6
6
  getRunnable() {
7
7
  // "&1" can be used for almost anything(field names, method names etc.) in macros
8
8
  // field names with only digits should not be possible
9
- return (0, combi_1.regex)(/^[&_!]?\*?\w*(\/\w+\/)?\d*[a-zA-Z_%\$][\w\*%\$\?#]*(~\w+)?$/);
9
+ return (0, combi_1.regex)(/^[&_!?]?\*?\w*(\/\w+\/)?\d*[a-zA-Z_%\$][\w\*%\$\?#]*(~\w+)?$/);
10
10
  }
11
11
  }
12
12
  exports.Field = Field;
@@ -6,7 +6,7 @@ const tokens_1 = require("../../1_lexer/tokens");
6
6
  const _1 = require(".");
7
7
  class FieldOffset extends combi_1.Expression {
8
8
  getRunnable() {
9
- const offset = (0, combi_1.seq)((0, combi_1.tok)(tokens_1.Plus), (0, combi_1.altPrio)((0, combi_1.regex)(/^\d+$/), _1.SimpleFieldChain2));
9
+ const offset = (0, combi_1.seq)((0, combi_1.tok)(tokens_1.Plus), (0, combi_1.optPrio)((0, combi_1.altPrio)((0, combi_1.regex)(/^\d+$/), _1.SimpleFieldChain2)));
10
10
  return offset;
11
11
  }
12
12
  }
@@ -7,7 +7,8 @@ const version_1 = require("../../../version");
7
7
  class Break {
8
8
  getMatcher() {
9
9
  const next = (0, combi_1.str)("AT NEXT APPLICATION STATEMENT");
10
- const ret = (0, combi_1.altPrio)((0, combi_1.seq)("BREAK-POINT", (0, combi_1.optPrio)((0, combi_1.altPrio)(next, expressions_1.Source))), (0, combi_1.seq)("BREAK", expressions_1.FieldSub));
10
+ // note BREAK is a special macro that wraps the parameter in a char
11
+ const ret = (0, combi_1.altPrio)((0, combi_1.seq)("BREAK-POINT", (0, combi_1.optPrio)((0, combi_1.altPrio)(next, expressions_1.Source))), (0, combi_1.seq)("BREAK", (0, combi_1.starPrio)((0, combi_1.regex)(/.*/))));
11
12
  return (0, combi_1.verNot)(version_1.Version.Cloud, ret);
12
13
  }
13
14
  }
@@ -2,15 +2,13 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.Diagnostics = void 0;
4
4
  const LServer = require("vscode-languageserver-types");
5
- const _lsp_utils_1 = require("./_lsp_utils");
6
5
  const severity_1 = require("../severity");
7
6
  class Diagnostics {
8
7
  constructor(reg) {
9
8
  this.reg = reg;
10
9
  }
11
10
  findIssues(textDocument) {
12
- this.reg.parse();
13
- const file = _lsp_utils_1.LSPUtils.getABAPFile(this.reg, textDocument.uri); // todo, this sould also run for xml files
11
+ const file = this.reg.getFileByName(textDocument.uri);
14
12
  if (file === undefined) {
15
13
  return [];
16
14
  }
@@ -18,6 +16,7 @@ class Diagnostics {
18
16
  if (obj === undefined) {
19
17
  return [];
20
18
  }
19
+ this.reg.parse();
21
20
  let issues = this.reg.findIssuesObject(obj);
22
21
  issues = issues.filter(i => i.getFilename() === file.getFilename());
23
22
  return issues;
@@ -67,7 +67,7 @@ class Registry {
67
67
  }
68
68
  static abaplintVersion() {
69
69
  // magic, see build script "version.sh"
70
- return "2.113.47";
70
+ return "2.113.48";
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.47",
3
+ "version": "2.113.48",
4
4
  "description": "abaplint - Core API",
5
5
  "main": "build/src/index.js",
6
6
  "typings": "build/abaplint.d.ts",