From 3032f2594232ff480799e1560854dbfeea49fa97 Mon Sep 17 00:00:00 2001 From: conrad Date: Fri, 16 Sep 2022 14:30:23 +1000 Subject: [PATCH] simplifications --- include/armadillo_bits/fn_powext.hpp | 22 ++++++++++---------- include/armadillo_bits/glue_powext_bones.hpp | 1 - 2 files changed, 11 insertions(+), 12 deletions(-) diff --git a/include/armadillo_bits/fn_powext.hpp b/include/armadillo_bits/fn_powext.hpp index dd169ef5..899c5a91 100644 --- a/include/armadillo_bits/fn_powext.hpp +++ b/include/armadillo_bits/fn_powext.hpp @@ -27,18 +27,18 @@ arma_inline typename enable_if2 < - ( is_arma_type::value && is_arma_type::value && is_same_type::yes ), + is_arma_type::value, const Glue >::result pow ( - const T1& X, - const T2& Y + const T1& X, + const Base& Y ) { arma_extra_debug_sigprint(); - return Glue(X, Y); + return Glue(X, Y.get_ref()); } @@ -49,18 +49,18 @@ arma_inline typename enable_if2 < - ( is_arma_type::value && is_arma_type::value && is_cx::yes && is_same_type::yes ), + ( is_arma_type::value && is_cx::yes ), const mtGlue >::result pow ( - const T1& X, - const T2& Y + const T1& X, + const Base& Y ) { arma_extra_debug_sigprint(); - return mtGlue(X, Y); + return mtGlue(X, Y.get_ref()); } @@ -88,13 +88,13 @@ inline typename enable_if2 < - ( is_cx::yes && is_same_type::yes ), + is_cx::yes, Mat >::result pow ( - const subview_each1& X, - const Base& Y + const subview_each1& X, + const Base& Y ) { arma_extra_debug_sigprint(); diff --git a/include/armadillo_bits/glue_powext_bones.hpp b/include/armadillo_bits/glue_powext_bones.hpp index c0035391..10f6f9af 100644 --- a/include/armadillo_bits/glue_powext_bones.hpp +++ b/include/armadillo_bits/glue_powext_bones.hpp @@ -33,7 +33,6 @@ class glue_powext template inline static void apply(Mat& out, const Mat& A, const Mat& B); template inline static Mat apply(const subview_each1& X, const Base& Y); - };