Crate fmty

Source
Expand description

§fmty docs.rs crates.io github

Composable core::fmt utilities, brought to you by Nikolai Vazquez.

If you find this crate useful, consider starring it as well as sponsoring or donating once. 💖

§Install

This crate is available on crates.io and can be used by running the following cargo command in your project directory:

cargo add fmty

or by manually adding the following to your project’s Cargo.toml:

[dependencies]
fmty = "0.1.1"

§MSRV

This crate’s minimum supported Rust version is 1.56.0. Updating the Rust version is considered a breaking change that will result in an appropriate crate version update.

§License

Like the Rust project, this library may be used under either the MIT License or Apache License (Version 2.0) at your choosing.

Modules§

types
Types defined by this crate.

Macros§

concat
Concatenates items that may be different types.
fmt
Like format_args! or fmt_with() depending on usage.
fmt_args
Like core::format_args!, but with full ownership.
format_args
Like core::format_args!, but with full ownership.

Traits§

FmtIterator
Iterator formatting methods.

Functions§

concat
Concatenates Iterator items.
concat_map
Concatenates mapped Iterator results.
concat_map_once
Concatenates mapped Iterator results, at most once.
concat_once
Concatenates Iterator items, at most once.
concat_tuple
Concatenates tuple items that may be different types.
cond
Conditionally writes a value.
cond_option
Conditionally writes an Option.
cond_option_or
Conditionally writes an Option, or its fallback if None.
cond_or
Conditionally writes a value, or its fallback if false.
cond_result
Conditionally writes a Result variant.
cond_with
Conditionally writes a closure result.
cond_with_option
Conditionally writes a closure Option result.
csv
Concatenates Iterator items with , between each.
csv_map
Concatenates mapped Iterator results with , between each.
csv_map_once
Concatenates mapped Iterator results with , between each, at most once.
csv_once
Concatenates Iterator items with , between each, at most once.
csv_tuple
Concatenates tuple items with , between each.
fmt_with
Formats via a closure.
infix
Places a value between left and right.
join
Concatenates Iterator items with a separator between each.
join_map
Concatenates mapped Iterator results with a separator between each.
join_map_once
Concatenates mapped Iterator results with a separator between each, at most once.
join_once
Concatenates Iterator items with a separator between each, at most once.
join_tuple
Concatenates tuple items with a separator between each.
no_op
Writes nothing.
quote_backtick
Places a value between `.
quote_cjk
Places a value between and .
quote_cjk_vert
Places a value between and .
quote_cjk_white
Places a value between and .
quote_cjk_white_vert
Places a value between and .
quote_curly_double
Places a value between and .
quote_curly_single
Places a value between and .
quote_de_double
Places a value between and .
quote_de_single
Places a value between and .
quote_double
Places a value between ".
quote_guillemet_double
Places a value between « and ».
quote_guillemet_single
Places a value between and .
quote_single
Places a value between '.
repeat
Repeats a value n times.
repeat_with
Repeats n results of a closure.
to_ascii_lowercase
Converts to ASCII lowercase.
to_ascii_uppercase
Converts to ASCII uppercase.
truncate_chars
Shortens to len chars.