#[derive(Pod)]Expand description
Derive Pod for a struct.
Requirements:
- Must be a struct (not enum or union).
- All fields must implement
Pod. - The struct will be given
#[repr(C)]semantics (the macro addsCloneandCopyderives and theunsafe impl Pod).
§Example
ⓘ
#[derive(photon_ring::Pod)]
struct Tick {
price: f64,
volume: u32,
_pad: u32,
}