Closed
Description
The #[linkage]
feature has some code that generates a symbol, e.g. for foo
it generates extern_with_linkage_foo
.
We have some code that causes the compilation to fail if it can detect that the generated symbol is the source of a collision.
rust/src/librustc_codegen_llvm/consts.rs
Lines 130 to 147 in 4680580
But as far as I can tell, we have no tests of this feature.
While I was working on PR #61231, I tried to manufacture such a test, but it was not obvious to me how to actually set things up to make the scenario happen. I don't want to forget about the need for this test after I put that task aside, so I'm filing this issue.