Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Force 4.0 Reference - 3253 array exceeds 64 k http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 3253                Array exceeds 64 K
------------------------------------------------------------------------------
 Description
   This error occurs when the full memory size of an array exceeds
   64 Kbytes. The total array size is calculated as the product of the
   number of elements and the size of each element. The limit is most
   likely to be exceeded with char arrays:

      vardef
         char        cStrings1[ 255 ]   // fits      256 * 255 = 65280
         char        cStrings1[ 256 ]   // too big   256 * 256 = 65535
         char( 254 ) cStrings3[ 256 ]   // fits      255 * 256 = 65280
      enddef

   Note that the length of a char variable without width specification
   is 255 bytes + 1 byte for the ending zero character.

 Solution
   Decrease the size of the array by decreasing the number of elements.
   Note that in practice a program that contains arrays that get near to
   the 64 Kbyte limit has no chance to pass the requirements imposed by the
   segmented memory architecture. Even if the compiler does not have a
   problem with the big arrays, the linker will. Store large amounts of
   data by other means than hardcoded arrays. Use allocated runtime memory
   or a non-volatile storage method, like a database.

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson