mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-22 23:04:33 +00:00
61058937e5
Make checking slightly cheaper (by restricting to the right item only). Add tests.
13 lines
224 B
Rust
13 lines
224 B
Rust
#![crate_name = "dependency"]
|
|
#![crate_type = "rlib"]
|
|
pub struct Type;
|
|
pub trait Trait {
|
|
fn foo(&self);
|
|
fn bar();
|
|
}
|
|
impl Trait for Type {
|
|
fn foo(&self) {}
|
|
fn bar() {}
|
|
}
|
|
pub fn do_something<X: Trait>(_: X) {}
|