string_concat

Crates.iostring_concat
lib.rsstring_concat
version0.0.1
sourcesrc
created_at2020-05-19 16:30:25.709467
updated_at2020-05-19 16:50:39.787994
descriptionA useful macro for concatenating strings in low overhead manner
homepage
repositoryhttps://github.com/richardanaya/string_concat
max_upload_size
id243506
size15,029
richardanaya2_2048b.Q6_K.gguf (richardanaya)

documentation

README

string_concat!

A useful macro for putting together strings in a low overhead manner for no_std + alloc apps.

let name = "Richard";
let msg:String = string_concat!("Hello ",name,"!");

saves you from typing

let name = "Richard";
let msg:String = {
  let temp_string = String::new();
  temp_string.push_str("Hello");
  temp_string.push_str(name);
  temp_string.push_str("!");
  temp_string
}

Contributors

  • @richardanaya
  • @RustyYato
Commit count: 9

cargo fmt