Use lambdas and pack expansion to reduce template instantiations in action_dispatch

2 jobs for improved-action-dispatch in 469 minutes and 1 second
Status Job ID Name Coverage
  Test
passed #4832
amd64
job_clang_amd64

07:49:01

passed #4831
amd64
job_gcc_amd64

05:10:28