"The total size of a static array cannot exceed 16Mb."

Walter Bright newshound1 at digitalmars.com
Tue Oct 2 16:03:36 PDT 2007


Vladimir Panteleev wrote:
> Yes, only one - when there should be none at all. *sigh*

For accessing a big array like that, it is hard to see how a single 
dereference through a register is going to affect the run time at all.


> Note that one thing which the compiler fails to prevent but still
> chokes the linker are having more than 16 Mb of data or even distinct
> types (which need initial values, such as structs/classes). Example:
> 
> uint[0x800000] a,b,c,d;
> 
> void main() { }
> 
> So - please, Just Fix That Linker ;)

Easier said than done :-(




More information about the Digitalmars-d mailing list