Skip to content

Commit 3afa28b

Browse files
committed
Fix various lints
1 parent 08222a3 commit 3afa28b

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

pkg/cache/lru/lru.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,15 +83,15 @@ func (c *LRU[K, V]) Get(key K) (value V, ok bool) {
8383
return e.Value.(entry[K, V]).value, true
8484
}
8585
c.metrics.misses.Inc()
86-
return
86+
return value, ok
8787
}
8888

8989
// Peek returns the key value (or undefined if not found) without updating the "recently used"-ness of the key.
9090
func (c *LRU[K, V]) Peek(key K) (value V, ok bool) {
9191
if e, ok := c.items[key]; ok {
9292
return e.Value.(entry[K, V]).value, true
9393
}
94-
return
94+
return value, ok
9595
}
9696

9797
// Remove removes the provided key from the cache.

pkg/query/flamegraph_arrow.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1592,19 +1592,19 @@ func newChildBuf() childBuf {
15921592
}
15931593
}
15941594

1595-
func (b childBuf) reset() {
1595+
func (b *childBuf) reset() {
15961596
b.values = b.values[:0]
15971597
b.indexes = b.indexes[:0]
15981598
}
15991599

1600-
func (b childBuf) reserve(n int) {
1600+
func (b *childBuf) reserve(n int) {
16011601
if cap(b.values) < n {
16021602
b.values = make([]int64, 0, n)
16031603
b.indexes = make([]int, 0, n)
16041604
}
16051605
}
16061606

1607-
func (b childBuf) append(value int64, index int) {
1607+
func (b *childBuf) append(value int64, index int) {
16081608
b.indexes = append(b.indexes, index)
16091609
b.values = append(b.values, value)
16101610
}

0 commit comments

Comments
 (0)