"bearophile" <[email protected]> wrote in message news:[email protected]...
Rainer Deyke:
(A function that performs I/O is
obviously not a candidate for CTFE.)

I don't fully agree, see this enhancement request of mine:
http://d.puremagic.com/issues/show_bug.cgi?id=3952

Bye,
bearophile

"performs I/O" refers to the semantics of the running program; the I/O is done at the time the function is invoked. I/O done by pragma(msg, ...) or ctputs is performed by the compiler, not by the function. Obviously, as Rainer said, no CTFE function can perform I/O since that I/O would never get performed by the running program.

Also, I think computing compile-time messages is an abuse of CTFE -- it certainly isn't its intended purpose.

Reply via email to