@abaplint/core 2.119.23 → 2.119.24

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.
@@ -13,7 +13,7 @@ class Data {
13
13
  const dd = node.findFirstExpression(Expressions.DataDefinition);
14
14
  if (dd) {
15
15
  const id = data_definition_1.DataDefinition.runSyntax(dd, input);
16
- if (id && this.isOnlyDigits(id.getName())) {
16
+ if (id && this.isOnlyDigits(id.getName()) && this.allowOnlyDigitsName(node, input) === false) {
17
17
  const message = "not possible to have a name with only digits";
18
18
  input.issues.push((0, _syntax_input_1.syntaxIssue)(input, id.getToken(), message));
19
19
  return new _typed_identifier_1.TypedIdentifier(id.getToken(), input.filename, basic_1.VoidType.get(_syntax_input_1.CheckSyntaxKey));
@@ -27,7 +27,7 @@ class Data {
27
27
  return id;
28
28
  }
29
29
  if (name) {
30
- if (this.isOnlyDigits(name.concatTokens())) {
30
+ if (this.isOnlyDigits(name.concatTokens()) && this.allowOnlyDigitsName(node, input) === false) {
31
31
  const message = "not possible to have a name with only digits";
32
32
  input.issues.push((0, _syntax_input_1.syntaxIssue)(input, name.getFirstToken(), message));
33
33
  }
@@ -38,6 +38,9 @@ class Data {
38
38
  isOnlyDigits(name) {
39
39
  return /^[0-9]+$/.test(name);
40
40
  }
41
+ allowOnlyDigitsName(node, input) {
42
+ return input.scope.isAnyOO() === false && node.getColon() !== undefined;
43
+ }
41
44
  }
42
45
  exports.Data = Data;
43
46
  //# sourceMappingURL=data.js.map
@@ -104,9 +104,11 @@ class ABAPObject extends _abstract_object_1.AbstractObject {
104
104
  }
105
105
  for (const t of (0, xml_utils_1.xmlToArray)(parsed.abapGit["asx:abap"]["asx:values"].TPOOL.item)) {
106
106
  const id = (_e = t.ID) === null || _e === void 0 ? void 0 : _e.toUpperCase();
107
- if (id === undefined
108
- || (id !== "R" && t.KEY === undefined)) {
109
- throw new Error("findTexts, undefined");
107
+ if (id === undefined) {
108
+ continue;
109
+ }
110
+ if (id !== "R" && t.KEY === undefined) {
111
+ continue;
110
112
  }
111
113
  const key = (_g = ((_f = t.KEY) !== null && _f !== void 0 ? _f : t.ID)) === null || _g === void 0 ? void 0 : _g.toUpperCase();
112
114
  if (key === undefined) {
@@ -74,7 +74,7 @@ class Registry {
74
74
  }
75
75
  static abaplintVersion() {
76
76
  // magic, see build script "version.sh"
77
- return "2.119.23";
77
+ return "2.119.24";
78
78
  }
79
79
  getDDICReferences() {
80
80
  return this.ddicReferences;
@@ -14,25 +14,54 @@ class FunctionModuleRecommendationsConf extends _basic_rule_config_1.BasicRuleCo
14
14
  * @uniqueItems true
15
15
  */
16
16
  this.recommendations = [
17
+ { name: "CALCULATE_HASH_FOR_CHAR", replace: "use CL_ABAP_MESSAGE_DIGEST" },
17
18
  { name: "CALCULATE_HASH_FOR_RAW", replace: "use CL_ABAP_HMAC or CL_ABAP_MESSAGE_DIGEST" },
18
19
  { name: "CCU_TIMESTAMP_DIFFERENCE", replace: "use CL_ABAP_TSTMP" },
20
+ { name: "CLPB_EXPORT", replace: "use CL_GUI_FRONTEND_SERVICES" },
21
+ { name: "CLPB_IMPORT", replace: "use CL_GUI_FRONTEND_SERVICES" },
19
22
  { name: "CONVERT_DATE_TO_EXTERNAL", replace: "use CL_ABAP_DATFM" },
20
23
  { name: "CONVERT_TIME_INPUT", replace: "use CL_ABAP_TIMEFM" },
24
+ { name: "DOWNLOAD", replace: "use CL_GUI_FRONTEND_SERVICES" },
21
25
  { name: "ECATT_CONV_XSTRING_TO_STRING", replace: "use CL_BINARY_CONVERT" },
22
26
  { name: "F4_FILENAME", replace: "use CL_GUI_FRONTEND_SERVICES" },
23
27
  { name: "FUNCTION_EXISTS", replace: "surround with try-catch CX_SY_DYN_CALL_ILLEGAL_METHOD instead" },
28
+ { name: "GUI_CREATE_DIRECTORY", replace: "use CL_GUI_FRONTEND_SERVICES" },
29
+ { name: "GUI_DELETE_FILE", replace: "use CL_GUI_FRONTEND_SERVICES" },
24
30
  { name: "GUI_DOWNLOAD", replace: "use CL_GUI_FRONTEND_SERVICES" },
31
+ { name: "GUI_EXEC", replace: "use CL_GUI_FRONTEND_SERVICES" },
32
+ { name: "GUI_FB_USAGE", replace: "use CL_GUI_FRONTEND_SERVICES" },
33
+ { name: "GUI_FILE_LOAD_DIALOG", replace: "use CL_GUI_FRONTEND_SERVICES" },
34
+ { name: "GUI_FILE_SAVE_DIALOG", replace: "use CL_GUI_FRONTEND_SERVICES" },
35
+ { name: "GUI_GET_DESKTOP_INFO", replace: "use CL_GUI_FRONTEND_SERVICES" },
36
+ { name: "GUI_GET_FILE_INFO", replace: "use CL_GUI_FRONTEND_SERVICES" },
37
+ { name: "GUI_GET_REGVALUE", replace: "use CL_GUI_FRONTEND_SERVICES" },
38
+ { name: "GUI_MULTIPLE_FILE_LOAD_DIALOG", replace: "use CL_GUI_FRONTEND_SERVICES" },
39
+ { name: "GUI_REMOVE_DIRECTORY", replace: "use CL_GUI_FRONTEND_SERVICES" },
40
+ { name: "GUI_RUN", replace: "use CL_GUI_FRONTEND_SERVICES" },
41
+ { name: "GUI_SET_REGVALUE", replace: "use CL_GUI_FRONTEND_SERVICES" },
25
42
  { name: "GUI_UPLOAD", replace: "use CL_GUI_FRONTEND_SERVICES" },
43
+ { name: "GUI_VSS_DOWNLOAD", replace: "use CL_GUI_FRONTEND_SERVICES" },
44
+ { name: "GUI_VSS_UPLOAD", replace: "use CL_GUI_FRONTEND_SERVICES" },
26
45
  { name: "GUID_CREATE", replace: "use CL_SYSTEM_UUID" },
27
46
  { name: "IGN_TIMESTAMP_DIFFERENCE", replace: "use CL_ABAP_TSTMP" },
28
47
  { name: "IGN_TIMESTAMP_PLUSMINUS", replace: "use CL_ABAP_TSTMP" },
29
48
  { name: "ISM_SD_GET_PRICING_CONDITIONS", replace: "use CL_PRC_RESULT_FACTORY as per note 2220005" },
30
49
  { name: "JOB_CREATE", replace: "use CL_BP_ABAP_JOB" },
31
50
  { name: "JOB_SUBMIT", replace: "use CL_BP_ABAP_JOB" },
51
+ { name: "MD5_CALCULATE_HASH_FOR_CHAR", replace: "use CL_ABAP_MESSAGE_DIGEST" },
52
+ { name: "MD5_CALCULATE_HASH_FOR_RAW", replace: "use CL_ABAP_MESSAGE_DIGEST" },
53
+ { name: "POPUP_TO_CONFIRM_LOSS_OF_DATA", replace: "use POPUP_TO_CONFIRM" },
32
54
  { name: "POPUP_TO_CONFIRM_STEP", replace: "use POPUP_TO_CONFIRM" },
55
+ { name: "POPUP_TO_CONFIRM_WITH_MESSAGE", replace: "use POPUP_TO_CONFIRM" },
56
+ { name: "POPUP_TO_CONFIRM_WITH_VALUE", replace: "use POPUP_TO_CONFIRM" },
57
+ { name: "POPUP_TO_CONFIRM_WITH_VALUE_2", replace: "use POPUP_TO_CONFIRM" },
33
58
  { name: "POPUP_TO_DECIDE", replace: "use POPUP_TO_CONFIRM" },
59
+ { name: "POPUP_TO_DECIDE_INFO", replace: "use POPUP_TO_CONFIRM" },
60
+ { name: "POPUP_TO_DECIDE_WITH_MESSAGE", replace: "use POPUP_TO_CONFIRM" },
34
61
  { name: "POPUP_TO_GET_VALUE", replace: "use POPUP_GET_VALUES" },
35
62
  { name: "QF05_RANDOM_INTEGER", replace: "use CL_ABAP_RANDOM_INT" },
63
+ { name: "REGISTRY_GET", replace: "use CL_GUI_FRONTEND_SERVICES" },
64
+ { name: "REGISTRY_SET", replace: "use CL_GUI_FRONTEND_SERVICES" },
36
65
  { name: "REUSE_ALV_GRID_DISPLAY", replace: "use CL_SALV_TABLE=>FACTORY or CL_GUI_ALV_GRID" },
37
66
  { name: "ROUND", replace: "use built in function: round()" },
38
67
  { name: "SAPGUI_PROGRESS_INDICATOR", replace: "use CL_PROGRESS_INDICATOR" },
@@ -42,7 +71,17 @@ class FunctionModuleRecommendationsConf extends _basic_rule_config_1.BasicRuleCo
42
71
  { name: "SSFC_BASE64_DECODE", replace: "use class CL_HTTP_UTILITY methods" },
43
72
  { name: "SSFC_BASE64_ENCODE", replace: "use class CL_HTTP_UTILITY methods" },
44
73
  { name: "SUBST_GET_FILE_LIST", replace: "see note 1686357" },
74
+ { name: "SYSTEM_GET_UNIQUE_ID", replace: "use CL_SYSTEM_UUID" },
75
+ { name: "SYSTEM_UUID_C_CREATE", replace: "use CL_SYSTEM_UUID" },
76
+ { name: "UPLOAD", replace: "use CL_GUI_FRONTEND_SERVICES" },
77
+ { name: "WS_DOWNLOAD", replace: "use CL_GUI_FRONTEND_SERVICES" },
78
+ { name: "WS_EXECUTE", replace: "use CL_GUI_FRONTEND_SERVICES" },
45
79
  { name: "WS_FILENAME_GET", replace: "use CL_GUI_FRONTEND_SERVICES" },
80
+ { name: "WS_FILE_ATTRIB", replace: "use CL_GUI_FRONTEND_SERVICES" },
81
+ { name: "WS_FILE_COPY", replace: "use CL_GUI_FRONTEND_SERVICES" },
82
+ { name: "WS_FILE_DELETE", replace: "use CL_GUI_FRONTEND_SERVICES" },
83
+ { name: "WS_QUERY", replace: "use CL_GUI_FRONTEND_SERVICES" },
84
+ { name: "WS_UPLOAD", replace: "use CL_GUI_FRONTEND_SERVICES" },
46
85
  ];
47
86
  }
48
87
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@abaplint/core",
3
- "version": "2.119.23",
3
+ "version": "2.119.24",
4
4
  "description": "abaplint - Core API",
5
5
  "main": "build/src/index.js",
6
6
  "typings": "build/abaplint.d.ts",