mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-24 15:54:15 +00:00
17 lines
303 B
Rust
17 lines
303 B
Rust
// Regression test for #93197
|
|
// check-pass
|
|
// edition:2021
|
|
// compile-flags: -Zdrop-tracking
|
|
|
|
#![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() {}
|