summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--searchlib/src/vespa/searchlib/attribute/attributevector.cpp4
-rw-r--r--searchlib/src/vespa/searchlib/attribute/attributevector.h4
-rw-r--r--searchlib/src/vespa/searchlib/bitcompression/pagedict4.cpp14
-rw-r--r--searchlib/src/vespa/searchlib/bitcompression/pagedict4.h12
-rw-r--r--searchlib/src/vespa/searchlib/common/packets.cpp2
-rw-r--r--searchlib/src/vespa/searchlib/common/packets.h6
-rw-r--r--searchlib/src/vespa/searchlib/diskindex/diskindex.cpp4
-rw-r--r--searchlib/src/vespa/searchlib/diskindex/diskindex.h4
-rw-r--r--searchlib/src/vespa/searchlib/diskindex/fieldwriter.cpp2
-rw-r--r--searchlib/src/vespa/searchlib/diskindex/fieldwriter.h2
-rw-r--r--searchlib/src/vespa/searchlib/docstore/chunkformat.cpp2
-rw-r--r--searchlib/src/vespa/searchlib/docstore/chunkformat.h2
-rw-r--r--searchlib/src/vespa/searchlib/docstore/summaryexceptions.cpp2
-rw-r--r--searchlib/src/vespa/searchlib/docstore/summaryexceptions.h2
-rw-r--r--searchlib/src/vespa/searchlib/expression/catserializer.cpp2
-rw-r--r--searchlib/src/vespa/searchlib/expression/catserializer.h2
-rw-r--r--searchlib/src/vespa/searchlib/expression/stringbucketresultnode.cpp2
-rw-r--r--searchlib/src/vespa/searchlib/expression/stringbucketresultnode.h4
-rw-r--r--searchlib/src/vespa/searchlib/features/dotproductfeature.h6
-rw-r--r--searchlib/src/vespa/searchlib/features/tensor_from_weighted_set_feature.cpp2
-rw-r--r--searchlib/src/vespa/searchlib/fef/blueprint.cpp2
-rw-r--r--searchlib/src/vespa/searchlib/fef/blueprint.h2
-rw-r--r--searchlib/src/vespa/searchlib/fef/properties.cpp14
-rw-r--r--searchlib/src/vespa/searchlib/fef/properties.h14
-rw-r--r--searchlib/src/vespa/searchlib/parsequery/parse.cpp2
-rw-r--r--searchlib/src/vespa/searchlib/parsequery/parse.h2
-rw-r--r--searchlib/src/vespa/searchlib/predicate/document_features_store.h2
-rw-r--r--searchlib/src/vespa/searchlib/query/tree/querybuilder.h50
-rw-r--r--searchlib/src/vespa/searchlib/query/tree/simplequery.h20
-rw-r--r--searchlib/src/vespa/searchlib/query/tree/termnodes.h16
-rw-r--r--searchsummary/src/vespa/searchsummary/docsummary/dynamicteaserdfw.cpp2
-rw-r--r--searchsummary/src/vespa/searchsummary/docsummary/itokenizer.h4
-rw-r--r--searchsummary/src/vespa/searchsummary/docsummary/summaryfeaturesdfw.cpp2
-rw-r--r--searchsummary/src/vespa/searchsummary/docsummary/summaryfeaturesdfw.h2
-rw-r--r--slobrok/src/vespa/slobrok/sbregister.cpp2
-rw-r--r--storage/src/tests/visiting/commandqueuetest.cpp2
-rw-r--r--storage/src/vespa/storage/common/hostreporter/kernelmetrictool.cpp2
-rw-r--r--storage/src/vespa/storage/common/hostreporter/kernelmetrictool.h2
-rw-r--r--storageapi/src/vespa/storageapi/message/bucket.cpp2
-rw-r--r--storageapi/src/vespa/storageapi/message/bucket.h2
-rw-r--r--storageapi/src/vespa/storageapi/message/persistence.cpp2
-rw-r--r--storageapi/src/vespa/storageapi/message/persistence.h2
-rw-r--r--storageapi/src/vespa/storageapi/message/stat.cpp4
-rw-r--r--storageapi/src/vespa/storageapi/message/stat.h6
-rw-r--r--storageapi/src/vespa/storageapi/message/visitor.cpp6
-rw-r--r--storageapi/src/vespa/storageapi/message/visitor.h6
-rw-r--r--storageapi/src/vespa/storageapi/messageapi/returncode.cpp2
-rw-r--r--storageapi/src/vespa/storageapi/messageapi/returncode.h2
48 files changed, 128 insertions, 128 deletions
diff --git a/searchlib/src/vespa/searchlib/attribute/attributevector.cpp b/searchlib/src/vespa/searchlib/attribute/attributevector.cpp
index 9fd70ddea77..fbeaaa6070c 100644
--- a/searchlib/src/vespa/searchlib/attribute/attributevector.cpp
+++ b/searchlib/src/vespa/searchlib/attribute/attributevector.cpp
@@ -59,8 +59,8 @@ namespace search {
IMPLEMENT_IDENTIFIABLE_ABSTRACT(AttributeVector, vespalib::Identifiable);
AttributeVector::BaseName::BaseName(vespalib::stringref base,
- const vespalib::stringref &snap,
- const vespalib::stringref &name)
+ vespalib::stringref snap,
+ vespalib::stringref name)
: string(base),
_name(name)
{
diff --git a/searchlib/src/vespa/searchlib/attribute/attributevector.h b/searchlib/src/vespa/searchlib/attribute/attributevector.h
index 72a595319a1..53736a62572 100644
--- a/searchlib/src/vespa/searchlib/attribute/attributevector.h
+++ b/searchlib/src/vespa/searchlib/attribute/attributevector.h
@@ -138,8 +138,8 @@ public:
}
BaseName(vespalib::stringref base,
- const vespalib::stringref &snap,
- const vespalib::stringref &name);
+ vespalib::stringref snap,
+ vespalib::stringref name);
~BaseName();
string getIndexName() const;
diff --git a/searchlib/src/vespa/searchlib/bitcompression/pagedict4.cpp b/searchlib/src/vespa/searchlib/bitcompression/pagedict4.cpp
index 5d1fec2f65d..ddf617d37ed 100644
--- a/searchlib/src/vespa/searchlib/bitcompression/pagedict4.cpp
+++ b/searchlib/src/vespa/searchlib/bitcompression/pagedict4.cpp
@@ -102,7 +102,7 @@ typedef PageDict4StartOffset StartOffset;
static uint32_t
getLCP(vespalib::stringref word,
- const vespalib::stringref &prevWord)
+ vespalib::stringref prevWord)
{
size_t len1 = word.size();
size_t len2 = prevWord.size();
@@ -1327,9 +1327,9 @@ void
PageDict4SPLookupRes::
lookup(const SSReader &ssReader,
const void *sparsePage,
- const vespalib::stringref &key,
- const vespalib::stringref &l6Word,
- const vespalib::stringref &lastSPWord,
+ vespalib::stringref key,
+ vespalib::stringref l6Word,
+ vespalib::stringref lastSPWord,
const StartOffset &l6StartOffset,
uint64_t l6WordNum,
uint64_t lowestPageNum)
@@ -1525,9 +1525,9 @@ bool
PageDict4PLookupRes::
lookup(const SSReader &ssReader,
const void *page,
- const vespalib::stringref &key,
- const vespalib::stringref &l3Word,
- const vespalib::stringref &lastPWord,
+ vespalib::stringref key,
+ vespalib::stringref l3Word,
+ vespalib::stringref lastPWord,
const StartOffset &l3StartOffset,
uint64_t l3WordNum)
{
diff --git a/searchlib/src/vespa/searchlib/bitcompression/pagedict4.h b/searchlib/src/vespa/searchlib/bitcompression/pagedict4.h
index 1669d45e33a..dc0ea3a5201 100644
--- a/searchlib/src/vespa/searchlib/bitcompression/pagedict4.h
+++ b/searchlib/src/vespa/searchlib/bitcompression/pagedict4.h
@@ -610,9 +610,9 @@ public:
void
lookup(const SSReader &ssReader,
const void *sparsePage,
- const vespalib::stringref &key,
- const vespalib::stringref &l6Word,
- const vespalib::stringref &lastSPWord,
+ vespalib::stringref key,
+ vespalib::stringref l6Word,
+ vespalib::stringref lastSPWord,
const StartOffset &l6StartOffset,
uint64_t l6WordNum,
uint64_t lowestPageNum);
@@ -641,9 +641,9 @@ public:
bool
lookup(const SSReader &ssReader,
const void *page,
- const vespalib::stringref &key,
- const vespalib::stringref &l3Word,
- const vespalib::stringref &lastPWord,
+ vespalib::stringref key,
+ vespalib::stringref l3Word,
+ vespalib::stringref lastPWord,
const StartOffset &l3StartOffset,
uint64_t l3WordNum);
};
diff --git a/searchlib/src/vespa/searchlib/common/packets.cpp b/searchlib/src/vespa/searchlib/common/packets.cpp
index 90157e318e9..e7ec0ffc9b9 100644
--- a/searchlib/src/vespa/searchlib/common/packets.cpp
+++ b/searchlib/src/vespa/searchlib/common/packets.cpp
@@ -239,7 +239,7 @@ FS4Properties::allocEntries(uint32_t cnt)
_backing.reserve(cnt*2*40); // Assume strings are average 40 bytes
}
-void FS4Properties::set(StringRef & e, const vespalib::stringref & s)
+void FS4Properties::set(StringRef & e, vespalib::stringref s)
{
e.first = _backing.size();
e.second = s.size();
diff --git a/searchlib/src/vespa/searchlib/common/packets.h b/searchlib/src/vespa/searchlib/common/packets.h
index 0a98bf87de8..3fd87ccfa25 100644
--- a/searchlib/src/vespa/searchlib/common/packets.h
+++ b/searchlib/src/vespa/searchlib/common/packets.h
@@ -165,7 +165,7 @@ private:
vespalib::string _name;
vespalib::string _backing;
const char * c_str(size_t sz) const { return _backing.c_str() + sz; }
- void set(StringRef & e, const vespalib::stringref & s);
+ void set(StringRef & e, vespalib::stringref s);
public:
FS4Properties(FS4Properties &&);
FS4Properties &operator=(FS4Properties &&);
@@ -178,11 +178,11 @@ public:
setName(val.data(), val.size());
}
void setKey(uint32_t entry, const char *key, uint32_t keySize);
- void setKey(uint32_t entry, const vespalib::stringref &val) {
+ void setKey(uint32_t entry, vespalib::stringref val) {
setKey(entry, val.data(), val.size());
}
void setValue(uint32_t entry, const char *value, uint32_t valueSize);
- void setValue(uint32_t entry, const vespalib::stringref &val) {
+ void setValue(uint32_t entry, vespalib::stringref val) {
setValue(entry, val.data(), val.size());
}
uint32_t size() const { return _entries.size(); }
diff --git a/searchlib/src/vespa/searchlib/diskindex/diskindex.cpp b/searchlib/src/vespa/searchlib/diskindex/diskindex.cpp
index 98f53da9858..e2fb7367b94 100644
--- a/searchlib/src/vespa/searchlib/diskindex/diskindex.cpp
+++ b/searchlib/src/vespa/searchlib/diskindex/diskindex.cpp
@@ -199,7 +199,7 @@ DiskIndex::setup(const TuneFileSearch &tuneFileSearch,
}
DiskIndex::LookupResult::UP
-DiskIndex::lookup(uint32_t index, const vespalib::stringref & word)
+DiskIndex::lookup(uint32_t index, vespalib::stringref word)
{
/** Only used for testing */
IndexList indexes;
@@ -252,7 +252,7 @@ unite(const DiskIndex::IndexList & indexes, const DiskIndex::LookupResultVector
}
DiskIndex::LookupResultVector
-DiskIndex::lookup(const std::vector<uint32_t> & indexes, const vespalib::stringref & word)
+DiskIndex::lookup(const std::vector<uint32_t> & indexes, vespalib::stringref word)
{
Key key(indexes, word);
LookupResultVector result;
diff --git a/searchlib/src/vespa/searchlib/diskindex/diskindex.h b/searchlib/src/vespa/searchlib/diskindex/diskindex.h
index eaeb768cc9a..dd3daab34cd 100644
--- a/searchlib/src/vespa/searchlib/diskindex/diskindex.h
+++ b/searchlib/src/vespa/searchlib/diskindex/diskindex.h
@@ -111,8 +111,8 @@ public:
* @param word the word to lookup.
* @return the lookup result or NULL if the word is not found.
**/
- LookupResult::UP lookup(uint32_t indexId, const vespalib::stringref & word);
- LookupResultVector lookup(const std::vector<uint32_t> & indexes, const vespalib::stringref & word);
+ LookupResult::UP lookup(uint32_t indexId, vespalib::stringref word);
+ LookupResultVector lookup(const std::vector<uint32_t> & indexes, vespalib::stringref word);
/**
diff --git a/searchlib/src/vespa/searchlib/diskindex/fieldwriter.cpp b/searchlib/src/vespa/searchlib/diskindex/fieldwriter.cpp
index d62b69c5bf5..ab90a1dacc5 100644
--- a/searchlib/src/vespa/searchlib/diskindex/fieldwriter.cpp
+++ b/searchlib/src/vespa/searchlib/diskindex/fieldwriter.cpp
@@ -121,7 +121,7 @@ FieldWriter::flush()
void
-FieldWriter::newWord(uint64_t wordNum, const vespalib::stringref &word)
+FieldWriter::newWord(uint64_t wordNum, vespalib::stringref word)
{
assert(wordNum <= _numWordIds);
assert(wordNum != noWordNum());
diff --git a/searchlib/src/vespa/searchlib/diskindex/fieldwriter.h b/searchlib/src/vespa/searchlib/diskindex/fieldwriter.h
index f0dc033b01e..74f515958fe 100644
--- a/searchlib/src/vespa/searchlib/diskindex/fieldwriter.h
+++ b/searchlib/src/vespa/searchlib/diskindex/fieldwriter.h
@@ -58,7 +58,7 @@ public:
FieldWriter(uint32_t docIdLimit, uint64_t numWordIds);
~FieldWriter();
- void newWord(uint64_t wordNum, const vespalib::stringref &word);
+ void newWord(uint64_t wordNum, vespalib::stringref word);
void newWord(vespalib::stringref word);
void add(const DocIdAndFeatures &features) {
diff --git a/searchlib/src/vespa/searchlib/docstore/chunkformat.cpp b/searchlib/src/vespa/searchlib/docstore/chunkformat.cpp
index 93f1d9c0d51..0f360d99247 100644
--- a/searchlib/src/vespa/searchlib/docstore/chunkformat.cpp
+++ b/searchlib/src/vespa/searchlib/docstore/chunkformat.cpp
@@ -13,7 +13,7 @@ using vespalib::compression::decompress;
using vespalib::compression::computeMaxCompressedsize;
using vespalib::compression::CompressionConfig;
-ChunkException::ChunkException(const vespalib::string & msg, const vespalib::stringref & location) :
+ChunkException::ChunkException(const vespalib::string & msg, vespalib::stringref location) :
Exception(make_string("Illegal chunk: %s", msg.c_str()), location)
{
}
diff --git a/searchlib/src/vespa/searchlib/docstore/chunkformat.h b/searchlib/src/vespa/searchlib/docstore/chunkformat.h
index 81feaf2a27f..ede1a02f0f4 100644
--- a/searchlib/src/vespa/searchlib/docstore/chunkformat.h
+++ b/searchlib/src/vespa/searchlib/docstore/chunkformat.h
@@ -12,7 +12,7 @@ namespace search {
class ChunkException : public vespalib::Exception
{
public:
- ChunkException(const vespalib::string & msg, const vespalib::stringref & location);
+ ChunkException(const vespalib::string & msg, vespalib::stringref location);
};
// This is an interface for implementing a chunk format
diff --git a/searchlib/src/vespa/searchlib/docstore/summaryexceptions.cpp b/searchlib/src/vespa/searchlib/docstore/summaryexceptions.cpp
index 0c8ae805c46..80510dbe883 100644
--- a/searchlib/src/vespa/searchlib/docstore/summaryexceptions.cpp
+++ b/searchlib/src/vespa/searchlib/docstore/summaryexceptions.cpp
@@ -10,7 +10,7 @@ namespace search {
SummaryException::SummaryException(vespalib::stringref msg,
FastOS_FileInterface &file,
- const vespalib::stringref &location)
+ vespalib::stringref location)
: IoException(make_string("%s : Failing file = '%s'. Reason given by OS = '%s'",
vespalib::string(msg).c_str(), file.GetFileName(), file.getLastErrorString().c_str()),
getErrorType(file.GetLastError()), location)
diff --git a/searchlib/src/vespa/searchlib/docstore/summaryexceptions.h b/searchlib/src/vespa/searchlib/docstore/summaryexceptions.h
index 58e441f0a08..a9e8f3ca763 100644
--- a/searchlib/src/vespa/searchlib/docstore/summaryexceptions.h
+++ b/searchlib/src/vespa/searchlib/docstore/summaryexceptions.h
@@ -11,7 +11,7 @@ namespace search {
class SummaryException : public vespalib::IoException
{
public:
- SummaryException(vespalib::stringref msg, FastOS_FileInterface & file, const vespalib::stringref &location);
+ SummaryException(vespalib::stringref msg, FastOS_FileInterface & file, vespalib::stringref location);
};
} // namespace search
diff --git a/searchlib/src/vespa/searchlib/expression/catserializer.cpp b/searchlib/src/vespa/searchlib/expression/catserializer.cpp
index f613bd16a54..2d64f3db9f9 100644
--- a/searchlib/src/vespa/searchlib/expression/catserializer.cpp
+++ b/searchlib/src/vespa/searchlib/expression/catserializer.cpp
@@ -14,7 +14,7 @@ using vespalib::Deserializer;
using vespalib::string;
using vespalib::stringref;
-CatSerializer & CatSerializer::put(const IFieldBase & field, const stringref & value)
+CatSerializer & CatSerializer::put(const IFieldBase & field, stringref value)
{
(void) field;
getStream().write(value.data(), value.size());
diff --git a/searchlib/src/vespa/searchlib/expression/catserializer.h b/searchlib/src/vespa/searchlib/expression/catserializer.h
index b635826fbf5..cce4af3880b 100644
--- a/searchlib/src/vespa/searchlib/expression/catserializer.h
+++ b/searchlib/src/vespa/searchlib/expression/catserializer.h
@@ -14,7 +14,7 @@ class CatSerializer : public vespalib::NBOSerializer, public ResultSerializer
public:
CatSerializer(vespalib::nbostream & stream) : vespalib::NBOSerializer(stream) { }
CatSerializer & put(const vespalib::IFieldBase & field, const vespalib::Identifiable & value) override;
- CatSerializer & put(const vespalib::IFieldBase & field, const vespalib::stringref & value) override;
+ CatSerializer & put(const vespalib::IFieldBase & field, vespalib::stringref value) override;
ResultSerializer & putResult(const vespalib::IFieldBase & field, const RawResultNode & value) override;
ResultSerializer & putResult(const vespalib::IFieldBase & field, const ResultNodeVector & value) override;
void proxyPut(const ResultNode & value) override;
diff --git a/searchlib/src/vespa/searchlib/expression/stringbucketresultnode.cpp b/searchlib/src/vespa/searchlib/expression/stringbucketresultnode.cpp
index fb0a467abb2..a072e06d811 100644
--- a/searchlib/src/vespa/searchlib/expression/stringbucketresultnode.cpp
+++ b/searchlib/src/vespa/searchlib/expression/stringbucketresultnode.cpp
@@ -40,7 +40,7 @@ StringBucketResultNode::StringBucketResultNode()
: _from(new StringResultNode()),
_to(new StringResultNode())
{}
-StringBucketResultNode::StringBucketResultNode(vespalib::stringref from, const vespalib::stringref & to)
+StringBucketResultNode::StringBucketResultNode(vespalib::stringref from, vespalib::stringref to)
: _from(new StringResultNode(from)),
_to(new StringResultNode(to))
{}
diff --git a/searchlib/src/vespa/searchlib/expression/stringbucketresultnode.h b/searchlib/src/vespa/searchlib/expression/stringbucketresultnode.h
index 9c8417214c2..c53fa06487c 100644
--- a/searchlib/src/vespa/searchlib/expression/stringbucketresultnode.h
+++ b/searchlib/src/vespa/searchlib/expression/stringbucketresultnode.h
@@ -23,7 +23,7 @@ public:
DECLARE_EXPRESSIONNODE(StringBucketResultNode);
DECLARE_NBO_SERIALIZE;
StringBucketResultNode();
- StringBucketResultNode(vespalib::stringref from, const vespalib::stringref & to);
+ StringBucketResultNode(vespalib::stringref from, vespalib::stringref to);
StringBucketResultNode(ResultNode::UP from, ResultNode::UP to) : _from(from.release()), _to(to.release()) {}
~StringBucketResultNode();
size_t hash() const override;
@@ -32,7 +32,7 @@ public:
int contains(const ConstBufferRef & v) const { return contains(v.c_str()); }
int contains(const char * v) const;
void visitMembers(vespalib::ObjectVisitor &visitor) const override;
- StringBucketResultNode &setRange(vespalib::stringref from, const vespalib::stringref & to) {
+ StringBucketResultNode &setRange(vespalib::stringref from, vespalib::stringref to) {
_from.reset(new StringResultNode(from));
_to.reset(new StringResultNode(to));
return *this;
diff --git a/searchlib/src/vespa/searchlib/features/dotproductfeature.h b/searchlib/src/vespa/searchlib/features/dotproductfeature.h
index c12b0f54cf6..61fb418636d 100644
--- a/searchlib/src/vespa/searchlib/features/dotproductfeature.h
+++ b/searchlib/src/vespa/searchlib/features/dotproductfeature.h
@@ -73,7 +73,7 @@ public:
**/
class IntegerVector : public VectorBase<int64_t, int64_t, feature_t> {
public:
- void insert(vespalib::stringref label, const vespalib::stringref & value) {
+ void insert(vespalib::stringref label, vespalib::stringref value) {
_vector.push_back(std::make_pair(util::strToNum<int64_t>(label), util::strToNum<feature_t>(value)));
}
};
@@ -85,7 +85,7 @@ class StringVector : public VectorBase<vespalib::string, const char *, feature_t
public:
StringVector();
~StringVector();
- void insert(vespalib::stringref label, const vespalib::stringref & value) {
+ void insert(vespalib::stringref label, vespalib::stringref value) {
_vector.push_back(std::make_pair(label, util::strToNum<feature_t>(value)));
}
};
@@ -98,7 +98,7 @@ private:
const search::attribute::IAttributeVector * _attribute;
public:
EnumVector(const search::attribute::IAttributeVector * attribute) : _attribute(attribute) {}
- void insert(vespalib::stringref label, const vespalib::stringref & value) {
+ void insert(vespalib::stringref label, vespalib::stringref value) {
search::attribute::EnumHandle e;
if (_attribute->findEnum(label.data(), e)) {
_vector.push_back(std::make_pair(e, util::strToNum<feature_t>(value)));
diff --git a/searchlib/src/vespa/searchlib/features/tensor_from_weighted_set_feature.cpp b/searchlib/src/vespa/searchlib/features/tensor_from_weighted_set_feature.cpp
index 7fdd216d447..3b0bde8f76f 100644
--- a/searchlib/src/vespa/searchlib/features/tensor_from_weighted_set_feature.cpp
+++ b/searchlib/src/vespa/searchlib/features/tensor_from_weighted_set_feature.cpp
@@ -36,7 +36,7 @@ namespace {
struct WeightedStringVector
{
std::vector<IAttributeVector::WeightedString> _data;
- void insert(vespalib::stringref key, const vespalib::stringref &weight) {
+ void insert(vespalib::stringref key, vespalib::stringref weight) {
_data.emplace_back(key, util::strToNum<int32_t>(weight));
}
};
diff --git a/searchlib/src/vespa/searchlib/fef/blueprint.cpp b/searchlib/src/vespa/searchlib/fef/blueprint.cpp
index 82e9a316321..4e1ccee99c4 100644
--- a/searchlib/src/vespa/searchlib/fef/blueprint.cpp
+++ b/searchlib/src/vespa/searchlib/fef/blueprint.cpp
@@ -19,7 +19,7 @@ Blueprint::defineInput(vespalib::stringref inName,
void
Blueprint::describeOutput(vespalib::stringref outName,
- const vespalib::stringref &desc,
+ vespalib::stringref desc,
const FeatureType &type)
{
(void) desc;
diff --git a/searchlib/src/vespa/searchlib/fef/blueprint.h b/searchlib/src/vespa/searchlib/fef/blueprint.h
index 7ac2d648cc1..617edbd0613 100644
--- a/searchlib/src/vespa/searchlib/fef/blueprint.h
+++ b/searchlib/src/vespa/searchlib/fef/blueprint.h
@@ -97,7 +97,7 @@ protected:
* @param outName output name
* @param desc output description
**/
- void describeOutput(vespalib::stringref outName, const vespalib::stringref &desc,
+ void describeOutput(vespalib::stringref outName, vespalib::stringref desc,
const FeatureType &type = FeatureType::number());
public:
diff --git a/searchlib/src/vespa/searchlib/fef/properties.cpp b/searchlib/src/vespa/searchlib/fef/properties.cpp
index 280f9b3eaec..626623a8647 100644
--- a/searchlib/src/vespa/searchlib/fef/properties.cpp
+++ b/searchlib/src/vespa/searchlib/fef/properties.cpp
@@ -84,7 +84,7 @@ Properties::~Properties()
}
Properties &
-Properties::add(vespalib::stringref key, const vespalib::stringref &value)
+Properties::add(vespalib::stringref key, vespalib::stringref value)
{
if (!key.empty()) {
Value & v = _data[key];
@@ -218,7 +218,7 @@ Properties::lookup(vespalib::stringref key) const
}
Property Properties::lookup(vespalib::stringref namespace1,
- const vespalib::stringref &key) const
+ vespalib::stringref key) const
{
if (namespace1.empty() ||
key.empty())
@@ -229,8 +229,8 @@ Property Properties::lookup(vespalib::stringref namespace1,
}
Property Properties::lookup(vespalib::stringref namespace1,
- const vespalib::stringref &namespace2,
- const vespalib::stringref &key) const
+ vespalib::stringref namespace2,
+ vespalib::stringref key) const
{
if (namespace1.empty() ||
namespace2.empty() ||
@@ -242,9 +242,9 @@ Property Properties::lookup(vespalib::stringref namespace1,
}
Property Properties::lookup(vespalib::stringref namespace1,
- const vespalib::stringref &namespace2,
- const vespalib::stringref &namespace3,
- const vespalib::stringref &key) const
+ vespalib::stringref namespace2,
+ vespalib::stringref namespace3,
+ vespalib::stringref key) const
{
if (namespace1.empty() ||
namespace2.empty() ||
diff --git a/searchlib/src/vespa/searchlib/fef/properties.h b/searchlib/src/vespa/searchlib/fef/properties.h
index 9814e3023b5..1cbc0ba9064 100644
--- a/searchlib/src/vespa/searchlib/fef/properties.h
+++ b/searchlib/src/vespa/searchlib/fef/properties.h
@@ -167,7 +167,7 @@ public:
* @param key the key
* @param value the value
**/
- Properties &add(vespalib::stringref key, const vespalib::stringref &value);
+ Properties &add(vespalib::stringref key, vespalib::stringref value);
/**
* Obtain the number of values for a given key.
@@ -272,7 +272,7 @@ public:
* @param key the key to look up
**/
Property lookup(vespalib::stringref namespace1,
- const vespalib::stringref &key) const;
+ vespalib::stringref key) const;
/**
* Look up a key inside a namespace using the proposed namespace
@@ -287,8 +287,8 @@ public:
* @param key the key to look up
**/
Property lookup(vespalib::stringref namespace1,
- const vespalib::stringref &namespace2,
- const vespalib::stringref &key) const;
+ vespalib::stringref namespace2,
+ vespalib::stringref key) const;
/**
* Look up a key inside a namespace using the proposed namespace
@@ -304,9 +304,9 @@ public:
* @param key the key to look up
**/
Property lookup(vespalib::stringref namespace1,
- const vespalib::stringref &namespace2,
- const vespalib::stringref &namespace3,
- const vespalib::stringref &key) const;
+ vespalib::stringref namespace2,
+ vespalib::stringref namespace3,
+ vespalib::stringref key) const;
void swap(Properties & rhs);
};
diff --git a/searchlib/src/vespa/searchlib/parsequery/parse.cpp b/searchlib/src/vespa/searchlib/parsequery/parse.cpp
index 60236275f76..cc6fd6ee915 100644
--- a/searchlib/src/vespa/searchlib/parsequery/parse.cpp
+++ b/searchlib/src/vespa/searchlib/parsequery/parse.cpp
@@ -58,7 +58,7 @@ void assert_type(ParseItem::ItemType type)
}
-ParseItem::ParseItem(ItemType type, const vespalib::stringref & idx, const char *term)
+ParseItem::ParseItem(ItemType type, vespalib::stringref idx, const char *term)
: PARSEITEM_DEFAULT_CONSTRUCTOR_LIST
{
assert_type(type);
diff --git a/searchlib/src/vespa/searchlib/parsequery/parse.h b/searchlib/src/vespa/searchlib/parsequery/parse.h
index d8cbdc696a5..15fb0e316e8 100644
--- a/searchlib/src/vespa/searchlib/parsequery/parse.h
+++ b/searchlib/src/vespa/searchlib/parsequery/parse.h
@@ -166,7 +166,7 @@ public:
* @param idx The name of the index of the ParseItem.
* @param term The actual term string of the ParseItem.
*/
- ParseItem(ItemType type, const vespalib::stringref & index, const char *term);
+ ParseItem(ItemType type, vespalib::stringref index, const char *term);
/**
* Overloaded constructor for ParseItem. Used for TERMs without index.
diff --git a/searchlib/src/vespa/searchlib/predicate/document_features_store.h b/searchlib/src/vespa/searchlib/predicate/document_features_store.h
index 5fa8e36e7de..73bd8c11f7a 100644
--- a/searchlib/src/vespa/searchlib/predicate/document_features_store.h
+++ b/searchlib/src/vespa/searchlib/predicate/document_features_store.h
@@ -39,7 +39,7 @@ class DocumentFeaturesStore {
}
public:
- KeyComp(const WordStore &word_store, const vespalib::stringref &word)
+ KeyComp(const WordStore &word_store, vespalib::stringref word)
: _word_store(word_store),
_word(word) {
}
diff --git a/searchlib/src/vespa/searchlib/query/tree/querybuilder.h b/searchlib/src/vespa/searchlib/query/tree/querybuilder.h
index 3a96de83a71..a2ad8eae84b 100644
--- a/searchlib/src/vespa/searchlib/query/tree/querybuilder.h
+++ b/searchlib/src/vespa/searchlib/query/tree/querybuilder.h
@@ -110,7 +110,7 @@ template <class NodeTypes>
typename NodeTypes::Or *createOr() { return new typename NodeTypes::Or; }
template <class NodeTypes>
-typename NodeTypes::WeakAnd *createWeakAnd(uint32_t minHits, const vespalib::stringref & view) {
+typename NodeTypes::WeakAnd *createWeakAnd(uint32_t minHits, vespalib::stringref view) {
return new typename NodeTypes::WeakAnd(minHits, view);
}
template <class NodeTypes>
@@ -155,50 +155,50 @@ typename NodeTypes::ONear *createONear(size_t distance) {
// Term nodes
template <class NodeTypes>
typename NodeTypes::NumberTerm *
-createNumberTerm(vespalib::stringref term, const vespalib::stringref &view, int32_t id, Weight weight) {
+createNumberTerm(vespalib::stringref term, vespalib::stringref view, int32_t id, Weight weight) {
return new typename NodeTypes::NumberTerm(term, view, id, weight);
}
template <class NodeTypes>
typename NodeTypes::PrefixTerm *
-createPrefixTerm(vespalib::stringref term, const vespalib::stringref &view, int32_t id, Weight weight) {
+createPrefixTerm(vespalib::stringref term, vespalib::stringref view, int32_t id, Weight weight) {
return new typename NodeTypes::PrefixTerm(term, view, id, weight);
}
template <class NodeTypes>
typename NodeTypes::RangeTerm *
-createRangeTerm(const Range &term, const vespalib::stringref &view, int32_t id, Weight weight) {
+createRangeTerm(const Range &term, vespalib::stringref view, int32_t id, Weight weight) {
return new typename NodeTypes::RangeTerm(term, view, id, weight);
}
template <class NodeTypes>
typename NodeTypes::StringTerm *
-createStringTerm(vespalib::stringref term, const vespalib::stringref &view, int32_t id, Weight weight) {
+createStringTerm(vespalib::stringref term, vespalib::stringref view, int32_t id, Weight weight) {
return new typename NodeTypes::StringTerm(term, view, id, weight);
}
template <class NodeTypes>
typename NodeTypes::SubstringTerm *
-createSubstringTerm(vespalib::stringref term, const vespalib::stringref &view, int32_t id, Weight weight) {
+createSubstringTerm(vespalib::stringref term, vespalib::stringref view, int32_t id, Weight weight) {
return new typename NodeTypes::SubstringTerm(term, view, id, weight);
}
template <class NodeTypes>
typename NodeTypes::SuffixTerm *
-createSuffixTerm(vespalib::stringref term, const vespalib::stringref &view, int32_t id, Weight weight) {
+createSuffixTerm(vespalib::stringref term, vespalib::stringref view, int32_t id, Weight weight) {
return new typename NodeTypes::SuffixTerm(term, view, id, weight);
}
template <class NodeTypes>
typename NodeTypes::LocationTerm *
-createLocationTerm(const Location &loc, const vespalib::stringref &view, int32_t id, Weight weight) {
+createLocationTerm(const Location &loc, vespalib::stringref view, int32_t id, Weight weight) {
return new typename NodeTypes::LocationTerm(loc, view, id, weight);
}
template <class NodeTypes>
typename NodeTypes::PredicateQuery *
-createPredicateQuery(PredicateQueryTerm::UP term, const vespalib::stringref &view, int32_t id, Weight weight) {
+createPredicateQuery(PredicateQueryTerm::UP term, vespalib::stringref view, int32_t id, Weight weight) {
return new typename NodeTypes::PredicateQuery(std::move(term), view, id, weight);
}
template <class NodeTypes>
typename NodeTypes::RegExpTerm *
-createRegExpTerm(vespalib::stringref term, const vespalib::stringref &view, int32_t id, Weight weight) {
+createRegExpTerm(vespalib::stringref term, vespalib::stringref view, int32_t id, Weight weight) {
return new typename NodeTypes::RegExpTerm(term, view, id, weight);
}
@@ -233,33 +233,33 @@ public:
typename NodeTypes::Or &addOr(int child_count) {
return addIntermediate(createOr<NodeTypes>(), child_count);
}
- typename NodeTypes::WeakAnd &addWeakAnd(int child_count, uint32_t minHits, const stringref & view) {
+ typename NodeTypes::WeakAnd &addWeakAnd(int child_count, uint32_t minHits, stringref view) {
return addIntermediate(createWeakAnd<NodeTypes>(minHits, view), child_count);
}
typename NodeTypes::Equiv &addEquiv(int child_count, int32_t id, Weight weight) {
return addIntermediate(createEquiv<NodeTypes>(id, weight), child_count);
}
- typename NodeTypes::Phrase &addPhrase(int child_count, const stringref &view, int32_t id, Weight weight) {
+ typename NodeTypes::Phrase &addPhrase(int child_count, stringref view, int32_t id, Weight weight) {
adjustWeight(weight);
typename NodeTypes::Phrase &node = addIntermediate(createPhrase<NodeTypes>(view, id, weight), child_count);
setWeightOverride(weight);
return node;
}
- typename NodeTypes::SameElement &addSameElement(int child_count, const stringref &view) {
+ typename NodeTypes::SameElement &addSameElement(int child_count, stringref view) {
return addIntermediate(createSameElement<NodeTypes>(view), child_count);
}
- typename NodeTypes::WeightedSetTerm &addWeightedSetTerm( int child_count, const stringref &view, int32_t id, Weight weight) {
+ typename NodeTypes::WeightedSetTerm &addWeightedSetTerm( int child_count, stringref view, int32_t id, Weight weight) {
adjustWeight(weight);
typename NodeTypes::WeightedSetTerm &node = addIntermediate(createWeightedSetTerm<NodeTypes>(view, id, weight), child_count);
return node;
}
- typename NodeTypes::DotProduct &addDotProduct( int child_count, const stringref &view, int32_t id, Weight weight) {
+ typename NodeTypes::DotProduct &addDotProduct( int child_count, stringref view, int32_t id, Weight weight) {
adjustWeight(weight);
typename NodeTypes::DotProduct &node = addIntermediate( createDotProduct<NodeTypes>(view, id, weight), child_count);
return node;
}
typename NodeTypes::WandTerm &addWandTerm(
- int child_count, const stringref &view,
+ int child_count, stringref view,
int32_t id, Weight weight, uint32_t targetNumHits,
int64_t scoreThreshold, double thresholdBoostFactor)
{
@@ -273,39 +273,39 @@ public:
return addIntermediate(createRank<NodeTypes>(), child_count);
}
- typename NodeTypes::NumberTerm &addNumberTerm(const stringref &term, const stringref &view, int32_t id, Weight weight) {
+ typename NodeTypes::NumberTerm &addNumberTerm(stringref term, stringref view, int32_t id, Weight weight) {
adjustWeight(weight);
return addTerm(createNumberTerm<NodeTypes>(term, view, id, weight));
}
- typename NodeTypes::PrefixTerm &addPrefixTerm(const stringref &term, const stringref &view, int32_t id, Weight weight) {
+ typename NodeTypes::PrefixTerm &addPrefixTerm(stringref term, stringref view, int32_t id, Weight weight) {
adjustWeight(weight);
return addTerm(createPrefixTerm<NodeTypes>(term, view, id, weight));
}
- typename NodeTypes::RangeTerm &addRangeTerm(const Range &range, const stringref &view, int32_t id, Weight weight) {
+ typename NodeTypes::RangeTerm &addRangeTerm(const Range &range, stringref view, int32_t id, Weight weight) {
adjustWeight(weight);
return addTerm(createRangeTerm<NodeTypes>(range, view, id, weight));
}
- typename NodeTypes::StringTerm &addStringTerm(const stringref &term, const stringref &view, int32_t id, Weight weight) {
+ typename NodeTypes::StringTerm &addStringTerm(stringref term, stringref view, int32_t id, Weight weight) {
adjustWeight(weight);
return addTerm(createStringTerm<NodeTypes>(term, view, id, weight));
}
- typename NodeTypes::SubstringTerm &addSubstringTerm(const stringref &t, const stringref &view, int32_t id, Weight weight) {
+ typename NodeTypes::SubstringTerm &addSubstringTerm(stringref t, stringref view, int32_t id, Weight weight) {
adjustWeight(weight);
return addTerm(createSubstringTerm<NodeTypes>(t, view, id, weight));
}
- typename NodeTypes::SuffixTerm &addSuffixTerm(const stringref &term, const stringref &view, int32_t id, Weight weight) {
+ typename NodeTypes::SuffixTerm &addSuffixTerm(stringref term, stringref view, int32_t id, Weight weight) {
adjustWeight(weight);
return addTerm(createSuffixTerm<NodeTypes>(term, view, id, weight));
}
- typename NodeTypes::LocationTerm &addLocationTerm(const Location &loc, const stringref &view, int32_t id, Weight weight) {
+ typename NodeTypes::LocationTerm &addLocationTerm(const Location &loc, stringref view, int32_t id, Weight weight) {
adjustWeight(weight);
return addTerm(createLocationTerm<NodeTypes>(loc, view, id, weight));
}
- typename NodeTypes::PredicateQuery &addPredicateQuery(PredicateQueryTerm::UP term, const stringref &view, int32_t id, Weight weight) {
+ typename NodeTypes::PredicateQuery &addPredicateQuery(PredicateQueryTerm::UP term, stringref view, int32_t id, Weight weight) {
adjustWeight(weight);
return addTerm(createPredicateQuery<NodeTypes>(std::move(term), view, id, weight));
}
- typename NodeTypes::RegExpTerm &addRegExpTerm(const stringref &term, const stringref &view, int32_t id, Weight weight) {
+ typename NodeTypes::RegExpTerm &addRegExpTerm(stringref term, stringref view, int32_t id, Weight weight) {
adjustWeight(weight);
return addTerm(createRegExpTerm<NodeTypes>(term, view, id, weight));
}
diff --git a/searchlib/src/vespa/searchlib/query/tree/simplequery.h b/searchlib/src/vespa/searchlib/query/tree/simplequery.h
index 3a2cc2f719e..707ed2aa0db 100644
--- a/searchlib/src/vespa/searchlib/query/tree/simplequery.h
+++ b/searchlib/src/vespa/searchlib/query/tree/simplequery.h
@@ -18,7 +18,7 @@ struct SimpleNear : Near { SimpleNear(size_t dist) : Near(dist) {} };
struct SimpleONear : ONear { SimpleONear(size_t dist) : ONear(dist) {} };
struct SimpleOr : Or {};
struct SimpleWeakAnd : WeakAnd {
- SimpleWeakAnd(uint32_t minHits, const vespalib::stringref & view) :
+ SimpleWeakAnd(uint32_t minHits, vespalib::stringref view) :
WeakAnd(minHits, view)
{}
};
@@ -49,56 +49,56 @@ struct SimpleWandTerm : WandTerm {
};
struct SimpleRank : Rank {};
struct SimpleNumberTerm : NumberTerm {
- SimpleNumberTerm(Type term, const vespalib::stringref &view,
+ SimpleNumberTerm(Type term, vespalib::stringref view,
int32_t id, Weight weight)
: NumberTerm(term, view, id, weight) {
}
};
struct SimpleLocationTerm : LocationTerm {
- SimpleLocationTerm(const Type &term, const vespalib::stringref &view,
+ SimpleLocationTerm(const Type &term, vespalib::stringref view,
int32_t id, Weight weight)
: LocationTerm(term, view, id, weight) {
}
};
struct SimplePrefixTerm : PrefixTerm {
- SimplePrefixTerm(const Type &term, const vespalib::stringref &view,
+ SimplePrefixTerm(const Type &term, vespalib::stringref view,
int32_t id, Weight weight)
: PrefixTerm(term, view, id, weight) {
}
};
struct SimpleRangeTerm : RangeTerm {
- SimpleRangeTerm(const Type &term, const vespalib::stringref &view,
+ SimpleRangeTerm(const Type &term, vespalib::stringref view,
int32_t id, Weight weight)
: RangeTerm(term, view, id, weight) {
}
};
struct SimpleStringTerm : StringTerm {
- SimpleStringTerm(const Type &term, const vespalib::stringref &view,
+ SimpleStringTerm(const Type &term, vespalib::stringref view,
int32_t id, Weight weight)
: StringTerm(term, view, id, weight) {
}
};
struct SimpleSubstringTerm : SubstringTerm {
- SimpleSubstringTerm(const Type &term, const vespalib::stringref &view,
+ SimpleSubstringTerm(const Type &term, vespalib::stringref view,
int32_t id, Weight weight)
: SubstringTerm(term, view, id, weight) {
}
};
struct SimpleSuffixTerm : SuffixTerm {
- SimpleSuffixTerm(const Type &term, const vespalib::stringref &view,
+ SimpleSuffixTerm(const Type &term, vespalib::stringref view,
int32_t id, Weight weight)
: SuffixTerm(term, view, id, weight) {
}
};
struct SimplePredicateQuery : PredicateQuery {
SimplePredicateQuery(PredicateQueryTerm::UP term,
- const vespalib::stringref &view,
+ vespalib::stringref view,
int32_t id, Weight weight)
: PredicateQuery(std::move(term), view, id, weight) {
}
};
struct SimpleRegExpTerm : RegExpTerm {
- SimpleRegExpTerm(const Type &term, const vespalib::stringref &view,
+ SimpleRegExpTerm(const Type &term, vespalib::stringref view,
int32_t id, Weight weight)
: RegExpTerm(term, view, id, weight) {
}
diff --git a/searchlib/src/vespa/searchlib/query/tree/termnodes.h b/searchlib/src/vespa/searchlib/query/tree/termnodes.h
index 9ea2c54f1a0..35c23dde985 100644
--- a/searchlib/src/vespa/searchlib/query/tree/termnodes.h
+++ b/searchlib/src/vespa/searchlib/query/tree/termnodes.h
@@ -15,7 +15,7 @@ typedef TermBase<vespalib::string> StringBase;
class NumberTerm : public QueryNodeMixin<NumberTerm, StringBase >
{
public:
- NumberTerm(Type term, const vespalib::stringref &view, int32_t id, Weight weight)
+ NumberTerm(Type term, vespalib::stringref view, int32_t id, Weight weight)
: QueryNodeMixinType(term, view, id, weight) {}
virtual ~NumberTerm() = 0;
};
@@ -25,7 +25,7 @@ public:
class PrefixTerm : public QueryNodeMixin<PrefixTerm, StringBase >
{
public:
- PrefixTerm(const Type &term, const vespalib::stringref &view,
+ PrefixTerm(const Type &term, vespalib::stringref view,
int32_t id, Weight weight)
: QueryNodeMixinType(term, view, id, weight)
{}
@@ -37,7 +37,7 @@ public:
class RangeTerm : public QueryNodeMixin<RangeTerm, TermBase<Range> >
{
public:
- RangeTerm(const Type& term, const vespalib::stringref &view,
+ RangeTerm(const Type& term, vespalib::stringref view,
int32_t id, Weight weight)
: QueryNodeMixinType(term, view, id, weight)
{}
@@ -58,7 +58,7 @@ public:
class SubstringTerm : public QueryNodeMixin<SubstringTerm, StringBase >
{
public:
- SubstringTerm(const Type &term, const vespalib::stringref &view,
+ SubstringTerm(const Type &term, vespalib::stringref view,
int32_t id, Weight weight)
: QueryNodeMixinType(term, view, id, weight)
{}
@@ -70,7 +70,7 @@ class SubstringTerm : public QueryNodeMixin<SubstringTerm, StringBase >
class SuffixTerm : public QueryNodeMixin<SuffixTerm, StringBase >
{
public:
- SuffixTerm(const Type &term, const vespalib::stringref &view,
+ SuffixTerm(const Type &term, vespalib::stringref view,
int32_t id, Weight weight)
: QueryNodeMixinType(term, view, id, weight)
{}
@@ -82,7 +82,7 @@ public:
class LocationTerm : public QueryNodeMixin<LocationTerm, TermBase<Location> >
{
public:
- LocationTerm(const Type &term, const vespalib::stringref &view,
+ LocationTerm(const Type &term, vespalib::stringref view,
int32_t id, Weight weight)
: QueryNodeMixinType(term, view, id, weight)
{}
@@ -95,7 +95,7 @@ class PredicateQuery : public QueryNodeMixin<PredicateQuery,
TermBase<PredicateQueryTerm::UP> >
{
public:
- PredicateQuery(PredicateQueryTerm::UP term, const vespalib::stringref &view,
+ PredicateQuery(PredicateQueryTerm::UP term, vespalib::stringref view,
int32_t id, Weight weight)
: QueryNodeMixinType(std::move(term), view, id, weight)
{}
@@ -106,7 +106,7 @@ public:
class RegExpTerm : public QueryNodeMixin<RegExpTerm, StringBase>
{
public:
- RegExpTerm(const Type &term, const vespalib::stringref &view,
+ RegExpTerm(const Type &term, vespalib::stringref view,
int32_t id, Weight weight)
: QueryNodeMixinType(term, view, id, weight)
{}
diff --git a/searchsummary/src/vespa/searchsummary/docsummary/dynamicteaserdfw.cpp b/searchsummary/src/vespa/searchsummary/docsummary/dynamicteaserdfw.cpp
index 73c62db864c..4112afc1895 100644
--- a/searchsummary/src/vespa/searchsummary/docsummary/dynamicteaserdfw.cpp
+++ b/searchsummary/src/vespa/searchsummary/docsummary/dynamicteaserdfw.cpp
@@ -119,7 +119,7 @@ private:
public:
JuniperQueryAdapter(KeywordExtractor *kwExtractor,
- const vespalib::stringref &buf,
+ vespalib::stringref buf,
const search::fef::Properties *highlightTerms = NULL)
: _kwExtractor(kwExtractor), _buf(buf), _highlightTerms(highlightTerms), _visitor(NULL) {}
diff --git a/searchsummary/src/vespa/searchsummary/docsummary/itokenizer.h b/searchsummary/src/vespa/searchsummary/docsummary/itokenizer.h
index 15a367761ec..e9fc3579f31 100644
--- a/searchsummary/src/vespa/searchsummary/docsummary/itokenizer.h
+++ b/searchsummary/src/vespa/searchsummary/docsummary/itokenizer.h
@@ -35,8 +35,8 @@ public:
_text(textBegin, textEnd - textBegin), _stem(), _type(type) {}
Token(const char * textBegin, const char * textEnd, const char * stemBegin, const char * stemEnd, Type type) :
_text(textBegin, textEnd - textBegin), _stem(stemBegin, stemEnd - stemBegin), _type(type) {}
- const vespalib::stringref & getText() const { return _text; }
- const vespalib::stringref & getStem() const { return _stem; }
+ vespalib::stringref getText() const { return _text; }
+ vespalib::stringref getStem() const { return _stem; }
bool hasStem() const { return _stem.data() != NULL; }
Type getType() const { return _type; }
};
diff --git a/searchsummary/src/vespa/searchsummary/docsummary/summaryfeaturesdfw.cpp b/searchsummary/src/vespa/searchsummary/docsummary/summaryfeaturesdfw.cpp
index a5fb9bd8539..7cf1e65fbc0 100644
--- a/searchsummary/src/vespa/searchsummary/docsummary/summaryfeaturesdfw.cpp
+++ b/searchsummary/src/vespa/searchsummary/docsummary/summaryfeaturesdfw.cpp
@@ -79,7 +79,7 @@ SummaryFeaturesDFW::insertField(uint32_t docid, GeneralResult *, GetDocsumsState
}
}
-void FeaturesDFW::featureDump(vespalib::JSONStringer & json, const vespalib::stringref & name, double feature)
+void FeaturesDFW::featureDump(vespalib::JSONStringer & json, vespalib::stringref name, double feature)
{
json.appendKey(name);
if (std::isnan(feature) || std::isinf(feature)) {
diff --git a/searchsummary/src/vespa/searchsummary/docsummary/summaryfeaturesdfw.h b/searchsummary/src/vespa/searchsummary/docsummary/summaryfeaturesdfw.h
index 5229e26475b..e417e89cf04 100644
--- a/searchsummary/src/vespa/searchsummary/docsummary/summaryfeaturesdfw.h
+++ b/searchsummary/src/vespa/searchsummary/docsummary/summaryfeaturesdfw.h
@@ -13,7 +13,7 @@ class IDocsumEnvironment;
class FeaturesDFW : public IDocsumFieldWriter
{
protected:
- void featureDump(vespalib::JSONStringer & json, const vespalib::stringref & name, double feature);
+ void featureDump(vespalib::JSONStringer & json, vespalib::stringref name, double feature);
};
class SummaryFeaturesDFW : public FeaturesDFW
diff --git a/slobrok/src/vespa/slobrok/sbregister.cpp b/slobrok/src/vespa/slobrok/sbregister.cpp
index 27bb5fbe83b..2d742e063ee 100644
--- a/slobrok/src/vespa/slobrok/sbregister.cpp
+++ b/slobrok/src/vespa/slobrok/sbregister.cpp
@@ -32,7 +32,7 @@ createSpec(FRT_Supervisor &orb)
void
-discard(std::vector<vespalib::string> &vec, const vespalib::stringref & val)
+discard(std::vector<vespalib::string> &vec, vespalib::stringref val)
{
uint32_t i = 0;
uint32_t size = vec.size();
diff --git a/storage/src/tests/visiting/commandqueuetest.cpp b/storage/src/tests/visiting/commandqueuetest.cpp
index 7b6d5dcafd6..e335df353f6 100644
--- a/storage/src/tests/visiting/commandqueuetest.cpp
+++ b/storage/src/tests/visiting/commandqueuetest.cpp
@@ -34,7 +34,7 @@ CPPUNIT_TEST_SUITE_REGISTRATION(CommandQueueTest);
namespace {
std::shared_ptr<api::CreateVisitorCommand> getCommand(
- const vespalib::stringref & name, int timeout,
+ vespalib::stringref name, int timeout,
uint8_t priority = 0)
{
vespalib::asciistream ost;
diff --git a/storage/src/vespa/storage/common/hostreporter/kernelmetrictool.cpp b/storage/src/vespa/storage/common/hostreporter/kernelmetrictool.cpp
index ea6e266f0b2..3dc23d8236b 100644
--- a/storage/src/vespa/storage/common/hostreporter/kernelmetrictool.cpp
+++ b/storage/src/vespa/storage/common/hostreporter/kernelmetrictool.cpp
@@ -31,7 +31,7 @@ vespalib::string stripWhitespace(const vespalib::string& s) {
}
vespalib::string getLine(vespalib::stringref key,
- const vespalib::stringref& content)
+ vespalib::stringref content)
{
vespalib::string::size_type start(0);
vespalib::string::size_type stop(content.find('\n'));
diff --git a/storage/src/vespa/storage/common/hostreporter/kernelmetrictool.h b/storage/src/vespa/storage/common/hostreporter/kernelmetrictool.h
index 0d07f045de2..ec7cff41d9a 100644
--- a/storage/src/vespa/storage/common/hostreporter/kernelmetrictool.h
+++ b/storage/src/vespa/storage/common/hostreporter/kernelmetrictool.h
@@ -16,7 +16,7 @@ vespalib::string readFile(const char* fileName);
vespalib::string stripWhitespace(const vespalib::string& s);
vespalib::string getLine(vespalib::stringref key,
- const vespalib::stringref& content);
+ vespalib::stringref content);
vespalib::string getToken(uint32_t index, const vespalib::string& line);
diff --git a/storageapi/src/vespa/storageapi/message/bucket.cpp b/storageapi/src/vespa/storageapi/message/bucket.cpp
index afceac0f78d..ee8aff31914 100644
--- a/storageapi/src/vespa/storageapi/message/bucket.cpp
+++ b/storageapi/src/vespa/storageapi/message/bucket.cpp
@@ -453,7 +453,7 @@ RequestBucketInfoCommand::RequestBucketInfoCommand(
RequestBucketInfoCommand::RequestBucketInfoCommand(
document::BucketSpace bucketSpace,
uint16_t distributor, const lib::ClusterState& state,
- const vespalib::stringref & distributionHash)
+ vespalib::stringref distributionHash)
: StorageCommand(MessageType::REQUESTBUCKETINFO),
_bucketSpace(bucketSpace),
_buckets(),
diff --git a/storageapi/src/vespa/storageapi/message/bucket.h b/storageapi/src/vespa/storageapi/message/bucket.h
index c0f65a0006a..f6185d9f8e7 100644
--- a/storageapi/src/vespa/storageapi/message/bucket.h
+++ b/storageapi/src/vespa/storageapi/message/bucket.h
@@ -349,7 +349,7 @@ public:
RequestBucketInfoCommand(document::BucketSpace bucketSpace,
uint16_t distributor,
const lib::ClusterState& state,
- const vespalib::stringref & _distributionHash);
+ vespalib::stringref _distributionHash);
RequestBucketInfoCommand(document::BucketSpace bucketSpace,
uint16_t distributor,
diff --git a/storageapi/src/vespa/storageapi/message/persistence.cpp b/storageapi/src/vespa/storageapi/message/persistence.cpp
index c1db27b4c1a..0b641eea253 100644
--- a/storageapi/src/vespa/storageapi/message/persistence.cpp
+++ b/storageapi/src/vespa/storageapi/message/persistence.cpp
@@ -176,7 +176,7 @@ UpdateReply::print(std::ostream& out, bool verbose, const std::string& indent) c
}
GetCommand::GetCommand(const document::Bucket &bucket, const document::DocumentId& docId,
- const vespalib::stringref & fieldSet, Timestamp before)
+ vespalib::stringref fieldSet, Timestamp before)
: BucketInfoCommand(MessageType::GET, bucket),
_docId(docId),
_beforeTimestamp(before),
diff --git a/storageapi/src/vespa/storageapi/message/persistence.h b/storageapi/src/vespa/storageapi/message/persistence.h
index c27264624b7..d352b2a5e94 100644
--- a/storageapi/src/vespa/storageapi/message/persistence.h
+++ b/storageapi/src/vespa/storageapi/message/persistence.h
@@ -188,7 +188,7 @@ class GetCommand : public BucketInfoCommand {
public:
GetCommand(const document::Bucket &bucket, const document::DocumentId&,
- const vespalib::stringref & fieldSet, Timestamp before = MAX_TIMESTAMP);
+ vespalib::stringref fieldSet, Timestamp before = MAX_TIMESTAMP);
~GetCommand() override;
void setBeforeTimestamp(Timestamp ts) { _beforeTimestamp = ts; }
const document::DocumentId& getDocumentId() const { return _docId; }
diff --git a/storageapi/src/vespa/storageapi/message/stat.cpp b/storageapi/src/vespa/storageapi/message/stat.cpp
index b061be885ff..a971aa0c4d5 100644
--- a/storageapi/src/vespa/storageapi/message/stat.cpp
+++ b/storageapi/src/vespa/storageapi/message/stat.cpp
@@ -12,7 +12,7 @@ IMPLEMENT_COMMAND(GetBucketListCommand, GetBucketListReply)
IMPLEMENT_REPLY(GetBucketListReply)
StatBucketCommand::StatBucketCommand(const document::Bucket& bucket,
- const vespalib::stringref & documentSelection)
+ vespalib::stringref documentSelection)
: BucketCommand(MessageType::STATBUCKET, bucket),
_docSelection(documentSelection)
{
@@ -33,7 +33,7 @@ StatBucketCommand::print(std::ostream& out, bool verbose,
}
StatBucketReply::StatBucketReply(const StatBucketCommand& cmd,
- const vespalib::stringref & results)
+ vespalib::stringref results)
: BucketReply(cmd),
_results(results)
{
diff --git a/storageapi/src/vespa/storageapi/message/stat.h b/storageapi/src/vespa/storageapi/message/stat.h
index 637c43255b8..9020d16622a 100644
--- a/storageapi/src/vespa/storageapi/message/stat.h
+++ b/storageapi/src/vespa/storageapi/message/stat.h
@@ -22,7 +22,7 @@ private:
vespalib::string _docSelection;
public:
StatBucketCommand(const document::Bucket &bucket,
- const vespalib::stringref & documentSelection);
+ vespalib::stringref documentSelection);
~StatBucketCommand();
const vespalib::string& getDocumentSelection() const { return _docSelection; }
@@ -33,7 +33,7 @@ public:
class StatBucketReply : public BucketReply {
vespalib::string _results;
public:
- StatBucketReply(const StatBucketCommand&, const vespalib::stringref & results = "");
+ StatBucketReply(const StatBucketCommand&, vespalib::stringref results = "");
const vespalib::string& getResults() { return _results; }
void print(std::ostream& out, bool verbose, const std::string& indent) const override;
DECLARE_STORAGEREPLY(StatBucketReply, onStatBucketReply)
@@ -63,7 +63,7 @@ public:
vespalib::string _bucketInformation;
BucketInfo(const document::BucketId& id,
- const vespalib::stringref & bucketInformation)
+ vespalib::stringref bucketInformation)
: _bucket(id),
_bucketInformation(bucketInformation)
{}
diff --git a/storageapi/src/vespa/storageapi/message/visitor.cpp b/storageapi/src/vespa/storageapi/message/visitor.cpp
index 2597b818d10..658e3d22ca3 100644
--- a/storageapi/src/vespa/storageapi/message/visitor.cpp
+++ b/storageapi/src/vespa/storageapi/message/visitor.cpp
@@ -14,9 +14,9 @@ IMPLEMENT_COMMAND(VisitorInfoCommand, VisitorInfoReply)
IMPLEMENT_REPLY(VisitorInfoReply)
CreateVisitorCommand::CreateVisitorCommand(document::BucketSpace bucketSpace,
- const vespalib::stringref & libraryName,
- const vespalib::stringref & instanceId,
- const vespalib::stringref & docSelection)
+ vespalib::stringref libraryName,
+ vespalib::stringref instanceId,
+ vespalib::stringref docSelection)
: StorageCommand(MessageType::VISITOR_CREATE),
_bucketSpace(bucketSpace),
_libName(libraryName),
diff --git a/storageapi/src/vespa/storageapi/message/visitor.h b/storageapi/src/vespa/storageapi/message/visitor.h
index c1dc65a23d6..696d8962256 100644
--- a/storageapi/src/vespa/storageapi/message/visitor.h
+++ b/storageapi/src/vespa/storageapi/message/visitor.h
@@ -54,9 +54,9 @@ private:
public:
CreateVisitorCommand(document::BucketSpace bucketSpace,
- const vespalib::stringref & libraryName,
- const vespalib::stringref & instanceId,
- const vespalib::stringref & docSelection);
+ vespalib::stringref libraryName,
+ vespalib::stringref instanceId,
+ vespalib::stringref docSelection);
/** Create another command with similar visitor settings. */
CreateVisitorCommand(const CreateVisitorCommand& template_);
diff --git a/storageapi/src/vespa/storageapi/messageapi/returncode.cpp b/storageapi/src/vespa/storageapi/messageapi/returncode.cpp
index 79a768541b9..68fbca75393 100644
--- a/storageapi/src/vespa/storageapi/messageapi/returncode.cpp
+++ b/storageapi/src/vespa/storageapi/messageapi/returncode.cpp
@@ -16,7 +16,7 @@ ReturnCode & ReturnCode::operator = (const ReturnCode &) = default;
ReturnCode & ReturnCode::operator = (ReturnCode &&) = default;
ReturnCode::~ReturnCode() {}
-ReturnCode::ReturnCode(Result result, const vespalib::stringref & msg)
+ReturnCode::ReturnCode(Result result, vespalib::stringref msg)
: _result(result),
_message(msg)
{}
diff --git a/storageapi/src/vespa/storageapi/messageapi/returncode.h b/storageapi/src/vespa/storageapi/messageapi/returncode.h
index 6e2aa79f09f..23c16c85c5e 100644
--- a/storageapi/src/vespa/storageapi/messageapi/returncode.h
+++ b/storageapi/src/vespa/storageapi/messageapi/returncode.h
@@ -73,7 +73,7 @@ private:
public:
ReturnCode();
- explicit ReturnCode(Result result, const vespalib::stringref & msg = "");
+ explicit ReturnCode(Result result, vespalib::stringref msg = "");
ReturnCode(const document::DocumentTypeRepo &repo,
document::ByteBuffer& buffer);
ReturnCode(const ReturnCode &);