Am 08.02.2014 16:56, schrieb Jürgen Hestermann:
because otherwise I would get an error in case the length is 0
because Low() and High() both give back 0.
The result of both functions is the same as if the array had exact one
element.
Here:
var MyArray : array of longint;
begin
writeln(low(MyArray));
writeln(high(MyArray));
end.
prints
0
-1
Unfortunatly you posted not a complete example which shows the behaviour
but only uncompilable code snippts. Post always complete examples when
discussing strange behaviour.
_______________________________________________
fpc-pascal maillist - fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal