Let's say I have a template structure:
template<typename... Args>
struct Foo {
static_assert(/*code*/);
//to do
}
I want to check in static_assert if types in Args
are all different types. I know how to do it using additional template structures and template specialization. Maybe there exists a one-line solution for this problem? I can use C++17
The linked question was asked 2 years ago and maybe there is a shorter solution which uses for example multiple pack expansion somehow.