summary refs log tree commit diff
path: root/src/test/ui/impl-trait/universal_wrong_bounds.rs
blob: 56a13ea257e88c6906e405ac96ed301d669604de (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
use std::fmt::Display;

fn foo(f: impl Display + Clone) -> String {
    wants_debug(f);
    wants_display(f);
    wants_clone(f);
}

fn wants_debug(g: impl Debug) { } //~ ERROR cannot find
fn wants_display(g: impl Debug) { } //~ ERROR cannot find
fn wants_clone(g: impl Clone) { }

fn main() {
}