[ADD] Static Analysis

This proposes a structure we can leverage for custom static analysis steps. The initial implementation contains a single analyzer that will fail the build on map iterations without a // analyze-ignore(map-iteration) comment. The following were flagged and have been ignored:

constants/constants.go:85:2: found map iteration
constants/constants.go:92:2: found map iteration
constants/constants.go:112:2: found map iteration
constants/constants.go:115:2: found map iteration
constants/constants.go:118:2: found map iteration
constants/constants.go:121:2: found map iteration
constants/constants.go:124:2: found map iteration
constants/constants.go:127:2: found map iteration
x/thorchain/types/type_tss.go:92:2: found map iteration
x/thorchain/keeper/v1/keeper_node_account.go:112:3: found map iteration
x/thorchain/keeper/v1/keeper_node_account.go:122:2: found map iteration
x/thorchain/keeper/v1/keeper_node_account.go:162:3: found map iteration
x/thorchain/keeper/v1/keeper_node_account.go:172:2: found map iteration
x/thorchain/genesis.go:351:2: found map iteration
x/thorchain/helpers_archive.go:481:2: found map iteration
x/thorchain/helpers_archive.go:548:2: found map iteration
x/thorchain/manager_observer_current.go:55:2: found map iteration
x/thorchain/manager_observer_current.go:65:2: found map iteration
x/thorchain/querier.go:505:2: found map iteration
x/thorchain/querier.go:592:3: found map iteration
x/thorchain/swap_v1.go:139:2: found map iteration
x/thorchain/swap_v1.go:160:3: found map iteration
x/thorchain/swap_v55.go:146:2: found map iteration
x/thorchain/swap_v55.go:167:3: found map iteration
x/thorchain/swap_v56.go:139:2: found map iteration
x/thorchain/swap_v56.go:160:3: found map iteration
Edited by Heimdall

Merge request reports

Loading