1
0
mirror of https://github.com/mgechev/revive.git synced 2025-11-25 22:12:38 +02:00

docs: improve comments for functions; enable godot (#1382)

This commit is contained in:
Oleksandr Redko
2025-05-27 08:44:24 +03:00
committed by GitHub
parent 398f7a83eb
commit f4976873e7
49 changed files with 135 additions and 132 deletions

View File

@@ -21,7 +21,7 @@ type RuleConfig struct {
excludeFilters []*FileFilter
}
// Initialize - should be called after reading from TOML file
// Initialize should be called after reading from TOML file.
func (rc *RuleConfig) Initialize() error {
for _, f := range rc.Exclude {
ff, err := ParseFileFilter(f)
@@ -36,7 +36,7 @@ func (rc *RuleConfig) Initialize() error {
// RulesConfig defines the config for all rules.
type RulesConfig = map[string]RuleConfig
// MustExclude - checks if given filename `name` must be excluded
// MustExclude checks if given filename `name` must be excluded.
func (rc *RuleConfig) MustExclude(name string) bool {
for _, exclude := range rc.excludeFilters {
if exclude.MatchFileName(name) {