summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--document/src/vespa/document/annotation/spantree.h2
-rw-r--r--document/src/vespa/document/base/testdocman.cpp1
-rw-r--r--document/src/vespa/document/select/valuenodes.cpp1
-rw-r--r--document/src/vespa/document/serialization/annotationdeserializer.cpp2
-rw-r--r--logd/src/logd/empty_forwarder.cpp1
-rw-r--r--searchcore/src/vespa/searchcore/proton/attribute/document_field_extractor.cpp1
-rw-r--r--searchcore/src/vespa/searchcore/proton/matching/partial_result.h2
-rw-r--r--searchcore/src/vespa/searchcorespi/index/iindexmaintaineroperations.h2
-rw-r--r--searchlib/src/apps/uniform/uniform.cpp1
-rw-r--r--searchlib/src/tests/fef/termfieldmodel/termfieldmodel_test.cpp22
-rw-r--r--searchlib/src/vespa/searchcommon/attribute/config.cpp7
-rw-r--r--searchlib/src/vespa/searchcommon/attribute/config.h7
-rw-r--r--searchlib/src/vespa/searchlib/attribute/load_utils.hpp1
-rw-r--r--searchlib/src/vespa/searchlib/attribute/readerbase.cpp8
-rw-r--r--searchlib/src/vespa/searchlib/attribute/readerbase.h7
-rw-r--r--searchlib/src/vespa/searchlib/bitcompression/compression.h2
-rw-r--r--searchlib/src/vespa/searchlib/bitcompression/countcompression.cpp1
-rw-r--r--searchlib/src/vespa/searchlib/bitcompression/pagedict4.h2
-rw-r--r--searchlib/src/vespa/searchlib/bitcompression/posocc_fields_params.cpp7
-rw-r--r--searchlib/src/vespa/searchlib/bitcompression/posocc_fields_params.h6
-rw-r--r--searchlib/src/vespa/searchlib/bitcompression/posocccompression.cpp1
-rw-r--r--searchlib/src/vespa/searchlib/diskindex/fieldreader.h8
-rw-r--r--searchlib/src/vespa/searchlib/diskindex/fileheader.cpp1
-rw-r--r--searchlib/src/vespa/searchlib/diskindex/fusion.cpp2
-rw-r--r--searchlib/src/vespa/searchlib/diskindex/zc4_posting_reader.cpp5
-rw-r--r--searchlib/src/vespa/searchlib/diskindex/zc4_posting_reader_base.cpp2
-rw-r--r--searchlib/src/vespa/searchlib/diskindex/zc4_posting_writer.cpp1
-rw-r--r--searchlib/src/vespa/searchlib/diskindex/zc4_posting_writer_base.cpp1
-rw-r--r--searchlib/src/vespa/searchlib/diskindex/zcposocciterators.cpp3
-rw-r--r--searchlib/src/vespa/searchlib/diskindex/zcposting.cpp1
-rw-r--r--searchlib/src/vespa/searchlib/diskindex/zcpostingiterators.cpp1
-rw-r--r--searchlib/src/vespa/searchlib/expression/documentfieldnode.cpp1
-rw-r--r--searchlib/src/vespa/searchlib/fef/objectstore.h2
-rw-r--r--searchlib/src/vespa/searchlib/fef/phrase_splitter_query_env.cpp1
-rw-r--r--searchlib/src/vespa/searchlib/fef/phrasesplitter.cpp1
-rw-r--r--searchlib/src/vespa/searchlib/fef/simpletermdata.h21
-rw-r--r--searchlib/src/vespa/searchlib/fef/termfieldmatchdataarray.h2
-rw-r--r--searchlib/src/vespa/searchlib/memoryindex/url_field_inverter.cpp1
-rw-r--r--searchlib/src/vespa/searchlib/query/tree/termnodes.cpp1
-rw-r--r--searchlib/src/vespa/searchlib/queryeval/fake_search.cpp11
-rw-r--r--searchlib/src/vespa/searchlib/queryeval/fake_search.h8
-rw-r--r--searchlib/src/vespa/searchlib/queryeval/same_element_search.cpp1
-rw-r--r--searchlib/src/vespa/searchlib/queryeval/simple_phrase_search.cpp1
-rw-r--r--searchlib/src/vespa/searchlib/test/diskindex/threelevelcountbuffers.cpp1
-rw-r--r--searchsummary/src/vespa/searchsummary/docsummary/docsumstate.cpp1
-rw-r--r--searchsummary/src/vespa/searchsummary/docsummary/geoposdfw.cpp1
-rw-r--r--streamingvisitors/src/vespa/vsm/vsm/docsumfilter.cpp1
-rw-r--r--vespalib/src/vespa/vespalib/btree/btreenodeallocator.h6
-rw-r--r--vespalib/src/vespa/vespalib/geo/zcurve.cpp28
-rw-r--r--vespalib/src/vespa/vespalib/geo/zcurve.h31
-rw-r--r--vespalib/src/vespa/vespalib/metrics/simple_metrics_manager.cpp1
-rw-r--r--vespalib/src/vespa/vespalib/metrics/stable_store.h5
-rw-r--r--vespalib/src/vespa/vespalib/util/fiddle.h6
-rw-r--r--vespalib/src/vespa/vespalib/util/latch.h1
54 files changed, 127 insertions, 115 deletions
diff --git a/document/src/vespa/document/annotation/spantree.h b/document/src/vespa/document/annotation/spantree.h
index a0010fafa74..8745fb4421d 100644
--- a/document/src/vespa/document/annotation/spantree.h
+++ b/document/src/vespa/document/annotation/spantree.h
@@ -4,7 +4,6 @@
#include "annotation.h"
#include <vector>
-#include <cassert>
namespace document {
struct SpanNode;
@@ -24,7 +23,6 @@ public:
SpanTree(vespalib::stringref name, std::unique_ptr<T> root)
: _name(name),
_root(std::move(root)) {
- assert(_root.get());
}
~SpanTree();
diff --git a/document/src/vespa/document/base/testdocman.cpp b/document/src/vespa/document/base/testdocman.cpp
index 471a2f8c196..d5b24b51f24 100644
--- a/document/src/vespa/document/base/testdocman.cpp
+++ b/document/src/vespa/document/base/testdocman.cpp
@@ -7,6 +7,7 @@
#include <vespa/document/fieldvalue/stringfieldvalue.h>
#include <vespa/vespalib/util/rand48.h>
#include <sstream>
+#include <cassert>
namespace document {
diff --git a/document/src/vespa/document/select/valuenodes.cpp b/document/src/vespa/document/select/valuenodes.cpp
index b3052cc07e2..06205e6b7d1 100644
--- a/document/src/vespa/document/select/valuenodes.cpp
+++ b/document/src/vespa/document/select/valuenodes.cpp
@@ -11,6 +11,7 @@
#include <vespa/vespalib/util/md5.h>
#include <vespa/document/util/stringutil.h>
#include <vespa/vespalib/text/lowercase.h>
+#include <cassert>
#include <iomanip>
#include <sys/time.h>
diff --git a/document/src/vespa/document/serialization/annotationdeserializer.cpp b/document/src/vespa/document/serialization/annotationdeserializer.cpp
index 41bc9ec8aaa..c449029440f 100644
--- a/document/src/vespa/document/serialization/annotationdeserializer.cpp
+++ b/document/src/vespa/document/serialization/annotationdeserializer.cpp
@@ -40,7 +40,7 @@ unique_ptr<SpanTree> AnnotationDeserializer::readSpanTree() {
deserializer.read(tree_name);
_nodes.clear();
SpanNode::UP root = readSpanNode();
- unique_ptr<SpanTree> span_tree(new SpanTree(tree_name.getValue(), std::move(root)));
+ auto span_tree = std::make_unique<SpanTree>(tree_name.getValue(), std::move(root));
uint32_t annotation_count = getInt1_2_4Bytes(_stream);
span_tree->reserveAnnotations(annotation_count);
diff --git a/logd/src/logd/empty_forwarder.cpp b/logd/src/logd/empty_forwarder.cpp
index dda03c46c01..b601ea6d890 100644
--- a/logd/src/logd/empty_forwarder.cpp
+++ b/logd/src/logd/empty_forwarder.cpp
@@ -5,6 +5,7 @@
#include <vespa/log/exceptions.h>
#include <vespa/log/log_message.h>
#include <vespa/vespalib/util/size_literals.h>
+#include <cassert>
#include <vespa/log/log.h>
LOG_SETUP(".logd.empty_forwarder");
diff --git a/searchcore/src/vespa/searchcore/proton/attribute/document_field_extractor.cpp b/searchcore/src/vespa/searchcore/proton/attribute/document_field_extractor.cpp
index c0c6f729509..9364be4570e 100644
--- a/searchcore/src/vespa/searchcore/proton/attribute/document_field_extractor.cpp
+++ b/searchcore/src/vespa/searchcore/proton/attribute/document_field_extractor.cpp
@@ -16,6 +16,7 @@
#include <vespa/searchcommon/common/undefinedvalues.h>
#include <vespa/vespalib/stllike/hash_map.hpp>
#include <vespa/vespalib/util/exceptions.h>
+#include <cassert>
using document::FieldValue;
using document::BoolFieldValue;
diff --git a/searchcore/src/vespa/searchcore/proton/matching/partial_result.h b/searchcore/src/vespa/searchcore/proton/matching/partial_result.h
index f4dc2e31d4d..314fefa3cc0 100644
--- a/searchcore/src/vespa/searchcore/proton/matching/partial_result.h
+++ b/searchcore/src/vespa/searchcore/proton/matching/partial_result.h
@@ -48,7 +48,7 @@ public:
_sortData.push_back(sd);
_sortDataSize += sd.second;
}
- virtual void merge(Source &rhs) override;
+ void merge(Source &rhs) override;
};
}
diff --git a/searchcore/src/vespa/searchcorespi/index/iindexmaintaineroperations.h b/searchcore/src/vespa/searchcorespi/index/iindexmaintaineroperations.h
index 9025b56dc27..0b089daff7c 100644
--- a/searchcore/src/vespa/searchcorespi/index/iindexmaintaineroperations.h
+++ b/searchcore/src/vespa/searchcorespi/index/iindexmaintaineroperations.h
@@ -19,7 +19,7 @@ struct IIndexMaintainerOperations {
using IFieldLengthInspector = search::index::IFieldLengthInspector;
using Schema = search::index::Schema;
using SelectorArray = search::diskindex::SelectorArray;
- virtual ~IIndexMaintainerOperations() {}
+ virtual ~IIndexMaintainerOperations() = default;
/**
* Creates a new memory index using the given schema.
diff --git a/searchlib/src/apps/uniform/uniform.cpp b/searchlib/src/apps/uniform/uniform.cpp
index 807b8d61a9e..95d2bb1a7d1 100644
--- a/searchlib/src/apps/uniform/uniform.cpp
+++ b/searchlib/src/apps/uniform/uniform.cpp
@@ -3,6 +3,7 @@
#include <vespa/vespalib/util/signalhandler.h>
#include <vespa/searchlib/bitcompression/compression.h>
#include <cinttypes>
+#include <cassert>
static uint64_t
maxExpGolombVal(uint64_t kValue, uint64_t maxBits)
diff --git a/searchlib/src/tests/fef/termfieldmodel/termfieldmodel_test.cpp b/searchlib/src/tests/fef/termfieldmodel/termfieldmodel_test.cpp
index 54a7d6ea286..4ac4c92f658 100644
--- a/searchlib/src/tests/fef/termfieldmodel/termfieldmodel_test.cpp
+++ b/searchlib/src/tests/fef/termfieldmodel/termfieldmodel_test.cpp
@@ -27,6 +27,26 @@ struct State {
State::State() : term(), md(), f3(nullptr), f5(nullptr), f7(nullptr), array() {}
State::~State() = default;
+/**
+ * convenience adapter for easy iteration
+ **/
+class SimpleTermFieldRangeAdapter
+{
+ SimpleTermData& _ref;
+ size_t _idx;
+ size_t _lim;
+public:
+ explicit SimpleTermFieldRangeAdapter(SimpleTermData& ref)
+ : _ref(ref), _idx(0), _lim(ref.numFields())
+ {}
+
+ [[nodiscard]] bool valid() const { return (_idx < _lim); }
+
+ [[nodiscard]] SimpleTermFieldData& get() const { return _ref.field(_idx); }
+
+ void next() { assert(valid()); ++_idx; }
+};
+
void testInvalidId() {
const TermFieldMatchData empty;
using search::queryeval::SearchIterator;
@@ -44,7 +64,7 @@ void testSetup(State &state) {
state.term.addField(5); // docfreq = 3
using FRA = search::fef::ITermFieldRangeAdapter;
- using SFR = search::fef::SimpleTermFieldRangeAdapter;
+ using SFR = SimpleTermFieldRangeAdapter;
// lookup terms
{
diff --git a/searchlib/src/vespa/searchcommon/attribute/config.cpp b/searchlib/src/vespa/searchcommon/attribute/config.cpp
index 70c2377289f..91495025dee 100644
--- a/searchlib/src/vespa/searchcommon/attribute/config.cpp
+++ b/searchlib/src/vespa/searchcommon/attribute/config.cpp
@@ -65,4 +65,11 @@ Config::operator==(const Config &b) const
_hnsw_index_params == b._hnsw_index_params;
}
+Config&
+Config::set_hnsw_index_params(const HnswIndexParams& params) {
+ assert(_distance_metric == params.distance_metric());
+ _hnsw_index_params = params;
+ return *this;
+}
+
}
diff --git a/searchlib/src/vespa/searchcommon/attribute/config.h b/searchlib/src/vespa/searchcommon/attribute/config.h
index 0102f362532..32cac7ec9d6 100644
--- a/searchlib/src/vespa/searchcommon/attribute/config.h
+++ b/searchlib/src/vespa/searchcommon/attribute/config.h
@@ -10,7 +10,6 @@
#include <vespa/searchcommon/common/dictionary_config.h>
#include <vespa/eval/eval/value_type.h>
#include <vespa/vespalib/datastore/compaction_strategy.h>
-#include <cassert>
#include <optional>
namespace search::attribute {
@@ -72,11 +71,7 @@ public:
_distance_metric = value;
return *this;
}
- Config& set_hnsw_index_params(const HnswIndexParams& params) {
- assert(_distance_metric == params.distance_metric());
- _hnsw_index_params = params;
- return *this;
- }
+ Config& set_hnsw_index_params(const HnswIndexParams& params);
Config& clear_hnsw_index_params() {
_hnsw_index_params.reset();
return *this;
diff --git a/searchlib/src/vespa/searchlib/attribute/load_utils.hpp b/searchlib/src/vespa/searchlib/attribute/load_utils.hpp
index 463a62ab01a..614e327942a 100644
--- a/searchlib/src/vespa/searchlib/attribute/load_utils.hpp
+++ b/searchlib/src/vespa/searchlib/attribute/load_utils.hpp
@@ -5,6 +5,7 @@
#include "load_utils.h"
#include "attributevector.h"
#include <vespa/searchcommon/attribute/multivalue.h>
+#include <cassert>
namespace search::attribute {
diff --git a/searchlib/src/vespa/searchlib/attribute/readerbase.cpp b/searchlib/src/vespa/searchlib/attribute/readerbase.cpp
index e4bc2c02ad6..382d9ccb110 100644
--- a/searchlib/src/vespa/searchlib/attribute/readerbase.cpp
+++ b/searchlib/src/vespa/searchlib/attribute/readerbase.cpp
@@ -6,6 +6,7 @@
#include <vespa/fastlib/io/bufferedfile.h>
#include <vespa/searchlib/util/filesizecalculator.h>
#include <vespa/vespalib/util/size_literals.h>
+#include <cassert>
#include <vespa/log/log.h>
LOG_SETUP(".search.attribute.readerbase");
@@ -73,6 +74,13 @@ ReaderBase::ReaderBase(AttributeVector &attr)
ReaderBase::~ReaderBase() = default;
+size_t
+ReaderBase::getEnumCount() const {
+ size_t dataSize = _datFile.data_size();
+ assert((dataSize % sizeof(uint32_t)) == 0);
+ return dataSize / sizeof(uint32_t);
+}
+
bool
ReaderBase::hasWeight() const {
return _weightFile.valid();
diff --git a/searchlib/src/vespa/searchlib/attribute/readerbase.h b/searchlib/src/vespa/searchlib/attribute/readerbase.h
index 070dc1f99fb..ff400acc824 100644
--- a/searchlib/src/vespa/searchlib/attribute/readerbase.h
+++ b/searchlib/src/vespa/searchlib/attribute/readerbase.h
@@ -4,7 +4,6 @@
#include <vespa/searchlib/util/file_with_header.h>
#include <vespa/searchlib/util/fileutil.h>
-#include <cassert>
namespace search {
@@ -25,11 +24,7 @@ public:
return (_idxFile.data_size()) /sizeof(uint32_t);
}
- size_t getEnumCount() const {
- size_t dataSize = _datFile.data_size();
- assert((dataSize % sizeof(uint32_t)) == 0);
- return dataSize / sizeof(uint32_t);
- }
+ size_t getEnumCount() const;
size_t getNumValues();
int32_t getNextWeight() { return _weightReader.readHostOrder(); }
diff --git a/searchlib/src/vespa/searchlib/bitcompression/compression.h b/searchlib/src/vespa/searchlib/bitcompression/compression.h
index a77d82d9e8f..2d6b8083d43 100644
--- a/searchlib/src/vespa/searchlib/bitcompression/compression.h
+++ b/searchlib/src/vespa/searchlib/bitcompression/compression.h
@@ -4,7 +4,6 @@
#include <vespa/searchlib/util/comprfile.h>
#include <vespa/vespalib/stllike/string.h>
-#include <cassert>
namespace vespalib {
@@ -1400,7 +1399,6 @@ public:
const uint8_t *
getByteCompr() const
{
- assert((_preRead & 7) == 0);
return reinterpret_cast<const uint8_t *>(getCompr()) +
(getBitOffset() >> 3);
}
diff --git a/searchlib/src/vespa/searchlib/bitcompression/countcompression.cpp b/searchlib/src/vespa/searchlib/bitcompression/countcompression.cpp
index cdae8058d76..7c38931df77 100644
--- a/searchlib/src/vespa/searchlib/bitcompression/countcompression.cpp
+++ b/searchlib/src/vespa/searchlib/bitcompression/countcompression.cpp
@@ -2,6 +2,7 @@
#include "countcompression.h"
#include <vespa/searchlib/index/postinglistcounts.h>
+#include <cassert>
namespace search::bitcompression {
diff --git a/searchlib/src/vespa/searchlib/bitcompression/pagedict4.h b/searchlib/src/vespa/searchlib/bitcompression/pagedict4.h
index 9208a5be3b8..b162bdc3f2b 100644
--- a/searchlib/src/vespa/searchlib/bitcompression/pagedict4.h
+++ b/searchlib/src/vespa/searchlib/bitcompression/pagedict4.h
@@ -3,8 +3,8 @@
#pragma once
#include "countcompression.h"
-#include <limits>
#include <vespa/vespalib/stllike/string.h>
+#include <cassert>
namespace search::bitcompression {
diff --git a/searchlib/src/vespa/searchlib/bitcompression/posocc_fields_params.cpp b/searchlib/src/vespa/searchlib/bitcompression/posocc_fields_params.cpp
index d2269787068..9d6258ce26f 100644
--- a/searchlib/src/vespa/searchlib/bitcompression/posocc_fields_params.cpp
+++ b/searchlib/src/vespa/searchlib/bitcompression/posocc_fields_params.cpp
@@ -5,6 +5,7 @@
#include <vespa/searchlib/index/schemautil.h>
#include <vespa/vespalib/data/fileheader.h>
#include <vespa/vespalib/stllike/asciistream.h>
+#include <cassert>
#include <vespa/log/log.h>
LOG_SETUP(".posocc_fields_params");
@@ -38,6 +39,12 @@ PosOccFieldsParams::operator=(const PosOccFieldsParams &rhs)
return *this;
}
+void
+PosOccFieldsParams::assertCachedParamsRef() const {
+ assert(_numFields == _params.size());
+ assert(_fieldParams == (_params.empty() ? nullptr : &_params[0]));
+}
+
bool
PosOccFieldsParams::operator==(const PosOccFieldsParams &rhs) const
diff --git a/searchlib/src/vespa/searchlib/bitcompression/posocc_fields_params.h b/searchlib/src/vespa/searchlib/bitcompression/posocc_fields_params.h
index 963a80f06dc..8748557e5a7 100644
--- a/searchlib/src/vespa/searchlib/bitcompression/posocc_fields_params.h
+++ b/searchlib/src/vespa/searchlib/bitcompression/posocc_fields_params.h
@@ -4,7 +4,6 @@
#include "posocc_field_params.h"
#include <vector>
-#include <cassert>
namespace search::bitcompression {
@@ -32,10 +31,7 @@ public:
_fieldParams = _params.empty() ? nullptr : &_params[0];
}
- void assertCachedParamsRef() const {
- assert(_numFields == _params.size());
- assert(_fieldParams == (_params.empty() ? nullptr : &_params[0]));
- }
+ void assertCachedParamsRef() const;
uint32_t getNumFields() const { return _numFields; }
const PosOccFieldParams *getFieldParams() const { return _fieldParams; }
diff --git a/searchlib/src/vespa/searchlib/bitcompression/posocccompression.cpp b/searchlib/src/vespa/searchlib/bitcompression/posocccompression.cpp
index fd6c723e901..8e1bfd2875c 100644
--- a/searchlib/src/vespa/searchlib/bitcompression/posocccompression.cpp
+++ b/searchlib/src/vespa/searchlib/bitcompression/posocccompression.cpp
@@ -7,6 +7,7 @@
#include <vespa/searchlib/index/postinglistparams.h>
#include <vespa/vespalib/stllike/asciistream.h>
#include <vespa/vespalib/data/fileheader.h>
+#include <cassert>
#include <vespa/log/log.h>
LOG_SETUP(".posocccompression");
diff --git a/searchlib/src/vespa/searchlib/diskindex/fieldreader.h b/searchlib/src/vespa/searchlib/diskindex/fieldreader.h
index 73b56559115..e97d5deb95c 100644
--- a/searchlib/src/vespa/searchlib/diskindex/fieldreader.h
+++ b/searchlib/src/vespa/searchlib/diskindex/fieldreader.h
@@ -1,14 +1,14 @@
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#pragma once
+#include "wordnummapper.h"
+#include "docidmapper.h"
+#include "fieldwriter.h"
#include <vespa/searchlib/index/postinglistcounts.h>
#include <vespa/searchlib/index/dictionaryfile.h>
#include <vespa/searchlib/index/docidandfeatures.h>
#include <vespa/searchlib/index/postinglistfile.h>
#include <vespa/searchlib/index/schemautil.h>
-#include "wordnummapper.h"
-#include "docidmapper.h"
-#include "fieldwriter.h"
namespace search::diskindex {
@@ -40,7 +40,7 @@ public:
using PostingListCounts = index::PostingListCounts;
using PostingListParams = index::PostingListParams;
- uint64_t _wordNum;
+ uint64_t _wordNum;
DocIdAndFeatures _docIdAndFeatures;
protected:
std::unique_ptr<DictionaryFileSeqRead> _dictFile;
diff --git a/searchlib/src/vespa/searchlib/diskindex/fileheader.cpp b/searchlib/src/vespa/searchlib/diskindex/fileheader.cpp
index 5399d70fbe7..432651278e0 100644
--- a/searchlib/src/vespa/searchlib/diskindex/fileheader.cpp
+++ b/searchlib/src/vespa/searchlib/diskindex/fileheader.cpp
@@ -6,6 +6,7 @@
#include <vespa/vespalib/data/fileheader.h>
#include <vespa/fastos/file.h>
#include <cinttypes>
+#include <cassert>
#include <arpa/inet.h>
#include <vespa/log/log.h>
diff --git a/searchlib/src/vespa/searchlib/diskindex/fusion.cpp b/searchlib/src/vespa/searchlib/diskindex/fusion.cpp
index 4fd9d116244..d12081ee89c 100644
--- a/searchlib/src/vespa/searchlib/diskindex/fusion.cpp
+++ b/searchlib/src/vespa/searchlib/diskindex/fusion.cpp
@@ -8,11 +8,9 @@
#include <vespa/searchlib/common/documentsummary.h>
#include <vespa/searchlib/common/i_flush_token.h>
#include <vespa/searchlib/index/schemautil.h>
-#include <vespa/vespalib/io/fileutil.h>
#include <vespa/vespalib/util/error.h>
#include <vespa/vespalib/util/exceptions.h>
#include <vespa/vespalib/util/lambdatask.h>
-#include <vespa/document/util/queue.h>
#include <filesystem>
#include <system_error>
diff --git a/searchlib/src/vespa/searchlib/diskindex/zc4_posting_reader.cpp b/searchlib/src/vespa/searchlib/diskindex/zc4_posting_reader.cpp
index 2170777dbd3..460fac36acc 100644
--- a/searchlib/src/vespa/searchlib/diskindex/zc4_posting_reader.cpp
+++ b/searchlib/src/vespa/searchlib/diskindex/zc4_posting_reader.cpp
@@ -3,6 +3,7 @@
#include "zc4_posting_reader.h"
#include "zc4_posting_header.h"
#include <vespa/searchlib/index/docidandfeatures.h>
+#include <cassert>
namespace search::diskindex {
@@ -19,9 +20,7 @@ Zc4PostingReader<bigEndian>::Zc4PostingReader(bool dynamic_k)
}
template <bool bigEndian>
-Zc4PostingReader<bigEndian>::~Zc4PostingReader()
-{
-}
+Zc4PostingReader<bigEndian>::~Zc4PostingReader() = default;
template <bool bigEndian>
void
diff --git a/searchlib/src/vespa/searchlib/diskindex/zc4_posting_reader_base.cpp b/searchlib/src/vespa/searchlib/diskindex/zc4_posting_reader_base.cpp
index b50835a648d..c71404d449b 100644
--- a/searchlib/src/vespa/searchlib/diskindex/zc4_posting_reader_base.cpp
+++ b/searchlib/src/vespa/searchlib/diskindex/zc4_posting_reader_base.cpp
@@ -3,7 +3,7 @@
#include "zc4_posting_reader_base.h"
#include "zc4_posting_header.h"
#include <vespa/searchlib/index/docidandfeatures.h>
-
+#include <cassert>
namespace search::diskindex {
using index::PostingListCounts;
diff --git a/searchlib/src/vespa/searchlib/diskindex/zc4_posting_writer.cpp b/searchlib/src/vespa/searchlib/diskindex/zc4_posting_writer.cpp
index 202ed5a23cd..3a1b7928c93 100644
--- a/searchlib/src/vespa/searchlib/diskindex/zc4_posting_writer.cpp
+++ b/searchlib/src/vespa/searchlib/diskindex/zc4_posting_writer.cpp
@@ -3,6 +3,7 @@
#include "zc4_posting_writer.h"
#include <vespa/searchlib/index/docidandfeatures.h>
#include <vespa/searchlib/index/postinglistcounts.h>
+#include <cassert>
using search::index::DocIdAndFeatures;
using search::index::PostingListCounts;
diff --git a/searchlib/src/vespa/searchlib/diskindex/zc4_posting_writer_base.cpp b/searchlib/src/vespa/searchlib/diskindex/zc4_posting_writer_base.cpp
index 3f44b56706a..8a84ccc5731 100644
--- a/searchlib/src/vespa/searchlib/diskindex/zc4_posting_writer_base.cpp
+++ b/searchlib/src/vespa/searchlib/diskindex/zc4_posting_writer_base.cpp
@@ -3,6 +3,7 @@
#include "zc4_posting_writer_base.h"
#include <vespa/searchlib/index/postinglistcounts.h>
#include <vespa/searchlib/index/postinglistparams.h>
+#include <cassert>
using search::index::PostingListCounts;
using search::index::PostingListParams;
diff --git a/searchlib/src/vespa/searchlib/diskindex/zcposocciterators.cpp b/searchlib/src/vespa/searchlib/diskindex/zcposocciterators.cpp
index b67a8409581..df33091a4e8 100644
--- a/searchlib/src/vespa/searchlib/diskindex/zcposocciterators.cpp
+++ b/searchlib/src/vespa/searchlib/diskindex/zcposocciterators.cpp
@@ -1,9 +1,10 @@
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#include "zcposocciterators.h"
+#include "zc4_posting_params.h"
#include <vespa/searchlib/bitcompression/posocc_fields_params.h>
#include <vespa/searchlib/fef/termfieldmatchdata.h>
-#include "zc4_posting_params.h"
+#include <cassert>
namespace search::diskindex {
diff --git a/searchlib/src/vespa/searchlib/diskindex/zcposting.cpp b/searchlib/src/vespa/searchlib/diskindex/zcposting.cpp
index ef540365208..c9a1563a8e3 100644
--- a/searchlib/src/vespa/searchlib/diskindex/zcposting.cpp
+++ b/searchlib/src/vespa/searchlib/diskindex/zcposting.cpp
@@ -8,6 +8,7 @@
#include <vespa/searchlib/index/postinglistparams.h>
#include <vespa/searchlib/common/fileheadercontext.h>
#include <vespa/vespalib/data/fileheader.h>
+#include <cassert>
#include <vespa/log/log.h>
LOG_SETUP(".diskindex.zcposting");
diff --git a/searchlib/src/vespa/searchlib/diskindex/zcpostingiterators.cpp b/searchlib/src/vespa/searchlib/diskindex/zcpostingiterators.cpp
index 66404c7a0ff..83a4ae20db5 100644
--- a/searchlib/src/vespa/searchlib/diskindex/zcpostingiterators.cpp
+++ b/searchlib/src/vespa/searchlib/diskindex/zcpostingiterators.cpp
@@ -4,6 +4,7 @@
#include <vespa/searchlib/fef/termfieldmatchdata.h>
#include <vespa/searchlib/fef/termfieldmatchdataarray.h>
#include <vespa/searchlib/bitcompression/posocccompression.h>
+#include <cassert>
namespace search::diskindex {
diff --git a/searchlib/src/vespa/searchlib/expression/documentfieldnode.cpp b/searchlib/src/vespa/searchlib/expression/documentfieldnode.cpp
index bd13c032a03..16f5ee04be4 100644
--- a/searchlib/src/vespa/searchlib/expression/documentfieldnode.cpp
+++ b/searchlib/src/vespa/searchlib/expression/documentfieldnode.cpp
@@ -6,6 +6,7 @@
#include <vespa/document/datatype/documenttype.h>
#include <vespa/vespalib/encoding/base64.h>
#include <vespa/vespalib/locale/c.h>
+#include <cassert>
#include <vespa/log/log.h>
LOG_SETUP(".searchlib.documentfieldnode");
diff --git a/searchlib/src/vespa/searchlib/fef/objectstore.h b/searchlib/src/vespa/searchlib/fef/objectstore.h
index 06575c61eb5..7ba08284111 100644
--- a/searchlib/src/vespa/searchlib/fef/objectstore.h
+++ b/searchlib/src/vespa/searchlib/fef/objectstore.h
@@ -2,7 +2,6 @@
#pragma once
#include <vespa/vespalib/stllike/hash_map.h>
-#include <cassert>
namespace search::fef {
@@ -66,7 +65,6 @@ const T &
as_value(const Anything &val) {
using WrapperType = AnyWrapper<T>;
const auto *wrapper = dynamic_cast<const WrapperType *>(&val);
- assert(wrapper != nullptr);
return wrapper->getValue();
}
diff --git a/searchlib/src/vespa/searchlib/fef/phrase_splitter_query_env.cpp b/searchlib/src/vespa/searchlib/fef/phrase_splitter_query_env.cpp
index dfa1d9886f7..bbbdbd69c67 100644
--- a/searchlib/src/vespa/searchlib/fef/phrase_splitter_query_env.cpp
+++ b/searchlib/src/vespa/searchlib/fef/phrase_splitter_query_env.cpp
@@ -43,7 +43,6 @@ PhraseSplitterQueryEnv::PhraseSplitterQueryEnv(const IQueryEnvironment & queryEn
TermFieldHandle numHandles = 0; // how many handles existed in underlying data
for (uint32_t i = 0; i < queryEnv.getNumTerms(); ++i) {
const ITermData *td = queryEnv.getTerm(i);
- assert(td != nullptr);
considerTerm(i, *td, fieldId);
numHandles += td->numFields();
}
diff --git a/searchlib/src/vespa/searchlib/fef/phrasesplitter.cpp b/searchlib/src/vespa/searchlib/fef/phrasesplitter.cpp
index 90a058eda00..b74f12bdb97 100644
--- a/searchlib/src/vespa/searchlib/fef/phrasesplitter.cpp
+++ b/searchlib/src/vespa/searchlib/fef/phrasesplitter.cpp
@@ -42,7 +42,6 @@ PhraseSplitter::update()
for (const auto &copy_info : _phrase_splitter_query_env.get_copy_info()) {
const TermFieldMatchData *src = _matchData->resolveTermField(copy_info.orig_handle);
TermFieldMatchData *dst = resolveSplittedTermField(copy_info.split_handle);
- assert(src != nullptr && dst != nullptr);
copyTermFieldMatchData(*dst, *src, copy_info.offsetInPhrase);
}
diff --git a/searchlib/src/vespa/searchlib/fef/simpletermdata.h b/searchlib/src/vespa/searchlib/fef/simpletermdata.h
index d501d0848e8..391a00e4c8a 100644
--- a/searchlib/src/vespa/searchlib/fef/simpletermdata.h
+++ b/searchlib/src/vespa/searchlib/fef/simpletermdata.h
@@ -7,7 +7,6 @@
#include "simpletermfielddata.h"
#include <vespa/searchlib/query/weight.h>
#include <vector>
-#include <cassert>
namespace search::fef {
@@ -128,24 +127,4 @@ public:
}
};
-/**
- * convenience adapter for easy iteration
- **/
-class SimpleTermFieldRangeAdapter
-{
- SimpleTermData& _ref;
- size_t _idx;
- size_t _lim;
-public:
- explicit SimpleTermFieldRangeAdapter(SimpleTermData& ref)
- : _ref(ref), _idx(0), _lim(ref.numFields())
- {}
-
- [[nodiscard]] bool valid() const { return (_idx < _lim); }
-
- [[nodiscard]] SimpleTermFieldData& get() const { return _ref.field(_idx); }
-
- void next() { assert(valid()); ++_idx; }
-};
-
}
diff --git a/searchlib/src/vespa/searchlib/fef/termfieldmatchdataarray.h b/searchlib/src/vespa/searchlib/fef/termfieldmatchdataarray.h
index 3c1b76ad40e..46d370ee8fe 100644
--- a/searchlib/src/vespa/searchlib/fef/termfieldmatchdataarray.h
+++ b/searchlib/src/vespa/searchlib/fef/termfieldmatchdataarray.h
@@ -3,7 +3,6 @@
#pragma once
#include <vector>
-#include <cassert>
#include <cstddef>
namespace search::fef {
@@ -43,7 +42,6 @@ public:
* @param value the pointer to be added
**/
TermFieldMatchDataArray &add(TermFieldMatchData *value) {
- assert(value != nullptr);
_array.push_back(value);
return *this;
}
diff --git a/searchlib/src/vespa/searchlib/memoryindex/url_field_inverter.cpp b/searchlib/src/vespa/searchlib/memoryindex/url_field_inverter.cpp
index c79d856676d..c1537c6b290 100644
--- a/searchlib/src/vespa/searchlib/memoryindex/url_field_inverter.cpp
+++ b/searchlib/src/vespa/searchlib/memoryindex/url_field_inverter.cpp
@@ -10,6 +10,7 @@
#include <vespa/vespalib/text/utf8.h>
#include <vespa/vespalib/util/stringfmt.h>
#include <stdexcept>
+#include <cassert>
#include <vespa/log/log.h>
LOG_SETUP(".memoryindex.url_field_inverter");
diff --git a/searchlib/src/vespa/searchlib/query/tree/termnodes.cpp b/searchlib/src/vespa/searchlib/query/tree/termnodes.cpp
index 00f17f7963c..51882e6d185 100644
--- a/searchlib/src/vespa/searchlib/query/tree/termnodes.cpp
+++ b/searchlib/src/vespa/searchlib/query/tree/termnodes.cpp
@@ -3,6 +3,7 @@
#include "termnodes.h"
#include <vespa/vespalib/util/exceptions.h>
#include <charconv>
+#include <cassert>
using vespalib::IllegalArgumentException;
using vespalib::stringref;
diff --git a/searchlib/src/vespa/searchlib/queryeval/fake_search.cpp b/searchlib/src/vespa/searchlib/queryeval/fake_search.cpp
index 94814dbb9b3..d2aa72011e6 100644
--- a/searchlib/src/vespa/searchlib/queryeval/fake_search.cpp
+++ b/searchlib/src/vespa/searchlib/queryeval/fake_search.cpp
@@ -5,9 +5,20 @@
#include <vespa/searchlib/fef/termfieldmatchdata.h>
#include <vespa/vespalib/objects/visit.h>
#include <vespa/searchcommon/attribute/i_search_context.h>
+#include <cassert>
namespace search::queryeval {
+FakeSearch::FakeSearch(const vespalib::string &tag, const vespalib::string &field,
+ const vespalib::string &term, const FakeResult &res,
+ fef::TermFieldMatchDataArray tfmda)
+ : _tag(tag), _field(field), _term(term),
+ _result(res), _offset(0), _tfmda(std::move(tfmda)),
+ _ctx(nullptr)
+{
+ assert(_tfmda.size() == 1);
+}
+
void
FakeSearch::doSeek(uint32_t docid)
{
diff --git a/searchlib/src/vespa/searchlib/queryeval/fake_search.h b/searchlib/src/vespa/searchlib/queryeval/fake_search.h
index 5cd04f80499..7b7fdf0f078 100644
--- a/searchlib/src/vespa/searchlib/queryeval/fake_search.h
+++ b/searchlib/src/vespa/searchlib/queryeval/fake_search.h
@@ -29,13 +29,7 @@ public:
const vespalib::string &field,
const vespalib::string &term,
const FakeResult &res,
- fef::TermFieldMatchDataArray tfmda)
- : _tag(tag), _field(field), _term(term),
- _result(res), _offset(0), _tfmda(std::move(tfmda)),
- _ctx(nullptr)
- {
- assert(_tfmda.size() == 1);
- }
+ fef::TermFieldMatchDataArray tfmda);
void attr_ctx(const attribute::ISearchContext *ctx) { _ctx = ctx; }
bool is_attr() const { return (_ctx != nullptr); }
void doSeek(uint32_t docid) override;
diff --git a/searchlib/src/vespa/searchlib/queryeval/same_element_search.cpp b/searchlib/src/vespa/searchlib/queryeval/same_element_search.cpp
index 98c51d7f1ca..5db1e0057cd 100644
--- a/searchlib/src/vespa/searchlib/queryeval/same_element_search.cpp
+++ b/searchlib/src/vespa/searchlib/queryeval/same_element_search.cpp
@@ -6,6 +6,7 @@
#include <vespa/vespalib/objects/visit.hpp>
#include <algorithm>
#include <functional>
+#include <cassert>
using TFMD = search::fef::TermFieldMatchData;
diff --git a/searchlib/src/vespa/searchlib/queryeval/simple_phrase_search.cpp b/searchlib/src/vespa/searchlib/queryeval/simple_phrase_search.cpp
index f5069fd4f53..ea264935d42 100644
--- a/searchlib/src/vespa/searchlib/queryeval/simple_phrase_search.cpp
+++ b/searchlib/src/vespa/searchlib/queryeval/simple_phrase_search.cpp
@@ -4,6 +4,7 @@
#include <vespa/searchlib/fef/termfieldmatchdata.h>
#include <vespa/vespalib/objects/visit.h>
#include <functional>
+#include <cassert>
using search::fef::TermFieldMatchData;
using std::unique_ptr;
diff --git a/searchlib/src/vespa/searchlib/test/diskindex/threelevelcountbuffers.cpp b/searchlib/src/vespa/searchlib/test/diskindex/threelevelcountbuffers.cpp
index bc92b691ce8..04c8b6b3904 100644
--- a/searchlib/src/vespa/searchlib/test/diskindex/threelevelcountbuffers.cpp
+++ b/searchlib/src/vespa/searchlib/test/diskindex/threelevelcountbuffers.cpp
@@ -1,6 +1,7 @@
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#include "threelevelcountbuffers.h"
+#include <cassert>
namespace search::diskindex {
diff --git a/searchsummary/src/vespa/searchsummary/docsummary/docsumstate.cpp b/searchsummary/src/vespa/searchsummary/docsummary/docsumstate.cpp
index db4ac0f32b0..f1fee7e9ac3 100644
--- a/searchsummary/src/vespa/searchsummary/docsummary/docsumstate.cpp
+++ b/searchsummary/src/vespa/searchsummary/docsummary/docsumstate.cpp
@@ -14,6 +14,7 @@
#include <vespa/searchlib/parsequery/stackdumpiterator.h>
#include <vespa/vespalib/stllike/hash_map.hpp>
#include <vespa/vespalib/util/issue.h>
+#include <cassert>
using search::common::GeoLocationParser;
using search::common::GeoLocationSpec;
diff --git a/searchsummary/src/vespa/searchsummary/docsummary/geoposdfw.cpp b/searchsummary/src/vespa/searchsummary/docsummary/geoposdfw.cpp
index 6d668561651..07e4bde54d0 100644
--- a/searchsummary/src/vespa/searchsummary/docsummary/geoposdfw.cpp
+++ b/searchsummary/src/vespa/searchsummary/docsummary/geoposdfw.cpp
@@ -10,6 +10,7 @@
#include <vespa/vespalib/stllike/asciistream.h>
#include <vespa/vespalib/util/issue.h>
#include <climits>
+#include <cassert>
#include <vespa/log/log.h>
LOG_SETUP(".searchlib.docsummary.geoposdfw");
diff --git a/streamingvisitors/src/vespa/vsm/vsm/docsumfilter.cpp b/streamingvisitors/src/vespa/vsm/vsm/docsumfilter.cpp
index 596525e17d7..146dd487769 100644
--- a/streamingvisitors/src/vespa/vsm/vsm/docsumfilter.cpp
+++ b/streamingvisitors/src/vespa/vsm/vsm/docsumfilter.cpp
@@ -11,6 +11,7 @@
#include <vespa/document/datatype/datatype.h>
#include <vespa/document/fieldvalue/stringfieldvalue.h>
#include <vespa/vespalib/data/slime/inserter.h>
+#include <cassert>
#include <vespa/log/log.h>
LOG_SETUP(".vsm.docsumfilter");
diff --git a/vespalib/src/vespa/vespalib/btree/btreenodeallocator.h b/vespalib/src/vespa/vespalib/btree/btreenodeallocator.h
index b537602c703..c7c635b4471 100644
--- a/vespalib/src/vespa/vespalib/btree/btreenodeallocator.h
+++ b/vespalib/src/vespa/vespalib/btree/btreenodeallocator.h
@@ -34,10 +34,6 @@ public:
using DataStoreBase = datastore::DataStoreBase;
private:
- BTreeNodeAllocator(const BTreeNodeAllocator &rhs);
-
- BTreeNodeAllocator & operator=(const BTreeNodeAllocator &rhs);
-
NodeStore _nodeStore;
using RefVector = vespalib::Array<BTreeNode::Ref>;
@@ -53,6 +49,8 @@ private:
RefVector _leafHoldUntilFreeze;
public:
+ BTreeNodeAllocator(const BTreeNodeAllocator &rhs) = delete;
+ BTreeNodeAllocator & operator=(const BTreeNodeAllocator &rhs) = delete;
BTreeNodeAllocator();
~BTreeNodeAllocator();
diff --git a/vespalib/src/vespa/vespalib/geo/zcurve.cpp b/vespalib/src/vespa/vespalib/geo/zcurve.cpp
index c207f966704..d04a04fda0a 100644
--- a/vespalib/src/vespa/vespalib/geo/zcurve.cpp
+++ b/vespalib/src/vespa/vespalib/geo/zcurve.cpp
@@ -10,15 +10,38 @@ namespace vespalib::geo {
namespace {
+ /**
+ * An area defined by its upper left and lower right corners. The
+ * z-coordinates between these corners act as a spacial
+ * over-estimation of the actual area. These areas may never cross
+ * signed borders, since that would break the whole concept of
+ * hierarchical spatial partitioning.
+ **/
+struct Area {
+ const ZCurve::Point min;
+ const ZCurve::Point max;
+ Area(const Area &rhs) = default;
+ Area(int32_t min_x, int32_t min_y,
+ int32_t max_x, int32_t max_y)
+ : min(min_x, min_y), max(max_x, max_y)
+ {
+ assert((min_x <= max_x) && ((min_x < 0) == (max_x < 0)));
+ assert((min_y <= max_y) && ((min_y < 0) == (max_y < 0)));
+ }
+ Area &operator=(Area &&rhs) { new ((void*)this) Area(rhs); return *this; }
+ int64_t size() const { return (static_cast<int64_t>(max.x) - min.x + 1) * (static_cast<int64_t>(max.y) - min.y + 1); }
+ int64_t estimate() const { return (max.z - min.z + 1); }
+ int64_t error() const { return estimate() - size(); }
+};
+
class ZAreaQueue
{
private:
struct MaxAreaErrorCmp {
- bool operator()(const ZCurve::Area &a, const ZCurve::Area &b) const {
+ bool operator()(const Area &a, const Area &b) const {
return (a.error() > b.error());
}
};
- using Area = ZCurve::Area;
using Range = ZCurve::Range;
using RangeVector = ZCurve::RangeVector;
using Queue = PriorityQueue<Area, MaxAreaErrorCmp, LeftArrayHeap>;
@@ -61,7 +84,6 @@ public:
class ZAreaSplitter
{
private:
- using Area = ZCurve::Area;
using RangeVector = ZCurve::RangeVector;
ZAreaQueue _queue;
diff --git a/vespalib/src/vespa/vespalib/geo/zcurve.h b/vespalib/src/vespa/vespalib/geo/zcurve.h
index 2f92b3a019b..c5fbdc08dce 100644
--- a/vespalib/src/vespa/vespalib/geo/zcurve.h
+++ b/vespalib/src/vespa/vespalib/geo/zcurve.h
@@ -3,7 +3,6 @@
#pragma once
#include <cstdint>
-#include <cassert>
#include <vector>
namespace vespalib::geo {
@@ -163,30 +162,6 @@ public:
Point(int32_t x_, int32_t y_) : x(x_), y(y_), z(encode(x_, y_)) {}
};
- /**
- * An area defined by its upper left and lower right corners. The
- * z-coordinates between these corners act as a spacial
- * over-estimation of the actual area. These areas may never cross
- * signed borders, since that would break the whole concept of
- * hierarchical spatial partitioning.
- **/
- struct Area {
- const Point min;
- const Point max;
- Area(const Area &rhs) = default;
- Area(int32_t min_x, int32_t min_y,
- int32_t max_x, int32_t max_y)
- : min(min_x, min_y), max(max_x, max_y)
- {
- assert((min_x <= max_x) && ((min_x < 0) == (max_x < 0)));
- assert((min_y <= max_y) && ((min_y < 0) == (max_y < 0)));
- }
- Area &operator=(Area &&rhs) { new ((void*)this) Area(rhs); return *this; }
- int64_t size() const { return (static_cast<int64_t>(max.x) - min.x + 1) * (static_cast<int64_t>(max.y) - min.y + 1); }
- int64_t estimate() const { return (max.z - min.z + 1); }
- int64_t error() const { return estimate() - size(); }
- };
-
class Range
{
private:
@@ -212,11 +187,9 @@ public:
static RangeVector find_ranges(int min_x, int min_y,
int max_x, int max_y);
- static int64_t
- encodeSlow(int32_t x, int32_t y);
+ static int64_t encodeSlow(int32_t x, int32_t y);
- static void
- decodeSlow(int64_t enc, int32_t *xp, int32_t *yp);
+ static void decodeSlow(int64_t enc, int32_t *xp, int32_t *yp);
};
}
diff --git a/vespalib/src/vespa/vespalib/metrics/simple_metrics_manager.cpp b/vespalib/src/vespa/vespalib/metrics/simple_metrics_manager.cpp
index 4b6b82697f7..534177e480a 100644
--- a/vespalib/src/vespa/vespalib/metrics/simple_metrics_manager.cpp
+++ b/vespalib/src/vespa/vespalib/metrics/simple_metrics_manager.cpp
@@ -1,6 +1,7 @@
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#include "simple_metrics_manager.h"
#include "simple_tick.h"
+#include <cassert>
#include <vespa/log/log.h>
LOG_SETUP(".vespalib.metrics.simple_metrics_manager");
diff --git a/vespalib/src/vespa/vespalib/metrics/stable_store.h b/vespalib/src/vespa/vespalib/metrics/stable_store.h
index f249fd7729e..d456150ab7e 100644
--- a/vespalib/src/vespa/vespalib/metrics/stable_store.h
+++ b/vespalib/src/vespa/vespalib/metrics/stable_store.h
@@ -4,7 +4,6 @@
#include <memory>
#include <vector>
-#include <assert.h>
namespace vespalib {
@@ -54,8 +53,8 @@ private:
StableStore(size_t sz, UP &&more, std::vector<T> &&mine);
- size_t _size;
- UP _more;
+ size_t _size;
+ UP _more;
std::vector<T> _mine;
};
diff --git a/vespalib/src/vespa/vespalib/util/fiddle.h b/vespalib/src/vespa/vespalib/util/fiddle.h
index f4d2ac33695..b6799d9c778 100644
--- a/vespalib/src/vespa/vespalib/util/fiddle.h
+++ b/vespalib/src/vespa/vespalib/util/fiddle.h
@@ -4,8 +4,7 @@
#include <cassert>
-namespace vespalib {
-namespace bits {
+namespace vespalib::bits {
//-----------------------------------------------------------------------------
@@ -79,6 +78,5 @@ uint32_t split_range(uint32_t min, uint32_t max,
//-----------------------------------------------------------------------------
-} // namespace bits
-} // namespace vespalib
+}
diff --git a/vespalib/src/vespa/vespalib/util/latch.h b/vespalib/src/vespa/vespalib/util/latch.h
index 3ae49aeb11f..9110b898372 100644
--- a/vespalib/src/vespa/vespalib/util/latch.h
+++ b/vespalib/src/vespa/vespalib/util/latch.h
@@ -4,7 +4,6 @@
#include <mutex>
#include <condition_variable>
-#include <cassert>
namespace vespalib {