[fpc-pascal] Range checks

Dmitry Boyarintsev skalogryz.lists at gmail.com
Sat Jan 27 17:03:20 CET 2018

On Sat, Jan 27, 2018 at 9:10 AM, C Western <l at c-m-w.me.uk> wrote:

> I can (more or less) see why, but it means that I can't (for example)
> compile the Cocoa widget set in 64 bit with bounds checking on, as then
> qword seems to be used as a count for, for example, NSarray.
> how about taking objc approach:

 RangeCheckCount = objccategory(NSArray)
    function intcount: Integer; message 'intcount';

{ RangeCheckCount }

function RangeCheckCount.intcount: Integer;

  arr : NSArray;

  for i:=0 to arr.intcount-1 do

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20180127/22342e5b/attachment.html>

More information about the fpc-pascal mailing list