Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJacques Lucke <jacques@blender.org>2020-06-29 15:29:05 +0300
committerJacques Lucke <jacques@blender.org>2020-06-29 15:30:06 +0300
commit18bff53c997f5bfac0435b8a03ee967eed8c9e20 (patch)
treeb0d3b788a7e2a64f746ba96e3456f01d7b274ca2 /source/blender/depsgraph
parent4fc5233467b1c273cdb82b221d8faa53249b99c6 (diff)
BLI: remove blender::Optional in favor of std::optional
`std::optional` can be used now, because we switched to C++17.
Diffstat (limited to 'source/blender/depsgraph')
-rw-r--r--source/blender/depsgraph/intern/depsgraph_type.h2
-rw-r--r--source/blender/depsgraph/intern/eval/deg_eval_runtime_backup_object.cc4
2 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/depsgraph/intern/depsgraph_type.h b/source/blender/depsgraph/intern/depsgraph_type.h
index 12150320391..5439a9dd31c 100644
--- a/source/blender/depsgraph/intern/depsgraph_type.h
+++ b/source/blender/depsgraph/intern/depsgraph_type.h
@@ -54,7 +54,6 @@ namespace DEG {
/* Commonly used types. */
using blender::Map;
-using blender::Optional;
using blender::Set;
using blender::Span;
using blender::StringRef;
@@ -62,6 +61,7 @@ using blender::StringRefNull;
using blender::Vector;
using blender::VectorSet;
using std::deque;
+using std::optional;
using std::pair;
using std::string;
using std::unique_ptr;
diff --git a/source/blender/depsgraph/intern/eval/deg_eval_runtime_backup_object.cc b/source/blender/depsgraph/intern/eval/deg_eval_runtime_backup_object.cc
index 975887ae7bf..71301ed45e5 100644
--- a/source/blender/depsgraph/intern/eval/deg_eval_runtime_backup_object.cc
+++ b/source/blender/depsgraph/intern/eval/deg_eval_runtime_backup_object.cc
@@ -172,10 +172,10 @@ void ObjectRuntimeBackup::restore_pose_channel_runtime_data(Object *object)
LISTBASE_FOREACH (bPoseChannel *, pchan, &object->pose->chanbase) {
/* This is nullptr in Edit mode. */
if (pchan->orig_pchan != nullptr) {
- Optional<bPoseChannel_Runtime> runtime = pose_channel_runtime_data.pop_try(
+ optional<bPoseChannel_Runtime> runtime = pose_channel_runtime_data.pop_try(
pchan->orig_pchan);
if (runtime.has_value()) {
- pchan->runtime = runtime.extract();
+ pchan->runtime = *runtime;
}
}
}