@abaplint/transpiler-cli 2.7.17 → 2.7.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/bundle.js +115 -5
- package/package.json +2 -2
package/build/bundle.js
CHANGED
|
@@ -70003,12 +70003,15 @@ __exportStar(__webpack_require__(/*! ./source_field_symbol */ "./node_modules/@a
|
|
|
70003
70003
|
__exportStar(__webpack_require__(/*! ./source_field */ "./node_modules/@abaplint/transpiler/build/src/expressions/source_field.js"), exports);
|
|
70004
70004
|
__exportStar(__webpack_require__(/*! ./source */ "./node_modules/@abaplint/transpiler/build/src/expressions/source.js"), exports);
|
|
70005
70005
|
__exportStar(__webpack_require__(/*! ./sql_cond */ "./node_modules/@abaplint/transpiler/build/src/expressions/sql_cond.js"), exports);
|
|
70006
|
+
__exportStar(__webpack_require__(/*! ./sql_field_and_value */ "./node_modules/@abaplint/transpiler/build/src/expressions/sql_field_and_value.js"), exports);
|
|
70006
70007
|
__exportStar(__webpack_require__(/*! ./sql_field */ "./node_modules/@abaplint/transpiler/build/src/expressions/sql_field.js"), exports);
|
|
70008
|
+
__exportStar(__webpack_require__(/*! ./sql_field_name */ "./node_modules/@abaplint/transpiler/build/src/expressions/sql_field_name.js"), exports);
|
|
70009
|
+
__exportStar(__webpack_require__(/*! ./sql_arithmetic_operator */ "./node_modules/@abaplint/transpiler/build/src/expressions/sql_arithmetic_operator.js"), exports);
|
|
70007
70010
|
__exportStar(__webpack_require__(/*! ./sql_from_source */ "./node_modules/@abaplint/transpiler/build/src/expressions/sql_from_source.js"), exports);
|
|
70008
70011
|
__exportStar(__webpack_require__(/*! ./sql_from */ "./node_modules/@abaplint/transpiler/build/src/expressions/sql_from.js"), exports);
|
|
70012
|
+
__exportStar(__webpack_require__(/*! ./sql_into_structure */ "./node_modules/@abaplint/transpiler/build/src/expressions/sql_into_structure.js"), exports);
|
|
70009
70013
|
__exportStar(__webpack_require__(/*! ./sql_join */ "./node_modules/@abaplint/transpiler/build/src/expressions/sql_join.js"), exports);
|
|
70010
70014
|
__exportStar(__webpack_require__(/*! ./sql_source_simple */ "./node_modules/@abaplint/transpiler/build/src/expressions/sql_source_simple.js"), exports);
|
|
70011
|
-
__exportStar(__webpack_require__(/*! ./sql_into_structure */ "./node_modules/@abaplint/transpiler/build/src/expressions/sql_into_structure.js"), exports);
|
|
70012
70015
|
__exportStar(__webpack_require__(/*! ./sql_source */ "./node_modules/@abaplint/transpiler/build/src/expressions/sql_source.js"), exports);
|
|
70013
70016
|
__exportStar(__webpack_require__(/*! ./sql_target */ "./node_modules/@abaplint/transpiler/build/src/expressions/sql_target.js"), exports);
|
|
70014
70017
|
__exportStar(__webpack_require__(/*! ./string_template_source */ "./node_modules/@abaplint/transpiler/build/src/expressions/string_template_source.js"), exports);
|
|
@@ -70822,6 +70825,30 @@ exports.SourceFieldSymbolTranspiler = SourceFieldSymbolTranspiler;
|
|
|
70822
70825
|
|
|
70823
70826
|
/***/ }),
|
|
70824
70827
|
|
|
70828
|
+
/***/ "./node_modules/@abaplint/transpiler/build/src/expressions/sql_arithmetic_operator.js":
|
|
70829
|
+
/*!********************************************************************************************!*\
|
|
70830
|
+
!*** ./node_modules/@abaplint/transpiler/build/src/expressions/sql_arithmetic_operator.js ***!
|
|
70831
|
+
\********************************************************************************************/
|
|
70832
|
+
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
70833
|
+
|
|
70834
|
+
"use strict";
|
|
70835
|
+
|
|
70836
|
+
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
70837
|
+
exports.SQLArithmeticOperatorTranspiler = void 0;
|
|
70838
|
+
const chunk_1 = __webpack_require__(/*! ../chunk */ "./node_modules/@abaplint/transpiler/build/src/chunk.js");
|
|
70839
|
+
class SQLArithmeticOperatorTranspiler {
|
|
70840
|
+
transpile(node, _traversal) {
|
|
70841
|
+
const chunk = new chunk_1.Chunk();
|
|
70842
|
+
const concat = node.concatTokens();
|
|
70843
|
+
chunk.appendString(concat);
|
|
70844
|
+
return chunk;
|
|
70845
|
+
}
|
|
70846
|
+
}
|
|
70847
|
+
exports.SQLArithmeticOperatorTranspiler = SQLArithmeticOperatorTranspiler;
|
|
70848
|
+
//# sourceMappingURL=sql_arithmetic_operator.js.map
|
|
70849
|
+
|
|
70850
|
+
/***/ }),
|
|
70851
|
+
|
|
70825
70852
|
/***/ "./node_modules/@abaplint/transpiler/build/src/expressions/sql_cond.js":
|
|
70826
70853
|
/*!*****************************************************************************!*\
|
|
70827
70854
|
!*** ./node_modules/@abaplint/transpiler/build/src/expressions/sql_cond.js ***!
|
|
@@ -71019,6 +71046,46 @@ exports.SQLFieldTranspiler = SQLFieldTranspiler;
|
|
|
71019
71046
|
|
|
71020
71047
|
/***/ }),
|
|
71021
71048
|
|
|
71049
|
+
/***/ "./node_modules/@abaplint/transpiler/build/src/expressions/sql_field_and_value.js":
|
|
71050
|
+
/*!****************************************************************************************!*\
|
|
71051
|
+
!*** ./node_modules/@abaplint/transpiler/build/src/expressions/sql_field_and_value.js ***!
|
|
71052
|
+
\****************************************************************************************/
|
|
71053
|
+
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
71054
|
+
|
|
71055
|
+
"use strict";
|
|
71056
|
+
|
|
71057
|
+
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
71058
|
+
exports.SQLFieldAndValueTranspiler = void 0;
|
|
71059
|
+
const abaplint = __webpack_require__(/*! @abaplint/core */ "./node_modules/@abaplint/core/build/src/index.js");
|
|
71060
|
+
const chunk_1 = __webpack_require__(/*! ../chunk */ "./node_modules/@abaplint/transpiler/build/src/chunk.js");
|
|
71061
|
+
class SQLFieldAndValueTranspiler {
|
|
71062
|
+
transpile(node, traversal) {
|
|
71063
|
+
const chunk = new chunk_1.Chunk();
|
|
71064
|
+
chunk.appendString("\"");
|
|
71065
|
+
for (const n of node.getChildren()) {
|
|
71066
|
+
const concat = n.concatTokens();
|
|
71067
|
+
if (concat === "=") {
|
|
71068
|
+
chunk.appendString(" = ");
|
|
71069
|
+
}
|
|
71070
|
+
else if (n.get() instanceof abaplint.Expressions.SQLSource) {
|
|
71071
|
+
const source = traversal.traverse(n);
|
|
71072
|
+
// todo: value conversion? abap vs db, traversal.isSQLConversion
|
|
71073
|
+
// todo: integers?
|
|
71074
|
+
chunk.appendString("'\" + " + source.getCode() + ".get() + \"'");
|
|
71075
|
+
}
|
|
71076
|
+
else {
|
|
71077
|
+
chunk.appendString(traversal.traverse(n).getCode() + " ");
|
|
71078
|
+
}
|
|
71079
|
+
}
|
|
71080
|
+
chunk.appendString("\"");
|
|
71081
|
+
return chunk;
|
|
71082
|
+
}
|
|
71083
|
+
}
|
|
71084
|
+
exports.SQLFieldAndValueTranspiler = SQLFieldAndValueTranspiler;
|
|
71085
|
+
//# sourceMappingURL=sql_field_and_value.js.map
|
|
71086
|
+
|
|
71087
|
+
/***/ }),
|
|
71088
|
+
|
|
71022
71089
|
/***/ "./node_modules/@abaplint/transpiler/build/src/expressions/sql_field_name.js":
|
|
71023
71090
|
/*!***********************************************************************************!*\
|
|
71024
71091
|
!*** ./node_modules/@abaplint/transpiler/build/src/expressions/sql_field_name.js ***!
|
|
@@ -71746,6 +71813,47 @@ exports.HandleEnqu = HandleEnqu;
|
|
|
71746
71813
|
|
|
71747
71814
|
/***/ }),
|
|
71748
71815
|
|
|
71816
|
+
/***/ "./node_modules/@abaplint/transpiler/build/src/handlers/handle_msag.js":
|
|
71817
|
+
/*!*****************************************************************************!*\
|
|
71818
|
+
!*** ./node_modules/@abaplint/transpiler/build/src/handlers/handle_msag.js ***!
|
|
71819
|
+
\*****************************************************************************/
|
|
71820
|
+
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
71821
|
+
|
|
71822
|
+
"use strict";
|
|
71823
|
+
|
|
71824
|
+
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
71825
|
+
exports.HandleMSAG = void 0;
|
|
71826
|
+
const chunk_1 = __webpack_require__(/*! ../chunk */ "./node_modules/@abaplint/transpiler/build/src/chunk.js");
|
|
71827
|
+
class HandleMSAG {
|
|
71828
|
+
runObject(obj, _reg) {
|
|
71829
|
+
var _a;
|
|
71830
|
+
const filename = (_a = obj.getXMLFile()) === null || _a === void 0 ? void 0 : _a.getFilename().replace(".xml", ".mjs").toLowerCase();
|
|
71831
|
+
if (filename === undefined) {
|
|
71832
|
+
return [];
|
|
71833
|
+
}
|
|
71834
|
+
const chunk = new chunk_1.Chunk().appendString(`abap.MSAG["${obj.getName().toUpperCase()}"] = {\n`);
|
|
71835
|
+
for (const m of obj.getMessages()) {
|
|
71836
|
+
chunk.appendString(` "${m.getNumber()}": "${m.getMessage().replace(/"/g, `\\"`)}",\n`);
|
|
71837
|
+
}
|
|
71838
|
+
chunk.appendString(`};`);
|
|
71839
|
+
const output = {
|
|
71840
|
+
object: {
|
|
71841
|
+
name: obj.getName(),
|
|
71842
|
+
type: obj.getType(),
|
|
71843
|
+
},
|
|
71844
|
+
filename: filename,
|
|
71845
|
+
chunk: chunk,
|
|
71846
|
+
requires: [],
|
|
71847
|
+
exports: [],
|
|
71848
|
+
};
|
|
71849
|
+
return [output];
|
|
71850
|
+
}
|
|
71851
|
+
}
|
|
71852
|
+
exports.HandleMSAG = HandleMSAG;
|
|
71853
|
+
//# sourceMappingURL=handle_msag.js.map
|
|
71854
|
+
|
|
71855
|
+
/***/ }),
|
|
71856
|
+
|
|
71749
71857
|
/***/ "./node_modules/@abaplint/transpiler/build/src/handlers/handle_smim.js":
|
|
71750
71858
|
/*!*****************************************************************************!*\
|
|
71751
71859
|
!*** ./node_modules/@abaplint/transpiler/build/src/handlers/handle_smim.js ***!
|
|
@@ -72064,6 +72172,7 @@ const handle_enqu_1 = __webpack_require__(/*! ./handlers/handle_enqu */ "./node_
|
|
|
72064
72172
|
const handle_type_pool_1 = __webpack_require__(/*! ./handlers/handle_type_pool */ "./node_modules/@abaplint/transpiler/build/src/handlers/handle_type_pool.js");
|
|
72065
72173
|
const handle_w3mi_1 = __webpack_require__(/*! ./handlers/handle_w3mi */ "./node_modules/@abaplint/transpiler/build/src/handlers/handle_w3mi.js");
|
|
72066
72174
|
const handle_smim_1 = __webpack_require__(/*! ./handlers/handle_smim */ "./node_modules/@abaplint/transpiler/build/src/handlers/handle_smim.js");
|
|
72175
|
+
const handle_msag_1 = __webpack_require__(/*! ./handlers/handle_msag */ "./node_modules/@abaplint/transpiler/build/src/handlers/handle_msag.js");
|
|
72067
72176
|
class Transpiler {
|
|
72068
72177
|
constructor(options) {
|
|
72069
72178
|
this.options = options;
|
|
@@ -72125,6 +72234,9 @@ class Transpiler {
|
|
|
72125
72234
|
else if (obj instanceof abaplint.Objects.WebMIME) {
|
|
72126
72235
|
output.objects.push(...new handle_w3mi_1.HandleW3MI().runObject(obj, reg));
|
|
72127
72236
|
}
|
|
72237
|
+
else if (obj instanceof abaplint.Objects.MessageClass) {
|
|
72238
|
+
output.objects.push(...new handle_msag_1.HandleMSAG().runObject(obj, reg));
|
|
72239
|
+
}
|
|
72128
72240
|
}
|
|
72129
72241
|
return output;
|
|
72130
72242
|
}
|
|
@@ -77548,7 +77660,6 @@ const chunk_1 = __webpack_require__(/*! ../chunk */ "./node_modules/@abaplint/tr
|
|
|
77548
77660
|
const expressions_1 = __webpack_require__(/*! ../expressions */ "./node_modules/@abaplint/transpiler/build/src/expressions/index.js");
|
|
77549
77661
|
class UpdateDatabaseTranspiler {
|
|
77550
77662
|
transpile(node, traversal) {
|
|
77551
|
-
var _a;
|
|
77552
77663
|
const dbtab = node.findFirstExpression(abaplint.Expressions.DatabaseTable);
|
|
77553
77664
|
if (dbtab === undefined) {
|
|
77554
77665
|
throw new Error("internal error, UpdateDatabaseTranspiler");
|
|
@@ -77564,9 +77675,7 @@ class UpdateDatabaseTranspiler {
|
|
|
77564
77675
|
if (sets.length > 0) {
|
|
77565
77676
|
const s = [];
|
|
77566
77677
|
for (const set of sets) {
|
|
77567
|
-
|
|
77568
|
-
const source = traversal.traverse(set.findDirectExpression(abaplint.Expressions.SQLSource));
|
|
77569
|
-
s.push("\"\\\"" + name + "\\\" = '\" + " + source.getCode() + ".get() + \"'\"");
|
|
77678
|
+
s.push(new expressions_1.SQLFieldAndValueTranspiler().transpile(set, traversal).getCode());
|
|
77570
77679
|
}
|
|
77571
77680
|
options.push(`"set": [${s.join(",")}]`);
|
|
77572
77681
|
}
|
|
@@ -80016,6 +80125,7 @@ run().then(() => {
|
|
|
80016
80125
|
if (obj instanceof abaplint.Objects.Table
|
|
80017
80126
|
|| obj instanceof abaplint.Objects.DataElement
|
|
80018
80127
|
|| obj instanceof abaplint.Objects.LockObject
|
|
80128
|
+
|| obj instanceof abaplint.Objects.MessageClass
|
|
80019
80129
|
|| obj instanceof abaplint.Objects.MIMEObject
|
|
80020
80130
|
|| obj instanceof abaplint.Objects.WebMIME
|
|
80021
80131
|
|| obj instanceof abaplint.Objects.TypePool
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@abaplint/transpiler-cli",
|
|
3
|
-
"version": "2.7.
|
|
3
|
+
"version": "2.7.19",
|
|
4
4
|
"description": "Transpiler - Command Line Interface",
|
|
5
5
|
"funding": "https://github.com/sponsors/larshp",
|
|
6
6
|
"bin": {
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"author": "abaplint",
|
|
27
27
|
"license": "MIT",
|
|
28
28
|
"devDependencies": {
|
|
29
|
-
"@abaplint/transpiler": "^2.7.
|
|
29
|
+
"@abaplint/transpiler": "^2.7.19",
|
|
30
30
|
"@types/glob": "^7.2.0",
|
|
31
31
|
"glob": "=7.2.0",
|
|
32
32
|
"@types/progress": "^2.0.5",
|