1
Fork 0
rust/tests/ui/issues/issue-7575.rs

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

18 lines
250 B
Rust
Raw Normal View History

//@ run-pass
2024-02-07 10:42:01 +08:00
trait Foo { //~ WARN trait `Foo` is never used
fn new() -> bool { false }
fn dummy(&self) { }
}
trait Bar {
fn new(&self) -> bool { true }
}
impl Bar for isize {}
impl Foo for isize {}
fn main() {
2015-01-25 22:05:03 +01:00
assert!(1.new());
}