[fpc-devel] Local variable names and colision with attributes/properties names

Sven Barth pascaldragon at googlemail.com
Thu Sep 27 20:51:52 CEST 2012

On 27.09.2012 19:33, Marco van de Voort wrote:
> In our previous episode, Marcos Douglas said:
>> - Records... "R" (?)
>> - Constants... UPPER_CASE? cSomething?
>> At least we would have a good and unique style.
> IMHO, that's taking it too far. Usually there is only made a difference between
> scopes (e.g. field and parameter, or global symbol and field), that could
> cause confusion. Within the same scope, duplicate identifiers are already
> excluded.
> The Delphi notation is not entirely consistent though, the interface "I"
> prefix convention e.g.  is therefore not that logical, and probably
> inherited.
> Enums are also commonly prefixed, but I wouldn't mind an option to turn
> enums into a different scope (so that you can only use them qualified).
> IIRC a recent Delphi adds such switch, but I'm already used to it from my M2
> days.

{$scopedenums on/off} already works in FPC 2.6.0.


More information about the fpc-devel mailing list