Colin Grogan:
Currently, I've been using a lot of recursive templates, but its beginning to give me a headache and I'd like to see if there's better ways around it.
That's a good strategy. In some cases you can use Iota: https://d.puremagic.com/issues/show_bug.cgi?id=4085
On a related note, is there plans to add foreach support to CTFE?
Yes, it's being worked on now by Timon. See the latest DIP. Bye, bearophile