summaryrefslogtreecommitdiffstats
path: root/searchcore
diff options
context:
space:
mode:
authorHenning Baldersheim <balder@oath.com>2018-04-03 14:08:01 +0200
committerHenning Baldersheim <balder@oath.com>2018-04-03 14:08:01 +0200
commit39a40b07cef9e73a46b4c1f00f4f213478faca57 (patch)
treeb99907e6f4aff148386a926316a95b1276b79e63 /searchcore
parent9e70b2520ace7245a949553f9f92646db910b804 (diff)
Nested namespace and default destructors
Diffstat (limited to 'searchcore')
-rw-r--r--searchcore/src/vespa/searchcore/proton/matching/blueprintbuilder.h6
-rw-r--r--searchcore/src/vespa/searchcore/proton/matching/matchdatareservevisitor.h6
-rw-r--r--searchcore/src/vespa/searchcore/proton/matching/query.cpp6
-rw-r--r--searchcore/src/vespa/searchcore/proton/matching/querynodes.cpp6
-rw-r--r--searchcore/src/vespa/searchcore/proton/matching/querynodes.h7
-rw-r--r--searchcore/src/vespa/searchcore/proton/matching/resolveviewvisitor.h6
-rw-r--r--searchcore/src/vespa/searchcore/proton/matching/termdataextractor.h13
-rw-r--r--searchcore/src/vespa/searchcore/proton/matching/viewresolver.cpp6
-rw-r--r--searchcore/src/vespa/searchcore/proton/matching/viewresolver.h11
9 files changed, 21 insertions, 46 deletions
diff --git a/searchcore/src/vespa/searchcore/proton/matching/blueprintbuilder.h b/searchcore/src/vespa/searchcore/proton/matching/blueprintbuilder.h
index 93439d97fc1..eb45a735780 100644
--- a/searchcore/src/vespa/searchcore/proton/matching/blueprintbuilder.h
+++ b/searchcore/src/vespa/searchcore/proton/matching/blueprintbuilder.h
@@ -6,8 +6,7 @@
#include <vespa/searchlib/query/tree/node.h>
#include <vespa/searchlib/queryeval/blueprint.h>
-namespace proton {
-namespace matching {
+namespace proton::matching {
struct BlueprintBuilder {
/**
@@ -20,6 +19,5 @@ struct BlueprintBuilder {
ISearchContext &context);
};
-} // namespace matching
-} // namespace proton
+}
diff --git a/searchcore/src/vespa/searchcore/proton/matching/matchdatareservevisitor.h b/searchcore/src/vespa/searchcore/proton/matching/matchdatareservevisitor.h
index dcd95b9e473..ebe4e9b2ad7 100644
--- a/searchcore/src/vespa/searchcore/proton/matching/matchdatareservevisitor.h
+++ b/searchcore/src/vespa/searchcore/proton/matching/matchdatareservevisitor.h
@@ -6,8 +6,7 @@
#include <vespa/searchlib/fef/matchdatalayout.h>
#include <vespa/searchlib/query/tree/templatetermvisitor.h>
-namespace proton {
-namespace matching {
+namespace proton::matching {
/**
* Visits all terms of a node tree, and allocates MatchData space for
@@ -34,6 +33,5 @@ public:
MatchDataReserveVisitor(search::fef::MatchDataLayout &mdl) : _mdl(mdl) {}
};
-} // namespace matching
-} // namespace proton
+}
diff --git a/searchcore/src/vespa/searchcore/proton/matching/query.cpp b/searchcore/src/vespa/searchcore/proton/matching/query.cpp
index e6408e89896..33118016d92 100644
--- a/searchcore/src/vespa/searchcore/proton/matching/query.cpp
+++ b/searchcore/src/vespa/searchcore/proton/matching/query.cpp
@@ -33,8 +33,7 @@ using search::queryeval::SearchIterator;
using vespalib::string;
using std::vector;
-namespace proton {
-namespace matching {
+namespace proton::matching {
namespace {
void AddLocationNode(const string &location_str, Node::UP &query_tree, Location &fef_location) {
@@ -168,5 +167,4 @@ Query::createSearch(MatchData &md) const
return _blueprint->createSearch(md, true);
}
-} // namespace matching
-} // namespace proton
+}
diff --git a/searchcore/src/vespa/searchcore/proton/matching/querynodes.cpp b/searchcore/src/vespa/searchcore/proton/matching/querynodes.cpp
index 18fce357cb0..63302424db6 100644
--- a/searchcore/src/vespa/searchcore/proton/matching/querynodes.cpp
+++ b/searchcore/src/vespa/searchcore/proton/matching/querynodes.cpp
@@ -25,8 +25,7 @@ using std::map;
using std::vector;
using vespalib::string;
-namespace proton {
-namespace matching {
+namespace proton::matching {
ProtonTermData::ProtonTermData() = default;
ProtonTermData::ProtonTermData(const ProtonTermData &) = default;
@@ -124,5 +123,4 @@ ProtonTermData::FieldEntry::getHandle() const
}
-} // namespace matching
-} // namespace proton
+}
diff --git a/searchcore/src/vespa/searchcore/proton/matching/querynodes.h b/searchcore/src/vespa/searchcore/proton/matching/querynodes.h
index 0729c9b37e9..ca6c8c75310 100644
--- a/searchcore/src/vespa/searchcore/proton/matching/querynodes.h
+++ b/searchcore/src/vespa/searchcore/proton/matching/querynodes.h
@@ -16,8 +16,7 @@
#include <memory>
#include <vector>
-namespace proton {
-namespace matching {
+namespace proton::matching {
class ViewResolver;
@@ -157,6 +156,4 @@ struct ProtonNodeTypes {
typedef ProtonRegExpTerm RegExpTerm;
};
-} // namespace matching
-} // namespace proton
-
+}
diff --git a/searchcore/src/vespa/searchcore/proton/matching/resolveviewvisitor.h b/searchcore/src/vespa/searchcore/proton/matching/resolveviewvisitor.h
index 7f533ea1a8b..ee6fd470d89 100644
--- a/searchcore/src/vespa/searchcore/proton/matching/resolveviewvisitor.h
+++ b/searchcore/src/vespa/searchcore/proton/matching/resolveviewvisitor.h
@@ -7,8 +7,7 @@
#include <vespa/searchlib/query/tree/templatetermvisitor.h>
#include <vespa/searchlib/fef/iindexenvironment.h>
-namespace proton {
-namespace matching {
+namespace proton::matching {
class ResolveViewVisitor
: public search::query::TemplateTermVisitor<ResolveViewVisitor,
@@ -31,6 +30,5 @@ public:
}
};
-} // namespace matching
-} // namespace proton
+}
diff --git a/searchcore/src/vespa/searchcore/proton/matching/termdataextractor.h b/searchcore/src/vespa/searchcore/proton/matching/termdataextractor.h
index 3d64acf9634..a6a3eb41e37 100644
--- a/searchcore/src/vespa/searchcore/proton/matching/termdataextractor.h
+++ b/searchcore/src/vespa/searchcore/proton/matching/termdataextractor.h
@@ -4,13 +4,10 @@
#include <vector>
-namespace search {
-namespace query { class Node; }
-namespace fef { class ITermData; }
-} // namespace search
+namespace search::query { class Node; }
+namespace search::fef { class ITermData; }
-namespace proton {
-namespace matching {
+namespace proton::matching {
struct TermDataExtractor {
/**
@@ -21,6 +18,4 @@ struct TermDataExtractor {
std::vector<const search::fef::ITermData *> &td);
};
-} // namespace matching
-} // namespace proton
-
+}
diff --git a/searchcore/src/vespa/searchcore/proton/matching/viewresolver.cpp b/searchcore/src/vespa/searchcore/proton/matching/viewresolver.cpp
index 84210508960..b1442fe5e92 100644
--- a/searchcore/src/vespa/searchcore/proton/matching/viewresolver.cpp
+++ b/searchcore/src/vespa/searchcore/proton/matching/viewresolver.cpp
@@ -3,8 +3,7 @@
#include "viewresolver.h"
#include <vespa/searchcommon/common/schema.h>
-namespace proton {
-namespace matching {
+namespace proton::matching {
ViewResolver &
ViewResolver::add(const vespalib::stringref &view,
@@ -43,5 +42,4 @@ ViewResolver::createFromSchema(const search::index::Schema &schema)
return resolver;
}
-} // namespace matching
-} // namespace proton
+}
diff --git a/searchcore/src/vespa/searchcore/proton/matching/viewresolver.h b/searchcore/src/vespa/searchcore/proton/matching/viewresolver.h
index d7a7f002e1c..124ebc67d52 100644
--- a/searchcore/src/vespa/searchcore/proton/matching/viewresolver.h
+++ b/searchcore/src/vespa/searchcore/proton/matching/viewresolver.h
@@ -6,12 +6,9 @@
#include <vector>
#include <map>
-namespace search {
-namespace index { class Schema; }
-} // namespace search
+namespace search::index { class Schema; }
-namespace proton {
-namespace matching {
+namespace proton::matching {
/**
* A small utility class used to resolve views into fields when
@@ -66,6 +63,4 @@ public:
static ViewResolver createFromSchema(const search::index::Schema &schema);
};
-} // namespace matching
-} // namespace proton
-
+}