const_format_crates icon indicating copy to clipboard operation
const_format_crates copied to clipboard

Compile-time string formatting

Results 14 const_format_crates issues
Sort by recently updated
recently updated
newest added

Sample ```rs use const_format::formatcp; const NAME: &str = "John"; const start: &str = formatcp!("{NAME}, age {}!", compute_age(NAME)); const fn compute_age(s: &str) -> usize { s.len() * 6 } fn main()...

wontfix

Not sure, maybe also rename other variables. Or maybe it's a bad practice Closes #44

My tests failed miserably in result of that problem. The standard library `format!()` macro formats hexadecimal numbers capitalized if `{:X}` is used, but in lower characters if `{:x}` is used....

Is it possible to have negative patterns in `str_replace` (or anything similar)? Specifically, I am interested in a use-case of replacing non-alphanumeric characters with underscore and have a proper identifier.

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...

When running with nursery clippy lints `concatcp` creates warnings. Not sure if this is a false positive or something that could be improved. ```bash cargo clippy -- -W clippy::nursery ```...

I know that floats are a bit icky when it comes to consts, but might it be possible using formatc and nightly?

Hello, currently I am having an issue when trying to match strings using `concatcp`: Let suppose we have following code: ```rust use const_format::concatcp; fn main() { const ABC: &str =...

The [readme is rendered wrong in docs.rs](https://docs.rs/crate/const_format/0.2.4) ,if somebody can figure out how to fix it, I'll merge the pull request.

bug
documentation

# Feature request I tried to use `formatcp` with generics, which caused an error. Is it possible to `formatcp` support generics? ```rust use const_format::formatcp; pub trait Named { const NAME:...