primitive vector types

Michel Fortin michel.fortin at michelf.com
Sat Feb 21 13:29:00 PST 2009


On 2009-02-21 15:11:15 -0500, Andrei Alexandrescu 
<SeeWebsiteForEmail at erdani.org> said:

> The conundrum is that a type system can't say that T[N] has some 
> semantics for N <= Nmax and some other semantics for N > Nmax. So we 
> need to pick one, and probably picking the value semantics is the right 
> thing to do.

I think it is the right decision too.

This way "static array" becomes the container type and "dynamic array" 
is the corresonding range type. Perhaps some concept renaming is in 
order for D2:

	static array  => array
	dynamic array => array range (or slice)

-- 
Michel Fortin
michel.fortin at michelf.com
http://michelf.com/




More information about the Digitalmars-d mailing list