[llvm] [NFC] Move parameter into field (PR #91065)
Danny Mösch via llvm-commits
llvm-commits at lists.llvm.org
Sat May 4 08:29:52 PDT 2024
https://github.com/SimplyDanny created https://github.com/llvm/llvm-project/pull/91065
Fixes #89194.
>From 4f69606df89cff9075d9ebc95d15bcd531fdf506 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Danny=20M=C3=B6sch?= <danny.moesch at icloud.com>
Date: Sat, 4 May 2024 17:29:17 +0200
Subject: [PATCH] [NFC] Move parameter into field
---
llvm/include/llvm/LTO/legacy/LTOCodeGenerator.h | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/llvm/include/llvm/LTO/legacy/LTOCodeGenerator.h b/llvm/include/llvm/LTO/legacy/LTOCodeGenerator.h
index 06f1396c06fe82..d8e41fe922581f 100644
--- a/llvm/include/llvm/LTO/legacy/LTOCodeGenerator.h
+++ b/llvm/include/llvm/LTO/legacy/LTOCodeGenerator.h
@@ -97,13 +97,15 @@ struct LTOCodeGenerator {
void setFileType(CodeGenFileType FT) { Config.CGFileType = FT; }
void setCpu(StringRef MCpu) { Config.CPU = std::string(MCpu); }
- void setAttrs(std::vector<std::string> MAttrs) { Config.MAttrs = MAttrs; }
+ void setAttrs(std::vector<std::string> MAttrs) {
+ Config.MAttrs = std::move(MAttrs);
+ }
void setOptLevel(unsigned OptLevel);
void setShouldInternalize(bool Value) { ShouldInternalize = Value; }
void setShouldEmbedUselists(bool Value) { ShouldEmbedUselists = Value; }
void setSaveIRBeforeOptPath(std::string Value) {
- SaveIRBeforeOptPath = Value;
+ SaveIRBeforeOptPath = std::move(Value);
}
/// Restore linkage of globals
More information about the llvm-commits
mailing list