Fix syntax error position indicators in parameters queries
To fix #2193 prefix_length member variable has been added to ParsedURL that is set to the length of "/service/version/profile/" prefix when the prefix is accepted by the parser. Also BOOST_FUSION_ADAPT_STRUCT for osrm::server::api::ParsedURL has been moved from header to url_parser.cpp to speed up compilation of CUs that do not use the fusion adaption.
This commit is contained in:
@@ -3,8 +3,6 @@
|
||||
|
||||
#include "util/coordinate.hpp"
|
||||
|
||||
#include <boost/fusion/include/adapt_struct.hpp>
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
@@ -21,17 +19,11 @@ struct ParsedURL final
|
||||
unsigned version;
|
||||
std::string profile;
|
||||
std::string query;
|
||||
std::size_t prefix_length;
|
||||
};
|
||||
|
||||
} // api
|
||||
} // server
|
||||
} // osrm
|
||||
|
||||
BOOST_FUSION_ADAPT_STRUCT(osrm::server::api::ParsedURL,
|
||||
(std::string, service)
|
||||
(unsigned, version)
|
||||
(std::string, profile)
|
||||
(std::string, query)
|
||||
)
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user