From fe22b1ad8090287325d1a678f5e4661e136a6331 Mon Sep 17 00:00:00 2001 From: Christian Zimmermann Date: Sun, 11 Apr 2021 16:34:01 +0200 Subject: [PATCH] im com + remove Getter class --- src/include/map_range.cc.h | 4 +- src/include/multi_array_operation.cc.h | 23 ++- src/include/multi_array_operation.h | 35 +++- src/include/pack_num.h | 21 +- src/include/statics/static_for.h | 25 +-- src/include/xfor/exttype.h | 262 +++++++++++++++++++++---- src/include/xfor/xfor.h | 156 +-------------- 7 files changed, 279 insertions(+), 247 deletions(-) diff --git a/src/include/map_range.cc.h b/src/include/map_range.cc.h index 8f786dd..4495c58 100644 --- a/src/include/map_range.cc.h +++ b/src/include/map_range.cc.h @@ -49,7 +49,7 @@ namespace MultiArrayTools if(pos != mIndPtr->max()){ const ExtType npos = last + mExt*pos; const size_t mnpos = PosForward::valuex(mlast, mStep, pos); - mExpr(mnpos, Getter::template getX( npos ) ); + mExpr(mnpos, getX( npos ) ); } } @@ -63,7 +63,7 @@ namespace MultiArrayTools if(pos != mIndPtr->max()){ const ExtType npos = last + mExt*pos; const size_t mnpos = PosForward::valuex(mlast, mStep, pos); - mExpr(mnpos, Getter::template getX( npos )); + mExpr(mnpos, getX( npos )); } } diff --git a/src/include/multi_array_operation.cc.h b/src/include/multi_array_operation.cc.h index e3f578a..6c0644f 100644 --- a/src/include/multi_array_operation.cc.h +++ b/src/include/multi_array_operation.cc.h @@ -226,29 +226,27 @@ namespace MultiArrayTools template inline size_t MOp::get(ExtType last) const { - return RootSumN::get(last,mOps); + return RootSumN::get(last,mOps.mOps); } template inline MOp& MOp::set(ExtType last) { - RootSumN::set(last,mOps); + RootSumN::set(last,mOps.mOps); return *this; } template template auto MOp::loop(Expr exp) const - -> decltype(PackNum::mkLoop( mOps, exp)) { - return PackNum::mkLoop( mOps, exp); + return MA_SCRAFOR(i,sizeof...(Ops),0,i-1,std::get(mOps.mOps),loop,exp); } template - auto MOp::rootSteps(std::intptr_t iPtrNum) const + auto MOp::rootSteps(std::intptr_t iPtrNum) const -> ExtType { - return MA_SCFOR(i,0,sizeof...(Ops),i+1,std::get(mOps).rootSteps(iPtrNum),extend); - //return RootSumN::rootSteps(mOps,iPtrNum); + return mOps.rootSteps(iPtrNum); } template @@ -989,7 +987,7 @@ namespace MultiArrayTools { typedef std::tuple OpTuple; return PackNum:: - template mkOpExpr(mF, pos, mOps); + template mkOpExpr(mF, pos, mOps.mOps); } template @@ -998,7 +996,7 @@ namespace MultiArrayTools { typedef std::tuple OpTuple; return PackNum:: - template mkVOpExpr>(mkVFuncPtr(mF), pos, mOps); // implement!!! + template mkVOpExpr>(mkVFuncPtr(mF), pos, mOps.mOps); // implement!!! } template @@ -1006,21 +1004,22 @@ namespace MultiArrayTools inline Operation& Operation::set(ET pos) { typedef std::tuple OpTuple; - PackNum::template setOpPos(mOps,pos); + PackNum::template setOpPos(mOps.mOps,pos); return *this; } template auto Operation::rootSteps(std::intptr_t iPtrNum) const + -> ExtType { - return MA_SCFOR(i,0,sizeof...(Ops),i+1,std::get(mOps).rootSteps(iPtrNum),extend); + return mOps.rootSteps(iPtrNum); } template template auto Operation::loop(Expr exp) const { - return MA_SCRAFOR(i,sizeof...(Ops),0,i-1,std::get(mOps),loop,exp); + return MA_SCRAFOR(i,sizeof...(Ops),0,i-1,std::get(mOps.mOps),loop,exp); } diff --git a/src/include/multi_array_operation.h b/src/include/multi_array_operation.h index e9ff90f..fedbec5 100644 --- a/src/include/multi_array_operation.h +++ b/src/include/multi_array_operation.h @@ -300,19 +300,33 @@ namespace MultiArrayTools template using AddExpr = AssignmentExpr,Target,OpClass,OIA>; + template + struct OperationTuple + { + OperationTuple(const Ops&... ops) : mOps(ops...) {} + std::tuple mOps; + auto rootSteps(std::intptr_t iPtrNum) const; + }; + + template + auto OperationTuple::rootSteps(std::intptr_t iPtrNum) const + { + return MA_SCFOR(i,0,sizeof...(Ops),i+1,std::get(mOps).rootSteps(iPtrNum),extend); + } + template class MOp { private: MOp() = default; - std::tuple mOps; - + OperationTuple mOps; + public: static constexpr size_t LAYER = 0; static constexpr size_t NHLAYER = 0; static constexpr size_t SIZE = (... + Ops::SIZE); - typedef decltype(RootSumN::rootSteps(mOps,0) ) ExtType; - + typedef decltype(mOps.rootSteps(0)) ExtType; + MOp(const Ops&... exprs); MOp(const MOp& in) = default; @@ -326,11 +340,10 @@ namespace MultiArrayTools inline size_t vget(ExtType last) const { return get(last); } inline MOp& set(ExtType last); - auto rootSteps(std::intptr_t iPtrNum = 0) const; + auto rootSteps(std::intptr_t iPtrNum = 0) const -> ExtType; template - auto loop(Expr exp) const - -> decltype(PackNum::mkLoop( mOps, exp)); + auto loop(Expr exp) const; T* data() const { assert(0); return nullptr; } @@ -782,8 +795,9 @@ namespace MultiArrayTools (... and (Ops::VABLE and std::is_same::value)); private: - std::tuple mOps; + OperationTuple mOps; std::shared_ptr mF; // only if non-static + typedef decltype(mOps.rootSteps(0)) ExtType; public: @@ -798,8 +812,9 @@ namespace MultiArrayTools template inline Operation& set(ET pos); - - auto rootSteps(std::intptr_t iPtrNum = 0) const; // nullptr for simple usage with decltype + + auto rootSteps(std::intptr_t iPtrNum = 0) const + -> ExtType; // nullptr for simple usage with decltype template auto loop(Expr exp) const; diff --git a/src/include/pack_num.h b/src/include/pack_num.h index 234e6bf..4f8c3b1 100644 --- a/src/include/pack_num.h +++ b/src/include/pack_num.h @@ -76,9 +76,9 @@ namespace MultiArrayHelper typedef typename std::remove_reference(ops))>::type NextOpType; static_assert(LAST >= NextOpType::SIZE, "inconsistent array positions"); static constexpr size_t NEXT = LAST - NextOpType::SIZE; - typedef decltype(std::get(ops).get(Getter::template getX( pos ))) ArgT; + typedef decltype(std::get(ops).get(getX( pos ))) ArgT; return PackNum::template mkOpExpr - ( f, pos, ops, std::get(ops).get(Getter::template getX( pos )), args...); + ( f, pos, ops, std::get(ops).get(getX( pos )), args...); } template @@ -87,9 +87,9 @@ namespace MultiArrayHelper typedef typename std::remove_reference(ops))>::type NextOpType; static_assert(LAST >= NextOpType::SIZE, "inconsistent array positions"); static constexpr size_t NEXT = LAST - NextOpType::SIZE; - typedef decltype(std::get(ops).template vget(Getter::template getX( pos ))) ArgT; + typedef decltype(std::get(ops).template vget(getX( pos ))) ArgT; return PackNum::template mkVOpExpr - ( f, pos, ops, std::get(ops).template vget(Getter::template getX( pos )), args...); + ( f, pos, ops, std::get(ops).template vget(getX( pos )), args...); } template @@ -132,7 +132,7 @@ namespace MultiArrayHelper typedef typename std::remove_reference(ot))>::type NextOpType; static_assert(LAST >= NextOpType::SIZE, "inconsistent array positions"); static constexpr size_t NEXT = LAST - NextOpType::SIZE; - std::get( ot ).set( Getter::template getX( et ) ); + std::get( ot ).set( getX( et ) ); PackNum::template setOpPos(ot, et); } }; @@ -174,9 +174,8 @@ namespace MultiArrayHelper typedef typename std::remove_reference(ops))>::type NextOpType; static constexpr size_t NEXT = LAST - NextOpType::SIZE; static_assert(NEXT == 0, "inconsistent array positions"); - typedef decltype(std::get<0>(ops).get(Getter<0>::template getX( pos ))) ArgT; - return Application::template apply(f, std::get<0>(ops).get(Getter<0>::template getX( pos )), args...); - //return OpFunction::apply(std::get<0>(ops).get(Getter<0>::template getX( pos )), args...); + typedef decltype(std::get<0>(ops).get(getX<0>( pos ))) ArgT; + return Application::template apply(f, std::get<0>(ops).get(getX<0>( pos )), args...); } template @@ -185,8 +184,8 @@ namespace MultiArrayHelper typedef typename std::remove_reference(ops))>::type NextOpType; static constexpr size_t NEXT = LAST - NextOpType::SIZE; static_assert(NEXT == 0, "inconsistent array positions"); - typedef decltype(std::get<0>(ops).template vget(Getter<0>::template getX( pos ))) ArgT; - return Application::template apply(f, std::get<0>(ops).template vget(Getter<0>::template getX( pos )), args...); + typedef decltype(std::get<0>(ops).template vget(getX<0>( pos ))) ArgT; + return Application::template apply(f, std::get<0>(ops).template vget(getX<0>( pos )), args...); } template @@ -229,7 +228,7 @@ namespace MultiArrayHelper typedef typename std::remove_reference(ot))>::type NextOpType; static constexpr size_t NEXT = LAST - NextOpType::SIZE; static_assert(NEXT == 0, "inconsistent array positions"); - std::get<0>( ot ).set( Getter::template getX( et ) ); + std::get<0>( ot ).set( getX( et ) ); } }; diff --git a/src/include/statics/static_for.h b/src/include/statics/static_for.h index a8c21a1..8176f9f 100644 --- a/src/include/statics/static_for.h +++ b/src/include/statics/static_for.h @@ -50,23 +50,12 @@ namespace MultiArrayTools //static_assert(abs(idx.value - END) >= abs(incr(idx) - END), // "this turns out to be a static endless loop"); auto tmp = f(idxm); - return sfor::unpack(incr, f, create, args..., tmp); - } - }; - - template - struct sfor - { - template - static inline auto exec(Incr incr, F f, Conc conc) - { - return 0; - } - - template - static inline auto unpack(Incr incr, F f, Create create, const Args&... args) - { - return create(args...); + if constexpr(BEG == END){ + return create(args...); + } + else { + return sfor::unpack(incr, f, create, args..., tmp); + } } }; } @@ -78,4 +67,6 @@ namespace MultiArrayTools #define MA_SCRAFOR(i,beg,end,decr,expr,conc,arg) sfor::exec([&](auto i) constexpr { return decr; }, [&](auto i){ return expr; }, [&](auto f, auto next) { return f.conc(next); }, arg) #define MA_CFOR(i,beg,end,incr,expr,cre) sfor::unpack([&](auto i) constexpr { return incr; }, [&](auto i){ expr }, [&](auto... args) { return cre(args...); }) +#define MA_SCFOR_X(i,beg,end,incr,expr,conc) sfor::exec([](auto i) constexpr { return incr; }, [](auto i){ return expr; }, [](auto f, auto next) { return f.conc(next); }) + #endif diff --git a/src/include/xfor/exttype.h b/src/include/xfor/exttype.h index b6202c4..50b2229 100644 --- a/src/include/xfor/exttype.h +++ b/src/include/xfor/exttype.h @@ -6,43 +6,91 @@ namespace MultiArrayHelper { - - template - struct Getter - { - template - static inline size_t get(const ExtType& et) - { - return Getter::get(et.next()); - } - - template - static inline auto getX(const ExtType& et) - -> decltype(Getter::getX(et.next())) - { - return Getter::getX(et.next()); - } - }; - - template <> - struct Getter<0> - { - template - static inline size_t get(const ExtType& et) - { - return et.get(); - } - - template - static inline auto getX(const ExtType& et) - -> ExtType - { - return et; - } - }; - + struct None; + class ExtBase + { + public: + ExtBase() = default; + ExtBase(const ExtBase& in) = default; + ExtBase(ExtBase&& in) = default; + ExtBase& operator=(const ExtBase& in) = default; + ExtBase& operator=(ExtBase&& in) = default; + + virtual size_t size() const = 0; + virtual const size_t& val() const = 0; + //virtual size_t rootSteps() const = 0; + virtual bool operator==(const ExtBase& in) const = 0; + virtual bool operator==(size_t in) const = 0; + + virtual std::shared_ptr operator+(const ExtBase& in) const = 0; + virtual std::shared_ptr operator*(size_t in) const = 0; + virtual void zero() = 0; + + virtual std::shared_ptr deepCopy() const = 0; + + template + const ExtType& expl() const; + + virtual std::string stype() const = 0; + }; + + typedef std::shared_ptr DExt; + + template + class ExtT : public ExtBase + { + private: + ExtType mExt; + public: + static constexpr size_t SIZE = ExtType::SIZE; + static constexpr size_t NUM = ExtType::NUM; + + ExtT() = default; + ExtT(const ExtT& in) = default; + ExtT(ExtT&& in) = default; + ExtT& operator=(const ExtT& in) = default; + ExtT& operator=(ExtT&& in) = default; + + ExtT(const ExtType& in) : mExt(in) {} + + virtual std::shared_ptr deepCopy() const override final { return std::make_shared>(mExt); } + + virtual size_t size() const override final { return sizeof(ExtType)/sizeof(size_t); } + //virtual size_t size() const override final { return ExtType::MExtSize(); } + //virtual size_t rootSteps() const override final; + const ExtType& ext() const { return mExt; } + virtual const size_t& val() const override final { return mExt.val(); } + virtual void zero() override final { mExt.zero(); } + + virtual bool operator==(const ExtBase& in) const override final + { return mExt == dynamic_cast&>(in).mExt; } + + virtual bool operator==(size_t in) const override final + { return mExt == in; } + + virtual DExt operator+(const ExtBase& in) const override final + { return std::make_shared>( mExt + dynamic_cast&>(in).mExt ); } + virtual DExt operator*(size_t in) const override final + { return std::make_shared>( mExt * in ); } + + virtual std::string stype() const override final { return std::string("T[") + mExt.stype() + "]"; } + }; + //class DExtT; + + template + DExt mkDExt(const ExtT& in) + { + return std::make_shared>(in); + } + + template + ExtT mkExtT(const ExtType& in) + { + return ExtT(in); + } + template class MExt { @@ -82,9 +130,7 @@ namespace MultiArrayHelper inline const X& next() const; template - inline auto nn() const - -> decltype(Getter::getX(*this)) - { return Getter::getX(*this); } + inline auto nn() const; inline bool operator==(const MExt& in) const { @@ -194,9 +240,7 @@ namespace MultiArrayHelper inline void zero(); template - inline auto nn() const - -> decltype(Getter::getX(*this)) - { return Getter::getX(*this); } + inline auto nn() const; inline MExt operator+(const MExt& in) const; inline MExt operator+(const None& in) const; @@ -210,7 +254,124 @@ namespace MultiArrayHelper }; + template + class DExtTX + { + private: + mutable DExt mDExt = nullptr; + X mNext; + template + friend class DExtTX; + public: + static constexpr size_t NUM = X::SIZE; + static constexpr size_t SIZE = NUM + 1; + + DExtTX() { mDExt = std::make_shared>(); } + DExtTX(const DExtTX& in) : mDExt(in.mDExt->deepCopy()), mNext(in.mNext) {} + DExtTX(DExtTX&& in) : mDExt(in.mDExt->deepCopy()), mNext(in.mNext) {} + DExtTX& operator=(const DExtTX& in) { mNext = in.mNext; mDExt = in.mDExt->deepCopy(); return *this; } + DExtTX& operator=(DExtTX&& in) { mNext = in.mNext; mDExt = in.mDExt->deepCopy(); return *this; } + explicit DExtTX(const DExt& in) : mDExt(in) {} + /* + template + DExtTX& operator=(const Y& y) { mDExt = std::make_shared>(y); return *this; } + + template + DExtTX(const Y& y) : mDExt(std::make_shared>(y)) {} + */ + bool operator==(const DExtTX& in) const + { return *mDExt == *in.mDExt and mNext == in.mNext; } + + bool operator==(size_t in) const + { return *mDExt == in and mNext == in; } + + template + DExtTX(const DExtTX& in) : mDExt(in.mDExt), mNext(in.mNext) {} + + DExtTX(const DExt& y, const X& x) : mDExt(y->deepCopy()), + mNext(x) {} + + virtual size_t size() const { return mDExt->size(); } + inline const DExt& get() const { return mDExt; } + + inline DExtTX reduce() const { return DExtTX(mDExt,None(0)); } + + inline DExtTX operator+(const DExtTX& in) const + { if (not mDExt) return in; else return DExtTX( (*mDExt) + (*in.mDExt), mNext + in.mNext ); } + inline DExtTX operator*(size_t in) const + { if (not mDExt) return *this; else return DExtTX((*mDExt) * in, mNext * in); } + + template + inline const ExtType& expl() const + { if(mDExt == nullptr) mDExt = std::make_shared>(); assert(mDExt != nullptr); return mDExt->expl(); } + + template + inline auto extend(const Y& y) const -> DExtTX + { return DExtTX(mDExt, mNext.extend(y)); } + + inline const size_t& val() const { return mDExt->val(); } + inline const X& next() const { return mNext; } + + inline void zero() { mDExt->zero(); } + + template + inline auto nn() const; + + std::string stype() const { return std::string("D[") + mDExt->stype() + "," + mNext.stype() + "]"; } + }; + + typedef DExtTX DExtT; + + inline MExt mkExt(size_t s) { return MExt(s); } + + + template + auto getX(const MExt& et) + { + if constexpr(I == 0){ + return et; + } + else { + return getX(et.next()); + } + } + + template + auto getX(const DExtTX& et) + { + if constexpr(I == 0){ + return et; + } + else { + return getX(et.next()); + } + } + + template + auto getX(const None& et) + { + static_assert(I == 0); + return et; + } + + template + size_t get(const MExt& et) + { + return getX(et).get(); + } + + template + size_t get(const DExtTX& et) + { + return getX(et).get(); + } + + template + size_t get(const None& et) + { + return getX(et).get(); + } } // end namespace MultiArrayHelper @@ -263,6 +424,13 @@ namespace MultiArrayHelper mNext.zero(); } + template + template + inline auto MExt::nn() const + { + return getX(*this); + } + template inline MExt MExt::operator+(const MExt& in) const { @@ -312,6 +480,12 @@ namespace MultiArrayHelper mExt = 0u; } + template + inline auto MExt::nn() const + { + return getX(*this); + } + inline const size_t& MExt::val() const { return mExt; @@ -334,6 +508,12 @@ namespace MultiArrayHelper return MExt(mExt * in); } + template + template + inline auto DExtTX::nn() const + { + return getX(*this); + } } // end namespace MultiArrayHelper diff --git a/src/include/xfor/xfor.h b/src/include/xfor/xfor.h index 372c334..0b761b3 100644 --- a/src/include/xfor/xfor.h +++ b/src/include/xfor/xfor.h @@ -23,159 +23,7 @@ namespace MultiArrayHelper //typedef std::pair DExt; - class ExtBase - { - public: - ExtBase() = default; - ExtBase(const ExtBase& in) = default; - ExtBase(ExtBase&& in) = default; - ExtBase& operator=(const ExtBase& in) = default; - ExtBase& operator=(ExtBase&& in) = default; - - virtual size_t size() const = 0; - virtual const size_t& val() const = 0; - //virtual size_t rootSteps() const = 0; - virtual bool operator==(const ExtBase& in) const = 0; - virtual bool operator==(size_t in) const = 0; - - virtual std::shared_ptr operator+(const ExtBase& in) const = 0; - virtual std::shared_ptr operator*(size_t in) const = 0; - virtual void zero() = 0; - virtual std::shared_ptr deepCopy() const = 0; - - template - const ExtType& expl() const; - - virtual std::string stype() const = 0; - }; - - typedef std::shared_ptr DExt; - - template - class ExtT : public ExtBase - { - private: - ExtType mExt; - public: - static constexpr size_t SIZE = ExtType::SIZE; - static constexpr size_t NUM = ExtType::NUM; - - ExtT() = default; - ExtT(const ExtT& in) = default; - ExtT(ExtT&& in) = default; - ExtT& operator=(const ExtT& in) = default; - ExtT& operator=(ExtT&& in) = default; - - ExtT(const ExtType& in) : mExt(in) {} - - virtual std::shared_ptr deepCopy() const override final { return std::make_shared>(mExt); } - - virtual size_t size() const override final { return sizeof(ExtType)/sizeof(size_t); } - //virtual size_t size() const override final { return ExtType::MExtSize(); } - //virtual size_t rootSteps() const override final; - const ExtType& ext() const { return mExt; } - virtual const size_t& val() const override final { return mExt.val(); } - virtual void zero() override final { mExt.zero(); } - - virtual bool operator==(const ExtBase& in) const override final - { return mExt == dynamic_cast&>(in).mExt; } - - virtual bool operator==(size_t in) const override final - { return mExt == in; } - - virtual DExt operator+(const ExtBase& in) const override final - { return std::make_shared>( mExt + dynamic_cast&>(in).mExt ); } - virtual DExt operator*(size_t in) const override final - { return std::make_shared>( mExt * in ); } - - virtual std::string stype() const override final { return std::string("T[") + mExt.stype() + "]"; } - }; - //class DExtT; - - template - DExt mkDExt(const ExtT& in) - { - return std::make_shared>(in); - } - - template - ExtT mkExtT(const ExtType& in) - { - return ExtT(in); - } - - template - class DExtTX - { - private: - mutable DExt mDExt = nullptr; - X mNext; - - template - friend class DExtTX; - public: - static constexpr size_t NUM = X::SIZE; - static constexpr size_t SIZE = NUM + 1; - - DExtTX() { mDExt = std::make_shared>(); } - DExtTX(const DExtTX& in) : mDExt(in.mDExt->deepCopy()), mNext(in.mNext) {} - DExtTX(DExtTX&& in) : mDExt(in.mDExt->deepCopy()), mNext(in.mNext) {} - DExtTX& operator=(const DExtTX& in) { mNext = in.mNext; mDExt = in.mDExt->deepCopy(); return *this; } - DExtTX& operator=(DExtTX&& in) { mNext = in.mNext; mDExt = in.mDExt->deepCopy(); return *this; } - explicit DExtTX(const DExt& in) : mDExt(in) {} - /* - template - DExtTX& operator=(const Y& y) { mDExt = std::make_shared>(y); return *this; } - - template - DExtTX(const Y& y) : mDExt(std::make_shared>(y)) {} - */ - bool operator==(const DExtTX& in) const - { return *mDExt == *in.mDExt and mNext == in.mNext; } - - bool operator==(size_t in) const - { return *mDExt == in and mNext == in; } - - template - DExtTX(const DExtTX& in) : mDExt(in.mDExt), mNext(in.mNext) {} - - DExtTX(const DExt& y, const X& x) : mDExt(y->deepCopy()), - mNext(x) {} - - virtual size_t size() const { return mDExt->size(); } - inline const DExt& get() const { return mDExt; } - - inline DExtTX reduce() const { return DExtTX(mDExt,None(0)); } - - inline DExtTX operator+(const DExtTX& in) const - { if (not mDExt) return in; else return DExtTX( (*mDExt) + (*in.mDExt), mNext + in.mNext ); } - inline DExtTX operator*(size_t in) const - { if (not mDExt) return *this; else return DExtTX((*mDExt) * in, mNext * in); } - - template - inline const ExtType& expl() const - { if(mDExt == nullptr) mDExt = std::make_shared>(); assert(mDExt != nullptr); return mDExt->expl(); } - - template - inline auto extend(const Y& y) const -> DExtTX - { return DExtTX(mDExt, mNext.extend(y)); } - - inline const size_t& val() const { return mDExt->val(); } - inline const X& next() const { return mNext; } - - inline void zero() { mDExt->zero(); } - - template - inline auto nn() const -> decltype(Getter::getX(*this)) - { return Getter::getX(*this); } - - std::string stype() const { return std::string("D[") + mDExt->stype() + "," + mNext.stype() + "]"; } - }; - - typedef DExtTX DExtT; - - inline MExt mkExt(size_t s) { return MExt(s); } class ExpressionBase { @@ -1061,7 +909,7 @@ namespace MultiArrayHelper const size_t pos = (*mSubSet)[last.val()]; const size_t mnpos = mlast; const ExtType npos = last + mExt*pos; - mExpr(mnpos, Getter<1>::template getX( npos )); + mExpr(mnpos, getX<1>( npos )); } template @@ -1072,7 +920,7 @@ namespace MultiArrayHelper const size_t pos = (*mSubSet)[last.val()]; const size_t mnpos = mlast; const ExtType npos = last + mExt*pos; - mExpr(mnpos, Getter<1>::template getX( npos )); + mExpr(mnpos, getX<1>( npos )); }