goscript 0.0.7 → 0.0.10
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/README.md +13 -5
- package/builtin/builtin.ts +180 -0
- package/compiler/compile_expr.go +119 -25
- package/compiler/compile_spec.go +175 -2
- package/compiler/compile_stmt.go +99 -69
- package/compiler/writer.go +2 -2
- package/dist/builtin/builtin.d.ts +55 -0
- package/dist/builtin/builtin.js +126 -0
- package/dist/builtin/builtin.js.map +1 -1
- package/dist/compliance/tests/array_literal/array_literal.gs.js +1 -0
- package/dist/compliance/tests/array_literal/array_literal.gs.js.map +1 -1
- package/dist/compliance/tests/composite_literal_assignment/composite_literal_assignment.gs.js +4 -0
- package/dist/compliance/tests/composite_literal_assignment/composite_literal_assignment.gs.js.map +1 -1
- package/dist/compliance/tests/copy_independence/copy_independence.gs.js +3 -1
- package/dist/compliance/tests/copy_independence/copy_independence.gs.js.map +1 -1
- package/dist/compliance/tests/embedded_interface_assertion/embedded_interface_assertion.gs.d.ts +1 -0
- package/dist/compliance/tests/embedded_interface_assertion/embedded_interface_assertion.gs.js +37 -0
- package/dist/compliance/tests/embedded_interface_assertion/embedded_interface_assertion.gs.js.map +1 -0
- package/dist/compliance/tests/float64/float64.gs.js +1 -0
- package/dist/compliance/tests/float64/float64.gs.js.map +1 -1
- package/dist/compliance/tests/for_loop_condition_only/for_loop_condition_only.gs.d.ts +1 -0
- package/dist/compliance/tests/for_loop_condition_only/for_loop_condition_only.gs.js +11 -0
- package/dist/compliance/tests/for_loop_condition_only/for_loop_condition_only.gs.js.map +1 -0
- package/dist/compliance/tests/func_literal/func_literal.gs.js.map +1 -1
- package/dist/compliance/tests/function_call_result_assignment/function_call_result_assignment.gs.d.ts +2 -0
- package/dist/compliance/tests/function_call_result_assignment/function_call_result_assignment.gs.js +4 -0
- package/dist/compliance/tests/function_call_result_assignment/function_call_result_assignment.gs.js.map +1 -1
- package/dist/compliance/tests/interface_multi_param_return/interface_multi_param_return.gs.d.ts +1 -0
- package/dist/compliance/tests/interface_multi_param_return/interface_multi_param_return.gs.js +34 -0
- package/dist/compliance/tests/interface_multi_param_return/interface_multi_param_return.gs.js.map +1 -0
- package/dist/compliance/tests/interface_to_interface_type_assertion/interface_to_interface_type_assertion.gs.js +8 -2
- package/dist/compliance/tests/interface_to_interface_type_assertion/interface_to_interface_type_assertion.gs.js.map +1 -1
- package/dist/compliance/tests/interface_type_assertion/interface_type_assertion.gs.js +6 -2
- package/dist/compliance/tests/interface_type_assertion/interface_type_assertion.gs.js.map +1 -1
- package/dist/compliance/tests/method_call_on_pointer_receiver/method_call_on_pointer_receiver.gs.js +3 -1
- package/dist/compliance/tests/method_call_on_pointer_receiver/method_call_on_pointer_receiver.gs.js.map +1 -1
- package/dist/compliance/tests/method_call_on_pointer_via_value/method_call_on_pointer_via_value.gs.js +3 -0
- package/dist/compliance/tests/method_call_on_pointer_via_value/method_call_on_pointer_via_value.gs.js.map +1 -1
- package/dist/compliance/tests/method_call_on_value_receiver/method_call_on_value_receiver.gs.js +3 -0
- package/dist/compliance/tests/method_call_on_value_receiver/method_call_on_value_receiver.gs.js.map +1 -1
- package/dist/compliance/tests/method_call_on_value_via_pointer/method_call_on_value_via_pointer.gs.js +3 -0
- package/dist/compliance/tests/method_call_on_value_via_pointer/method_call_on_value_via_pointer.gs.js.map +1 -1
- package/dist/compliance/tests/pointer_assignment_no_copy/pointer_assignment_no_copy.gs.js +3 -0
- package/dist/compliance/tests/pointer_assignment_no_copy/pointer_assignment_no_copy.gs.js.map +1 -1
- package/dist/compliance/tests/pointer_composite_literal_assignment/pointer_composite_literal_assignment.gs.js +3 -0
- package/dist/compliance/tests/pointer_composite_literal_assignment/pointer_composite_literal_assignment.gs.js.map +1 -1
- package/dist/compliance/tests/pointer_deref_multiassign/pointer_deref_multiassign.gs.js +3 -0
- package/dist/compliance/tests/pointer_deref_multiassign/pointer_deref_multiassign.gs.js.map +1 -1
- package/dist/compliance/tests/pointer_initialization/pointer_initialization.gs.js +3 -1
- package/dist/compliance/tests/pointer_initialization/pointer_initialization.gs.js.map +1 -1
- package/dist/compliance/tests/select_receive_on_closed_channel_no_default/select_receive_on_closed_channel_no_default.gs.js +17 -16
- package/dist/compliance/tests/select_receive_on_closed_channel_no_default/select_receive_on_closed_channel_no_default.gs.js.map +1 -1
- package/dist/compliance/tests/select_send_on_full_buffered_channel_with_default/select_send_on_full_buffered_channel_with_default.gs.js +13 -13
- package/dist/compliance/tests/select_send_on_full_buffered_channel_with_default/select_send_on_full_buffered_channel_with_default.gs.js.map +1 -1
- package/dist/compliance/tests/select_statement/select_statement.gs.js +119 -119
- package/dist/compliance/tests/select_statement/select_statement.gs.js.map +1 -1
- package/dist/compliance/tests/simple_deref_assignment/simple_deref_assignment.gs.js +3 -1
- package/dist/compliance/tests/simple_deref_assignment/simple_deref_assignment.gs.js.map +1 -1
- package/dist/compliance/tests/string_rune_conversion/string_rune_conversion.gs.js.map +1 -1
- package/dist/compliance/tests/struct_field_access/struct_field_access.gs.js +3 -0
- package/dist/compliance/tests/struct_field_access/struct_field_access.gs.js.map +1 -1
- package/dist/compliance/tests/struct_value_init_clone/struct_value_init_clone.gs.js +3 -0
- package/dist/compliance/tests/struct_value_init_clone/struct_value_init_clone.gs.js.map +1 -1
- package/dist/compliance/tests/value_type_copy_behavior/value_type_copy_behavior.gs.js +3 -1
- package/dist/compliance/tests/value_type_copy_behavior/value_type_copy_behavior.gs.js.map +1 -1
- package/package.json +2 -2
|
@@ -6,161 +6,161 @@ export async function main() {
|
|
|
6
6
|
// Create a buffered channel so sends don't block
|
|
7
7
|
let ch1 = goscript.makeChannel(1, "");
|
|
8
8
|
// First test: empty channel, should hit default
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
9
|
+
await goscript.selectStatement([
|
|
10
|
+
{
|
|
11
|
+
id: 0,
|
|
12
|
+
isSend: false,
|
|
13
|
+
channel: ch1,
|
|
14
|
+
onSelected: async (result) => {
|
|
15
|
+
const msg = result.value;
|
|
16
|
+
console.log("TEST1: Received unexpected value:", msg);
|
|
17
|
+
}
|
|
18
|
+
},
|
|
19
|
+
{
|
|
20
20
|
id: -1,
|
|
21
21
|
isSend: false,
|
|
22
22
|
channel: null,
|
|
23
23
|
onSelected: async (result) => {
|
|
24
24
|
console.log("TEST1: Default case hit correctly");
|
|
25
25
|
}
|
|
26
|
-
}
|
|
27
|
-
|
|
26
|
+
},
|
|
27
|
+
], true);
|
|
28
28
|
// Now put something in the channel
|
|
29
29
|
await ch1.send("hello");
|
|
30
30
|
// Second test: should read from channel
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
31
|
+
await goscript.selectStatement([
|
|
32
|
+
{
|
|
33
|
+
id: 0,
|
|
34
|
+
isSend: false,
|
|
35
|
+
channel: ch1,
|
|
36
|
+
onSelected: async (result) => {
|
|
37
|
+
const msg = result.value;
|
|
38
|
+
console.log("TEST2: Received expected value:", msg);
|
|
39
|
+
}
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
42
|
id: -1,
|
|
43
43
|
isSend: false,
|
|
44
44
|
channel: null,
|
|
45
45
|
onSelected: async (result) => {
|
|
46
46
|
console.log("TEST2: Default case hit unexpectedly");
|
|
47
47
|
}
|
|
48
|
-
}
|
|
49
|
-
|
|
48
|
+
},
|
|
49
|
+
], true);
|
|
50
50
|
// Test 3: Select with channel closing and ok value
|
|
51
51
|
let ch2 = goscript.makeChannel(1, 0);
|
|
52
52
|
await ch2.send(42);
|
|
53
53
|
ch2.close();
|
|
54
54
|
// First receive gets the buffered value
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
55
|
+
await goscript.selectStatement([
|
|
56
|
+
{
|
|
57
|
+
id: 0,
|
|
58
|
+
isSend: false,
|
|
59
|
+
channel: ch2,
|
|
60
|
+
onSelected: async (result) => {
|
|
61
|
+
const val = result.value;
|
|
62
|
+
const ok = result.ok;
|
|
63
|
+
if (ok) {
|
|
64
|
+
console.log("TEST3: Received buffered value with ok==true:", val);
|
|
65
|
+
}
|
|
66
|
+
else {
|
|
67
|
+
console.log("TEST3: Unexpected ok==false");
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
72
|
id: -1,
|
|
73
73
|
isSend: false,
|
|
74
74
|
channel: null,
|
|
75
75
|
onSelected: async (result) => {
|
|
76
76
|
console.log("TEST3: Default hit unexpectedly");
|
|
77
77
|
}
|
|
78
|
-
}
|
|
79
|
-
|
|
78
|
+
},
|
|
79
|
+
], true);
|
|
80
80
|
// Second receive gets the zero value with ok==false
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
81
|
+
await goscript.selectStatement([
|
|
82
|
+
{
|
|
83
|
+
id: 0,
|
|
84
|
+
isSend: false,
|
|
85
|
+
channel: ch2,
|
|
86
|
+
onSelected: async (result) => {
|
|
87
|
+
const val = result.value;
|
|
88
|
+
const ok = result.ok;
|
|
89
|
+
if (ok) {
|
|
90
|
+
console.log("TEST4: Unexpected ok==true:", val);
|
|
91
|
+
}
|
|
92
|
+
else {
|
|
93
|
+
console.log("TEST4: Received zero value with ok==false:", val);
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
98
|
id: -1,
|
|
99
99
|
isSend: false,
|
|
100
100
|
channel: null,
|
|
101
101
|
onSelected: async (result) => {
|
|
102
102
|
console.log("TEST4: Default hit unexpectedly");
|
|
103
103
|
}
|
|
104
|
-
}
|
|
105
|
-
|
|
104
|
+
},
|
|
105
|
+
], true);
|
|
106
106
|
// Test 5: Send operations
|
|
107
107
|
let ch3 = goscript.makeChannel(1, 0);
|
|
108
108
|
// First send should succeed (buffer not full)
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
109
|
+
await goscript.selectStatement([
|
|
110
|
+
{
|
|
111
|
+
id: 0,
|
|
112
|
+
isSend: true,
|
|
113
|
+
channel: ch3,
|
|
114
|
+
value: 5,
|
|
115
|
+
onSelected: async (result) => {
|
|
116
|
+
console.log("TEST5: Sent value successfully");
|
|
117
|
+
}
|
|
118
|
+
},
|
|
119
|
+
{
|
|
120
120
|
id: -1,
|
|
121
121
|
isSend: false,
|
|
122
122
|
channel: null,
|
|
123
123
|
onSelected: async (result) => {
|
|
124
124
|
console.log("TEST5: Default hit unexpectedly");
|
|
125
125
|
}
|
|
126
|
-
}
|
|
127
|
-
|
|
126
|
+
},
|
|
127
|
+
], true);
|
|
128
128
|
// Second send should hit default (buffer full)
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
129
|
+
await goscript.selectStatement([
|
|
130
|
+
{
|
|
131
|
+
id: 0,
|
|
132
|
+
isSend: true,
|
|
133
|
+
channel: ch3,
|
|
134
|
+
value: 10,
|
|
135
|
+
onSelected: async (result) => {
|
|
136
|
+
console.log("TEST6: Sent unexpectedly");
|
|
137
|
+
}
|
|
138
|
+
},
|
|
139
|
+
{
|
|
140
140
|
id: -1,
|
|
141
141
|
isSend: false,
|
|
142
142
|
channel: null,
|
|
143
143
|
onSelected: async (result) => {
|
|
144
144
|
console.log("TEST6: Default hit correctly (channel full)");
|
|
145
145
|
}
|
|
146
|
-
}
|
|
147
|
-
|
|
146
|
+
},
|
|
147
|
+
], true);
|
|
148
148
|
// Test 7: Multiple channel select (with known values)
|
|
149
149
|
let ch4 = goscript.makeChannel(1, "");
|
|
150
150
|
let ch5 = goscript.makeChannel(1, "");
|
|
151
151
|
await ch4.send("from ch4");
|
|
152
152
|
// Should select ch4 because it has data, ch5 is empty
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
153
|
+
await goscript.selectStatement([
|
|
154
|
+
{
|
|
155
|
+
id: 0,
|
|
156
|
+
isSend: false,
|
|
157
|
+
channel: ch4,
|
|
158
|
+
onSelected: async (result) => {
|
|
159
|
+
const msg = result.value;
|
|
160
|
+
console.log("TEST7: Selected ch4 correctly:", msg);
|
|
161
|
+
}
|
|
162
|
+
},
|
|
163
|
+
{
|
|
164
164
|
id: 1,
|
|
165
165
|
isSend: false,
|
|
166
166
|
channel: ch5,
|
|
@@ -168,22 +168,22 @@ export async function main() {
|
|
|
168
168
|
const msg = result.value;
|
|
169
169
|
console.log("TEST7: Selected ch5 unexpectedly:", msg);
|
|
170
170
|
}
|
|
171
|
-
}
|
|
172
|
-
|
|
171
|
+
},
|
|
172
|
+
], false);
|
|
173
173
|
// Now ch4 is empty and ch5 is empty
|
|
174
174
|
await ch5.send("from ch5");
|
|
175
175
|
// Should select ch5 because it has data, ch4 is empty
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
176
|
+
await goscript.selectStatement([
|
|
177
|
+
{
|
|
178
|
+
id: 0,
|
|
179
|
+
isSend: false,
|
|
180
|
+
channel: ch4,
|
|
181
|
+
onSelected: async (result) => {
|
|
182
|
+
const msg = result.value;
|
|
183
|
+
console.log("TEST8: Selected ch4 unexpectedly:", msg);
|
|
184
|
+
}
|
|
185
|
+
},
|
|
186
|
+
{
|
|
187
187
|
id: 1,
|
|
188
188
|
isSend: false,
|
|
189
189
|
channel: ch5,
|
|
@@ -191,14 +191,14 @@ export async function main() {
|
|
|
191
191
|
const msg = result.value;
|
|
192
192
|
console.log("TEST8: Selected ch5 correctly:", msg);
|
|
193
193
|
}
|
|
194
|
-
}
|
|
195
|
-
|
|
194
|
+
},
|
|
195
|
+
], false);
|
|
196
196
|
// Test 9: Channel closing test case for a separate test
|
|
197
197
|
let chClose = goscript.makeChannel(0, false);
|
|
198
198
|
chClose.close();
|
|
199
|
-
const
|
|
200
|
-
let val =
|
|
201
|
-
let ok =
|
|
199
|
+
const _tempVar1 = await chClose.receiveWithOk();
|
|
200
|
+
let val = _tempVar1.value;
|
|
201
|
+
let ok = _tempVar1.ok;
|
|
202
202
|
if (!ok) {
|
|
203
203
|
console.log("TEST9: Channel is closed, ok is false, val:", val);
|
|
204
204
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"select_statement.gs.js","sourceRoot":"","sources":["../../../../compliance/tests/select_statement/select_statement.gs.ts"],"names":[],"mappings":"AAAA,8CAA8C;AAC9C,yDAAyD;AAEzD,OAAO,KAAK,QAAQ,MAAM,aAAa,CAAC;AAExC,MAAM,CAAC,KAAK,UAAU,IAAI;IACzB,mDAAmD;IACnD,iDAAiD;IACjD,IAAI,GAAG,GAAG,QAAQ,CAAC,WAAW,CAAS,CAAC,EAAE,EAAE,CAAC,CAAA;IAE7C,gDAAgD;IAChD,MAAM,
|
|
1
|
+
{"version":3,"file":"select_statement.gs.js","sourceRoot":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
3
|
+
import * as goscript from "@go/builtin";
|
|
3
4
|
class MyStruct {
|
|
4
5
|
MyInt = 0;
|
|
5
6
|
MyString = "";
|
|
6
|
-
myBool = false;
|
|
7
7
|
constructor(init) { if (init)
|
|
8
8
|
Object.assign(this, init); }
|
|
9
9
|
clone() { return Object.assign(Object.create(MyStruct.prototype), this); }
|
|
10
|
+
// Register this type with the runtime type system
|
|
11
|
+
static __typeInfo = goscript.registerType('MyStruct', goscript.TypeKind.Struct, new MyStruct(), new Set([]), MyStruct);
|
|
10
12
|
}
|
|
11
13
|
export async function main() {
|
|
12
14
|
let structPointer = new MyStruct({ MyInt: 4, MyString: "hello world" });
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"simple_deref_assignment.gs.js","sourceRoot":"","sources":["../../../../compliance/tests/simple_deref_assignment/simple_deref_assignment.gs.ts"],"names":[],"mappings":"AAAA,qDAAqD;AACrD,yDAAyD;
|
|
1
|
+
{"version":3,"file":"simple_deref_assignment.gs.js","sourceRoot":"","sources":["../../../../compliance/tests/simple_deref_assignment/simple_deref_assignment.gs.ts"],"names":[],"mappings":"AAAA,qDAAqD;AACrD,yDAAyD;AAEzD,OAAO,KAAK,QAAQ,MAAM,aAAa,CAAC;AAExC,MAAM,QAAQ;IACN,KAAK,GAAW,CAAC,CAAC;IAClB,QAAQ,GAAW,EAAE,CAAC;IAE7B,YAAY,IAAwB,IAAI,IAAI,IAAI;QAAE,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,IAAW,CAAC,CAAC,CAAC,CAAC;IAC9E,KAAK,KAAe,OAAO,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC,SAAS,CAAa,EAAE,IAAI,CAAC,CAAC,CAAC,CAAC;IAEvG,kDAAkD;IAClD,MAAM,CAAC,UAAU,GAAG,QAAQ,CAAC,YAAY,CACvC,UAAU,EACV,QAAQ,CAAC,QAAQ,CAAC,MAAM,EACxB,IAAI,QAAQ,EAAE,EACd,IAAI,GAAG,CAAC,EAAE,CAAC,EACX,QAAQ,CACT,CAAC;;AAGH,MAAM,CAAC,KAAK,UAAU,IAAI;IACzB,IAAI,aAAa,GAAG,IAAI,QAAQ,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,QAAQ,EAAE,aAAa,EAAE,CAAC,CAAA;IACvE,qDAAqD;IACrD,IAAI,sBAAsB,GAAG,aAAa,CAAC,KAAK,EAAE,CAAA;IAClD,sFAAsF;IACtF,sBAAsB,CAAC,QAAQ,GAAG,4BAA4B,CAAA;IAC9D,0BAA0B;IAC1B,OAAO,CAAC,GAAG,CAAC,gGAAgG,GAAG,aAAa,CAAC,QAAQ,CAAC,CAAA;IACtI,yCAAyC;IACzC,OAAO,CAAC,GAAG,CAAC,0EAA0E,GAAG,sBAAsB,CAAC,QAAQ,CAAC,CAAA;AAC1H,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"string_rune_conversion.gs.js","sourceRoot":"","sources":["../../../../compliance/tests/string_rune_conversion/string_rune_conversion.gs.ts"],"names":[],"mappings":"AAAA,oDAAoD;AACpD,yDAAyD;AAIzD,MAAM,CAAC,KAAK,UAAU,IAAI;IACzB,kCAAkC;IAClC,IAAI,CAAC,
|
|
1
|
+
{"version":3,"file":"string_rune_conversion.gs.js","sourceRoot":"","sources":["../../../../compliance/tests/string_rune_conversion/string_rune_conversion.gs.ts"],"names":[],"mappings":"AAAA,oDAAoD;AACpD,yDAAyD;AAIzD,MAAM,CAAC,KAAK,UAAU,IAAI;IACzB,kCAAkC;IAClC,IAAI,CAAC,GAAG,EAAE,CAAA;IACV,IAAI,CAAC,GAAG,MAAM,CAAC,YAAY,CAAC,CAAC,CAAC,CAAA;IAC9B,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,CAAA;IAEd,MAAM;IACN,IAAI,EAAE,GAAW,EAAE,CAAC;IACpB,IAAI,EAAE,GAAG,MAAM,CAAC,YAAY,CAAC,EAAE,CAAC,CAAA;IAChC,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,CAAA;IAEf,MAAM;IACN,IAAI,EAAE,GAAW,MAAM,CAAC;IACxB,IAAI,EAAE,GAAG,MAAM,CAAC,YAAY,CAAC,EAAE,CAAC,CAAA;IAChC,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,CAAA;AAChB,CAAC"}
|
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
// Generated file based on struct_field_access.go
|
|
2
2
|
// Updated when compliance tests are re-run, DO NOT EDIT!
|
|
3
|
+
import * as goscript from "@go/builtin";
|
|
3
4
|
class MyStruct {
|
|
4
5
|
MyInt = 0;
|
|
5
6
|
MyString = "";
|
|
6
7
|
constructor(init) { if (init)
|
|
7
8
|
Object.assign(this, init); }
|
|
8
9
|
clone() { return Object.assign(Object.create(MyStruct.prototype), this); }
|
|
10
|
+
// Register this type with the runtime type system
|
|
11
|
+
static __typeInfo = goscript.registerType('MyStruct', goscript.TypeKind.Struct, new MyStruct(), new Set([]), MyStruct);
|
|
9
12
|
}
|
|
10
13
|
export async function main() {
|
|
11
14
|
// === Struct Field Access ===
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"struct_field_access.gs.js","sourceRoot":"","sources":["../../../../compliance/tests/struct_field_access/struct_field_access.gs.ts"],"names":[],"mappings":"AAAA,iDAAiD;AACjD,yDAAyD;
|
|
1
|
+
{"version":3,"file":"struct_field_access.gs.js","sourceRoot":"","sources":["../../../../compliance/tests/struct_field_access/struct_field_access.gs.ts"],"names":[],"mappings":"AAAA,iDAAiD;AACjD,yDAAyD;AAEzD,OAAO,KAAK,QAAQ,MAAM,aAAa,CAAC;AAExC,MAAM,QAAQ;IACN,KAAK,GAAW,CAAC,CAAC;IAClB,QAAQ,GAAW,EAAE,CAAC;IAE7B,YAAY,IAAwB,IAAI,IAAI,IAAI;QAAE,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,IAAW,CAAC,CAAC,CAAC,CAAC;IAC9E,KAAK,KAAe,OAAO,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC,SAAS,CAAa,EAAE,IAAI,CAAC,CAAC,CAAC,CAAC;IAEvG,kDAAkD;IAClD,MAAM,CAAC,UAAU,GAAG,QAAQ,CAAC,YAAY,CACvC,UAAU,EACV,QAAQ,CAAC,QAAQ,CAAC,MAAM,EACxB,IAAI,QAAQ,EAAE,EACd,IAAI,GAAG,CAAC,EAAE,CAAC,EACX,QAAQ,CACT,CAAC;;AAGH,MAAM,CAAC,KAAK,UAAU,IAAI;IACzB,8BAA8B;IAC9B,IAAI,EAAE,GAAG,IAAI,QAAQ,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC,CAAA;IACrD,OAAO,CAAC,GAAG,CAAC,8BAA8B,EAAE,EAAE,CAAC,KAAK,CAAC,CAAA;IACrD,OAAO,CAAC,GAAG,CAAC,kCAAkC,EAAE,EAAE,CAAC,QAAQ,CAAC,CAAA;AAC7D,CAAC"}
|
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
// Generated file based on struct_value_init_clone.go
|
|
2
2
|
// Updated when compliance tests are re-run, DO NOT EDIT!
|
|
3
|
+
import * as goscript from "@go/builtin";
|
|
3
4
|
class Point {
|
|
4
5
|
X = 0;
|
|
5
6
|
Y = 0;
|
|
6
7
|
constructor(init) { if (init)
|
|
7
8
|
Object.assign(this, init); }
|
|
8
9
|
clone() { return Object.assign(Object.create(Point.prototype), this); }
|
|
10
|
+
// Register this type with the runtime type system
|
|
11
|
+
static __typeInfo = goscript.registerType('Point', goscript.TypeKind.Struct, new Point(), new Set([]), Point);
|
|
9
12
|
}
|
|
10
13
|
export async function main() {
|
|
11
14
|
// Initialize directly
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"struct_value_init_clone.gs.js","sourceRoot":"","sources":["../../../../compliance/tests/struct_value_init_clone/struct_value_init_clone.gs.ts"],"names":[],"mappings":"AAAA,qDAAqD;AACrD,yDAAyD;
|
|
1
|
+
{"version":3,"file":"struct_value_init_clone.gs.js","sourceRoot":"","sources":["../../../../compliance/tests/struct_value_init_clone/struct_value_init_clone.gs.ts"],"names":[],"mappings":"AAAA,qDAAqD;AACrD,yDAAyD;AAEzD,OAAO,KAAK,QAAQ,MAAM,aAAa,CAAC;AAExC,MAAM,KAAK;IACH,CAAC,GAAW,CAAC,CAAC;IACd,CAAC,GAAW,CAAC,CAAC;IAErB,YAAY,IAAqB,IAAI,IAAI,IAAI;QAAE,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,IAAW,CAAC,CAAC,CAAC,CAAC;IAC3E,KAAK,KAAY,OAAO,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC,SAAS,CAAU,EAAE,IAAI,CAAC,CAAC,CAAC,CAAC;IAE9F,kDAAkD;IAClD,MAAM,CAAC,UAAU,GAAG,QAAQ,CAAC,YAAY,CACvC,OAAO,EACP,QAAQ,CAAC,QAAQ,CAAC,MAAM,EACxB,IAAI,KAAK,EAAE,EACX,IAAI,GAAG,CAAC,EAAE,CAAC,EACX,KAAK,CACN,CAAC;;AAGH,MAAM,CAAC,KAAK,UAAU,IAAI;IACzB,sBAAsB;IACtB,IAAI,EAAE,GAAG,IAAI,KAAK,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,CAAA;IAClC,OAAO,CAAC,GAAG,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,CAAA;IAE9B,oDAAoD;IACpD,IAAI,EAAE,GAAG,EAAE,CAAC,KAAK,EAAE,CAAA;IACnB,EAAE,CAAC,CAAC,GAAG,EAAE,CAAA,CAAC,kBAAkB;IAE5B,0CAA0C;IAC1C,OAAO,CAAC,GAAG,CAAC,kBAAkB,EAAE,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,CAAA;IAC3C,OAAO,CAAC,GAAG,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,CAAA;IAE9B,qCAAqC;IACrC,IAAI,CAAC,GAAG,IAAI,KAAK,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,CAAA;IACjC,IAAI,EAAE,GAAG,CAAC,CAAC,KAAK,EAAE,CAAA,CAAC,uBAAuB;IAC1C,EAAE,CAAC,CAAC,GAAG,EAAE,CAAA,CAAC,kBAAkB;IAE5B,OAAO,CAAC,GAAG,CAAC,iBAAiB,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAA;IACxC,OAAO,CAAC,GAAG,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,CAAA;AAC/B,CAAC"}
|
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
// Generated file based on value_type_copy_behavior.go
|
|
2
2
|
// Updated when compliance tests are re-run, DO NOT EDIT!
|
|
3
|
+
import * as goscript from "@go/builtin";
|
|
3
4
|
class MyStruct {
|
|
4
5
|
MyInt = 0;
|
|
5
6
|
MyString = "";
|
|
6
|
-
myBool = false;
|
|
7
7
|
constructor(init) { if (init)
|
|
8
8
|
Object.assign(this, init); }
|
|
9
9
|
clone() { return Object.assign(Object.create(MyStruct.prototype), this); }
|
|
10
|
+
// Register this type with the runtime type system
|
|
11
|
+
static __typeInfo = goscript.registerType('MyStruct', goscript.TypeKind.Struct, new MyStruct(), new Set([]), MyStruct);
|
|
10
12
|
}
|
|
11
13
|
export async function main() {
|
|
12
14
|
let dereferencedStructCopy = new MyStruct({ MyString: "original" });
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"value_type_copy_behavior.gs.js","sourceRoot":"","sources":["../../../../compliance/tests/value_type_copy_behavior/value_type_copy_behavior.gs.ts"],"names":[],"mappings":"AAAA,sDAAsD;AACtD,yDAAyD;
|
|
1
|
+
{"version":3,"file":"value_type_copy_behavior.gs.js","sourceRoot":"","sources":["../../../../compliance/tests/value_type_copy_behavior/value_type_copy_behavior.gs.ts"],"names":[],"mappings":"AAAA,sDAAsD;AACtD,yDAAyD;AAEzD,OAAO,KAAK,QAAQ,MAAM,aAAa,CAAC;AAExC,MAAM,QAAQ;IACN,KAAK,GAAW,CAAC,CAAC;IAClB,QAAQ,GAAW,EAAE,CAAC;IAE7B,YAAY,IAAwB,IAAI,IAAI,IAAI;QAAE,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,IAAW,CAAC,CAAC,CAAC,CAAC;IAC9E,KAAK,KAAe,OAAO,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC,SAAS,CAAa,EAAE,IAAI,CAAC,CAAC,CAAC,CAAC;IAEvG,kDAAkD;IAClD,MAAM,CAAC,UAAU,GAAG,QAAQ,CAAC,YAAY,CACvC,UAAU,EACV,QAAQ,CAAC,QAAQ,CAAC,MAAM,EACxB,IAAI,QAAQ,EAAE,EACd,IAAI,GAAG,CAAC,EAAE,CAAC,EACX,QAAQ,CACT,CAAC;;AAGH,MAAM,CAAC,KAAK,UAAU,IAAI;IACzB,IAAI,sBAAsB,GAAG,IAAI,QAAQ,CAAC,EAAE,QAAQ,EAAE,UAAU,EAAE,CAAC,CAAA;IACnE,mCAAmC;IACnC,8DAA8D;IAC9D,IAAI,UAAU,GAAG,sBAAsB,CAAC,KAAK,EAAE,CAAA;IAC/C,IAAI,UAAU,GAAG,sBAAsB,CAAC,KAAK,EAAE,CAAA;IAC/C,IAAI,WAAW,GAAG,sBAAsB,CAAA;IACxC,kEAAkE;IAClE,UAAU,CAAC,QAAQ,GAAG,cAAc,CAAA;IACpC,sBAAsB,CAAC,QAAQ,GAAG,qCAAqC,CAAA,CAAC,kCAAkC;IAC1G,UAAU,CAAC,QAAQ,GAAG,cAAc,CAAA;IACpC,2BAA2B;IAC3B,OAAO,CAAC,GAAG,CAAC,8CAA8C,GAAG,UAAU,CAAC,QAAQ,CAAC,CAAA;IACjF,kDAAkD;IAClD,OAAO,CAAC,GAAG,CAAC,mHAAmH,GAAG,sBAAsB,CAAC,QAAQ,CAAC,CAAA;IAClK,2BAA2B;IAC3B,OAAO,CAAC,GAAG,CAAC,8CAA8C,GAAG,UAAU,CAAC,QAAQ,CAAC,CAAA;AAClF,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "goscript",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.10",
|
|
4
4
|
"description": "Go to TypeScript compiler",
|
|
5
5
|
"bin": {
|
|
6
6
|
"goscript": "./cmd/goscript/main.js"
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"example": "cd ./example/simple && bash run.bash",
|
|
33
33
|
"test": "npm run test:js && npm run test:go",
|
|
34
34
|
"test:go": "go test -v ./...",
|
|
35
|
-
"test:js": "vitest run",
|
|
35
|
+
"test:js": "tsc --noEmit && vitest run",
|
|
36
36
|
"format": "npm run format:go && npm run format:js && npm run format:config",
|
|
37
37
|
"format:config": "prettier --write tsconfig.json package.json",
|
|
38
38
|
"format:go": "gofumpt -w .",
|