pub(crate) fn get_backend_from_raw_matches(
early_dcx: &EarlyDiagCtxt,
matches: &Matches,
) -> Box<dyn CodegenBackend>Expand description
Get the codegen backend based on the raw Matches.
rustc -vV and rustc -Cpasses=list need to get the codegen backend before we have parsed all
arguments and created a Session. This function reads -Zcodegen-backend, --target and
--sysroot without validating any other arguments and loads the codegen backend based on these
arguments.