diff options
author | Kazu Hirata <kazu@google.com> | 2022-11-21 19:03:40 -0800 |
---|---|---|
committer | Kazu Hirata <kazu@google.com> | 2022-11-21 19:03:40 -0800 |
commit | 1f914944b6c9a5e4229ceb9f06140fdf178c5ea0 (patch) | |
tree | 970a2fd47cccb79d76035fde4bd2dd602da2e987 /llvm/lib/CodeGen/SafeStack.cpp | |
parent | b39b76f2ef30c75734baa04fc236fff621b65833 (diff) | |
download | llvm-1f914944b6c9a5e4229ceb9f06140fdf178c5ea0.zip llvm-1f914944b6c9a5e4229ceb9f06140fdf178c5ea0.tar.gz llvm-1f914944b6c9a5e4229ceb9f06140fdf178c5ea0.tar.bz2 |
Don't use Optional::getPointer (NFC)
Since std::optional does not offer getPointer(), this patch replaces
X.getPointer() with &*X to make the migration from llvm::Optional to
std::optional easier.
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
Differential Revision: https://reviews.llvm.org/D138466
Diffstat (limited to 'llvm/lib/CodeGen/SafeStack.cpp')
-rw-r--r-- | llvm/lib/CodeGen/SafeStack.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/SafeStack.cpp b/llvm/lib/CodeGen/SafeStack.cpp index 00a551a..0e65a0b 100644 --- a/llvm/lib/CodeGen/SafeStack.cpp +++ b/llvm/lib/CodeGen/SafeStack.cpp @@ -907,7 +907,7 @@ public: } else { // Otherwise, we need to compute it. LazilyComputedDomTree.emplace(F); - DT = LazilyComputedDomTree.getPointer(); + DT = &*LazilyComputedDomTree; ShouldPreserveDominatorTree = false; } |