forked from organicmaps/organicmaps
[generator:regions] Fix for review
This commit is contained in:
parent
61672cbf8f
commit
88f936a926
3 changed files with 5 additions and 5 deletions
|
@ -199,7 +199,7 @@ UNIT_TEST(RegionsBuilderTest_GetCountryTrees)
|
|||
RegionsBuilder builder(MakeTestDataSet1(collector));
|
||||
builder.ForEachNormalizedCountry([&](std::string const & name, Node::Ptr const & tree) {
|
||||
Visit(tree, [&](Node::Ptr const & node) {
|
||||
auto path = MakeNodePath(node);
|
||||
auto const path = MakeNodePath(node);
|
||||
StringJoinPolicy stringifier;
|
||||
bankOfNames.push_back(stringifier.ToString(path));
|
||||
});
|
||||
|
|
|
@ -47,8 +47,8 @@ private:
|
|||
template <typename Data, typename Visitor>
|
||||
void Visit(std::shared_ptr<PlaceNode<Data>> const & tree, Visitor && visitor)
|
||||
{
|
||||
std::forward<Visitor>(visitor)(tree);
|
||||
visitor(tree);
|
||||
for (auto const & subtree : tree->GetChildren())
|
||||
Visit(subtree, std::forward<Visitor>(visitor));
|
||||
Visit(subtree, visitor);
|
||||
}
|
||||
} // namespace generator
|
||||
|
|
|
@ -80,8 +80,8 @@ private:
|
|||
|
||||
auto jsonPolicy = JsonPolicy{m_verbose};
|
||||
Visit(tree, [&](auto && node) {
|
||||
auto id = node->GetData().GetId();
|
||||
auto path = MakeNodePath(node);
|
||||
auto const id = node->GetData().GetId();
|
||||
auto const path = MakeNodePath(node);
|
||||
regionsKv << static_cast<int64_t>(id.GetEncodedId()) << " " << jsonPolicy.ToString(path) << "\n";
|
||||
++countIds;
|
||||
if (!setIds.insert(id).second)
|
||||
|
|
Loading…
Add table
Reference in a new issue