Documentation

Lean.Linter.InternalModule

Enables the Lean core internalModule linter, which warns when a module considered "internal" declares a declaration that is not itself "internal".

The intent is that declarations living in internal modules (for example, anything under the Lean namespace, or the omega/grind implementation modules) stay internal, rather than becoming part of a project's public API by accident.

This linter is off by default and is not intended for use by non-core projects. It is a member of the linter.coreInternal set, so it can also be enabled via set_option linter.coreInternal true.

A module or declaration is internal if one of its name components is one of these strings.

Equations
Instances For

    A module is internal if it is (a submodule of) one of these modules.

    Equations
    Instances For

      Whether mod is an "internal" module, i.e. one whose declarations should stay internal.

      Equations
      • One or more equations did not get rendered due to their size.
      Instances For

        A declaration is internal if it lives in (a namespace under) one of these namespaces.

        Equations
        Instances For

          Whether declName is an "internal" declaration.

          Equations
          • One or more equations did not get rendered due to their size.
          Instances For

            Enables the Lean core internalModule linter, which warns when a module considered "internal" declares a declaration that is not itself "internal".

            The intent is that declarations living in internal modules (for example, anything under the Lean namespace, or the omega/grind implementation modules) stay internal, rather than becoming part of a project's public API by accident.

            This linter is off by default and is not intended for use by non-core projects. It is a member of the linter.coreInternal set, so it can also be enabled via set_option linter.coreInternal true.

            Equations
            • One or more equations did not get rendered due to their size.
            Instances For