Skip to main content

punc

Macro punc 

Source
macro_rules! punc {
    (value $value:expr) => { ... };
    (pairs $first:expr; $($punctuation:expr => $next:expr),+ $(,)?) => { ... };
    ($value:ty) => { ... };
}
Expand description

Names or constructs a nonempty comma-punctuated sequence.

  • punc!(T) names Punctuated<T>.
  • punc!(value first) constructs one value.
  • punc!(pairs first; comma => second, ...) constructs a sequence while retaining every supplied typed comma and its span.