const_format_crates
const_format_crates copied to clipboard
Support `width` configuration in `formatcp!`
The standard format!
macro supports with
configuration https://doc.rust-lang.org/std/fmt/index.html#width
I am trying to format 0x0100
using "{:#06x}"
however I am getting
failed to parse the format string at the character number 2,
unknown formatting: "#06x"
When I remove 06
from the format (the resulting format is "{:#x}"
) I am getting 0x100
which is not what I want.
Is there a way to set with?
There is no way to set width, don't know how hard it'd be to implement such that it works like in std for all types.
In the meantime could you remove the statement "The {}/{:} formatter works the same as in format"? I wasted a while assuming that meant I could pass it the same things as format!
before I found this issue.