Skip to content

Commit

Permalink
Replace interface{} with any (#325)
Browse files Browse the repository at this point in the history
  • Loading branch information
deining authored Jan 3, 2025
1 parent f7a9441 commit bb0f300
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions account_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -145,10 +145,10 @@ func (r *recordingStorage) Unlock(ctx context.Context, name string) error {

type recordedCall struct {
name string
args []interface{}
args []any
}

func (r *recordingStorage) record(name string, args ...interface{}) {
func (r *recordingStorage) record(name string, args ...any) {
r.calls = append(r.calls, recordedCall{name: name, args: args})
}

Expand Down
4 changes: 2 additions & 2 deletions internal/testutil/testutil.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ func Failnow(t testing.TB, xs string, msgs ...string) {
t.FailNow()
}

func ObjectsAreEqual(expected, actual interface{}) bool {
func ObjectsAreEqual(expected, actual any) bool {
if expected == nil || actual == nil {
return expected == actual
}
Expand All @@ -84,7 +84,7 @@ func ObjectsAreEqual(expected, actual interface{}) bool {
return bytes.Equal(exp, act)
}

func ObjectsAreEqualValues(expected, actual interface{}) bool {
func ObjectsAreEqualValues(expected, actual any) bool {
if ObjectsAreEqual(expected, actual) {
return true
}
Expand Down

0 comments on commit bb0f300

Please sign in to comment.