From 8e07123178b6a0c1909f60fc0c1546208c945a25 Mon Sep 17 00:00:00 2001 From: Yuya Asano <64895419+sukeya@users.noreply.github.com> Date: Tue, 18 Jul 2023 11:55:52 +0900 Subject: [PATCH] Fix calling default constructor by uniform init. I fixed calling default constructor in ImathTypeTraits.h by using uniform initialization. Signed-off-by: Yuya Asano <64895419+sukeya@users.noreply.github.com> --- src/Imath/ImathTypeTraits.h | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/src/Imath/ImathTypeTraits.h b/src/Imath/ImathTypeTraits.h index 60c85e1c..c3ad212a 100644 --- a/src/Imath/ImathTypeTraits.h +++ b/src/Imath/ImathTypeTraits.h @@ -85,8 +85,8 @@ template struct has_xy // Valid only if .x, .y exist and are the right type: return a Yes. template < typename C, - IMATH_ENABLE_IF (std::is_same::value), - IMATH_ENABLE_IF (std::is_same::value)> + IMATH_ENABLE_IF (std::is_same::value), + IMATH_ENABLE_IF (std::is_same::value)> static Yes& test (int); // Fallback, default to returning a No. @@ -113,9 +113,9 @@ template struct has_xyz // Valid only if .x, .y, .z exist and are the right type: return a Yes. template < typename C, - IMATH_ENABLE_IF (std::is_same::value), - IMATH_ENABLE_IF (std::is_same::value), - IMATH_ENABLE_IF (std::is_same::value)> + IMATH_ENABLE_IF (std::is_same::value), + IMATH_ENABLE_IF (std::is_same::value), + IMATH_ENABLE_IF (std::is_same::value)> static Yes& test (int); // Fallback, default to returning a No. @@ -142,10 +142,10 @@ template struct has_xyzw // Valid only if .x, .y, .z, .w exist and are the right type: return a Yes. template < typename C, - IMATH_ENABLE_IF (std::is_same::value), - IMATH_ENABLE_IF (std::is_same::value), - IMATH_ENABLE_IF (std::is_same::value), - IMATH_ENABLE_IF (std::is_same::value)> + IMATH_ENABLE_IF (std::is_same::value), + IMATH_ENABLE_IF (std::is_same::value), + IMATH_ENABLE_IF (std::is_same::value), + IMATH_ENABLE_IF (std::is_same::value)> static Yes& test (int); // Fallback, default to returning a No. @@ -173,7 +173,7 @@ template struct has_subscript template < typename C, IMATH_ENABLE_IF (std::is_same< - typename std::decay::type, + typename std::decay::type, Base>::value)> static Yes& test (int); @@ -208,7 +208,7 @@ struct has_double_subscript template < typename C, IMATH_ENABLE_IF (std::is_same< - typename std::decay::type, + typename std::decay::type, Base>::value)> static Yes& test (int);