I'm trying to create a template method to construct a packed parameter list of types at compile time by sequentially appending a new member type. I tried with a construct to define an alias for the packed parameter I found on the WEB:
template <typename... T> using... type_pack = T;
using... my_types = type_pack<int, char, double>;
and then (and here I am guessing on the syntax)
using... list = my_types.., new_member;
or maybe
using ... list = type_pack<my_types..., new_member>;
The compiler rejects the using... syntax. (I've tried g++ 9.4.0 with c++11,c++14 and c++17.)
$ c++ -o/dev/null -std=c++17 PackedParameters.cc
PackedParameters.cc:9:31: error: expected identifier before ‘...’ token
9 | template <typename... T> using... type_pack = T;
| ^~~
PackedParameters.cc:9:31: error: expected unqualified-id before ‘...’ token
PackedParameters.cc:10:6: error: expected nested-name-specifier before ‘...’ token
10 | using... my_types = type_pack<int, char, double>;
| ^~~
PackedParameters.cc:12:6: error: expected nested-name-specifier before ‘...’ token
12 | using... my_list = my_types..., int;
What am I missing?