[fpc-pascal] type helper default property

Mattias Gaertner nc-gaertnma at netcologne.de
Thu Jan 17 13:17:37 CET 2019


For example:
  THelper = type helper for string
    function GetItems(Index: word): word;
    property Items[Index: word]: word read GetItems; default;

Delphi forbids this with "'default' directive not allowed in record
helper type".
FPC ignores it. Aka aString[1] has still the normal meaning.

Same for arrays, double, integers.

Is this an oversight, or has FPC some use for the default directive?


More information about the fpc-pascal mailing list