[fpc-devel] is that intended? private type section in classes versus visibility
graemeg.lists at gmail.com
Sun Jul 25 12:37:20 CEST 2010
Renaming existing units for one project that conflicts is not a
On 24 July 2010 12:52, Marco van de Voort <marcov at stack.nl> wrote:
> Delphi dotted unit names are just a prefixes with a different separator
> char. Still, while no super solution, it would make duplication less likely
> (avg unitname would go up), and no ugly cryptic prefixes.
Does FPC support dotted unit names? eg
then fpGUI and LCL (and any other projects) could do similar.... eg:
Currently fpGUI already does something similar (as I stated before) by
prefixing all classes with 'Tfpg' and all units names are prefixed
with 'fpg_' eg:
I did this to minimize any possible conflicts, but other projects have
not done this, so they stand a much greater chance to get conflicts
with FPC or other projects.
I guess Object Pascal users will feel this is "weird" at first - I did
too with my change in fpGUI, but you soon get used to it. The benefits
outweigh with temporary "weird" factor. I would probably have
preferred a "dotted" unit naming format, but I think last time I
tried, FPC didn't support a dotted unit name.
> Other solutions that really involve two .pas files with the same name need
> something to uniquely identify them. E.g. Java does this with the location
> in the classpath hierarchy, but I doubt we would go that far.
Why not something like IInterface or IUnknown does by using a GUID
somewhere in the unit.
But then comes the problem that not all editors can generate a GUID
via a keyboard shortcut - but then, how to they program with
Interfaces (so maybe a GUID is not a issue).
- Graeme -
fpGUI - a cross-platform Free Pascal GUI toolkit
More information about the fpc-devel