Wait, what? What is AliasSeq?

John Colvin via Digitalmars-d digitalmars-d at puremagic.com
Wed Jul 8 09:29:23 PDT 2015


On Tuesday, 7 July 2015 at 21:15:40 UTC, Andrei Alexandrescu 
wrote:
> So I thought we were supposed to replace bad names with good 
> names. Template arguments are indexable, so "sequence" doesn't 
> quite apply.
>
> What happened? Why are we replacing a crappy term with another 
> crappy term?
>
>
> Andrei

I reckon Collect would be a good name. It describes what you're 
doing: collecting some things together. Is also fits nicely with 
the currently private but hugely useful std.typetuple.Pack.


Collect: collect things together to one symbol, but they're not 
bound together, they'll auto-expand if they can.

Pack: pack things together, they only come apart explicitly (via 
.expand).


The best thing about it? It doesn't say anything misleading about 
the contents. It also doesn't say anything confusing about 
runtime vs compile-time.

Speaking as someone who's written ridiculous numbers of lines of 
code using TypeTuple and various incarnations of Pack, Collect 
fits my way of thinking.


More information about the Digitalmars-d mailing list