[fpc-devel] Public modifier: brackets or not?

Sven Barth pascaldragon at googlemail.com
Mon Feb 24 00:09:09 CET 2020

Bart via fpc-devel <fpc-devel at lists.freepascal.org> schrieb am So., 23.
Feb. 2020, 16:35:

> However, this will compile also:
> Function Second : Real; [Public name ’second’];
> begin
>   Second := 1;
> end;
> So, what is the correct syntax?

Both are correct. The brackets allow a comma separated list of directives.
However as Mattias wrote this syntax conflicts with attributes and thus is
disabled if modeswitch PrefixedAttributes is enabled.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-devel/attachments/20200224/2e4c288a/attachment.html>

More information about the fpc-devel mailing list