coord/base: don't use std::fill in constexpr constructor

This commit is contained in:
Danny Robson 2017-08-27 11:37:18 +10:00
parent 3c9dcba2fb
commit 8f216a0a27

View File

@ -57,8 +57,11 @@ namespace util::coord {
/// constructs an instance where all elements are initialised to `val'.
constexpr explicit
base (T val)
{ std::fill (begin (), end (), val); }
base (T fill)
{
for (decltype(S) i = 0; i < S; ++i)
this->data[i] = fill;
}
constexpr base (const base<S,T,KLASS,tags...> &rhs) = default;
base& operator= (const base<S,T,KLASS,tags...> &rhs) = default;