mirror of
https://github.com/prometheus/prometheus.git
synced 2024-11-09 23:24:05 -08:00
Clarify Postings.At() contract (#12921)
It's implicit, but should be explicit. It is invalid to call At() after a failed call to Next() or Seek(). Following up on https://github.com/prometheus/prometheus/pull/12906 Signed-off-by: Oleg Zaytsev <mail@olegzaytsev.com>
This commit is contained in:
parent
b787e5f190
commit
5bd8c8c561
|
@ -413,6 +413,7 @@ type Postings interface {
|
|||
Seek(v storage.SeriesRef) bool
|
||||
|
||||
// At returns the value at the current iterator position.
|
||||
// At should only be called after a successful call to Next or Seek.
|
||||
At() storage.SeriesRef
|
||||
|
||||
// Err returns the last error of the iterator.
|
||||
|
|
Loading…
Reference in a new issue