On Wednesday, 26 September 2012 at 12:20:56 UTC, Dmitry Olshansky wrote:
On 25-Sep-12 23:29, kenji hara wrote:
My suggestion is very simple.
1. Change all words "built-in tuple" in the documentation to "built-in sequence". Then, in the D language world, we can have clarify name for
the built-in one.
2. Introduce new templates, Seq, TypeSeq, and ExpSeq.

    template Seq(T...) { alias T Seq; }    // identical with
std.typetuple.TypeTuple
template TypeSeq(T...) if (allSatisfy!(isType, T)) { alias T TypeSeq; } template ExpSeq(T...) if (allSatisfy!(isExpression, T)) { alias T ExpSeq; }

If you really want to a sequence with heterogeneous elements, use Seq template. Otherwise use TypeSeq or ExpSeq based on your purpose.

vote++;

vote++.

(This is also what would be in my never finished std.meta proposal – interesting how we seem to converge towards the same solutions in the metaprogramming space…)

David

Reply via email to