[llvm] 3888913 - [ADT] Remove deperecated methods in OptionalStorage
Kazu Hirata via llvm-commits
llvm-commits at lists.llvm.org
Sun Nov 20 12:24:22 PST 2022
Author: Kazu Hirata
Date: 2022-11-20T12:24:16-08:00
New Revision: 38889132d440261dc171be6bf95741f61ddc9028
URL: https://github.com/llvm/llvm-project/commit/38889132d440261dc171be6bf95741f61ddc9028
DIFF: https://github.com/llvm/llvm-project/commit/38889132d440261dc171be6bf95741f61ddc9028.diff
LOG: [ADT] Remove deperecated methods in OptionalStorage
Note that I deprecated these methods on August 7, 2022 in commit
commit b5f8d42efe3e246d582d4a1a328fac915e4ce8dc.
Added:
Modified:
llvm/include/llvm/ADT/Optional.h
Removed:
################################################################################
diff --git a/llvm/include/llvm/ADT/Optional.h b/llvm/include/llvm/ADT/Optional.h
index fc4737bfc9fe..d504560cfae4 100644
--- a/llvm/include/llvm/ADT/Optional.h
+++ b/llvm/include/llvm/ADT/Optional.h
@@ -190,36 +190,19 @@ template <typename T> class OptionalStorage<T, true> {
}
constexpr bool has_value() const noexcept { return hasVal; }
- LLVM_DEPRECATED("Use has_value instead.", "has_value")
- constexpr bool hasValue() const noexcept {
- return hasVal;
- }
T &value() &noexcept {
assert(hasVal);
return val;
}
- LLVM_DEPRECATED("Use value instead.", "value") T &getValue() &noexcept {
- assert(hasVal);
- return val;
- }
constexpr T const &value() const &noexcept {
assert(hasVal);
return val;
}
- LLVM_DEPRECATED("Use value instead.", "value")
- constexpr T const &getValue() const &noexcept {
- assert(hasVal);
- return val;
- }
T &&value() &&noexcept {
assert(hasVal);
return std::move(val);
}
- LLVM_DEPRECATED("Use value instead.", "value") T &&getValue() &&noexcept {
- assert(hasVal);
- return std::move(val);
- }
template <class... Args> void emplace(Args &&...args) {
reset();
More information about the llvm-commits
mailing list