Skip to content

Commit

Permalink
Fix unused linter warnings
Browse files Browse the repository at this point in the history
Fix the following warnings:

export_test.go:12:31: func `lowerCaseExport.foo` is unused (unused)
func (export lowerCaseExport) foo() (string, *Error) {
                              ^
conn.go:935:29: func `(*callTracker).finalize` is unused (unused)
func (tracker *callTracker) finalize(sn uint32) {
                            ^
variant_parser.go:420:2: field `val` is unused (unused)
	val      interface{}
	^
default_handler.go:218:25: func `(*exportedObj).isFallbackInterface` is unused (unused)
func (obj *exportedObj) isFallbackInterface() bool {
                        ^
variant_parser.go:577:2: field `val` is unused (unused)
	val        interface{}
	^

Signed-off-by: Kir Kolyshkin <[email protected]>
  • Loading branch information
kolyshkin committed Mar 1, 2022
1 parent b01fa8e commit 496d83c
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 21 deletions.
11 changes: 0 additions & 11 deletions conn.go
Original file line number Diff line number Diff line change
Expand Up @@ -941,17 +941,6 @@ func (tracker *callTracker) handleSendError(msg *Message, err error) {
}
}

// finalize was the only func that did not strobe Done
func (tracker *callTracker) finalize(sn uint32) {
tracker.lck.Lock()
defer tracker.lck.Unlock()
c, ok := tracker.calls[sn]
if ok {
delete(tracker.calls, sn)
c.ContextCancel()
}
}

func (tracker *callTracker) finalizeWithBody(sn uint32, sequence Sequence, body []interface{}) {
tracker.lck.Lock()
c, ok := tracker.calls[sn]
Expand Down
4 changes: 0 additions & 4 deletions default_handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -215,10 +215,6 @@ func (obj *exportedObj) LookupMethod(name string) (Method, bool) {
return nil, false
}

func (obj *exportedObj) isFallbackInterface() bool {
return false
}

func newExportedIntf(methods map[string]Method, includeSubtree bool) *exportedIntf {
return &exportedIntf{
methods: methods,
Expand Down
4 changes: 0 additions & 4 deletions export_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,6 @@ import (

type lowerCaseExport struct{}

func (export lowerCaseExport) foo() (string, *Error) {
return "bar", nil
}

type fooExport struct {
message Message
}
Expand Down
2 changes: 0 additions & 2 deletions variant_parser.go
Original file line number Diff line number Diff line change
Expand Up @@ -417,7 +417,6 @@ func (b boolNode) Value(sig Signature) (interface{}, error) {
type arrayNode struct {
set sigSet
children []varNode
val interface{}
}

func (n arrayNode) Infer() (Signature, error) {
Expand Down Expand Up @@ -574,7 +573,6 @@ type dictEntry struct {
type dictNode struct {
kset, vset sigSet
children []dictEntry
val interface{}
}

func (n dictNode) Infer() (Signature, error) {
Expand Down

0 comments on commit 496d83c

Please sign in to comment.