Time for std.reflection
Philippe Sigaud
philippe.sigaud at gmail.com
Mon Jul 23 03:27:40 PDT 2012
On Mon, Jul 23, 2012 at 9:46 AM, Simen Kjaeraas <simen.kjaras at gmail.com> wrote:
> Wrong way around. Try this:
>
>
> template Twice(double d)
> {
> enum Twice = d * 2;
> }
>
> double foo(double d)
> {
> return Twice!d;
> }
>
> void main()
> {
> enum t = foo(1.0);
> pragma(msg, t);
> }
Ah, that, OK. And __ctfe does not help.
Would it really limit the proposed scheme for std.reflection?
More information about the Digitalmars-d
mailing list