[Bf-blender-cvs] [8897e4a6964] temp-multi-function-eval-varray: improve ownership hint

Jacques Lucke noreply at git.blender.org
Wed Apr 6 16:18:14 CEST 2022


Commit: 8897e4a6964b6645b2cf88e1bb7d9470e44362d3
Author: Jacques Lucke
Date:   Wed Apr 6 15:11:46 2022 +0200
Branches: temp-multi-function-eval-varray
https://developer.blender.org/rB8897e4a6964b6645b2cf88e1bb7d9470e44362d3

improve ownership hint

===================================================================

M	source/blender/blenlib/BLI_virtual_array.hh

===================================================================

diff --git a/source/blender/blenlib/BLI_virtual_array.hh b/source/blender/blenlib/BLI_virtual_array.hh
index bca0eb914a5..56476a2e52b 100644
--- a/source/blender/blenlib/BLI_virtual_array.hh
+++ b/source/blender/blenlib/BLI_virtual_array.hh
@@ -457,6 +457,11 @@ template<typename T, typename GetFunc> class VArrayImpl_For_Func final : public
       }
     });
   }
+
+  bool may_have_ownership() const override
+  {
+    return !std::is_trivially_destructible_v<GetFunc>;
+  }
 };
 
 /**



More information about the Bf-blender-cvs mailing list