I wanted to define a variadic tuple type to represent coordinates. For example, for some magic type:
template <unsigned int N>
struct CoordT {
typedef std::tuple<_some_magic_> coord_type;
};
I'd like to have CoordT<3>::coord_type to be the 3-dimensional coordinate type:
std::tuple<double, double, double>
.
But I don't know how to use template programming to generate N repeated doubles.
Can anyone please help explain how to write it?