diff options
Diffstat (limited to 'source/blender/functions')
-rw-r--r-- | source/blender/functions/FN_attributes_ref.hh | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/source/blender/functions/FN_attributes_ref.hh b/source/blender/functions/FN_attributes_ref.hh index 1a4c1d2aadc..383b26330bf 100644 --- a/source/blender/functions/FN_attributes_ref.hh +++ b/source/blender/functions/FN_attributes_ref.hh @@ -24,6 +24,8 @@ * and index. */ +#include <optional> + #include "FN_spans.hh" #include "BLI_linear_allocator.hh" @@ -204,7 +206,7 @@ class MutableAttributesRef { return this->get<T>(m_info->index_of(name)); } - Optional<GMutableSpan> try_get(StringRef name, const CPPType &type) const + std::optional<GMutableSpan> try_get(StringRef name, const CPPType &type) const { int index = m_info->try_index_of(name, type); if (index == -1) { @@ -215,7 +217,7 @@ class MutableAttributesRef { } } - template<typename T> Optional<MutableSpan<T>> try_get(StringRef name) const + template<typename T> std::optional<MutableSpan<T>> try_get(StringRef name) const { int index = m_info->try_index_of(name); if (index == -1) { |