rust/tests/ui/issues/issue-40951.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

13 lines
226 B
Rust
Raw Normal View History

//@ run-pass
#![allow(unused_variables)]
// Regression test for #40951.
const FOO: [&'static str; 1] = ["foo"];
fn find<T: PartialEq>(t: &[T], element: &T) { }
fn main() {
let x = format!("hi");
find(&FOO, &&*x);
}