From 881f09a0ed2b96044cae879f9e39f0e08591e112 Mon Sep 17 00:00:00 2001 From: tatiana-yan Date: Wed, 17 Jun 2020 18:07:53 +0300 Subject: [PATCH] [search] Fix clang 11.0.3 crash. --- search/types_skipper.cpp | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/search/types_skipper.cpp b/search/types_skipper.cpp index 82adf6aa5d..14ac397f31 100644 --- a/search/types_skipper.cpp +++ b/search/types_skipper.cpp @@ -16,13 +16,14 @@ TypesSkipper::TypesSkipper() { Classificator const & c = classif(); - for (auto const & e : (StringIL[]){{"building"}, {"highway"}, {"landuse"}, {"natural"}, - {"office"}, {"waterway"}, {"area:highway"}}) + StringIL const typesLengthOne[] = {{"building"}, {"highway"}, {"landuse"}, {"natural"}, + {"office"}, {"waterway"}, {"area:highway"}}; + for (auto const & e : typesLengthOne) { m_skipIfEmptyName[0].push_back(c.GetTypeByPath(e)); } - for (auto const & e : (StringIL[]){{"man_made", "chimney"}, + StringIL const typesLengthTwo[] = {{"man_made", "chimney"}, {"place", "country"}, {"place", "state"}, {"place", "county"}, @@ -31,10 +32,12 @@ TypesSkipper::TypesSkipper() {"place", "town"}, {"place", "suburb"}, {"place", "neighbourhood"}, - {"place", "square"}}) + {"place", "square"}}; + for (auto const & e : typesLengthTwo) { m_skipIfEmptyName[1].push_back(c.GetTypeByPath(e)); } + m_skipAlways[1].push_back(c.GetTypeByPath({"sponsored", "partner18"})); m_skipAlways[1].push_back(c.GetTypeByPath({"sponsored", "partner19"})); m_skipAlways[0].push_back(c.GetTypeByPath({"isoline"}));