Missing stacktraces when processes send messages to themselves
This was found as part of #293 (closed). This code:
import std::stdio::STDOUT
import std::process::(sleep)
import std::time::(Duration, Instant)
class async Main {
fn print_step(message: String) {
STDOUT.new.print(message)
sleep(Duration.from_secs(1))
}
fn async loop {
while true {
async self.print_step('hello world!')
async self.print_step('hello world!')
}
}
fn async main {
let main = Main{}
main.loop
}
}
Produces the following output:
Stack trace (the most recent call comes last):
Process 0x7f2bac000e50 panicked: Processes can't send messages to themselves, as this could result in deadlocks
The error is correct, but the stacktrace is missing.