[fpc-pascal] What is the difference between the declarations at the beginning of a class and those declared in the public section?
Frank Church
vfclists at gmail.com
Sun Nov 6 21:28:45 CET 2011
On 6 November 2011 18:33, Jonas Maebe <jonas.maebe at elis.ugent.be> wrote:
>
> On 06 Nov 2011, at 19:26, Frank Church wrote:
>
> > So it means that unless a field or method is in the private or protected
> > section
>
> or published, strict private or strict protected section
>
> > it is automatically public?
>
> Yes (or published in case of {$m+}, as Michael added).
>
>
>
If that is the case then a lot of Free Pascal and Delphi demos are teaching
bad practices because they make most members accessible externally when
there is no real reason to. I never thought about that much because I just
wanted to get my apps working rather than think about proper OOP practices,
especially in the case of UI objects like forms, controls etc
> Jonas
> _______________________________________________
> fpc-pascal maillist - fpc-pascal at lists.freepascal.org
> http://lists.freepascal.org/mailman/listinfo/fpc-pascal
>
--
Frank Church
=======================
http://devblog.brahmancreations.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20111106/a6e75099/attachment.html>
More information about the fpc-pascal
mailing list