projects
/
platform
/
upstream
/
llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4700e7c
)
[Support] Use std::optional in HashBuilder.h (NFC)
author
Kazu Hirata
<kazu@google.com>
Sun, 27 Nov 2022 22:16:06 +0000
(14:16 -0800)
committer
Kazu Hirata
<kazu@google.com>
Sun, 27 Nov 2022 22:16:06 +0000
(14:16 -0800)
This is part of an effort to migrate from llvm::Optional to
std::optional:
https://discourse.llvm.org/t/deprecating-llvm-optional-x-hasvalue-getvalue-getvalueor/63716
llvm/include/llvm/Support/HashBuilder.h
patch
|
blob
|
history
diff --git
a/llvm/include/llvm/Support/HashBuilder.h
b/llvm/include/llvm/Support/HashBuilder.h
index
5df0bc2
..
d2b47c8
100644
(file)
--- a/
llvm/include/llvm/Support/HashBuilder.h
+++ b/
llvm/include/llvm/Support/HashBuilder.h
@@
-23,6
+23,7
@@
#include "llvm/Support/type_traits.h"
#include <iterator>
+#include <optional>
#include <utility>
namespace llvm {
@@
-80,7
+81,7
@@
protected:
Hasher(*OptionalHasher) {}
private:
-
O
ptional<HasherT> OptionalHasher;
+
std::o
ptional<HasherT> OptionalHasher;
HasherT &Hasher;
};