On Wednesday, 26 June 2013 at 20:51:54 UTC, Marco Leise wrote:
So the compiler would eagerly turn arguments into compile-time
parameters and offer some trait to check if a particular
instantiation of writefln made 'fmt' a template argument ?

Yeah, something like that. Or making literals a different type that we can overload on (which would also be kinda cool for user defined replacements for them).

writefln(T...)(__string_literal fmt, T t)

distinct from string fmt. The literals would always be available at compile time, whether the function is a template or not.

Reply via email to