mirror of
https://github.com/rust-lang/rust.git
synced 2025-12-02 10:18:24 +00:00
9 lines
214 B
Rust
9 lines
214 B
Rust
// Regression test for #146537.
|
|
|
|
struct NonCopy;
|
|
fn main() {
|
|
let tuple = &(NonCopy,);
|
|
let b: NonCopy;
|
|
(b,) = *tuple; //~ ERROR: cannot move out of `tuple.0` which is behind a shared reference [E0507]
|
|
}
|