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:
Diffstat (limited to 'source/blender/blenlib/BLI_array.hh')
-rw-r--r--source/blender/blenlib/BLI_array.hh10
1 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/blenlib/BLI_array.hh b/source/blender/blenlib/BLI_array.hh
index 352bf379d4d..80464499634 100644
--- a/source/blender/blenlib/BLI_array.hh
+++ b/source/blender/blenlib/BLI_array.hh
@@ -31,7 +31,7 @@
*
* A main benefit of using Array over Vector is that it expresses the intent of the developer
* better. It indicates that the size of the data structure is not expected to change. Furthermore,
- * you can be more certain that an array does not overallocate.
+ * you can be more certain that an array does not over-allocate.
*
* blender::Array supports small object optimization to improve performance when the size turns out
* to be small at run-time.
@@ -100,7 +100,7 @@ class Array {
/**
* Create a new array that contains copies of all values.
*/
- template<typename U, typename std::enable_if_t<std::is_convertible_v<U, T>> * = nullptr>
+ template<typename U, BLI_ENABLE_IF((std::is_convertible_v<U, T>))>
Array(Span<U> values, Allocator allocator = {}) : Array(NoExceptConstructor(), allocator)
{
const int64_t size = values.size();
@@ -112,7 +112,7 @@ class Array {
/**
* Create a new array that contains copies of all values.
*/
- template<typename U, typename std::enable_if_t<std::is_convertible_v<U, T>> * = nullptr>
+ template<typename U, BLI_ENABLE_IF((std::is_convertible_v<U, T>))>
Array(const std::initializer_list<U> &values, Allocator allocator = {})
: Array(Span<U>(values), allocator)
{
@@ -230,13 +230,13 @@ class Array {
return MutableSpan<T>(data_, size_);
}
- template<typename U, typename std::enable_if_t<is_span_convertible_pointer_v<T, U>> * = nullptr>
+ template<typename U, BLI_ENABLE_IF((is_span_convertible_pointer_v<T, U>))>
operator Span<U>() const
{
return Span<U>(data_, size_);
}
- template<typename U, typename std::enable_if_t<is_span_convertible_pointer_v<T, U>> * = nullptr>
+ template<typename U, BLI_ENABLE_IF((is_span_convertible_pointer_v<T, U>))>
operator MutableSpan<U>()
{
return MutableSpan<U>(data_, size_);