diff options
author | Kazu Hirata <kazu@google.com> | 2022-12-05 22:43:53 -0800 |
---|---|---|
committer | Kazu Hirata <kazu@google.com> | 2022-12-05 22:43:53 -0800 |
commit | 1d0ba311d88d02caa6b5e1607047fdb6c909b705 (patch) | |
tree | 4eeb2ba09521c345c633cb2b442e35c51de0b089 /lldb/bindings | |
parent | 2a1962542423f62928a4c2e6cf42e97b190de49d (diff) | |
download | llvm-1d0ba311d88d02caa6b5e1607047fdb6c909b705.tar.gz |
[lldb] Use std::nullopt instead of llvm::None (NFC)
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
Diffstat (limited to 'lldb/bindings')
-rw-r--r-- | lldb/bindings/python/python-wrapper.swig | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lldb/bindings/python/python-wrapper.swig b/lldb/bindings/python/python-wrapper.swig index adac8a405ab9..7342d9d7e82f 100644 --- a/lldb/bindings/python/python-wrapper.swig +++ b/lldb/bindings/python/python-wrapper.swig @@ -946,7 +946,7 @@ llvm::Optional<std::string> lldb_private::LLDBSWIGPythonRunScriptKeywordThread( lldb::ThreadSP thread) { if (python_function_name == NULL || python_function_name[0] == '\0' || !session_dictionary_name) - return llvm::None; + return std::nullopt; PyErr_Cleaner py_err_cleaner(true); @@ -956,7 +956,7 @@ llvm::Optional<std::string> lldb_private::LLDBSWIGPythonRunScriptKeywordThread( python_function_name, dict); if (!pfunc.IsAllocated()) - return llvm::None; + return std::nullopt; auto result = pfunc(ToSWIGWrapper(std::move(thread)), dict); @@ -993,7 +993,7 @@ llvm::Optional<std::string> lldb_private::LLDBSWIGPythonRunScriptKeywordFrame( lldb::StackFrameSP frame) { if (python_function_name == NULL || python_function_name[0] == '\0' || !session_dictionary_name) - return llvm::None; + return std::nullopt; PyErr_Cleaner py_err_cleaner(true); @@ -1003,7 +1003,7 @@ llvm::Optional<std::string> lldb_private::LLDBSWIGPythonRunScriptKeywordFrame( python_function_name, dict); if (!pfunc.IsAllocated()) - return llvm::None; + return std::nullopt; auto result = pfunc(ToSWIGWrapper(std::move(frame)), dict); |