about summary refs log tree commit diff
path: root/compiler/rustc_mir/src/transform/coverage/debug.rs
diff options
context:
space:
mode:
authorMara Bos <m-ou.se@m-ou.se>2021-01-22 14:30:17 +0000
committerGitHub <noreply@github.com>2021-01-22 14:30:17 +0000
commit81a60b7aa8dca83e2c9543390cf116016192871a (patch)
treee12d9cae433f85c9956060f2380fba91b0bf9bfc /compiler/rustc_mir/src/transform/coverage/debug.rs
parent2ceee724270f2186e5e85acff49acd35bf8a652a (diff)
parentd0c1405564024d109ec22b130584d74fcb82d153 (diff)
downloadrust-81a60b7aa8dca83e2c9543390cf116016192871a.tar.gz
rust-81a60b7aa8dca83e2c9543390cf116016192871a.zip
Rollup merge of #81233 - lzutao:dbg, r=KodrAus
Document why not use concat! in dbg! macro

Original title: Reduce code generated by `dbg!` macro
The expanded code before/after: <https://rust.godbolt.org/z/hE3j95>.

---

We cannot use `concat!` since `file!` could contains `{` or the expression is a block (`{ .. }`).
Using it will generated malformed format strings.
So let's document this reason why we don't use `concat!` macro at all.
Diffstat (limited to 'compiler/rustc_mir/src/transform/coverage/debug.rs')
0 files changed, 0 insertions, 0 deletions