Error: array dimension overflow
Spacen Jasset
spacenjasset at yahoo.co.uk
Fri Apr 4 02:50:03 PDT 2008
Jarrett Billingsley wrote:
> "Jarrett Billingsley" <kb3ctd2 at yahoo.com> wrote in message
> news:ft3757$11cb$1 at digitalmars.com...
>> "Spacen Jasset" <spacen at yahoo.co.uk> wrote in message
>> news:ft35ik$q7g$1 at digitalmars.com...
>>> Bill Baxter wrote:
>>>> Brian Hay wrote:
>>>>> Newbie Q:
>>>>>
>>>>> During compilation I'm getting the error: "array dimension overflow"
>>>>> but it doesn't provide any information as to where (module and line
>>>>> number) the error might be, so I'm at a loss. Other errors seem to
>>>>> provide such information.
>>>>>
>>>>> Any ideas?
>>>> I think there's a limit of 16K for the size of static arrays.
>>>> Do you have any really big static arrays?
>>>>
>>>> Anyway, the compiler should generate a line number for that. Not
>>>> providing one is a bug.
>>>>
>>>> --bb
>>> 16k Seems shockingly low. Is there documentation on this. Even old Dos
>>> compilers for C support close to 64k indexes.
>
> Son of a.
>
> Bill made a typo, the max is 16MB. While Walter says that this is because
> "any larger array should really be allocated at runtime and not in the
> static data segment", I think it's really because OPTLINK crashes if you
> have something larger than 16MB in the static data segment.
>
> 9_9
>
>
16Mb is more like it. Doubtless this limit will go away one day when the
need becomes more pressing. Nothing to worry about too much... moving
on. :-)
More information about the Digitalmars-d-learn
mailing list