@abaplint/runtime 1.8.11 → 1.8.14
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.
|
@@ -37,6 +37,7 @@ __exportStar(require("./round"), exports);
|
|
|
37
37
|
__exportStar(require("./shift_left"), exports);
|
|
38
38
|
__exportStar(require("./sign"), exports);
|
|
39
39
|
__exportStar(require("./sin"), exports);
|
|
40
|
+
__exportStar(require("./sqrt"), exports);
|
|
40
41
|
__exportStar(require("./strlen"), exports);
|
|
41
42
|
__exportStar(require("./substring_after"), exports);
|
|
42
43
|
__exportStar(require("./substring_before"), exports);
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.sqrt = void 0;
|
|
4
|
+
/* eslint-disable radix */
|
|
5
|
+
const types_1 = require("../types");
|
|
6
|
+
function sqrt(input) {
|
|
7
|
+
let num_in = undefined;
|
|
8
|
+
if (typeof input.val === "number") {
|
|
9
|
+
num_in = input.val;
|
|
10
|
+
}
|
|
11
|
+
else if (typeof input.val === "string") {
|
|
12
|
+
num_in = parseFloat(input.val);
|
|
13
|
+
}
|
|
14
|
+
else if (input.val instanceof types_1.Float) {
|
|
15
|
+
num_in = input.val.getRaw();
|
|
16
|
+
}
|
|
17
|
+
else {
|
|
18
|
+
num_in = parseFloat(input.val.get().toString());
|
|
19
|
+
}
|
|
20
|
+
return Math.sqrt(num_in);
|
|
21
|
+
}
|
|
22
|
+
exports.sqrt = sqrt;
|
|
23
|
+
//# sourceMappingURL=sqrt.js.map
|
package/build/src/rfc.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import { FieldSymbol, Structure, Table } from "./types";
|
|
|
2
2
|
import { ICharacter } from "./types/_character";
|
|
3
3
|
import { INumeric } from "./types/_numeric";
|
|
4
4
|
declare type TypeType = INumeric | Table | ICharacter | Structure | FieldSymbol;
|
|
5
|
-
export declare type
|
|
5
|
+
export declare type RFCCallSignature = {
|
|
6
6
|
exporting?: {
|
|
7
7
|
[name: string]: TypeType;
|
|
8
8
|
};
|
|
@@ -20,6 +20,6 @@ export declare type RFCCallInput = {
|
|
|
20
20
|
};
|
|
21
21
|
};
|
|
22
22
|
export interface RFCClient {
|
|
23
|
-
call(name: string,
|
|
23
|
+
call(name: string, signature: RFCCallSignature): Promise<void>;
|
|
24
24
|
}
|
|
25
25
|
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@abaplint/runtime",
|
|
3
|
-
"version": "1.8.
|
|
3
|
+
"version": "1.8.14",
|
|
4
4
|
"description": "Transpiler - Runtime",
|
|
5
5
|
"main": "build/src/index.js",
|
|
6
6
|
"typings": "build/src/index.d.ts",
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
"@types/mocha": "^9.1.0",
|
|
36
36
|
"@types/sql.js": "^1.4.3",
|
|
37
37
|
"chai": "^4.3.6",
|
|
38
|
-
"mocha": "^9.2.
|
|
38
|
+
"mocha": "^9.2.2",
|
|
39
39
|
"source-map-support": "^0.5.21",
|
|
40
40
|
"typescript": "^4.6.2"
|
|
41
41
|
}
|