C++

hello, i am having some troubles wrapping my head around manipulating elements with templates

hello, i am having some troubles wrapping my head around manipulating elements with templates, using recursion i am able to do some processing on the types passed to my templated function but i can't seem to figure out how to pack the results into a tuple and return them.
I am getting <source>:34:6: note: candidate template ignored: invalid explicitly-specified argument for template parameter 'key_encoding'. And i dont understand why the template is not getting picked. It is clearly passing name lookup and is able to deduce the template argument but for some reason it is dropping the function
https://godbolt.org/z/h3lSgw <--- here is my code :confused: this is my first time writing slightly harder template code and i would appreciate the help. Thanks
You already invited:

Ali

Upvotes from:

here's a simpler version that compiles: https://godbolt.org/z/ttIOsw
not sure if it does the right thing, but should get you an idea for how to do this better :slightly_smiling_face:
(you could build things recursively like you tried, but not exactly as you tried - some additional logic for `Pack` concatenation would be necessary)

If you wanna answer this question please Login or Register