Skip to content

Commit

Permalink
Updated for Go 1.18 beta 1
Browse files Browse the repository at this point in the history
  • Loading branch information
ancientlore committed Dec 15, 2021
1 parent 8bb5f71 commit 1ca70d3
Show file tree
Hide file tree
Showing 14 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ env:
GO111MODULE=on

go:
- 1.16.x
- 1.18.x

before_install:
- go get github.com/mattn/goveralls
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module github.com/ancientlore/go-avltree/v2

go 1.15
go 1.18
2 changes: 1 addition & 1 deletion map.go2 → map.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ func (m *Map[K, V]) Find(key K) *V {
func (m *Map[K, V]) Do(f func(K, V) bool) {

if f != nil && m.t.root != nil {
iterateFunc(Pair[K, V])(func(e Pair[K, V]) bool {
iterateFunc[Pair[K, V]](func(e Pair[K, V]) bool {
return f(e.Key, e.Value)
}).iterate(m.t.root)
}
Expand Down
File renamed without changes.
8 changes: 4 additions & 4 deletions node.go2 → node.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@ type treeNode[T any] struct {
// Left and right nodes.
left, right *treeNode[T]

// The number of nodes in the left and right subtrees
// (excludes this node).
size int

// The contents of this node.
value T

// The balance factor of this node.
bal byte

// The number of nodes in the left and right subtrees
// (excludes this node).
size int
}

// leftSize returns the size of the left subtree
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit 1ca70d3

Please sign in to comment.