[Lazarus] OOP basics - 2

Graeme Geldenhuys graemeg.lists at gmail.com
Thu Apr 15 10:23:00 CEST 2010


2010/4/15 Juha Manninen <juha.manninen at phnet.fi>:
>
> "We never encountered a problem. We just typecast everything! Hey no
> problem!"
>
> Funny :-)

True.  Lazarus even forces new code contributions to always reference
units in the Interface section to force circular reference errors as
soon as possible (I was told that apparently FPC had a issue with
loading units - this must have been before my time). Then classes must
be slapped into a single large unit to overcome the issue. I
definitely agree Juha, it is not a great design idea.

I must confess, over the years I have hit circular reference problems,
but not many. In the cases that I did get the problem, I had to resort
to a base class, and then typecast later. I just assumed this is part
of the Object Pascal language design (to improve compilation speed),
and is now stuck with us forever.


-- 
Regards,
  - Graeme -


_______________________________________________
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/




More information about the Lazarus mailing list