From 2fcb2b5c16e21d2a94741e19bbe7443d88127273 Mon Sep 17 00:00:00 2001 From: Dmitry Vyukov Date: Thu, 4 Jun 2020 22:35:04 +0200 Subject: .golangci.yml: enable gocognit checker Finds too complex functions. Similar to gocyclo, but uses somewhat different metric. --- pkg/ifuzz/decode.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'pkg/ifuzz/decode.go') diff --git a/pkg/ifuzz/decode.go b/pkg/ifuzz/decode.go index b16c9f0bd..327fad82e 100644 --- a/pkg/ifuzz/decode.go +++ b/pkg/ifuzz/decode.go @@ -10,7 +10,7 @@ import ( // Decode decodes instruction length for the given mode. // It can have falsely decode incorrect instructions, // but should not fail to decode correct instructions. -// nolint: gocyclo, nestif +// nolint: gocyclo, nestif, gocognit func Decode(mode int, text []byte) (int, error) { if len(text) == 0 { return 0, fmt.Errorf("zero-length instruction") -- cgit mrf-deployment