[][src]Macro mynewt::fill_zero

macro_rules! fill_zero {
    ($type:ident) => { ... };
}

Return a const struct that has all fields set to 0. Used for initialising static mutable structs like os_task. fill_zero!(os_task) expands to

unsafe { 
::core::mem::transmute::
<
 [
   u8; 
   ::core::mem::size_of::<os_task>()
 ], 
 os_task
>
(
 [
   0; 
   ::core::mem::size_of::<os_task>()
 ]
) 
}