| Crates.io | has_impl |
| lib.rs | has_impl |
| version | 0.1.0 |
| created_at | 2020-06-04 18:37:14.221951+00 |
| updated_at | 2020-06-04 18:37:14.221951+00 |
| description | Check if trait is implemented for type in compile time |
| homepage | |
| repository | https://github.com/Frago9876543210/has_impl |
| max_upload_size | |
| id | 250108 |
| size | 4,092 |
Check if trait is implemented for type at compile time
use has_impl::*;
trait Foo {}
impl Foo for i32 {}
fn main() {
assert_eq!(has_impl!(i32: Foo), true);
}
[dependencies]
has_impl = "0.1"