[fpc-pascal] Record helper properties
ryan at thealchemistguild.com
Wed Apr 24 02:36:29 CEST 2019
> On Apr 23, 2019, at 8:28 PM, Alexander Grotewohl <alex at dcclost.com> wrote:
> under the checklistbox extender example.
> I'd guess it's looking for THelper.GetX and THelper.SetX in your and not finding them
Oh now I get it. Is this what I should be doing? I really didn’t want those getters so I’m putting them as strict private. The error message could be better on this.
Honestly this seems kind of crazy though. We’re making all this boiler plate because published fields? Why not just allow field access unless there are published fields? I’ve never used published fields personally so it’s an unfortunate restriction.
TRec = record
THelper = record helper for TRec
function GetX: integer; inline;
procedure SetX (newValue: integer); inline;
property F: integer read GetX write SetX;
function THelper.GetX: integer;
result := x;
procedure THelper.SetX (newValue: integer);
x := newValue;
More information about the fpc-pascal