[lazarus] More of a FPC question but... dynamic arrays

Peter Vreman peter at freepascal.org
Mon Sep 30 01:40:57 EDT 2002


> In Delphi 4 I used dynamically sized arrays using setlength to resize
> them as needed.
> 
> I haven't been able to get it to work in FPC / Lazarus, and it looks
> like the setlength function isn't there.  In fact, defining the array
> using:
> 
> var
> 	MyArray: array of TObject;
> 
> Doesn't work either...
> 
> This was a feature they added in Delphi 4.  I've got over 60,000 lines
> of code that rely heavily on this that I was looking to migrate to
> Lazarus.
> 
> Have I just missed something, or must I write my own linked list manager
> or use a TCollection to get this to work?

The 1.1 development compiler supports dynamic arrays.








More information about the Lazarus mailing list