Skip to content

Commit d39b606

Browse files
Add .rs- instead of .rc-extension to LLVM module name
1 parent b0280ac commit d39b606

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/librustc/middle/trans/base.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2741,15 +2741,15 @@ pub fn trans_crate(sess: session::Session,
27412741
let link_meta = link::build_link_meta(sess, crate.attrs, output,
27422742
&mut symbol_hasher);
27432743

2744-
// Append ".rc" to crate name as LLVM module identifier.
2744+
// Append ".rs" to crate name as LLVM module identifier.
27452745
//
27462746
// LLVM code generator emits a ".file filename" directive
27472747
// for ELF backends. Value of the "filename" is set as the
27482748
// LLVM module identifier. Due to a LLVM MC bug[1], LLVM
27492749
// crashes if the module identifer is same as other symbols
27502750
// such as a function name in the module.
27512751
// 1. http://llvm.org/bugs/show_bug.cgi?id=11479
2752-
let llmod_id = link_meta.crateid.name.clone() + ".rc";
2752+
let llmod_id = link_meta.crateid.name.clone() + ".rs";
27532753

27542754
let ccx = @CrateContext::new(sess,
27552755
llmod_id,

0 commit comments

Comments
 (0)