On Thu, 03 Mar 2011 06:25:36 -0500, bearophile <bearophileh...@lycos.com> wrote:

Ali Çehreli:

<quote>
Template value parameter types can be any type which can be statically
initialized at compile time, and the value argument can be any
expression which can be evaluated at compile time. This includes
integers, floating point types, and strings.
</quote>

I have needed arrays as template specialization arguments few times (I have used alias to solve the problem). Allowing strings but not arrays is one limitation that I don't understand.

An array literal is a runtime-initialized entity, much to the chagrin of Don and others (like myself).

There have been several pushes to try and get Walter to change array literals to immutable compile-time things, but it has so far not been accepted.

-Steve

Reply via email to