mirror of
https://gitlab.com/pulsechaincom/erigon-pulse.git
synced 2025-01-07 19:41:19 +00:00
add constant kv.Unlim=-1 (#955)
This commit is contained in:
parent
a4034d5cea
commit
0b9404adb8
@ -61,6 +61,9 @@ import (
|
||||
|
||||
const ReadersLimit = 32000 // MDBX_READERS_LIMIT=32767
|
||||
|
||||
// const Unbounded []byte = nil
|
||||
const Unlim int = -1
|
||||
|
||||
var (
|
||||
ErrAttemptToDeleteNonDeprecatedBucket = errors.New("only buckets from dbutils.ChaindataDeprecatedTables can be deleted")
|
||||
|
||||
|
@ -126,7 +126,7 @@ func TestRange(t *testing.T) {
|
||||
_, tx, _ := BaseCase(t)
|
||||
|
||||
//[from, to)
|
||||
it, err := tx.RangeDescend("Table", []byte("key3"), []byte("key1"), -1)
|
||||
it, err := tx.RangeDescend("Table", []byte("key3"), []byte("key1"), kv.Unlim)
|
||||
require.NoError(t, err)
|
||||
require.True(t, it.HasNext())
|
||||
k, v, err := it.Next()
|
||||
|
Loading…
Reference in New Issue
Block a user