mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-25 16:24:46 +00:00
13 lines
239 B
Rust
13 lines
239 B
Rust
//@ known-bug: rust-lang/rust#125059
|
|
#![feature(deref_patterns)]
|
|
#![allow(incomplete_features)]
|
|
|
|
fn simple_vec(vec: Vec<u32>) -> u32 {
|
|
(|| match Vec::<u32>::new() {
|
|
deref!([]) => 100,
|
|
_ => 2000,
|
|
})()
|
|
}
|
|
|
|
fn main() {}
|