Revert "Revert "Reconstruct Template Parameters""

This reverts commit 25873bcc96a5df962c14d576e2509687bbf82bb3.