I played with my post above a bit more and was able to write a C++14 version, but my MSVC still complains about "auto" appearing in a template parameter. Still, neither GCC nor Clang have any issue. I'll admit that I didn't really understand why MSVC is complaining, but perhaps someone could make headway with the version here, which is maybe closer to working: http://rextester.com/FTWIG95683 .
helios,
When you don't understand something, you can ask.
As for me, I never told I didn't understand the idea nor your question. I just say that maybe you have requirement or limitations you don't tell us about.
Keep cool man. If you don't need help, just don't ask.
@helios, you're not wrong, but the way you replied on page 1 could be interpreted as being deliberately harsh. I understand if you don't have patience for people that try a solution without understanding the problem--I'm not here to judge that--but expect to get more "comeback" justification responses like punksheep's or tpb's the next time.