[llvm] a9c6c1d - [NFC] Fix deprecated use of lookupTarget in Kaleidoscope (#162220)
via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 6 21:52:25 PDT 2025
Author: Connector Switch
Date: 2025-10-07T12:52:21+08:00
New Revision: a9c6c1dde7be43c5522a7033f9d5f261e57eca1d
URL: https://github.com/llvm/llvm-project/commit/a9c6c1dde7be43c5522a7033f9d5f261e57eca1d
DIFF: https://github.com/llvm/llvm-project/commit/a9c6c1dde7be43c5522a7033f9d5f261e57eca1d.diff
LOG: [NFC] Fix deprecated use of lookupTarget in Kaleidoscope (#162220)
Related:
https://github.com/llvm/llvm-project/commit/009da92e19aa7536daee1553cc65e40e1bb60372
Added:
Modified:
llvm/examples/Kaleidoscope/Chapter8/toy.cpp
Removed:
################################################################################
diff --git a/llvm/examples/Kaleidoscope/Chapter8/toy.cpp b/llvm/examples/Kaleidoscope/Chapter8/toy.cpp
index 739b8954aa8b2..1575211978b96 100644
--- a/llvm/examples/Kaleidoscope/Chapter8/toy.cpp
+++ b/llvm/examples/Kaleidoscope/Chapter8/toy.cpp
@@ -1228,7 +1228,8 @@ int main() {
TheModule->setTargetTriple(Triple(TargetTriple));
std::string Error;
- auto Target = TargetRegistry::lookupTarget(TargetTriple, Error);
+ auto Target =
+ TargetRegistry::lookupTarget(TheModule->getTargetTriple(), Error);
// Print an error and exit if we couldn't find the requested target.
// This generally occurs if we've forgotten to initialise the
More information about the llvm-commits
mailing list