macro_rules! create_device {
($Device:expr) => { ... };
}
Expand description
Convenience macro for creating a new Device
from any type implementing DeviceTrait
.
This macro wraps the provided device implementation in an Arc
and creates a DeviceType
.
ยงExamples
let memory_device = Memory_device_type::<512>::new(1024);
let device = create_device!(memory_device);