Use nested namespace

It's a mechanical change to modernize the code base
This commit is contained in:
Dennis Luxen
2022-12-11 10:10:26 +01:00
parent 152a52bc1a
commit a4aa153ba4
456 changed files with 469 additions and 2474 deletions
+1 -7
View File
@@ -1,11 +1,7 @@
#ifndef OSRM_EXTRACTOR_INTERSECTION_CONSTANTS_HPP_
#define OSRM_EXTRACTOR_INTERSECTION_CONSTANTS_HPP_
namespace osrm
{
namespace extractor
{
namespace intersection
namespace osrm::extractor::intersection
{
// what angle is interpreted as going straight
@@ -30,8 +26,6 @@ const auto constexpr ASSUMED_LANE_WIDTH = 3.25;
// how far apart can roads be at the most, when thinking about merging them?
const auto constexpr MERGABLE_ANGLE_DIFFERENCE = 95.0;
} // namespace intersection
} // namespace extractor
} // namespace osrm
#endif // OSRM_EXTRACTOR_INTERSECTION_CONSTANTS_HPP_
@@ -11,11 +11,7 @@
#include "util/coordinate.hpp"
#include "util/node_based_graph.hpp"
namespace osrm
{
namespace extractor
{
namespace intersection
namespace osrm::extractor::intersection
{
class CoordinateExtractor
@@ -251,8 +247,6 @@ class CoordinateExtractor
const std::uint8_t considered_lanes) const;
};
} // namespace intersection
} // namespace extractor
} // namespace osrm
#endif // OSRM_EXTRACTOR_INTERSECTION_COORDINATE_EXTRACTOR_HPP_
@@ -5,11 +5,7 @@
#include "extractor/suffix_table.hpp"
#include "guidance/constants.hpp"
namespace osrm
{
namespace extractor
{
namespace intersection
namespace osrm::extractor::intersection
{
// check if two name ids can be seen as identical (in presence of refs/others)
@@ -20,8 +16,6 @@ bool HaveIdenticalNames(const NameID lhs,
const NameTable &name_table,
const SuffixTable &street_name_suffix_table);
} // namespace intersection
} // namespace extractor
} // namespace osrm
#endif /*OSRM_EXTRACTOR_INTERSECTION_HAVE_IDENTICAL_NAMES_HPP_*/
@@ -14,11 +14,7 @@
#include <unordered_set>
#include <vector>
namespace osrm
{
namespace extractor
{
namespace intersection
namespace osrm::extractor::intersection
{
IntersectionEdges getIncomingEdges(const util::NodeBasedDynamicGraph &graph,
@@ -89,8 +85,6 @@ getConnectedRoadsForEdgeGeometries(const util::NodeBasedDynamicGraph &graph,
// for getConnectedRoads.
IntersectionEdge skipDegreeTwoNodes(const util::NodeBasedDynamicGraph &graph,
IntersectionEdge road);
} // namespace intersection
} // namespace extractor
} // namespace osrm
#endif
@@ -5,11 +5,7 @@
#include <vector>
namespace osrm
{
namespace extractor
{
namespace intersection
namespace osrm::extractor::intersection
{
// IntersectionEdge is an alias for incoming and outgoing node-based graph edges of an intersection
@@ -42,8 +38,6 @@ struct IntersectionEdgeGeometry
};
using IntersectionEdgeGeometries = std::vector<IntersectionEdgeGeometry>;
} // namespace intersection
} // namespace extractor
} // namespace osrm
#endif
@@ -21,11 +21,7 @@
#include <type_traits>
#include <vector>
namespace osrm
{
namespace extractor
{
namespace intersection
namespace osrm::extractor::intersection
{
inline auto makeCompareAngularDeviation(const double angle)
@@ -232,8 +228,6 @@ struct IntersectionView final : std::vector<IntersectionViewData>, //
using Base = std::vector<IntersectionViewData>;
};
} // namespace intersection
} // namespace extractor
} // namespace osrm
#endif /* OSRM_EXTRACTOR_INTERSECTION_INTERSECTION_VIEW_HPP_*/
@@ -15,11 +15,7 @@
#include <cstdint>
#include <utility>
namespace osrm
{
namespace extractor
{
namespace intersection
namespace osrm::extractor::intersection
{
/*
@@ -311,8 +307,6 @@ struct DistanceToNextIntersectionAccumulator
double distance = 0.;
};
} // namespace intersection
} // namespace extractor
} // namespace osrm
#endif