On Fri, 25 Mar 2011 12:54:46 -0400, Trass3r <[email protected]> wrote:

Steven Schveighoffer Wrote:

Not only that, but it's compile-time, meaning there is no actual call to
some operator processor to generate the timestamp.

You forget CTFE ;)

CTFE is only used when you are defining a compile-time constant, or creating a static initializer.

literals are not CTFE'd. For example, an array literal still calls a runtime function to construct the array.

The call could also be optimized out, but when the literal is a generic template (not necessarily a function), you can *force* it to be compile-time, regardless of optimizations or inlining.

-Steve

Reply via email to