]> git.lizzy.rs Git - rust.git/commit - src/tools/miri
Auto merge of #84507 - crlf0710:codegen_nonlocal_main_wrapper, r=nagisa
authorbors <bors@rust-lang.org>
Mon, 10 May 2021 00:42:31 +0000 (00:42 +0000)
committerbors <bors@rust-lang.org>
Mon, 10 May 2021 00:42:31 +0000 (00:42 +0000)
commitd29289c509c60c52b16277b0cce5abfc5cf06985
tree6a2acded658f23aa72493144a765bb951dce645f
parentc55c26cb36a988d5df8b9f4442dc8af93e687a39
parent89a67051a76f8511372d7b9f14610474b1dba6aa
Auto merge of #84507 - crlf0710:codegen_nonlocal_main_wrapper, r=nagisa

Add primary marker on codegen unit and generate main wrapper on primary codegen.

This is the codegen part of changes extracted from #84062.

This add a marker called `primary` on each codegen units, where exactly one codegen unit will be `primary = true` at a time. This specific codegen unit will take charge of generating `main` wrapper when `main` is imported from a foreign crate after the implementation of RFC 1260.

cc #28937

I'm not sure who should i ask for review for codegen changes, so feel free to reassign.
r? `@nagisa`