Skip to content

Commit 9b02acb

Browse files
committed
Fix formatting of multi-line blocks in asm-comments
1 parent f676547 commit 9b02acb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/rustc/middle/trans/build.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -653,7 +653,7 @@ fn add_comment(bcx: block, text: ~str) {
653653
let ccx = bcx.ccx();
654654
if !ccx.sess.no_asm_comments() {
655655
let sanitized = str::replace(text, ~"$", ~"");
656-
let comment_text = ~"# " + sanitized;
656+
let comment_text = ~"# " + str::replace(sanitized, ~"\n", ~"\n\t# ");
657657
let asm = str::as_c_str(comment_text, |c| {
658658
str::as_c_str(~"", |e| {
659659
count_insn(bcx, ~"inlineasm");

0 commit comments

Comments
 (0)