[][src]Macro format_xml::csv

macro_rules! csv {
    ($($e:expr),+) => { ... };
    ($($e:expr),+; $s:literal) => { ... };
}

Displays the arguments as comma-separated values.

The arguments are moved instead of captured by reference unlike format_args!.

let result = csv!(1, 2.0, true).to_string();
assert_eq!(result, "1,2,true");

Optionally, the formatting can be specified:

let result = csv!(10, 11, 12; "{:#x}").to_string();
assert_eq!(result, "0xa,0xb,0xc");