Store arbitrary elements in contiguous memory
问题 I am trying to create a data structure, where it will hold N number of different types in contiguous memory. So at compile time I can say I want to store 4 elements of 3 different types, and in memory it will look like 111122223333. I've been going with a variadic template approach, which I think will do what I want, however I am not sure how to add the elements to each array in the add method. template<std::size_t N, typename... Args> class Batch { private: std::tuple<std::array<Args, N>...>