Skip to content

Commit 593452a

Browse files
committed
[lldb] Disable llvm::None deprecation warnings when including Swift
Swift hasn't migrated everything to `std::optional` yet, ignore the deprecation of `None` until that's been done.
1 parent 63cf602 commit 593452a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

llvm/include/llvm/ADT/None.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,12 @@
2222
namespace llvm {
2323
/// A simple null object to allow implicit construction of std::optional<T>
2424
/// and similar types without having to spell out the specialization's name.
25-
#ifndef SWIFT_TARGET // radar://112153764 -- remove once swift transitions
25+
#if !defined(SWIFT_TARGET) && !defined(LLDB_ENABLE_SWIFT) // radar://112153764 -- remove once swift transitions
2626
LLVM_DEPRECATED("Use std::nullopt_t instead", "std::nullopt_t")
2727
#endif // SWIFT_TARGET
2828
typedef std::nullopt_t NoneType;
2929

30-
#ifndef SWIFT_TARGET // radar://112153764 -- remove once swift transitions
30+
#if !defined(SWIFT_TARGET) && !defined(LLDB_ENABLE_SWIFT) // radar://112153764 -- remove once swift transitions
3131
LLVM_DEPRECATED("Use std::nullopt instead.", "std::nullopt")
3232
#endif // SWIFT_TARGET
3333
inline constexpr std::nullopt_t None = std::nullopt;

0 commit comments

Comments
 (0)