format_many 1.0.0

Extended format_many! macro which allows formatting with variable number of argument inside one macro call
Documentation
  • Coverage
  • 100%
    2 out of 2 items documented2 out of 2 items with examples
  • Size
  • Source code size: 6.8 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 1.04 MB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 12s Average build duration of successful builds.
  • all releases: 12s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • Homepage
  • IoaNNUwU/format_many
    2 1 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • IoaNNUwU

format_many

This crate provides extended format_many! macro which allows formatting with variable number of argument inside one macro call.

This macro implemented using macro_rules! thus lightweight and IDE-friendly

use format_many::format_many;

let text: String = format_many!(
    "Hello {}", "World"
);

let text: String = format_many!(
    "Hello {}", "World";
    "Numbers {}, {}", 10, 11;
    "String literal";
    "Format {:?}", [1, 2, 3]
);

format_many! recieves a list of format strings with corresponding values separated by ;. Arguments in this inner lists are separated by ,.

Each argument separated by ; behaves like it's own format! call, with compile-time checked number of arguments.