rust/tests/ui/delegation/ice-issue-122550.rs

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

19 lines
333 B
Rust
Raw Normal View History

#![feature(fn_delegation)]
#![allow(incomplete_features)]
trait Trait {
fn description(&self) -> &str {}
//~^ ERROR mismatched types
}
struct F;
struct S(F);
impl S {
reuse <S as Trait>::description { &self.0 }
//~^ ERROR mismatched types
//~| ERROR the trait bound `S: Trait` is not satisfied
}
fn main() {}