I was looking at using this crate and for use with std Rust it would be much more ergonomic to have an enum for each of the different cases cases that implements fmt::Display and calls the appropriate escape function. This would let you wrap values you want to print in format!(...) with the enum to have them be escaped appropriately.
I was looking at using this crate and for use with std Rust it would be much more ergonomic to have an enum for each of the different cases cases that implements fmt::Display and calls the appropriate escape function. This would let you wrap values you want to print in format!(...) with the enum to have them be escaped appropriately.