3 stable releases

1.0.2 May 13, 2023

#2268 in Development tools

Apache-2.0

3KB

WEC

A collection of useful Rust macros for creating vec!s.

bec!

Tired of writing vec![ Box::new(1), ... Box::new(100) ]? Me too. So here's macro that does it for you.

let v = bec![1, 2, 3];
assert_eq!(v, vec![Box::new(1), Box::new(2), Box::new(3)]);

vinto!

Calls .into() on each element.

let v: Vec<String> = vinto!["foo", String::from("bar")];
assert_eq!(v, vec![String::from("foo"), String::from("bar")]);

lib.rs:

A collection of useful Rust macros for creating vec!s.

No runtime deps