AutoCaps

Derive Macro AutoCaps 

Source
#[derive(AutoCaps)]
Expand description

Derive macro to auto-detect standard trait implementations.

This is the recommended way to enable caps_check! for user-defined types.

§Usage

#[derive(Clone, Debug, AutoCaps)]
struct MyType { data: String }

// Now you can check traits:
assert!(caps_check!(MyType: Clone));
assert!(caps_check!(MyType: Debug));
assert!(!caps_check!(MyType: Copy));