[−][src]Macro slash_formatter::concat_with_file_separator_mut
Concatenate multiple strings with FILE_SEPARATORs.
#[macro_use] extern crate slash_formatter; if cfg!(windows) { let mut s = String::from("path"); concat_with_file_separator_mut!(&mut s, r"to\", r"\file\"); assert_eq!(r"path\to\file", s); } else { let mut s = String::from("path"); concat_with_file_separator_mut!(&mut s, "to/", "/file/"); assert_eq!("path/to/file", s); }