fix compile errors

This commit is contained in:
Christian Zimmermann 2022-11-12 00:15:26 +01:00
parent fb94a382bb
commit 113a0e7209
5 changed files with 8 additions and 23 deletions

View file

@ -9,7 +9,7 @@
namespace CNORXZ
{
template <SizeT O, SizeT... Is>
std::index_sequence<(Is+O)...> mkIsqAdd(std::index_sequence<is...> is) { return {}; }
std::index_sequence<(Is+O)...> mkIsqAdd(std::index_sequence<Is...> is) { return {}; }
template <SizeT B, SizeT E>
struct MkIsq
@ -17,14 +17,14 @@ namespace CNORXZ
static auto make()
{
static_assert(B <= E, "begin of sequence must be smaller than end of sequence");
return mkIsqAdd<B>( std::make_index_sequence<E-B> );
return mkIsqAdd<B>( std::make_index_sequence<E-B>{} );
}
typedef decltype(make()) type;
};
template <SizeT B, SizeT E>
using Isqr = MkIsq<B,E>::type;
using Isqr = typename MkIsq<B,E>::type;
}
#endif

View file

@ -3,7 +3,7 @@
#define __cxz_iter_cc_h__
#include "iter.h"
#include "functional/fundamental.h"
#include "xpr/func.h"
namespace CNORXZ
{
@ -11,10 +11,10 @@ namespace CNORXZ
constexpr decltype(auto) iteri(const G& g, const F& f, Isq<Is...> is)
{
if constexpr(std::is_same<F,NoF>::value){
( g(std::integral_constant<SizeT,Is>{}, args...), ... );
( g(std::integral_constant<SizeT,Is>{}), ... );
}
else {
return f( g(std::integral_constant<SizeT,Is>{}, args...) ... );
return f( g(std::integral_constant<SizeT,Is>{}) ... );
}
}

View file

@ -45,7 +45,7 @@ namespace CNORXZ
using TupleElem = std::tuple_element<I,Tuple<T...>>;
template <typename T>
using RemoveRef = std::remove_reference<T>::type;
using RemoveRef = typename std::remove_reference<T>::type;
template <typename K, typename V>
using Map = std::map<K,V>;

View file

@ -1,15 +0,0 @@
#ifndef __cxz_fundamental_h__
#define __cxz_fundamental_h__
#include <cstdlib>
namespace CNORXZ
{
struct NoF
{
constexpr void operator()() const {};
};
}
#endif

View file

@ -176,7 +176,7 @@ namespace CNORXZ
template <class PosT>
constexpr decltype(auto) FPos::extend(const PosT& a) const
{
return MPos<FPos,PosT1>(*this,a);
return MPos<FPos,PosT>(*this,a);
}
template <class PosT>