[PATCH] D98494: [NFC] Minor cleanup to use default setting of getLastArg()
Maxim Kuvyrkov via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Mar 18 00:48:06 PDT 2021
This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.
Closed by commit rG6802fdf8871f: [NFC] Minor cleanup to use default setting of getLastArg() (authored by maxim-kuvyrkov).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D98494/new/
https://reviews.llvm.org/D98494
Files:
clang/lib/Driver/ToolChain.cpp
Index: clang/lib/Driver/ToolChain.cpp
===================================================================
--- clang/lib/Driver/ToolChain.cpp
+++ clang/lib/Driver/ToolChain.cpp
@@ -571,8 +571,8 @@
// Get -fuse-ld= first to prevent -Wunused-command-line-argument. -fuse-ld= is
// considered as the linker flavor, e.g. "bfd", "gold", or "lld".
- const Arg* A = Args.getLastArg(options::OPT_fuse_ld_EQ);
- StringRef UseLinker = A ? A->getValue() : CLANG_DEFAULT_LINKER;
+ StringRef UseLinker = Args.getLastArgValue(options::OPT_fuse_ld_EQ,
+ CLANG_DEFAULT_LINKER);
// --ld-path= takes precedence over -fuse-ld= and specifies the executable
// name. -B, COMPILER_PATH and PATH and consulted if the value does not
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D98494.331479.patch
Type: text/x-patch
Size: 736 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20210318/1486bda5/attachment.bin>
More information about the cfe-commits
mailing list