[Lazarus] Strange dependency of units

J├╝rgen Hestermann juergen.hestermann at gmx.de
Sat Mar 31 13:51:28 CEST 2012

I have my own general purpose unit with functions and procedures I often 
use. There are also some routines that operate on TStringGrid types so I 
had to add GRIDS to the uses clause in the interface part of this unit. 
If I now write a very simple "Hello World" program that uses just one 
simple function from my unit I get errors

Error: Undefined symbol: WSRegisterCustomImageList
Error: Undefined symbol: WSRegisterMenuItem

at the end of my program. After a long searching I found out that I had 
to add INTERFACES to the uses clause of my program. My questions:

How should anybody know that this is required in this situation?
Why is the INTERFACES unit not required in the unit itself?

More information about the Lazarus mailing list