2022-01-25 17:19:33 -06:00
|
|
|
// Regression test for #93197
|
2022-01-26 12:47:13 -06:00
|
|
|
// check-pass
|
2022-01-25 17:19:33 -06:00
|
|
|
// edition:2021
|
2022-01-25 18:13:07 -06:00
|
|
|
// compile-flags: -Zdrop-tracking
|
2022-01-25 17:19:33 -06:00
|
|
|
|
|
|
|
#![feature(try_blocks)]
|
|
|
|
|
|
|
|
use std::sync::{mpsc, mpsc::SendError};
|
|
|
|
|
|
|
|
pub async fn foo() {
|
|
|
|
let (tx, _) = mpsc::channel();
|
|
|
|
|
|
|
|
let _: Result<(), SendError<&str>> = try { tx.send("hello")?; };
|
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {}
|