* Add TList<T>.list property for Delphi compatibility. Fixes #40642

This commit is contained in:
Michaël Van Canneyt 2024-02-15 12:22:05 +01:00
parent a3b730b0f1
commit aa4136ce52

View File

@ -186,12 +186,13 @@ type
protected
type // bug #24282
TArrayHelperBugHack = TArrayHelper<T>;
TArrayOfT = array of T;
private
FOnNotify: TCollectionNotifyEvent<T>;
function GetCapacity: SizeInt; inline;
protected
FLength: SizeInt;
FItems: array of T;
FItems: TArrayOfT;
function PrepareAddingItem: SizeInt; virtual;
function PrepareAddingRange(ACount: SizeInt): SizeInt; virtual;
@ -204,6 +205,7 @@ type
property Count: SizeInt read GetCount;
property Capacity: SizeInt read GetCapacity write SetCapacity;
property List: TArrayOfT read FItems;
property OnNotify: TCollectionNotifyEvent<T> read FOnNotify write FOnNotify;
procedure TrimExcess; virtual; abstract;