summaryrefslogtreecommitdiffstats
path: root/vespalib
diff options
context:
space:
mode:
authorTor Egge <Tor.Egge@broadpark.no>2021-02-21 17:30:59 +0100
committerTor Egge <Tor.Egge@broadpark.no>2021-02-21 17:30:59 +0100
commit39aa52502e7c2ff2981b4e51cf0217a6f7ac3538 (patch)
treecdbcf793200ca3b64ac0c614bb4be0086a241ffc /vespalib
parente4d417a2a1423aaab5d0b1b00369fb4fbe7757b3 (diff)
Eliminate array bounds warning.
Diffstat (limited to 'vespalib')
-rw-r--r--vespalib/src/tests/btree/btree_test.cpp4
-rw-r--r--vespalib/src/tests/btree/btreeaggregation_test.cpp4
2 files changed, 8 insertions, 0 deletions
diff --git a/vespalib/src/tests/btree/btree_test.cpp b/vespalib/src/tests/btree/btree_test.cpp
index b71aca92cd6..ec2b37f9546 100644
--- a/vespalib/src/tests/btree/btree_test.cpp
+++ b/vespalib/src/tests/btree/btree_test.cpp
@@ -517,6 +517,8 @@ Test::requireThatNodeSplitInsertWorks()
}
}
+namespace {
+
struct BTreeStealTraits
{
static constexpr size_t LEAF_SLOTS = 6;
@@ -525,6 +527,8 @@ struct BTreeStealTraits
static constexpr bool BINARY_SEEK = true;
};
+}
+
void
Test::requireThatNodeStealWorks()
{
diff --git a/vespalib/src/tests/btree/btreeaggregation_test.cpp b/vespalib/src/tests/btree/btreeaggregation_test.cpp
index 9ce57dbaf1d..a50c160351a 100644
--- a/vespalib/src/tests/btree/btreeaggregation_test.cpp
+++ b/vespalib/src/tests/btree/btreeaggregation_test.cpp
@@ -596,6 +596,8 @@ Test::requireThatTreeInsertWorks()
}
}
+namespace {
+
struct BTreeStealTraits
{
static constexpr size_t LEAF_SLOTS = 6;
@@ -604,6 +606,8 @@ struct BTreeStealTraits
static constexpr bool BINARY_SEEK = true;
};
+}
+
void
Test::requireThatNodeStealWorks()
{