rust/tests/ui/trait-bounds/issue-93008.rs

16 lines
218 B
Rust
Raw Normal View History

2022-06-11 16:31:33 -05:00
// build-pass
// compile-flags: -Zmir-opt-level=3 --crate-type=lib
2022-06-11 16:31:33 -05:00
#![feature(trivial_bounds)]
#![allow(trivial_bounds)]
trait Foo {
fn test(self);
}
fn baz<T>()
where
2022-06-11 16:31:33 -05:00
&'static str: Foo,
{
2022-06-11 16:31:33 -05:00
"Foo".test()
}