mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-09-24 22:02:23 +01:00
Use Overload of lookupTarget Accepting Triple (#6205)
The overload accepting a string/llvm::StringRef is deprecated and will be removed when LLVM 22 branches.
This commit is contained in:
@@ -885,7 +885,7 @@ auto CompileSubcommand::Run(DriverEnv& driver_env) -> DriverResult {
|
||||
// Validate the target before passing it to Clang.
|
||||
std::string target_error;
|
||||
const llvm::Target* target = llvm::TargetRegistry::lookupTarget(
|
||||
options_.codegen_options.target, target_error);
|
||||
llvm::Triple(options_.codegen_options.target), target_error);
|
||||
if (!target) {
|
||||
CARBON_DIAGNOSTIC(CompileTargetInvalid, Error, "invalid target: {0}",
|
||||
std::string);
|
||||
|
||||
Reference in New Issue
Block a user