Merge PR #1429: tools: Add ineffassign linter

* tools: Add ineffassign linter

This errors on assignments that don't actually do anything. i.e.

x, err := myFunc(1)
y, err = myFunc(2)

This will call out that the first function's call error was never
used.

* Fix makefile, add misspell to makefile
This commit is contained in:
Dev Ojha
2018-06-28 19:12:02 +02:00
committed by Christopher Goes
parent 2755c66545
commit 3e14868bd6
13 changed files with 81 additions and 28 deletions
+2 -2
View File
@@ -155,7 +155,7 @@ func TestIAVLSubspaceIterator(t *testing.T) {
iavlStore.Set([]byte{byte(255), byte(255), byte(1)}, []byte("test4"))
iavlStore.Set([]byte{byte(255), byte(255), byte(255)}, []byte("test4"))
i := 0
var i int
iter := sdk.KVStorePrefixIterator(iavlStore, []byte("test"))
expected := []string{"test1", "test2", "test3"}
@@ -214,7 +214,7 @@ func TestIAVLReverseSubspaceIterator(t *testing.T) {
iavlStore.Set([]byte{byte(255), byte(255), byte(1)}, []byte("test4"))
iavlStore.Set([]byte{byte(255), byte(255), byte(255)}, []byte("test4"))
i := 0
var i int
iter := sdk.KVStoreReversePrefixIterator(iavlStore, []byte("test"))
expected := []string{"test3", "test2", "test1"}