On 04/06/2012 04:23 PM, Steven Schveighoffer wrote:
Why should we be restricted to only structs? Or any type for that matter?


A restriction to only structs is not a restriction because structs can have arbitrary field types.

The benefit to using CTFE functions is that the compiler already knows
how to deal with them at compile-time. i.e. less work to make the
compiler implement this.


It is exactly the same amount of work because CTFE is able to execute struct constructors.

Reply via email to