[fpc-pascal] Syntax problem with first unit

Tomas Hajny XHajT03 at mbox.vol.cz
Sun Apr 5 19:27:52 CEST 2009

On Sun, April 5, 2009 17:23, Francisco Reyes wrote:
> Michael Van Canneyt writes:
>>> It may help newcomers like myself if this was mentioned on the ref
>>> document.
>>> Just double checked and it does not mention this.
> In particular it would be helpful if that note (ie name of fuction and
> unit
> name can't be same) was in the unit section.

Well, this is something more general, not specific to units - using the
same identifier for different things (although possibly having different
scope) may lead to conflicts, of course. As an example, the same is true
for having the same name for a local variable (function, procedure) and a
global one. In this context, placing such a note in the unit section isn't
very logical. I haven't checked whether some hint in this sense appears in
the general section about identifiers, but that is the right place in my
opinion (if we want to mention something like that explicitly - note that
it's quite logical and everyone understands that if two people have the
same name, one needs to find some other means of differentiating between


More information about the fpc-pascal mailing list