mirror of
https://github.com/rust-lang/rust.git
synced 2025-10-07 04:40:11 +00:00
9 lines
170 B
Rust
9 lines
170 B
Rust
//! Check that a bare string literal is typed as a `&'static str` and is usable.
|
|
|
|
//@ run-pass
|
|
|
|
pub fn main() {
|
|
let x: &'static str = "foo";
|
|
println!("{}", x);
|
|
}
|