[Lazarus] How to find out why a unit is used in a project?

Bo Berglund bo.berglund at gmail.com
Thu Sep 24 15:22:12 CEST 2020

On Thu, 24 Sep 2020 14:22:13 +0200, Sven Barth via lazarus
<lazarus at lists.lazarus-ide.org> wrote:

>Well, Bo could always split the data type declarations into a separate

But I cannot wrap my head around this (constructed example):


 TMyRecord = packed record
   Item1: word;
   Item2: Cardinal;

TMyController = class
    FGPIO_driver: TIoDriver;
    FGpF: TIoPort;
    function CheckValidRelay(Relay: byte): boolean;
    constructor Create;
    destructor Destroy; override;
    procedure ClearRelays;
    function PulseRelay(Relay: byte; PulseTime: LongWord): boolean;
    function RelayOff(Relay: byte): boolean;
    function RelayOn(Relay: byte): boolean;
    function RelayState(Relay: byte): boolean;
    procedure Delay(T: LongWord);

  ...All of the methods here...

AFAIK the records could be declared elsewhere but the objects not
since their methods, constructor, destructor etc reside in the same
file below implementation, right?

Just specifying a uses file with everything above the implementation
will not cut it, right?

But as I indicated I have just moved on and I am leaving this because
it seems to do more harm than good and is a lot of work too.

Bo Berglund
Developer in Sweden

More information about the lazarus mailing list