Spawns a new thread named thread_name running thread_func with user_data passed to it.
thread_func must return a [class@Dex.Future].
If this function is called from a thread that is not running a [class@Dex.Scheduler] then the default scheduler will be used to call
user_data_destroy.
If the resulting [class@Dex.Future] has not resolved or rejected, then the same scheduler used to call user_data_destroy
will be used to propagate the result to the caller.
| thread_name |
the name for the thread |
| thread_func |
the function to call on a thread |
| user_data |
closure data for |
| user_data_destroy |
callback to free |
|
a [class@Dex.Future] that resolves or rejects the value or error returned from |