[−][src]Crate proc_unroll
proc_unroll
is a proc macro to unroll loops inside a function. It supports loops of the
following forms:
for pat in int..int
for pat in &[elem, elem]
Example:
#[proc_unroll::unroll] fn unrolled() -> Vec<u32> { let mut vec = Vec::new(); for x in 10..20 { vec.push(x); } vec } assert_eq!(unrolled(), (10..20).collect::<Vec<_>>());
Attribute Macros
unroll |