@@ -203,6 +203,7 @@ There are few downsides to them
203
203
- could do full JSImport/JSExport to it's own JS ` self ` context
204
204
- there is `JSSynchronizationContext`` installed on it
205
205
- so that user code could dispatch back to it, in case that it needs to call ` JSObject ` proxy (with thread affinity)
206
+ - this thread needs to throw on any ` .Wait ` because of the problem ** 7**
206
207
207
208
## HTTP and WS clients
208
209
- are implemented in terms of ` JSObject ` and ` Promise ` proxies
@@ -280,7 +281,7 @@ There are few downsides to them
280
281
- there are 2 dimensions: the thread and the method
281
282
- there are 2 steps:
282
283
- A) obtain existing ` JSHandle ` on next call (if available)
283
- - to avoid double dispatch, this needs to be accessible
284
+ - to avoid double dispatch, this needs to be accessible
284
285
- by any caller thread
285
286
- or by UI thread C code (not managed)
286
287
- B) if this is first call to the method on the target thread, create the target ` JSHandle ` by binding existing JS function
@@ -719,7 +720,7 @@ Related Net8 tracking https://github.com/dotnet/runtime/issues/85592
719
720
- enable dynamic thread allocation
720
721
- throw exceptions in dev loop when UI thread does ` lock ` or ` .Wait ` in user code
721
722
722
- ## Scratch pad
723
+ ## Scratch pad
723
724
724
725
current generated ` JSImport ` in Net7, Net8
725
726
@@ -736,11 +737,11 @@ public static partial Task WebSocketReceive(JSObject webSocket, nint bufferPtr,
736
737
{
737
738
if (__signature_WebSocketReceive_1144640460 == null )
738
739
{
739
- __signature_WebSocketReceive_1144640460 = JSFunctionBinding .BindJSFunction (" INTERNAL.ws_wasm_receive" , null , new JSMarshalerType [] {
740
- JSMarshalerType .Task (),
741
- JSMarshalerType .JSObject ,
742
- JSMarshalerType .IntPtr ,
743
- JSMarshalerType .Int32
740
+ __signature_WebSocketReceive_1144640460 = JSFunctionBinding .BindJSFunction (" INTERNAL.ws_wasm_receive" , null , new JSMarshalerType [] {
741
+ JSMarshalerType .Task (),
742
+ JSMarshalerType .JSObject ,
743
+ JSMarshalerType .IntPtr ,
744
+ JSMarshalerType .Int32
744
745
});
745
746
}
746
747
@@ -750,7 +751,7 @@ public static partial Task WebSocketReceive(JSObject webSocket, nint bufferPtr,
750
751
ref JSMarshalerArgument __arg_return = ref __arguments_buffer [1 ];
751
752
__arg_return .Initialize ();
752
753
Task __retVal ;
753
-
754
+
754
755
ref JSMarshalerArgument __bufferLength_native__js_arg = ref __arguments_buffer [4 ];
755
756
ref JSMarshalerArgument __bufferPtr_native__js_arg = ref __arguments_buffer [3 ];
756
757
ref JSMarshalerArgument __webSocket_native__js_arg = ref __arguments_buffer [2 ];
@@ -780,7 +781,7 @@ internal static unsafe void __Wrapper_Dummy_1616792047(JSMarshalerArgument* __ar
780
781
try
781
782
{
782
783
783
- __meaningPromise_native__js_arg .ToManaged (out meaningPromise ,
784
+ __meaningPromise_native__js_arg .ToManaged (out meaningPromise ,
784
785
static (ref JSMarshalerArgument __task_result_arg , out int __task_result ) =>
785
786
{
786
787
__task_result_arg .ToManaged (out __task_result );
0 commit comments