@abaplint/transpiler-cli 2.3.72 → 2.3.74

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.
Files changed (2) hide show
  1. package/build/bundle.js +18 -7
  2. package/package.json +4 -4
package/build/bundle.js CHANGED
@@ -13667,7 +13667,7 @@ eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\n
13667
13667
  /***/ (function(__unused_webpack_module, exports, __webpack_require__) {
13668
13668
 
13669
13669
  "use strict";
13670
- eval("\r\nvar __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n var desc = Object.getOwnPropertyDescriptor(m, k);\r\n if (!desc || (\"get\" in desc ? !m.__esModule : desc.writable || desc.configurable)) {\r\n desc = { enumerable: true, get: function() { return m[k]; } };\r\n }\r\n Object.defineProperty(o, k2, desc);\r\n}) : (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n}));\r\nvar __exportStar = (this && this.__exportStar) || function(m, exports) {\r\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);\r\n};\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\n__exportStar(__webpack_require__(/*! ./arith_operator */ \"./node_modules/@abaplint/transpiler/build/src/expressions/arith_operator.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./attribute_chain */ \"./node_modules/@abaplint/transpiler/build/src/expressions/attribute_chain.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./attribute_name */ \"./node_modules/@abaplint/transpiler/build/src/expressions/attribute_name.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./call_transformation_options */ \"./node_modules/@abaplint/transpiler/build/src/expressions/call_transformation_options.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./call_transformation_parameters */ \"./node_modules/@abaplint/transpiler/build/src/expressions/call_transformation_parameters.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./compare_operator */ \"./node_modules/@abaplint/transpiler/build/src/expressions/compare_operator.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./compare */ \"./node_modules/@abaplint/transpiler/build/src/expressions/compare.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./component_chain_simple */ \"./node_modules/@abaplint/transpiler/build/src/expressions/component_chain_simple.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./component_chain */ \"./node_modules/@abaplint/transpiler/build/src/expressions/component_chain.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./component_compare */ \"./node_modules/@abaplint/transpiler/build/src/expressions/component_compare.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./component_cond_sub */ \"./node_modules/@abaplint/transpiler/build/src/expressions/component_cond_sub.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./component_cond */ \"./node_modules/@abaplint/transpiler/build/src/expressions/component_cond.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./cond_sub */ \"./node_modules/@abaplint/transpiler/build/src/expressions/cond_sub.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./cond */ \"./node_modules/@abaplint/transpiler/build/src/expressions/cond.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./constant */ \"./node_modules/@abaplint/transpiler/build/src/expressions/constant.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./database_table */ \"./node_modules/@abaplint/transpiler/build/src/expressions/database_table.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./field_chain */ \"./node_modules/@abaplint/transpiler/build/src/expressions/field_chain.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./field_length */ \"./node_modules/@abaplint/transpiler/build/src/expressions/field_length.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./field_offset */ \"./node_modules/@abaplint/transpiler/build/src/expressions/field_offset.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./field_symbol */ \"./node_modules/@abaplint/transpiler/build/src/expressions/field_symbol.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./function_exporting */ \"./node_modules/@abaplint/transpiler/build/src/expressions/function_exporting.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./sql_from */ \"./node_modules/@abaplint/transpiler/build/src/expressions/sql_from.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./sql_join */ \"./node_modules/@abaplint/transpiler/build/src/expressions/sql_join.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./function_parameters */ \"./node_modules/@abaplint/transpiler/build/src/expressions/function_parameters.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./message_number */ \"./node_modules/@abaplint/transpiler/build/src/expressions/message_number.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./method_call_body */ \"./node_modules/@abaplint/transpiler/build/src/expressions/method_call_body.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./method_call_chain */ \"./node_modules/@abaplint/transpiler/build/src/expressions/method_call_chain.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./method_call_param */ \"./node_modules/@abaplint/transpiler/build/src/expressions/method_call_param.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./method_call */ \"./node_modules/@abaplint/transpiler/build/src/expressions/method_call.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./method_parameters */ \"./node_modules/@abaplint/transpiler/build/src/expressions/method_parameters.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./method_source */ \"./node_modules/@abaplint/transpiler/build/src/expressions/method_source.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./parameter_list_s */ \"./node_modules/@abaplint/transpiler/build/src/expressions/parameter_list_s.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./parameter_list_t */ \"./node_modules/@abaplint/transpiler/build/src/expressions/parameter_list_t.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./parameter_name */ \"./node_modules/@abaplint/transpiler/build/src/expressions/parameter_name.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./parameter_s */ \"./node_modules/@abaplint/transpiler/build/src/expressions/parameter_s.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./parameter_t */ \"./node_modules/@abaplint/transpiler/build/src/expressions/parameter_t.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./simple_source1 */ \"./node_modules/@abaplint/transpiler/build/src/expressions/simple_source1.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./simple_source2 */ \"./node_modules/@abaplint/transpiler/build/src/expressions/simple_source2.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./simple_source3 */ \"./node_modules/@abaplint/transpiler/build/src/expressions/simple_source3.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./simple_source4 */ \"./node_modules/@abaplint/transpiler/build/src/expressions/simple_source4.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./source_field_symbol */ \"./node_modules/@abaplint/transpiler/build/src/expressions/source_field_symbol.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./source */ \"./node_modules/@abaplint/transpiler/build/src/expressions/source.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./sql_cond */ \"./node_modules/@abaplint/transpiler/build/src/expressions/sql_cond.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./sql_source_simple */ \"./node_modules/@abaplint/transpiler/build/src/expressions/sql_source_simple.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./sql_source */ \"./node_modules/@abaplint/transpiler/build/src/expressions/sql_source.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./string_template_source */ \"./node_modules/@abaplint/transpiler/build/src/expressions/string_template_source.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./string_template */ \"./node_modules/@abaplint/transpiler/build/src/expressions/string_template.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./target */ \"./node_modules/@abaplint/transpiler/build/src/expressions/target.js\"), exports);\r\n//# sourceMappingURL=index.js.map\n\n//# sourceURL=webpack://@abaplint/transpiler-cli/./node_modules/@abaplint/transpiler/build/src/expressions/index.js?");
13670
+ eval("\r\nvar __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n var desc = Object.getOwnPropertyDescriptor(m, k);\r\n if (!desc || (\"get\" in desc ? !m.__esModule : desc.writable || desc.configurable)) {\r\n desc = { enumerable: true, get: function() { return m[k]; } };\r\n }\r\n Object.defineProperty(o, k2, desc);\r\n}) : (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n}));\r\nvar __exportStar = (this && this.__exportStar) || function(m, exports) {\r\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);\r\n};\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\n__exportStar(__webpack_require__(/*! ./arith_operator */ \"./node_modules/@abaplint/transpiler/build/src/expressions/arith_operator.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./attribute_chain */ \"./node_modules/@abaplint/transpiler/build/src/expressions/attribute_chain.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./attribute_name */ \"./node_modules/@abaplint/transpiler/build/src/expressions/attribute_name.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./call_transformation_options */ \"./node_modules/@abaplint/transpiler/build/src/expressions/call_transformation_options.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./call_transformation_parameters */ \"./node_modules/@abaplint/transpiler/build/src/expressions/call_transformation_parameters.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./compare_operator */ \"./node_modules/@abaplint/transpiler/build/src/expressions/compare_operator.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./compare */ \"./node_modules/@abaplint/transpiler/build/src/expressions/compare.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./component_chain_simple */ \"./node_modules/@abaplint/transpiler/build/src/expressions/component_chain_simple.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./component_chain */ \"./node_modules/@abaplint/transpiler/build/src/expressions/component_chain.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./component_compare */ \"./node_modules/@abaplint/transpiler/build/src/expressions/component_compare.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./component_cond_sub */ \"./node_modules/@abaplint/transpiler/build/src/expressions/component_cond_sub.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./component_cond */ \"./node_modules/@abaplint/transpiler/build/src/expressions/component_cond.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./cond_sub */ \"./node_modules/@abaplint/transpiler/build/src/expressions/cond_sub.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./cond */ \"./node_modules/@abaplint/transpiler/build/src/expressions/cond.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./constant */ \"./node_modules/@abaplint/transpiler/build/src/expressions/constant.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./database_table */ \"./node_modules/@abaplint/transpiler/build/src/expressions/database_table.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./field_chain */ \"./node_modules/@abaplint/transpiler/build/src/expressions/field_chain.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./field_length */ \"./node_modules/@abaplint/transpiler/build/src/expressions/field_length.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./field_offset */ \"./node_modules/@abaplint/transpiler/build/src/expressions/field_offset.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./field_symbol */ \"./node_modules/@abaplint/transpiler/build/src/expressions/field_symbol.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./function_exporting */ \"./node_modules/@abaplint/transpiler/build/src/expressions/function_exporting.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./function_parameters */ \"./node_modules/@abaplint/transpiler/build/src/expressions/function_parameters.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./message_number */ \"./node_modules/@abaplint/transpiler/build/src/expressions/message_number.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./method_call_body */ \"./node_modules/@abaplint/transpiler/build/src/expressions/method_call_body.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./method_call_chain */ \"./node_modules/@abaplint/transpiler/build/src/expressions/method_call_chain.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./method_call_param */ \"./node_modules/@abaplint/transpiler/build/src/expressions/method_call_param.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./method_call */ \"./node_modules/@abaplint/transpiler/build/src/expressions/method_call.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./method_parameters */ \"./node_modules/@abaplint/transpiler/build/src/expressions/method_parameters.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./method_source */ \"./node_modules/@abaplint/transpiler/build/src/expressions/method_source.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./parameter_list_s */ \"./node_modules/@abaplint/transpiler/build/src/expressions/parameter_list_s.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./parameter_list_t */ \"./node_modules/@abaplint/transpiler/build/src/expressions/parameter_list_t.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./parameter_name */ \"./node_modules/@abaplint/transpiler/build/src/expressions/parameter_name.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./parameter_s */ \"./node_modules/@abaplint/transpiler/build/src/expressions/parameter_s.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./parameter_t */ \"./node_modules/@abaplint/transpiler/build/src/expressions/parameter_t.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./simple_source1 */ \"./node_modules/@abaplint/transpiler/build/src/expressions/simple_source1.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./simple_source2 */ \"./node_modules/@abaplint/transpiler/build/src/expressions/simple_source2.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./simple_source3 */ \"./node_modules/@abaplint/transpiler/build/src/expressions/simple_source3.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./simple_source4 */ \"./node_modules/@abaplint/transpiler/build/src/expressions/simple_source4.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./source_field_symbol */ \"./node_modules/@abaplint/transpiler/build/src/expressions/source_field_symbol.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./source */ \"./node_modules/@abaplint/transpiler/build/src/expressions/source.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./sql_cond */ \"./node_modules/@abaplint/transpiler/build/src/expressions/sql_cond.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./sql_from */ \"./node_modules/@abaplint/transpiler/build/src/expressions/sql_from.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./sql_join */ \"./node_modules/@abaplint/transpiler/build/src/expressions/sql_join.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./sql_source_simple */ \"./node_modules/@abaplint/transpiler/build/src/expressions/sql_source_simple.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./sql_source */ \"./node_modules/@abaplint/transpiler/build/src/expressions/sql_source.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./sql_target */ \"./node_modules/@abaplint/transpiler/build/src/expressions/sql_target.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./string_template_source */ \"./node_modules/@abaplint/transpiler/build/src/expressions/string_template_source.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./string_template */ \"./node_modules/@abaplint/transpiler/build/src/expressions/string_template.js\"), exports);\r\n__exportStar(__webpack_require__(/*! ./target */ \"./node_modules/@abaplint/transpiler/build/src/expressions/target.js\"), exports);\r\n//# sourceMappingURL=index.js.map\n\n//# sourceURL=webpack://@abaplint/transpiler-cli/./node_modules/@abaplint/transpiler/build/src/expressions/index.js?");
13671
13671
 
13672
13672
  /***/ }),
13673
13673
 
@@ -13924,6 +13924,17 @@ eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\n
13924
13924
 
13925
13925
  /***/ }),
13926
13926
 
13927
+ /***/ "./node_modules/@abaplint/transpiler/build/src/expressions/sql_target.js":
13928
+ /*!*******************************************************************************!*\
13929
+ !*** ./node_modules/@abaplint/transpiler/build/src/expressions/sql_target.js ***!
13930
+ \*******************************************************************************/
13931
+ /***/ ((__unused_webpack_module, exports, __webpack_require__) => {
13932
+
13933
+ "use strict";
13934
+ eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\nexports.SQLTargetTranspiler = void 0;\r\nconst abaplint = __webpack_require__(/*! @abaplint/core */ \"./node_modules/@abaplint/core/build/src/index.js\");\r\nclass SQLTargetTranspiler {\r\n transpile(node, traversal) {\r\n const s = node.findDirectExpression(abaplint.Expressions.Target);\r\n return traversal.traverse(s);\r\n }\r\n}\r\nexports.SQLTargetTranspiler = SQLTargetTranspiler;\r\n//# sourceMappingURL=sql_target.js.map\n\n//# sourceURL=webpack://@abaplint/transpiler-cli/./node_modules/@abaplint/transpiler/build/src/expressions/sql_target.js?");
13935
+
13936
+ /***/ }),
13937
+
13927
13938
  /***/ "./node_modules/@abaplint/transpiler/build/src/expressions/string_template.js":
13928
13939
  /*!************************************************************************************!*\
13929
13940
  !*** ./node_modules/@abaplint/transpiler/build/src/expressions/string_template.js ***!
@@ -14030,7 +14041,7 @@ eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\n
14030
14041
  /***/ ((__unused_webpack_module, exports, __webpack_require__) => {
14031
14042
 
14032
14043
  "use strict";
14033
- eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\nexports.Transpiler = exports.config = void 0;\r\nconst abaplint = __webpack_require__(/*! @abaplint/core */ \"./node_modules/@abaplint/core/build/src/index.js\");\r\nconst validation_1 = __webpack_require__(/*! ./validation */ \"./node_modules/@abaplint/transpiler/build/src/validation.js\");\r\nObject.defineProperty(exports, \"config\", ({ enumerable: true, get: function () { return validation_1.config; } }));\r\nconst unit_test_1 = __webpack_require__(/*! ./unit_test */ \"./node_modules/@abaplint/transpiler/build/src/unit_test.js\");\r\nconst keywords_1 = __webpack_require__(/*! ./keywords */ \"./node_modules/@abaplint/transpiler/build/src/keywords.js\");\r\nconst db_1 = __webpack_require__(/*! ./db */ \"./node_modules/@abaplint/transpiler/build/src/db/index.js\");\r\nconst handle_table_1 = __webpack_require__(/*! ./handlers/handle_table */ \"./node_modules/@abaplint/transpiler/build/src/handlers/handle_table.js\");\r\nconst handle_abap_1 = __webpack_require__(/*! ./handlers/handle_abap */ \"./node_modules/@abaplint/transpiler/build/src/handlers/handle_abap.js\");\r\nconst handle_data_element_1 = __webpack_require__(/*! ./handlers/handle_data_element */ \"./node_modules/@abaplint/transpiler/build/src/handlers/handle_data_element.js\");\r\nconst handle_table_type_1 = __webpack_require__(/*! ./handlers/handle_table_type */ \"./node_modules/@abaplint/transpiler/build/src/handlers/handle_table_type.js\");\r\nconst handle_view_1 = __webpack_require__(/*! ./handlers/handle_view */ \"./node_modules/@abaplint/transpiler/build/src/handlers/handle_view.js\");\r\nconst handle_enqu_1 = __webpack_require__(/*! ./handlers/handle_enqu */ \"./node_modules/@abaplint/transpiler/build/src/handlers/handle_enqu.js\");\r\nclass Transpiler {\r\n constructor(options) {\r\n this.options = options;\r\n if (this.options === undefined) {\r\n this.options = {};\r\n }\r\n if (this.options.unknownTypes === undefined) {\r\n this.options.unknownTypes = \"compileError\";\r\n }\r\n }\r\n // workaround for web/webpack\r\n async runRaw(files) {\r\n const memory = files.map(f => new abaplint.MemoryFile(f.filename, f.contents));\r\n const reg = new abaplint.Registry().addFiles(memory).parse();\r\n return new Transpiler().run(reg);\r\n }\r\n async run(reg, progress) {\r\n var _a, _b, _c, _d, _e, _f;\r\n reg.parse();\r\n new keywords_1.Keywords().handle(reg);\r\n this.validate(reg);\r\n const dbSetup = new db_1.DatabaseSetup(reg).run();\r\n const output = {\r\n objects: [],\r\n unitTestScript: new unit_test_1.UnitTest().unitTestScript(reg, (_a = this.options) === null || _a === void 0 ? void 0 : _a.skip, (_b = this.options) === null || _b === void 0 ? void 0 : _b.only),\r\n unitTestScriptOpen: new unit_test_1.UnitTest().unitTestScriptOpen(reg, (_c = this.options) === null || _c === void 0 ? void 0 : _c.skip, (_d = this.options) === null || _d === void 0 ? void 0 : _d.only),\r\n initializationScript: new unit_test_1.UnitTest().initializationScript(reg, dbSetup, (_e = this.options) === null || _e === void 0 ? void 0 : _e.extraSetup),\r\n initializationScript2: new unit_test_1.UnitTest().initializationScript(reg, dbSetup, (_f = this.options) === null || _f === void 0 ? void 0 : _f.extraSetup, true),\r\n databaseSetup: dbSetup,\r\n reg: reg,\r\n };\r\n progress === null || progress === void 0 ? void 0 : progress.set(reg.getObjectCount(false), \"Building, Syntax Logic\");\r\n for (const obj of reg.getObjects()) {\r\n await (progress === null || progress === void 0 ? void 0 : progress.tick(\"Building, Syntax Logic, \" + obj.getName()));\r\n if (obj instanceof abaplint.ABAPObject) {\r\n // todo, this is already done inside reg.parse()?\r\n new abaplint.SyntaxLogic(reg, obj).run();\r\n }\r\n }\r\n progress === null || progress === void 0 ? void 0 : progress.set(reg.getObjectCount(false), \"Building\");\r\n for (const obj of reg.getObjects()) {\r\n await (progress === null || progress === void 0 ? void 0 : progress.tick(\"Building, \" + obj.getName()));\r\n if (obj instanceof abaplint.ABAPObject && !(obj instanceof abaplint.Objects.TypePool)) {\r\n output.objects.push(...new handle_abap_1.HandleABAP(this.options).runObject(obj, reg));\r\n }\r\n else if (obj instanceof abaplint.Objects.Table) {\r\n output.objects.push(...new handle_table_1.HandleTable().runObject(obj, reg));\r\n }\r\n else if (obj instanceof abaplint.Objects.View) {\r\n output.objects.push(...new handle_view_1.HandleView().runObject(obj, reg));\r\n }\r\n else if (obj instanceof abaplint.Objects.LockObject) {\r\n output.objects.push(...new handle_enqu_1.HandleEnqu().runObject(obj, reg));\r\n }\r\n else if (obj instanceof abaplint.Objects.DataElement) {\r\n output.objects.push(...new handle_data_element_1.HandleDataElement().runObject(obj, reg));\r\n }\r\n else if (obj instanceof abaplint.Objects.TableType) {\r\n output.objects.push(...new handle_table_type_1.HandleTableType().runObject(obj, reg));\r\n }\r\n }\r\n return output;\r\n }\r\n // ///////////////////////////////\r\n validate(reg) {\r\n const issues = new validation_1.Validation(this.options).run(reg);\r\n if (issues.length > 0) {\r\n const messages = issues.map(i => i.getKey() + \", \" +\r\n i.getMessage() + \", \" +\r\n i.getFilename() + \":\" +\r\n i.getStart().getRow());\r\n throw new Error(messages.join(\"\\n\"));\r\n }\r\n }\r\n}\r\nexports.Transpiler = Transpiler;\r\n//# sourceMappingURL=index.js.map\n\n//# sourceURL=webpack://@abaplint/transpiler-cli/./node_modules/@abaplint/transpiler/build/src/index.js?");
14044
+ eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\nexports.Transpiler = exports.config = void 0;\r\nconst abaplint = __webpack_require__(/*! @abaplint/core */ \"./node_modules/@abaplint/core/build/src/index.js\");\r\nconst validation_1 = __webpack_require__(/*! ./validation */ \"./node_modules/@abaplint/transpiler/build/src/validation.js\");\r\nObject.defineProperty(exports, \"config\", ({ enumerable: true, get: function () { return validation_1.config; } }));\r\nconst unit_test_1 = __webpack_require__(/*! ./unit_test */ \"./node_modules/@abaplint/transpiler/build/src/unit_test.js\");\r\nconst keywords_1 = __webpack_require__(/*! ./keywords */ \"./node_modules/@abaplint/transpiler/build/src/keywords.js\");\r\nconst db_1 = __webpack_require__(/*! ./db */ \"./node_modules/@abaplint/transpiler/build/src/db/index.js\");\r\nconst handle_table_1 = __webpack_require__(/*! ./handlers/handle_table */ \"./node_modules/@abaplint/transpiler/build/src/handlers/handle_table.js\");\r\nconst handle_abap_1 = __webpack_require__(/*! ./handlers/handle_abap */ \"./node_modules/@abaplint/transpiler/build/src/handlers/handle_abap.js\");\r\nconst handle_data_element_1 = __webpack_require__(/*! ./handlers/handle_data_element */ \"./node_modules/@abaplint/transpiler/build/src/handlers/handle_data_element.js\");\r\nconst handle_table_type_1 = __webpack_require__(/*! ./handlers/handle_table_type */ \"./node_modules/@abaplint/transpiler/build/src/handlers/handle_table_type.js\");\r\nconst handle_view_1 = __webpack_require__(/*! ./handlers/handle_view */ \"./node_modules/@abaplint/transpiler/build/src/handlers/handle_view.js\");\r\nconst handle_enqu_1 = __webpack_require__(/*! ./handlers/handle_enqu */ \"./node_modules/@abaplint/transpiler/build/src/handlers/handle_enqu.js\");\r\nclass Transpiler {\r\n constructor(options) {\r\n this.options = options;\r\n if (this.options === undefined) {\r\n this.options = {};\r\n }\r\n if (this.options.unknownTypes === undefined) {\r\n this.options.unknownTypes = \"compileError\";\r\n }\r\n }\r\n // workaround for web/webpack\r\n async runRaw(files) {\r\n const memory = files.map(f => new abaplint.MemoryFile(f.filename, f.contents));\r\n const reg = new abaplint.Registry().addFiles(memory).parse();\r\n return new Transpiler().run(reg);\r\n }\r\n async run(reg, progress) {\r\n var _a, _b, _c, _d, _e, _f, _g;\r\n reg.parse();\r\n new keywords_1.Keywords((_a = this.options) === null || _a === void 0 ? void 0 : _a.keywords).handle(reg);\r\n this.validate(reg);\r\n const dbSetup = new db_1.DatabaseSetup(reg).run();\r\n const output = {\r\n objects: [],\r\n unitTestScript: new unit_test_1.UnitTest().unitTestScript(reg, (_b = this.options) === null || _b === void 0 ? void 0 : _b.skip, (_c = this.options) === null || _c === void 0 ? void 0 : _c.only),\r\n unitTestScriptOpen: new unit_test_1.UnitTest().unitTestScriptOpen(reg, (_d = this.options) === null || _d === void 0 ? void 0 : _d.skip, (_e = this.options) === null || _e === void 0 ? void 0 : _e.only),\r\n initializationScript: new unit_test_1.UnitTest().initializationScript(reg, dbSetup, (_f = this.options) === null || _f === void 0 ? void 0 : _f.extraSetup),\r\n initializationScript2: new unit_test_1.UnitTest().initializationScript(reg, dbSetup, (_g = this.options) === null || _g === void 0 ? void 0 : _g.extraSetup, true),\r\n databaseSetup: dbSetup,\r\n reg: reg,\r\n };\r\n progress === null || progress === void 0 ? void 0 : progress.set(reg.getObjectCount(false), \"Building, Syntax Logic\");\r\n for (const obj of reg.getObjects()) {\r\n await (progress === null || progress === void 0 ? void 0 : progress.tick(\"Building, Syntax Logic, \" + obj.getName()));\r\n if (obj instanceof abaplint.ABAPObject) {\r\n // todo, this is already done inside reg.parse()?\r\n new abaplint.SyntaxLogic(reg, obj).run();\r\n }\r\n }\r\n progress === null || progress === void 0 ? void 0 : progress.set(reg.getObjectCount(false), \"Building\");\r\n for (const obj of reg.getObjects()) {\r\n await (progress === null || progress === void 0 ? void 0 : progress.tick(\"Building, \" + obj.getName()));\r\n if (obj instanceof abaplint.ABAPObject && !(obj instanceof abaplint.Objects.TypePool)) {\r\n output.objects.push(...new handle_abap_1.HandleABAP(this.options).runObject(obj, reg));\r\n }\r\n else if (obj instanceof abaplint.Objects.Table) {\r\n output.objects.push(...new handle_table_1.HandleTable().runObject(obj, reg));\r\n }\r\n else if (obj instanceof abaplint.Objects.View) {\r\n output.objects.push(...new handle_view_1.HandleView().runObject(obj, reg));\r\n }\r\n else if (obj instanceof abaplint.Objects.LockObject) {\r\n output.objects.push(...new handle_enqu_1.HandleEnqu().runObject(obj, reg));\r\n }\r\n else if (obj instanceof abaplint.Objects.DataElement) {\r\n output.objects.push(...new handle_data_element_1.HandleDataElement().runObject(obj, reg));\r\n }\r\n else if (obj instanceof abaplint.Objects.TableType) {\r\n output.objects.push(...new handle_table_type_1.HandleTableType().runObject(obj, reg));\r\n }\r\n }\r\n return output;\r\n }\r\n // ///////////////////////////////\r\n validate(reg) {\r\n const issues = new validation_1.Validation(this.options).run(reg);\r\n if (issues.length > 0) {\r\n const messages = issues.map(i => i.getKey() + \", \" +\r\n i.getMessage() + \", \" +\r\n i.getFilename() + \":\" +\r\n i.getStart().getRow());\r\n throw new Error(messages.join(\"\\n\"));\r\n }\r\n }\r\n}\r\nexports.Transpiler = Transpiler;\r\n//# sourceMappingURL=index.js.map\n\n//# sourceURL=webpack://@abaplint/transpiler-cli/./node_modules/@abaplint/transpiler/build/src/index.js?");
14034
14045
 
14035
14046
  /***/ }),
14036
14047
 
@@ -14041,7 +14052,7 @@ eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\n
14041
14052
  /***/ ((__unused_webpack_module, exports, __webpack_require__) => {
14042
14053
 
14043
14054
  "use strict";
14044
- eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\nexports.Keywords = void 0;\r\nconst abaplint = __webpack_require__(/*! @abaplint/core */ \"./node_modules/@abaplint/core/build/src/index.js\");\r\n/** Replaces javascript keywords in ABAP source code, in-memory only */\r\nclass Keywords {\r\n handle(reg) {\r\n reg.parse();\r\n for (const o of reg.getObjects()) {\r\n if (!(o instanceof abaplint.ABAPObject)) {\r\n continue;\r\n }\r\n for (const f of o.getABAPFiles()) {\r\n const tokens = [];\r\n for (const s of f.getStatements()) {\r\n tokens.push(...this.traverse(s, f));\r\n }\r\n if (tokens.length === 0) {\r\n continue;\r\n }\r\n const rows = f.getRawRows();\r\n for (const t of tokens.reverse()) {\r\n const original = rows[t.getRow() - 1];\r\n const index = t.getEnd().getCol() - 1;\r\n rows[t.getRow() - 1] = original.substring(0, index) + \"_\" + original.substring(index);\r\n }\r\n reg.updateFile(new abaplint.MemoryFile(f.getFilename(), rows.join(\"\\n\")));\r\n }\r\n }\r\n reg.parse();\r\n }\r\n traverse(node, file) {\r\n // https://www.w3schools.com/js/js_reserved.asp\r\n const keywords = [\r\n \"abstract\", \"arguments\", \"await\",\r\n \"break\", \"byte\", \"catch\",\r\n \"char\", \"class\", \"const\", \"continue\",\r\n \"debugger\", \"default\", \"do\",\r\n \"double\", \"else\", \"enum\", \"eval\",\r\n \"export\", \"extends\", \"false\", \"final\",\r\n \"finally\", \"for\", \"function\",\r\n \"goto\", \"if\", \"implements\", \"import\",\r\n \"in\", \"instanceof\", \"interface\",\r\n \"let\", \"long\", \"native\", \"new\",\r\n \"null\", \"package\", \"private\",\r\n \"public\", \"return\", \"short\", \"static\",\r\n \"switch\", \"synchronized\", \"this\",\r\n \"throw\", \"throws\", \"transient\", \"true\",\r\n \"try\", \"typeof\", \"var\", \"void\",\r\n \"volatile\", \"while\", \"yield\"\r\n ];\r\n // \"with\"\r\n // \"delete\"\r\n const ret = [];\r\n for (const c of node.getChildren()) {\r\n if (c instanceof abaplint.Nodes.TokenNodeRegex) {\r\n const token = c.getFirstToken();\r\n const start = token.getStart();\r\n if (start instanceof abaplint.VirtualPosition) {\r\n continue;\r\n }\r\n for (const k of keywords) {\r\n const lower = token.getStr().toLowerCase();\r\n if (k === lower\r\n || \"!\" + k === lower\r\n || lower.endsWith(\"~\" + k)) {\r\n ret.push(token);\r\n break;\r\n }\r\n }\r\n }\r\n else if (c instanceof abaplint.Nodes.TokenNode) {\r\n continue;\r\n }\r\n else {\r\n ret.push(...this.traverse(c, file));\r\n }\r\n }\r\n return ret;\r\n }\r\n}\r\nexports.Keywords = Keywords;\r\n//# sourceMappingURL=keywords.js.map\n\n//# sourceURL=webpack://@abaplint/transpiler-cli/./node_modules/@abaplint/transpiler/build/src/keywords.js?");
14055
+ eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\nexports.Keywords = void 0;\r\nconst abaplint = __webpack_require__(/*! @abaplint/core */ \"./node_modules/@abaplint/core/build/src/index.js\");\r\n// https://www.w3schools.com/js/js_reserved.asp\r\nconst defaultKeywords = [\r\n \"abstract\", \"arguments\", \"await\",\r\n \"break\", \"byte\", \"catch\",\r\n \"char\", \"class\", \"const\", \"continue\",\r\n \"debugger\", \"default\", \"do\",\r\n \"double\", \"else\", \"enum\", \"eval\",\r\n \"export\", \"extends\", \"false\", \"final\",\r\n \"finally\", \"for\", \"function\",\r\n \"goto\", \"if\", \"implements\", \"import\",\r\n \"in\", \"instanceof\", \"interface\",\r\n \"let\", \"long\", \"native\", \"new\",\r\n \"null\", \"package\", \"private\",\r\n \"public\", \"return\", \"short\", \"static\",\r\n \"switch\", \"synchronized\", \"this\",\r\n \"throw\", \"throws\", \"transient\", \"true\",\r\n \"try\", \"typeof\", \"var\", \"void\",\r\n \"volatile\", \"while\", \"yield\"\r\n];\r\n// \"with\"\r\n// \"delete\"\r\n/** Replaces javascript keywords in ABAP source code, in-memory only */\r\nclass Keywords {\r\n constructor(keywords) {\r\n this.keywords = [];\r\n if (keywords !== undefined) {\r\n this.keywords = keywords;\r\n }\r\n else {\r\n this.keywords = defaultKeywords;\r\n }\r\n }\r\n handle(reg) {\r\n reg.parse();\r\n for (const o of reg.getObjects()) {\r\n if (!(o instanceof abaplint.ABAPObject)) {\r\n continue;\r\n }\r\n for (const f of o.getABAPFiles()) {\r\n const tokens = [];\r\n for (const s of f.getStatements()) {\r\n tokens.push(...this.traverse(s, f));\r\n }\r\n if (tokens.length === 0) {\r\n continue;\r\n }\r\n const rows = f.getRawRows();\r\n for (const t of tokens.reverse()) {\r\n const original = rows[t.getRow() - 1];\r\n const index = t.getEnd().getCol() - 1;\r\n rows[t.getRow() - 1] = original.substring(0, index) + \"_\" + original.substring(index);\r\n }\r\n reg.updateFile(new abaplint.MemoryFile(f.getFilename(), rows.join(\"\\n\")));\r\n }\r\n }\r\n reg.parse();\r\n }\r\n traverse(node, file) {\r\n const ret = [];\r\n for (const c of node.getChildren()) {\r\n if (c instanceof abaplint.Nodes.TokenNodeRegex) {\r\n const token = c.getFirstToken();\r\n const start = token.getStart();\r\n if (start instanceof abaplint.VirtualPosition) {\r\n continue;\r\n }\r\n for (const k of this.keywords) {\r\n const lower = token.getStr().toLowerCase();\r\n if (k === lower\r\n || \"!\" + k === lower\r\n || lower.endsWith(\"~\" + k)) {\r\n ret.push(token);\r\n break;\r\n }\r\n }\r\n }\r\n else if (c instanceof abaplint.Nodes.TokenNode) {\r\n continue;\r\n }\r\n else {\r\n ret.push(...this.traverse(c, file));\r\n }\r\n }\r\n return ret;\r\n }\r\n}\r\nexports.Keywords = Keywords;\r\n//# sourceMappingURL=keywords.js.map\n\n//# sourceURL=webpack://@abaplint/transpiler-cli/./node_modules/@abaplint/transpiler/build/src/keywords.js?");
14045
14056
 
14046
14057
  /***/ }),
14047
14058
 
@@ -14932,7 +14943,7 @@ eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\n
14932
14943
  /***/ ((__unused_webpack_module, exports, __webpack_require__) => {
14933
14944
 
14934
14945
  "use strict";
14935
- eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\nexports.MethodImplementationTranspiler = void 0;\r\nconst abaplint = __webpack_require__(/*! @abaplint/core */ \"./node_modules/@abaplint/core/build/src/index.js\");\r\nconst transpile_types_1 = __webpack_require__(/*! ../transpile_types */ \"./node_modules/@abaplint/transpiler/build/src/transpile_types.js\");\r\nconst traversal_1 = __webpack_require__(/*! ../traversal */ \"./node_modules/@abaplint/transpiler/build/src/traversal.js\");\r\nconst expressions_1 = __webpack_require__(/*! ../expressions */ \"./node_modules/@abaplint/transpiler/build/src/expressions/index.js\");\r\nconst chunk_1 = __webpack_require__(/*! ../chunk */ \"./node_modules/@abaplint/transpiler/build/src/chunk.js\");\r\nconst unique_identifier_1 = __webpack_require__(/*! ../unique_identifier */ \"./node_modules/@abaplint/transpiler/build/src/unique_identifier.js\");\r\nclass MethodImplementationTranspiler {\r\n transpile(node, traversal) {\r\n var _a, _b;\r\n const token = node.findFirstExpression(abaplint.Expressions.MethodName).getFirstToken();\r\n let methodName = token.getStr();\r\n const scope = traversal.findCurrentScopeByToken(token);\r\n if (scope === undefined) {\r\n throw new Error(\"MethodTranspiler, scope not found, \" + methodName);\r\n }\r\n else if (scope.getIdentifier().sname !== methodName) {\r\n throw new Error(\"MethodTranspiler, wrong scope found, \" + scope.getIdentifier().sname);\r\n }\r\n let after = \"\";\r\n const classDef = traversal.getClassDefinition(token);\r\n let unique = \"\";\r\n if (methodName.toUpperCase() === \"CONSTRUCTOR\" && classDef) {\r\n // note that all ABAP identifiers are lower cased, sometimes the kernel does magic, so it needs to know the method input name\r\n unique = \"INPUT\";\r\n after = traversal.buildConstructorContents(scope.getParent(), classDef);\r\n methodName = \"constructor_\";\r\n }\r\n const methodDef = this.findMethodParameters(scope);\r\n const vars = scope.getData().vars;\r\n for (const n in vars) {\r\n const identifier = vars[n];\r\n const varName = n.toLowerCase();\r\n if (identifier.getMeta().includes(\"importing\" /* abaplint.IdentifierMeta.MethodImporting */)\r\n || identifier.getMeta().includes(\"changing\" /* abaplint.IdentifierMeta.MethodChanging */)\r\n || identifier.getMeta().includes(\"exporting\" /* abaplint.IdentifierMeta.MethodExporting */)) {\r\n if (unique === \"\") {\r\n unique = \"INPUT\";\r\n }\r\n after = after + new transpile_types_1.TranspileTypes().declare(identifier) + \"\\n\";\r\n const type = identifier.getType();\r\n const charOne = type instanceof abaplint.BasicTypes.CharacterType && type.getLength() === 1;\r\n if (identifier.getMeta().includes(\"importing\" /* abaplint.IdentifierMeta.MethodImporting */)\r\n && type.isGeneric() === false\r\n && charOne === false) {\r\n after += \"if (\" + unique + \" && \" + unique + \".\" + varName + \") {\" + varName + \".set(\" + unique + \".\" + varName + \");}\\n\";\r\n }\r\n else {\r\n after += \"if (\" + unique + \" && \" + unique + \".\" + varName + \") {\" + varName + \" = \" + unique + \".\" + varName + \";}\\n\";\r\n }\r\n const parameterDefault = methodDef === null || methodDef === void 0 ? void 0 : methodDef.getParameterDefault(varName);\r\n if (parameterDefault) {\r\n let val = \"\";\r\n if (parameterDefault.get() instanceof abaplint.Expressions.Constant) {\r\n val = new expressions_1.ConstantTranspiler().transpile(parameterDefault, traversal).getCode();\r\n }\r\n else if (parameterDefault.get() instanceof abaplint.Expressions.FieldChain) {\r\n if (parameterDefault.getFirstToken().getStr().toLowerCase() === \"abap_true\") {\r\n val = \"abap.builtin.abap_true\";\r\n }\r\n else if (parameterDefault.getFirstToken().getStr().toLowerCase() === \"abap_false\") {\r\n val = \"abap.builtin.abap_false\";\r\n }\r\n else if (parameterDefault.getFirstToken().getStr().toLowerCase() === \"space\") {\r\n val = \"abap.builtin.space\";\r\n }\r\n else if (parameterDefault.concatTokens().toLowerCase() === \"sy-uname\") {\r\n val = \"abap.builtin.sy.get().uname\";\r\n }\r\n else {\r\n // note: this can be difficult, the \"def\" might be from an interface, ie. a different scope than the method\r\n val = new expressions_1.FieldChainTranspiler().transpile(parameterDefault, traversal, true, methodDef === null || methodDef === void 0 ? void 0 : methodDef.getFilename()).getCode();\r\n if (val.startsWith(parameterDefault.getFirstToken().getStr().toLowerCase()) === true) {\r\n val = \"this.\" + val;\r\n }\r\n }\r\n }\r\n else {\r\n throw new Error(\"MethodImplementationTranspiler, unknown default param type\");\r\n }\r\n after += \"if (\" + unique + \" === undefined || \" + unique + \".\" + varName + \" === undefined) {\" + varName + \" = \" + val + \";}\\n\";\r\n }\r\n }\r\n else if (identifier.getMeta().includes(\"returning\" /* abaplint.IdentifierMeta.MethodReturning */)) {\r\n after = after + new transpile_types_1.TranspileTypes().declare(identifier) + \"\\n\";\r\n }\r\n }\r\n if (after.length > 0) { // argh\r\n after = \"\\n\" + after;\r\n after = after.substring(0, after.length - 1);\r\n }\r\n const method = this.findMethod(methodName, classDef, traversal);\r\n let staticMethod = \"\";\r\n methodName = methodName.replace(\"~\", \"$\").toLowerCase();\r\n const superDef = traversal.findClassDefinition(classDef === null || classDef === void 0 ? void 0 : classDef.getSuperClass(), scope);\r\n for (const a of (superDef === null || superDef === void 0 ? void 0 : superDef.getAliases().getAll()) || []) {\r\n if (a.getName().toLowerCase() === methodName) {\r\n methodName = a.getComponent().replace(\"~\", \"$\").toLowerCase();\r\n }\r\n }\r\n if (method && method.isStatic()) {\r\n // in ABAP static methods can be called with instance arrows, \"->\"\r\n const className = (_b = (_a = scope.getParent()) === null || _a === void 0 ? void 0 : _a.getIdentifier().sname) === null || _b === void 0 ? void 0 : _b.toLowerCase();\r\n staticMethod = \"async \" + traversal_1.Traversal.escapeClassName(methodName) + \"(\" + unique + \") {\\n\" +\r\n \"return \" + traversal_1.Traversal.escapeClassName(className) + \".\" + traversal_1.Traversal.escapeClassName(methodName) + \"(\" + unique + \");\\n\" +\r\n \"}\\n\" + \"static \";\r\n }\r\n unique_identifier_1.UniqueIdentifier.resetIndexBackup();\r\n const str = staticMethod + \"async \" + traversal_1.Traversal.escapeClassName(methodName) + \"(\" + unique + \") {\" + after;\r\n return new chunk_1.Chunk().append(str, node, traversal);\r\n }\r\n /////////////////////////////\r\n findMethod(name, cdef, traversal) {\r\n var _a, _b;\r\n if (cdef === undefined) {\r\n return undefined;\r\n }\r\n if (name.includes(\"~\")) {\r\n const split = name.split(\"~\");\r\n const intfName = split[0];\r\n name = split[1];\r\n const scope = traversal.findCurrentScopeByToken(cdef.getToken());\r\n const intf = traversal.findInterfaceDefinition(intfName, scope);\r\n return (_a = intf === null || intf === void 0 ? void 0 : intf.getMethodDefinitions()) === null || _a === void 0 ? void 0 : _a.getByName(name);\r\n }\r\n else {\r\n return (_b = cdef.getMethodDefinitions()) === null || _b === void 0 ? void 0 : _b.getByName(name);\r\n }\r\n }\r\n findMethodParameters(scope) {\r\n for (const r of scope.getData().references) {\r\n if (r.referenceType === abaplint.ReferenceType.MethodImplementationReference\r\n && r.resolved instanceof abaplint.Types.MethodDefinition) {\r\n return r.resolved.getParameters();\r\n }\r\n }\r\n return undefined;\r\n }\r\n}\r\nexports.MethodImplementationTranspiler = MethodImplementationTranspiler;\r\n//# sourceMappingURL=method_implementation.js.map\n\n//# sourceURL=webpack://@abaplint/transpiler-cli/./node_modules/@abaplint/transpiler/build/src/statements/method_implementation.js?");
14946
+ eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\nexports.MethodImplementationTranspiler = void 0;\r\nconst abaplint = __webpack_require__(/*! @abaplint/core */ \"./node_modules/@abaplint/core/build/src/index.js\");\r\nconst transpile_types_1 = __webpack_require__(/*! ../transpile_types */ \"./node_modules/@abaplint/transpiler/build/src/transpile_types.js\");\r\nconst traversal_1 = __webpack_require__(/*! ../traversal */ \"./node_modules/@abaplint/transpiler/build/src/traversal.js\");\r\nconst expressions_1 = __webpack_require__(/*! ../expressions */ \"./node_modules/@abaplint/transpiler/build/src/expressions/index.js\");\r\nconst chunk_1 = __webpack_require__(/*! ../chunk */ \"./node_modules/@abaplint/transpiler/build/src/chunk.js\");\r\nconst unique_identifier_1 = __webpack_require__(/*! ../unique_identifier */ \"./node_modules/@abaplint/transpiler/build/src/unique_identifier.js\");\r\nclass MethodImplementationTranspiler {\r\n transpile(node, traversal) {\r\n var _a, _b;\r\n const token = node.findFirstExpression(abaplint.Expressions.MethodName).getFirstToken();\r\n let methodName = token.getStr();\r\n const scope = traversal.findCurrentScopeByToken(token);\r\n if (scope === undefined) {\r\n throw new Error(\"MethodTranspiler, scope not found, \" + methodName);\r\n }\r\n else if (scope.getIdentifier().sname !== methodName) {\r\n throw new Error(\"MethodTranspiler, wrong scope found, \" + scope.getIdentifier().sname);\r\n }\r\n let after = \"\";\r\n const classDef = traversal.getClassDefinition(token);\r\n let unique = \"\";\r\n if (methodName.toUpperCase() === \"CONSTRUCTOR\" && classDef) {\r\n // note that all ABAP identifiers are lower cased, sometimes the kernel does magic, so it needs to know the method input name\r\n unique = \"INPUT\";\r\n after = traversal.buildConstructorContents(scope.getParent(), classDef);\r\n methodName = \"constructor_\";\r\n }\r\n const methodDef = this.findMethodParameters(scope);\r\n const vars = scope.getData().vars;\r\n for (const n in vars) {\r\n const identifier = vars[n];\r\n const varName = n.toLowerCase();\r\n if (identifier.getMeta().includes(\"importing\" /* abaplint.IdentifierMeta.MethodImporting */)\r\n || identifier.getMeta().includes(\"changing\" /* abaplint.IdentifierMeta.MethodChanging */)\r\n || identifier.getMeta().includes(\"exporting\" /* abaplint.IdentifierMeta.MethodExporting */)) {\r\n if (unique === \"\") {\r\n unique = \"INPUT\";\r\n }\r\n after = after + new transpile_types_1.TranspileTypes().declare(identifier) + \"\\n\";\r\n const type = identifier.getType();\r\n const charOne = type instanceof abaplint.BasicTypes.CharacterType && type.getLength() === 1;\r\n if (identifier.getMeta().includes(\"importing\" /* abaplint.IdentifierMeta.MethodImporting */)\r\n && type.isGeneric() === false\r\n && charOne === false) {\r\n after += \"if (\" + unique + \" && \" + unique + \".\" + varName + \") {\" + varName + \".set(\" + unique + \".\" + varName + \");}\\n\";\r\n }\r\n else {\r\n after += \"if (\" + unique + \" && \" + unique + \".\" + varName + \") {\" + varName + \" = \" + unique + \".\" + varName + \";}\\n\";\r\n }\r\n const parameterDefault = methodDef === null || methodDef === void 0 ? void 0 : methodDef.getParameterDefault(varName);\r\n if (parameterDefault) {\r\n let val = \"\";\r\n if (parameterDefault.get() instanceof abaplint.Expressions.Constant) {\r\n val = new expressions_1.ConstantTranspiler().transpile(parameterDefault, traversal).getCode();\r\n }\r\n else if (parameterDefault.get() instanceof abaplint.Expressions.FieldChain) {\r\n if (parameterDefault.getFirstToken().getStr().toLowerCase() === \"abap_true\") {\r\n val = \"abap.builtin.abap_true\";\r\n }\r\n else if (parameterDefault.getFirstToken().getStr().toLowerCase() === \"abap_false\") {\r\n val = \"abap.builtin.abap_false\";\r\n }\r\n else if (parameterDefault.getFirstToken().getStr().toLowerCase() === \"space\") {\r\n val = \"abap.builtin.space\";\r\n }\r\n else if (parameterDefault.concatTokens().toLowerCase() === \"sy-langu\") {\r\n val = \"abap.builtin.sy.get().langu\";\r\n }\r\n else if (parameterDefault.concatTokens().toLowerCase() === \"sy-uname\") {\r\n val = \"abap.builtin.sy.get().uname\";\r\n }\r\n else {\r\n // note: this can be difficult, the \"def\" might be from an interface, ie. a different scope than the method\r\n val = new expressions_1.FieldChainTranspiler().transpile(parameterDefault, traversal, true, methodDef === null || methodDef === void 0 ? void 0 : methodDef.getFilename()).getCode();\r\n if (val.startsWith(parameterDefault.getFirstToken().getStr().toLowerCase()) === true) {\r\n val = \"this.\" + val;\r\n }\r\n }\r\n }\r\n else {\r\n throw new Error(\"MethodImplementationTranspiler, unknown default param type\");\r\n }\r\n after += \"if (\" + unique + \" === undefined || \" + unique + \".\" + varName + \" === undefined) {\" + varName + \" = \" + val + \";}\\n\";\r\n }\r\n }\r\n else if (identifier.getMeta().includes(\"returning\" /* abaplint.IdentifierMeta.MethodReturning */)) {\r\n after = after + new transpile_types_1.TranspileTypes().declare(identifier) + \"\\n\";\r\n }\r\n }\r\n if (after.length > 0) { // argh\r\n after = \"\\n\" + after;\r\n after = after.substring(0, after.length - 1);\r\n }\r\n const method = this.findMethod(methodName, classDef, traversal);\r\n let staticMethod = \"\";\r\n methodName = methodName.replace(\"~\", \"$\").toLowerCase();\r\n const superDef = traversal.findClassDefinition(classDef === null || classDef === void 0 ? void 0 : classDef.getSuperClass(), scope);\r\n for (const a of (superDef === null || superDef === void 0 ? void 0 : superDef.getAliases().getAll()) || []) {\r\n if (a.getName().toLowerCase() === methodName) {\r\n methodName = a.getComponent().replace(\"~\", \"$\").toLowerCase();\r\n }\r\n }\r\n if (method && method.isStatic()) {\r\n // in ABAP static methods can be called with instance arrows, \"->\"\r\n const className = (_b = (_a = scope.getParent()) === null || _a === void 0 ? void 0 : _a.getIdentifier().sname) === null || _b === void 0 ? void 0 : _b.toLowerCase();\r\n staticMethod = \"async \" + traversal_1.Traversal.escapeClassName(methodName) + \"(\" + unique + \") {\\n\" +\r\n \"return \" + traversal_1.Traversal.escapeClassName(className) + \".\" + traversal_1.Traversal.escapeClassName(methodName) + \"(\" + unique + \");\\n\" +\r\n \"}\\n\" + \"static \";\r\n }\r\n unique_identifier_1.UniqueIdentifier.resetIndexBackup();\r\n const str = staticMethod + \"async \" + traversal_1.Traversal.escapeClassName(methodName) + \"(\" + unique + \") {\" + after;\r\n return new chunk_1.Chunk().append(str, node, traversal);\r\n }\r\n /////////////////////////////\r\n findMethod(name, cdef, traversal) {\r\n var _a, _b;\r\n if (cdef === undefined) {\r\n return undefined;\r\n }\r\n if (name.includes(\"~\")) {\r\n const split = name.split(\"~\");\r\n const intfName = split[0];\r\n name = split[1];\r\n const scope = traversal.findCurrentScopeByToken(cdef.getToken());\r\n const intf = traversal.findInterfaceDefinition(intfName, scope);\r\n return (_a = intf === null || intf === void 0 ? void 0 : intf.getMethodDefinitions()) === null || _a === void 0 ? void 0 : _a.getByName(name);\r\n }\r\n else {\r\n return (_b = cdef.getMethodDefinitions()) === null || _b === void 0 ? void 0 : _b.getByName(name);\r\n }\r\n }\r\n findMethodParameters(scope) {\r\n for (const r of scope.getData().references) {\r\n if (r.referenceType === abaplint.ReferenceType.MethodImplementationReference\r\n && r.resolved instanceof abaplint.Types.MethodDefinition) {\r\n return r.resolved.getParameters();\r\n }\r\n }\r\n return undefined;\r\n }\r\n}\r\nexports.MethodImplementationTranspiler = MethodImplementationTranspiler;\r\n//# sourceMappingURL=method_implementation.js.map\n\n//# sourceURL=webpack://@abaplint/transpiler-cli/./node_modules/@abaplint/transpiler/build/src/statements/method_implementation.js?");
14936
14947
 
14937
14948
  /***/ }),
14938
14949
 
@@ -15207,7 +15218,7 @@ eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\n
15207
15218
  /***/ ((__unused_webpack_module, exports, __webpack_require__) => {
15208
15219
 
15209
15220
  "use strict";
15210
- eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\nexports.SelectTranspiler = void 0;\r\nconst abaplint = __webpack_require__(/*! @abaplint/core */ \"./node_modules/@abaplint/core/build/src/index.js\");\r\nconst chunk_1 = __webpack_require__(/*! ../chunk */ \"./node_modules/@abaplint/transpiler/build/src/chunk.js\");\r\nconst expressions_1 = __webpack_require__(/*! ../expressions */ \"./node_modules/@abaplint/transpiler/build/src/expressions/index.js\");\r\nconst unique_identifier_1 = __webpack_require__(/*! ../unique_identifier */ \"./node_modules/@abaplint/transpiler/build/src/unique_identifier.js\");\r\nconst sql_from_1 = __webpack_require__(/*! ../expressions/sql_from */ \"./node_modules/@abaplint/transpiler/build/src/expressions/sql_from.js\");\r\nclass SelectTranspiler {\r\n transpile(node, traversal, targetOverride) {\r\n var _a, _b, _c;\r\n let target = \"undefined\";\r\n if (targetOverride) {\r\n target = targetOverride;\r\n }\r\n else if (node.findFirstExpression(abaplint.Expressions.Target)) {\r\n target = traversal.traverse(node.findFirstExpression(abaplint.Expressions.Target)).getCode();\r\n }\r\n let select = \"SELECT \";\r\n const fieldList = node.findFirstExpression(abaplint.Expressions.SQLFieldList)\r\n || node.findFirstExpression(abaplint.Expressions.SQLFieldListLoop);\r\n if ((fieldList === null || fieldList === void 0 ? void 0 : fieldList.getChildren().length) === 1) {\r\n select += fieldList.concatTokens();\r\n }\r\n else {\r\n // add commas between field names, this is required for SQLite, and easy to remove in other clients?\r\n select += fieldList === null || fieldList === void 0 ? void 0 : fieldList.findAllExpressions(abaplint.Expressions.SQLField).map(e => e.concatTokens()).join(\", \");\r\n }\r\n select += \" \";\r\n const from = node.findFirstExpression(abaplint.Expressions.SQLFrom);\r\n if (from) {\r\n select += new sql_from_1.SQLFromTranspiler().transpile(from, traversal).getCode();\r\n }\r\n let where = undefined;\r\n for (const sqlCond of node.findAllExpressions(abaplint.Expressions.SQLCond)) {\r\n if (this.isWhereExpression(node, sqlCond)) {\r\n where = sqlCond;\r\n }\r\n }\r\n if (where) {\r\n select += \"WHERE \" + traversal.traverse(where).getCode() + \" \";\r\n }\r\n const upTo = node.findFirstExpression(abaplint.Expressions.SQLUpTo);\r\n if (upTo) {\r\n const s = upTo.findFirstExpression(abaplint.Expressions.SimpleSource3);\r\n if (s) {\r\n select += `UP TO \" + ${new expressions_1.SourceTranspiler(true).transpile(s, traversal).getCode()} + \" ROWS `;\r\n }\r\n else {\r\n select += upTo.concatTokens() + \" \";\r\n }\r\n }\r\n const orderBy = node.findFirstExpression(abaplint.Expressions.SQLOrderBy);\r\n if (orderBy) {\r\n select += orderBy.concatTokens() + \" \";\r\n }\r\n for (const d of node.findAllExpressionsRecursive(abaplint.Expressions.Dynamic)) {\r\n const chain = d.findFirstExpression(abaplint.Expressions.FieldChain);\r\n if (chain) {\r\n const code = new expressions_1.FieldChainTranspiler(true).transpile(chain, traversal).getCode();\r\n const search = d.concatTokens();\r\n select = select.replace(search, `\" + ${code} + \"`);\r\n }\r\n }\r\n if (node.concatTokens().toUpperCase().startsWith(\"SELECT SINGLE \")) {\r\n select += \"UP TO 1 ROWS\";\r\n }\r\n let runtimeOptions = \"\";\r\n if (node.concatTokens().toUpperCase().includes(\" APPENDING TABLE \")) {\r\n runtimeOptions = `, {appending: true}`;\r\n }\r\n let extra = \"\";\r\n const keys = this.findKeys(node, traversal);\r\n if (keys.length > 0) {\r\n extra = `, primaryKey: ${JSON.stringify(keys)}`;\r\n }\r\n if (node.findFirstExpression(abaplint.Expressions.SQLForAllEntries)) {\r\n const unique = unique_identifier_1.UniqueIdentifier.get();\r\n const faeName = (_c = (_b = (_a = node.findFirstExpression(abaplint.Expressions.SQLForAllEntries)) === null || _a === void 0 ? void 0 : _a.findDirectExpression(abaplint.Expressions.SQLSource)) === null || _b === void 0 ? void 0 : _b.concatTokens()) === null || _c === void 0 ? void 0 : _c.toLowerCase();\r\n select = select.replace(new RegExp(\" \" + faeName, \"g\"), \" \" + unique);\r\n select = select.replace(unique + \".get().table_line.get()\", unique + \".get()\"); // there can be only one?\r\n const code = `if (${faeName}.array().length === 0) {\r\n throw \"FAE, todo, empty table\";\r\n} else {\r\n abap.statements.clear(${target});\r\n for await (const ${unique} of abap.statements.loop(${faeName})) {\r\n await abap.statements.select(${target}, {select: \"${select.trim()}\"${extra}}, {appending: true});\r\n }\r\n abap.builtin.sy.get().dbcnt.set(${target}.array().length);\r\n}`;\r\n return new chunk_1.Chunk().append(code, node, traversal);\r\n }\r\n else {\r\n return new chunk_1.Chunk().append(`await abap.statements.select(${target}, {select: \"${select.trim()}\"${extra}}${runtimeOptions});`, node, traversal);\r\n }\r\n }\r\n findKeys(node, traversal) {\r\n let keys = [];\r\n const from = node.findAllExpressions(abaplint.Expressions.SQLFromSource).map(e => e.concatTokens());\r\n if (from.length === 1) {\r\n const tabl = traversal.findTable(from[0]);\r\n if (tabl) {\r\n keys = tabl.listKeys(traversal.reg).map(k => k.toLowerCase());\r\n }\r\n }\r\n return keys;\r\n }\r\n isWhereExpression(node, expression) {\r\n // check if previous token before sqlCond is \"WHERE\". It could also be \"ON\" in case of join condition\r\n let prevToken;\r\n const sqlCondToken = expression.getFirstToken();\r\n for (const token of node.getTokens()) {\r\n if (token.getStart() === sqlCondToken.getStart()) {\r\n break;\r\n }\r\n prevToken = token;\r\n }\r\n if (prevToken && prevToken.getStr() === \"WHERE\") {\r\n return true;\r\n }\r\n else {\r\n return false;\r\n }\r\n }\r\n}\r\nexports.SelectTranspiler = SelectTranspiler;\r\n//# sourceMappingURL=select.js.map\n\n//# sourceURL=webpack://@abaplint/transpiler-cli/./node_modules/@abaplint/transpiler/build/src/statements/select.js?");
15221
+ eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\nexports.SelectTranspiler = void 0;\r\nconst abaplint = __webpack_require__(/*! @abaplint/core */ \"./node_modules/@abaplint/core/build/src/index.js\");\r\nconst chunk_1 = __webpack_require__(/*! ../chunk */ \"./node_modules/@abaplint/transpiler/build/src/chunk.js\");\r\nconst expressions_1 = __webpack_require__(/*! ../expressions */ \"./node_modules/@abaplint/transpiler/build/src/expressions/index.js\");\r\nconst unique_identifier_1 = __webpack_require__(/*! ../unique_identifier */ \"./node_modules/@abaplint/transpiler/build/src/unique_identifier.js\");\r\nconst sql_from_1 = __webpack_require__(/*! ../expressions/sql_from */ \"./node_modules/@abaplint/transpiler/build/src/expressions/sql_from.js\");\r\nclass SelectTranspiler {\r\n transpile(node, traversal, targetOverride) {\r\n var _a;\r\n let target = \"undefined\";\r\n if (targetOverride) {\r\n target = targetOverride;\r\n }\r\n else if (node.findFirstExpression(abaplint.Expressions.Target)) {\r\n target = traversal.traverse(node.findFirstExpression(abaplint.Expressions.Target)).getCode();\r\n }\r\n let select = \"SELECT \";\r\n const fieldList = node.findFirstExpression(abaplint.Expressions.SQLFieldList)\r\n || node.findFirstExpression(abaplint.Expressions.SQLFieldListLoop);\r\n if ((fieldList === null || fieldList === void 0 ? void 0 : fieldList.getChildren().length) === 1) {\r\n select += fieldList.concatTokens();\r\n }\r\n else {\r\n // add commas between field names, this is required for SQLite, and easy to remove in other clients?\r\n select += fieldList === null || fieldList === void 0 ? void 0 : fieldList.findAllExpressions(abaplint.Expressions.SQLField).map(e => e.concatTokens()).join(\", \");\r\n }\r\n select += \" \";\r\n const from = node.findFirstExpression(abaplint.Expressions.SQLFrom);\r\n if (from) {\r\n select += new sql_from_1.SQLFromTranspiler().transpile(from, traversal).getCode();\r\n }\r\n let where = undefined;\r\n for (const sqlCond of node.findAllExpressions(abaplint.Expressions.SQLCond)) {\r\n if (this.isWhereExpression(node, sqlCond)) {\r\n where = sqlCond;\r\n }\r\n }\r\n if (where) {\r\n select += \"WHERE \" + traversal.traverse(where).getCode() + \" \";\r\n }\r\n const upTo = node.findFirstExpression(abaplint.Expressions.SQLUpTo);\r\n if (upTo) {\r\n const s = upTo.findFirstExpression(abaplint.Expressions.SimpleSource3);\r\n if (s) {\r\n select += `UP TO \" + ${new expressions_1.SourceTranspiler(true).transpile(s, traversal).getCode()} + \" ROWS `;\r\n }\r\n else {\r\n select += upTo.concatTokens() + \" \";\r\n }\r\n }\r\n const orderBy = node.findFirstExpression(abaplint.Expressions.SQLOrderBy);\r\n if (orderBy) {\r\n select += orderBy.concatTokens() + \" \";\r\n }\r\n for (const d of node.findAllExpressionsRecursive(abaplint.Expressions.Dynamic)) {\r\n const chain = d.findFirstExpression(abaplint.Expressions.FieldChain);\r\n if (chain) {\r\n const code = new expressions_1.FieldChainTranspiler(true).transpile(chain, traversal).getCode();\r\n const search = d.concatTokens();\r\n select = select.replace(search, `\" + ${code} + \"`);\r\n }\r\n }\r\n if (node.concatTokens().toUpperCase().startsWith(\"SELECT SINGLE \")) {\r\n select += \"UP TO 1 ROWS\";\r\n }\r\n let runtimeOptions = \"\";\r\n if (node.concatTokens().toUpperCase().includes(\" APPENDING TABLE \")) {\r\n runtimeOptions = `, {appending: true}`;\r\n }\r\n let extra = \"\";\r\n const keys = this.findKeys(node, traversal);\r\n if (keys.length > 0) {\r\n extra = `, primaryKey: ${JSON.stringify(keys)}`;\r\n }\r\n if (node.findFirstExpression(abaplint.Expressions.SQLForAllEntries)) {\r\n const unique = unique_identifier_1.UniqueIdentifier.get();\r\n const fn = (_a = node.findFirstExpression(abaplint.Expressions.SQLForAllEntries)) === null || _a === void 0 ? void 0 : _a.findDirectExpression(abaplint.Expressions.SQLSource);\r\n const faeTranspiled = new expressions_1.SQLSourceTranspiler().transpile(fn, traversal).getCode();\r\n select = select.replace(new RegExp(\" \" + faeTranspiled, \"g\"), \" \" + unique);\r\n select = select.replace(unique + \".get().table_line.get()\", unique + \".get()\"); // there can be only one?\r\n const code = `if (${faeTranspiled}.array().length === 0) {\r\n throw \"FAE, todo, empty table\";\r\n} else {\r\n abap.statements.clear(${target});\r\n for await (const ${unique} of abap.statements.loop(${faeTranspiled})) {\r\n await abap.statements.select(${target}, {select: \"${select.trim()}\"${extra}}, {appending: true});\r\n }\r\n abap.builtin.sy.get().dbcnt.set(${target}.array().length);\r\n}`;\r\n return new chunk_1.Chunk().append(code, node, traversal);\r\n }\r\n else {\r\n return new chunk_1.Chunk().append(`await abap.statements.select(${target}, {select: \"${select.trim()}\"${extra}}${runtimeOptions});`, node, traversal);\r\n }\r\n }\r\n findKeys(node, traversal) {\r\n let keys = [];\r\n const from = node.findAllExpressions(abaplint.Expressions.SQLFromSource).map(e => e.concatTokens());\r\n if (from.length === 1) {\r\n const tabl = traversal.findTable(from[0]);\r\n if (tabl) {\r\n keys = tabl.listKeys(traversal.reg).map(k => k.toLowerCase());\r\n }\r\n }\r\n return keys;\r\n }\r\n isWhereExpression(node, expression) {\r\n // check if previous token before sqlCond is \"WHERE\". It could also be \"ON\" in case of join condition\r\n let prevToken;\r\n const sqlCondToken = expression.getFirstToken();\r\n for (const token of node.getTokens()) {\r\n if (token.getStart() === sqlCondToken.getStart()) {\r\n break;\r\n }\r\n prevToken = token;\r\n }\r\n if (prevToken && prevToken.getStr() === \"WHERE\") {\r\n return true;\r\n }\r\n else {\r\n return false;\r\n }\r\n }\r\n}\r\nexports.SelectTranspiler = SelectTranspiler;\r\n//# sourceMappingURL=select.js.map\n\n//# sourceURL=webpack://@abaplint/transpiler-cli/./node_modules/@abaplint/transpiler/build/src/statements/select.js?");
15211
15222
 
15212
15223
  /***/ }),
15213
15224
 
@@ -15625,7 +15636,7 @@ eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\n
15625
15636
  /***/ ((__unused_webpack_module, exports, __webpack_require__) => {
15626
15637
 
15627
15638
  "use strict";
15628
- eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\nexports.SelectTranspiler = void 0;\r\nconst abaplint = __webpack_require__(/*! @abaplint/core */ \"./node_modules/@abaplint/core/build/src/index.js\");\r\nconst select_1 = __webpack_require__(/*! ../statements/select */ \"./node_modules/@abaplint/transpiler/build/src/statements/select.js\");\r\nconst chunk_1 = __webpack_require__(/*! ../chunk */ \"./node_modules/@abaplint/transpiler/build/src/chunk.js\");\r\nconst unique_identifier_1 = __webpack_require__(/*! ../unique_identifier */ \"./node_modules/@abaplint/transpiler/build/src/unique_identifier.js\");\r\nclass SelectTranspiler {\r\n transpile(node, traversal) {\r\n var _a, _b;\r\n const ret = new chunk_1.Chunk();\r\n const selectStatement = node.findFirstStatement(abaplint.Statements.SelectLoop);\r\n if (selectStatement === undefined) {\r\n throw \"Structure, select loop not found\";\r\n }\r\n const from = (_a = selectStatement.findFirstExpression(abaplint.Expressions.SQLFromSource)) === null || _a === void 0 ? void 0 : _a.concatTokens().toUpperCase();\r\n const intoName = (_b = selectStatement.findFirstExpression(abaplint.Expressions.SQLTarget)) === null || _b === void 0 ? void 0 : _b.concatTokens();\r\n // note: this implementation SELECTs everything into memory, which might be bad, and sometimes not correct\r\n const targetName = unique_identifier_1.UniqueIdentifier.get();\r\n const loopName = unique_identifier_1.UniqueIdentifier.get();\r\n ret.appendString(`let ${targetName} = new abap.types.Table(abap.DDIC[\"${from}\"].type);\\n`);\r\n ret.appendChunk(new select_1.SelectTranspiler().transpile(selectStatement, traversal, targetName));\r\n ret.appendString(`\\nfor (const ${loopName} of ${targetName}.array()) {\\n`);\r\n ret.appendString(`${intoName === null || intoName === void 0 ? void 0 : intoName.replace(\"-\", \".get().\")}.set(${loopName});\\n`);\r\n const body = node.findDirectStructure(abaplint.Structures.Body);\r\n if (body) {\r\n ret.appendChunk(traversal.traverse(body));\r\n }\r\n ret.appendString(\"}\\n\");\r\n return ret;\r\n }\r\n}\r\nexports.SelectTranspiler = SelectTranspiler;\r\n//# sourceMappingURL=select.js.map\n\n//# sourceURL=webpack://@abaplint/transpiler-cli/./node_modules/@abaplint/transpiler/build/src/structures/select.js?");
15639
+ eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\nexports.SelectTranspiler = void 0;\r\nconst abaplint = __webpack_require__(/*! @abaplint/core */ \"./node_modules/@abaplint/core/build/src/index.js\");\r\nconst select_1 = __webpack_require__(/*! ../statements/select */ \"./node_modules/@abaplint/transpiler/build/src/statements/select.js\");\r\nconst chunk_1 = __webpack_require__(/*! ../chunk */ \"./node_modules/@abaplint/transpiler/build/src/chunk.js\");\r\nconst unique_identifier_1 = __webpack_require__(/*! ../unique_identifier */ \"./node_modules/@abaplint/transpiler/build/src/unique_identifier.js\");\r\nconst expressions_1 = __webpack_require__(/*! ../expressions */ \"./node_modules/@abaplint/transpiler/build/src/expressions/index.js\");\r\nclass SelectTranspiler {\r\n transpile(node, traversal) {\r\n var _a;\r\n const ret = new chunk_1.Chunk();\r\n const selectStatement = node.findFirstStatement(abaplint.Statements.SelectLoop);\r\n if (selectStatement === undefined) {\r\n throw \"Structure, select loop not found\";\r\n }\r\n const from = (_a = selectStatement.findFirstExpression(abaplint.Expressions.SQLFromSource)) === null || _a === void 0 ? void 0 : _a.concatTokens().toUpperCase();\r\n const intoName = new expressions_1.SQLTargetTranspiler().transpile(selectStatement.findFirstExpression(abaplint.Expressions.SQLTarget), traversal).getCode();\r\n // note: this implementation SELECTs everything into memory, which might be bad, and sometimes not correct\r\n const targetName = unique_identifier_1.UniqueIdentifier.get();\r\n const loopName = unique_identifier_1.UniqueIdentifier.get();\r\n ret.appendString(`let ${targetName} = new abap.types.Table(abap.DDIC[\"${from}\"].type);\\n`);\r\n ret.appendChunk(new select_1.SelectTranspiler().transpile(selectStatement, traversal, targetName));\r\n ret.appendString(`\\nfor (const ${loopName} of ${targetName}.array()) {\\n`);\r\n ret.appendString(`${intoName}.set(${loopName});\\n`);\r\n const body = node.findDirectStructure(abaplint.Structures.Body);\r\n if (body) {\r\n ret.appendChunk(traversal.traverse(body));\r\n }\r\n ret.appendString(\"}\\n\");\r\n return ret;\r\n }\r\n}\r\nexports.SelectTranspiler = SelectTranspiler;\r\n//# sourceMappingURL=select.js.map\n\n//# sourceURL=webpack://@abaplint/transpiler-cli/./node_modules/@abaplint/transpiler/build/src/structures/select.js?");
15629
15640
 
15630
15641
  /***/ }),
15631
15642
 
@@ -15724,7 +15735,7 @@ eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\n
15724
15735
  /***/ ((__unused_webpack_module, exports, __webpack_require__) => {
15725
15736
 
15726
15737
  "use strict";
15727
- eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\nexports.Validation = exports.config = void 0;\r\nconst core_1 = __webpack_require__(/*! @abaplint/core */ \"./node_modules/@abaplint/core/build/src/index.js\");\r\nexports.config = {\r\n \"global\": {\r\n \"files\": \"/**/*.*\",\r\n \"skipGeneratedGatewayClasses\": true,\r\n \"skipGeneratedPersistentClasses\": true,\r\n \"skipGeneratedFunctionGroups\": true,\r\n },\r\n \"syntax\": {\r\n \"version\": core_1.Version.OpenABAP,\r\n \"errorNamespace\": \".\",\r\n },\r\n \"rules\": {\r\n \"when_others_last\": true,\r\n \"avoid_use\": {\r\n \"execSQL\": true,\r\n \"kernelCall\": true,\r\n \"communication\": true,\r\n \"systemCall\": true,\r\n \"break\": false,\r\n \"statics\": true,\r\n \"endselect\": false,\r\n \"defaultKey\": false,\r\n },\r\n \"parser_error\": true,\r\n \"allowed_object_types\": {\r\n \"allowed\": [\"INTF\", \"CLAS\", \"PROG\", \"DEVC\", \"TABL\", \"SHLP\", \"VIEW\", \"XSLT\", \"ENQU\", \"SHMA\", \"SICF\", \"NROB\", \"TYPE\", \"DTEL\", \"DOMA\", \"TTYP\", \"MSAG\", \"FUGR\"],\r\n },\r\n \"unknown_types\": true,\r\n \"ambiguous_statement\": true,\r\n \"implement_methods\": true,\r\n \"begin_end_names\": true,\r\n \"check_syntax\": true,\r\n \"form_no_dash\": true,\r\n \"omit_preceding_zeros\": true,\r\n \"obsolete_statement\": {\r\n \"compute\": true,\r\n \"setExtended\": true,\r\n },\r\n \"forbidden_identifier\": {\r\n \"check\": [\r\n \"^abstract$\", \"^arguments$\", \"^await$\",\r\n \"^break$\", \"^byte$\", \"^catch$\",\r\n \"^char$\", \"^class$\", \"^const$\", \"^continue$\",\r\n \"^debugger$\", \"^default$\", \"^do$\",\r\n \"^double$\", \"^else$\", \"^enum$\", \"^eval$\",\r\n \"^export$\", \"^extends$\", \"^false$\", \"^final$\",\r\n \"^finally$\", \"^for$\", \"^function$\",\r\n \"^goto$\", \"^if$\", \"^implements$\", \"^import$\",\r\n \"^in$\", \"^instanceof$\", \"^interface$\",\r\n \"^let$\", \"^long$\", \"^native$\", \"^new$\",\r\n \"^null$\", \"^package$\", \"^private$\",\r\n // \"^protected$\",\r\n \"^public$\", \"^return$\", \"^short$\", \"^static$\",\r\n \"^switch$\", \"^synchronized$\", \"^this$\",\r\n \"^throw$\", \"^throws$\", \"^transient$\", \"^true$\",\r\n \"^try$\", \"^typeof$\", \"^var$\", \"^void$\",\r\n \"^volatile$\", \"^while$\", \"^yield$\",\r\n \"^unique\\\\d+$\"\r\n ],\r\n },\r\n },\r\n};\r\n// todo, make sure nothing is overloaded, eg \"lines()\", there is a rule for this in abaplint now\r\nclass Validation {\r\n constructor(options) {\r\n this.options = options;\r\n }\r\n run(reg) {\r\n var _a, _b;\r\n if (((_a = this.options) === null || _a === void 0 ? void 0 : _a.ignoreSyntaxCheck) === true) {\r\n exports.config.rules.check_syntax = false;\r\n }\r\n else {\r\n exports.config.rules.check_syntax = true;\r\n }\r\n if (((_b = this.options) === null || _b === void 0 ? void 0 : _b.unknownTypes) === \"runtimeError\") {\r\n exports.config.syntax.errorNamespace = \"VOID_EVERYTHING\"; // this is not a constant, just a regex that happens to not match anything\r\n // config.rules[\"unknown_types\"] = false;\r\n }\r\n const conf = new core_1.Config(JSON.stringify(exports.config));\r\n reg.setConfig(conf);\r\n const issues = reg.findIssues();\r\n return issues;\r\n }\r\n}\r\nexports.Validation = Validation;\r\n//# sourceMappingURL=validation.js.map\n\n//# sourceURL=webpack://@abaplint/transpiler-cli/./node_modules/@abaplint/transpiler/build/src/validation.js?");
15738
+ eval("\r\nObject.defineProperty(exports, \"__esModule\", ({ value: true }));\r\nexports.Validation = exports.config = void 0;\r\nconst core_1 = __webpack_require__(/*! @abaplint/core */ \"./node_modules/@abaplint/core/build/src/index.js\");\r\nexports.config = {\r\n \"global\": {\r\n \"files\": \"/**/*.*\",\r\n \"skipGeneratedGatewayClasses\": true,\r\n \"skipGeneratedPersistentClasses\": true,\r\n \"skipGeneratedFunctionGroups\": true,\r\n },\r\n \"syntax\": {\r\n \"version\": core_1.Version.OpenABAP,\r\n \"errorNamespace\": \".\",\r\n },\r\n \"rules\": {\r\n \"when_others_last\": true,\r\n \"avoid_use\": {\r\n \"execSQL\": true,\r\n \"kernelCall\": true,\r\n \"communication\": true,\r\n \"systemCall\": true,\r\n \"break\": false,\r\n \"statics\": true,\r\n \"endselect\": false,\r\n \"defaultKey\": false,\r\n },\r\n \"parser_error\": true,\r\n \"allowed_object_types\": {\r\n \"allowed\": [\r\n \"AUTH\",\r\n \"CLAS\",\r\n \"DEVC\",\r\n \"DOMA\",\r\n \"DTEL\",\r\n \"ENQU\",\r\n \"FUGR\",\r\n \"INTF\",\r\n \"MSAG\",\r\n \"NROB\",\r\n \"PARA\",\r\n \"PROG\",\r\n \"SHLP\",\r\n \"SHMA\",\r\n \"SICF\",\r\n \"SMIM\",\r\n \"SRFC\",\r\n \"SUSO\",\r\n \"TABL\",\r\n \"TOBJ\",\r\n \"TRAN\",\r\n \"TTYP\",\r\n \"TYPE\",\r\n \"VIEW\",\r\n \"XSLT\",\r\n ],\r\n },\r\n \"unknown_types\": true,\r\n \"ambiguous_statement\": true,\r\n \"implement_methods\": true,\r\n \"begin_end_names\": true,\r\n \"check_syntax\": true,\r\n \"form_no_dash\": true,\r\n \"omit_preceding_zeros\": true,\r\n \"obsolete_statement\": {\r\n \"compute\": true,\r\n \"setExtended\": true,\r\n },\r\n \"forbidden_identifier\": {\r\n \"check\": [\r\n \"^abstract$\", \"^arguments$\", \"^await$\",\r\n \"^break$\", \"^byte$\", \"^catch$\",\r\n \"^char$\", \"^class$\", \"^const$\", \"^continue$\",\r\n \"^debugger$\", \"^default$\", \"^do$\",\r\n \"^double$\", \"^else$\", \"^enum$\", \"^eval$\",\r\n \"^export$\", \"^extends$\", \"^false$\", \"^final$\",\r\n \"^finally$\", \"^for$\", \"^function$\",\r\n \"^goto$\", \"^if$\", \"^implements$\", \"^import$\",\r\n \"^in$\", \"^instanceof$\", \"^interface$\",\r\n \"^let$\", \"^long$\", \"^native$\", \"^new$\",\r\n \"^null$\", \"^package$\", \"^private$\",\r\n // \"^protected$\",\r\n \"^public$\", \"^return$\", \"^short$\", \"^static$\",\r\n \"^switch$\", \"^synchronized$\", \"^this$\",\r\n \"^throw$\", \"^throws$\", \"^transient$\", \"^true$\",\r\n \"^try$\", \"^typeof$\", \"^var$\", \"^void$\",\r\n \"^volatile$\", \"^while$\", \"^yield$\",\r\n \"^unique\\\\d+$\"\r\n ],\r\n },\r\n },\r\n};\r\n// todo, make sure nothing is overloaded, eg \"lines()\", there is a rule for this in abaplint now\r\nclass Validation {\r\n constructor(options) {\r\n this.options = options;\r\n }\r\n run(reg) {\r\n var _a, _b;\r\n if (((_a = this.options) === null || _a === void 0 ? void 0 : _a.ignoreSyntaxCheck) === true) {\r\n exports.config.rules.check_syntax = false;\r\n }\r\n else {\r\n exports.config.rules.check_syntax = true;\r\n }\r\n if (((_b = this.options) === null || _b === void 0 ? void 0 : _b.unknownTypes) === \"runtimeError\") {\r\n exports.config.syntax.errorNamespace = \"VOID_EVERYTHING\"; // this is not a constant, just a regex that happens to not match anything\r\n // config.rules[\"unknown_types\"] = false;\r\n }\r\n const conf = new core_1.Config(JSON.stringify(exports.config));\r\n reg.setConfig(conf);\r\n const issues = reg.findIssues();\r\n return issues;\r\n }\r\n}\r\nexports.Validation = Validation;\r\n//# sourceMappingURL=validation.js.map\n\n//# sourceURL=webpack://@abaplint/transpiler-cli/./node_modules/@abaplint/transpiler/build/src/validation.js?");
15728
15739
 
15729
15740
  /***/ }),
15730
15741
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@abaplint/transpiler-cli",
3
- "version": "2.3.72",
3
+ "version": "2.3.74",
4
4
  "description": "Transpiler - Command Line Interface",
5
5
  "bin": {
6
6
  "abap_transpile": "./abap_transpile"
@@ -25,14 +25,14 @@
25
25
  "author": "abaplint",
26
26
  "license": "MIT",
27
27
  "devDependencies": {
28
- "@abaplint/transpiler": "^2.3.72",
28
+ "@abaplint/transpiler": "^2.3.74",
29
29
  "@types/glob": "^7.2.0",
30
30
  "glob": "=7.2.0",
31
31
  "@types/progress": "^2.0.5",
32
32
  "@abaplint/core": "^2.94.2",
33
33
  "progress": "^2.0.3",
34
34
  "webpack": "^5.75.0",
35
- "webpack-cli": "^5.0.0",
36
- "typescript": "^4.8.4"
35
+ "webpack-cli": "^5.0.1",
36
+ "typescript": "=4.8.4"
37
37
  }
38
38
  }