ImplicitVisibilityOption

Michalis Kamburelis edited this page Jan 7, 2017 · 3 revisions
Clone this wiki locally

When you declare a class, ObjectPascal rules say that default ("implicit") visibility of members is public, unless the class is declared within {$M+} state or the class inherits from another class declared in {$M+} state (like TPersistent) — then it’s published.

However, pasdoc cannot always absolutely correctly implement this behavior (only the compiler really knows whether class inherits from another class declared in {$M+} state; see old pasdoc bug #1221900).

You can control using the command-line option --implicit-visibility how exactly pasdoc handles members with "implicit visibility":

--implicit-visibility=public

Visibility of implicit members is public, unless the class is declared within {$M+} state, then visibility is published. This is the default setting.

--implicit-visibility=published

Visibility of implicit members is always published.

--implicit-visibility=implicit

Visibility of implicit members is always implicit. Implicit is new visibility kind, invented only for the sake of pasdoc. It’s another possible kind for --visible-members option_. By default, --visible-members do not include implicit members.

If you don’t use --implicit-visibility=implicit command-line option then no members will be ever considered as having an implicit visibility by pasdoc.