[fpc-pascal] Const Array Length (was Dynamic Array Length)
RainerStratmann at t-online.de
Sat Jan 2 17:23:27 CET 2010
Am Saturday 02 January 2010 16:34:57 schrieb JoshyFun:
> a: array[1..] or string = ('aaa', 'bbb', 'ccc');
That would be perfect.
Then you can automatically calculate the amount:
amax = sizeof( a ) div sizeof( a[ 1 ] );
And you are free to set the number of the first array, in this case 1.
Like Jürgen says it is not a big deal to change the upper border, but it would
make life easier a bit.
It would be a userfriendly bit.
May be people from delphi switch to fpc then... (ok not only for this reason,
but if there are another useful bits...)
Happy new year.
More information about the fpc-pascal