5

I need to construct an std::tuple object so that std::tuple_size<T>::value = 0. Is there a way to do this?

Darius Duesentrieb
  • 837
  • 10
  • 20

1 Answers1

18
std::tuple<> empty;
using empty_t = std::tuple<>;
auto empty2 = std::make_tuple();
static_assert(std::tuple_size<std::tuple<>>::value == 0);
cmdLP
  • 1,658
  • 9
  • 19