You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'll be happy to take this on but I'm not entirely sure what a good syntax for this would be. I was thinking of:
macro_rules! vec(($($e:expr),*) => ({// leading _ to allow empty construction without a warning.letmut _temp = ::std::vec_ng::Vec::with_capacity(#($e));
$(_temp.push($e);)*
_temp
}))
Since the individual elements in a multiplicative pattern can contain an arbitrary tree of expressions, # would recursively count all the elements that would expand to a specific $identifier.