Documentation ¶
Overview ¶
Package gorules contains ruleguard linter rules.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func UberStyleErrors ¶ added in v0.50.0
UberStyleErrors detects error messages like
errors.Wrap(err, "failed to do something")
but you should avoid "failed to" and use
errors.Wrap(err, "do something")
according to https://github.com/uber-go/guide/blob/master/style.md#error-wrapping.
func UnnecessaryErrorFormat ¶ added in v0.50.0
UnnecessaryErrorFormat detects unnecessary error formatting like
errors.New("error")
and suggests instead
errors.New("error")
func ZapPreferNoWith ¶
ZapPreferNoWith suggests replace expressions like
l.With(...).Debug("")
to
l.Debug("", ...).
where l is a *zap.Logger.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.