Skip to content

Commit 18b8e3b

Browse files
[ADT] Add a missing std::move to StringSwitch::EndsWithLower (#167151)
All others seem to use std::move in StringSwitch.
1 parent ace77c2 commit 18b8e3b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

llvm/include/llvm/ADT/StringSwitch.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ class StringSwitch {
158158

159159
StringSwitch &EndsWithLower(StringLiteral S, T Value) {
160160
if (!Result && Str.ends_with_insensitive(S))
161-
Result = Value;
161+
Result = std::move(Value);
162162

163163
return *this;
164164
}

0 commit comments

Comments
 (0)