mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-27 17:24:06 +00:00
12 lines
201 B
Rust
12 lines
201 B
Rust
//@ compile-flags: -Znext-solver
|
|
|
|
use std::collections::HashMap;
|
|
|
|
fn foo() -> &'static HashMap<i32, i32>
|
|
{
|
|
&HashMap::new()
|
|
//~^ ERROR cannot return reference to temporary value
|
|
}
|
|
|
|
fn main() {}
|