[Lazarus] Packages and units with the same name

Marcos Douglas B. Santos md at delfire.net
Fri Oct 13 21:32:37 CEST 2017


On Fri, Oct 13, 2017 at 4:16 PM, Mattias Gaertner via Lazarus
<lazarus at lists.lazarus-ide.org> wrote:
> On Fri, 13 Oct 2017 15:42:27 -0300
> "Marcos Douglas B. Santos via Lazarus" <lazarus at lists.lazarus-ide.org>
> wrote:
>
>>[...]
>> I thought that only units included in package would be visible outside
>> (other programs/packages) but I realized that doesn't matter if were
>> included or not, the visibility is defined only by path (-Fu).
>
> Correct. Unit names must be unique in a program.

Right. But when we use 3rd packages, we don't control which names they
will use to name their units.
Moreover, I believe each package should work only in a bounded
context. Its developers should not named their files considering that
these names could be used in a bigger context. Don't you agree?

IMHO, would be better if packages may have just some "exported units".
What do you think?

Best regards,
Marcos Douglas


More information about the Lazarus mailing list