29.02.2012 17:05, Sven Barth пишет:
It's not a bug in Delphi if they write it in the documentation. Whether we
should copy this behavior
is the question (maybe only in Delphi mode).
It cannot be fixed for Delphi mode only because a single copy of RTL is used
for all compiler modes.
The current situation where out of range 'length' parameter is adjusted but 'index' out of range
raises exception is simply self-inconsistent. It is also inconsistent with behavior of Copy for strings.
Adjusting index will neither cause any buffer overflows nor make code slower,
so it should be fixed.
Regards,
Sergei
_______________________________________________
fpc-devel maillist - fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel