Skip to content

Files

Latest commit

 

History

History
30 lines (19 loc) · 1.03 KB

exported.md

File metadata and controls

30 lines (19 loc) · 1.03 KB

Pattern: Undocumented exported function/method

Issue: -

Description

Exported function and methods should have comments. This warns on undocumented exported functions and methods.

More information here

Configuration

([]string) rule flags. Please notice that without configuration, the default behavior of the rule is that of its golint counterpart. Available flags are:

  • checkPrivateReceivers enables checking public methods of private types
  • disableStutteringCheck disables checking for method names that stutter with the package name (i.e. avoid failure messages of the form type name will be used as x.XY by other packages, and that stutters; consider calling this Y)
  • sayRepetitiveInsteadOfStutters replaces the use of the term stutters by repetitive in failure messages

Example:

[rule.exported]
  arguments =["checkPrivateReceivers","disableStutteringCheck"]

Further Reading