functionalscript 0.0.459 → 0.0.460
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/com/test/build.cjs +1 -1
- package/com/test/build.f.cjs +16 -17
- package/com/test/cs/Program.cs +7 -1
- package/com/test/cs/cs.csproj +4 -0
- package/com/test/rust/src/lib.rs +3 -0
- package/package.json +1 -1
package/com/test/build.cjs
CHANGED
package/com/test/build.f.cjs
CHANGED
|
@@ -62,22 +62,20 @@ const output = platform => name => {
|
|
|
62
62
|
}
|
|
63
63
|
|
|
64
64
|
/** @type {Func} */
|
|
65
|
-
const cpp = ({dirname, platform}) => {
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
}
|
|
80
|
-
}
|
|
65
|
+
const cpp = ({dirname, platform}) => ({
|
|
66
|
+
file: {
|
|
67
|
+
name: `${dirname}/cpp/_result.hpp`,
|
|
68
|
+
content: cppContent,
|
|
69
|
+
},
|
|
70
|
+
line: [
|
|
71
|
+
flat([
|
|
72
|
+
['clang', '-shared', '-o', output(platform)('main')],
|
|
73
|
+
flags(platform),
|
|
74
|
+
[`${dirname}/cpp/main.cpp`]]
|
|
75
|
+
),
|
|
76
|
+
],
|
|
77
|
+
})
|
|
78
|
+
|
|
81
79
|
|
|
82
80
|
/** @type {Func} */
|
|
83
81
|
const cs = ({dirname}) => ({
|
|
@@ -85,7 +83,8 @@ const cs = ({dirname}) => ({
|
|
|
85
83
|
name: `${dirname}/cs/_result.cs`,
|
|
86
84
|
content: csContent,
|
|
87
85
|
},
|
|
88
|
-
line: [
|
|
86
|
+
line: [
|
|
87
|
+
['dotnet', 'run', '--project', `${dirname}/cs/cs.csproj`]],
|
|
89
88
|
})
|
|
90
89
|
|
|
91
90
|
/** @type {Func} */
|
package/com/test/cs/Program.cs
CHANGED
|
@@ -1,2 +1,8 @@
|
|
|
1
|
-
|
|
1
|
+
using System.Runtime.InteropServices;
|
|
2
|
+
|
|
3
|
+
[DllImport("testrust")]
|
|
4
|
+
static extern int get();
|
|
5
|
+
|
|
6
|
+
// See https://aka.ms/new-console-template for more information
|
|
2
7
|
Console.WriteLine("Hello, World!");
|
|
8
|
+
Console.WriteLine(get());
|
package/com/test/cs/cs.csproj
CHANGED
package/com/test/rust/src/lib.rs
CHANGED