Releases: dtolnay/indoc
Releases · dtolnay/indoc
0.2.1
-
Add an
unstable
feature that changes the implementation to be a Macros 2.0 macro. This is required in call sites that need a string literal rather than just a &'static str, such as in a format string. (#12)[dependencies] indoc = { version = "0.2.1", features = ["unstable"] }
#![feature(proc_macro)] extern crate indoc; use indoc::indoc; fn main() { let username = "Boscop"; let body = "Check this out"; let message = format!( indoc!(" Hello {username} ======{underline} {body} "), username = username, underline = "=".repeat(username.len()), body = body, ); print!("{}", message); }
0.2.0
- Rewrite to use
proc-macro-hack
and work on stable Rust