Skip to content

Commit 8a1afe4

Browse files
committed
Works around Unreachable Warning for Debug Build
1 parent f1384f5 commit 8a1afe4

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

src/extractor/guidance/sliproad_handler.cpp

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -186,11 +186,9 @@ operator()(const NodeID /*nid*/, const EdgeID source_edge_id, Intersection inter
186186
if (is_left_sliproad_turn)
187187
return main_road_intersection->intersection.getLeftmostRoad();
188188

189-
if (is_right_sliproad_turn)
190-
return main_road_intersection->intersection.getRightmostRoad();
191-
192-
BOOST_ASSERT_MSG(false, "Sliproad is neither a left nor right of obvious main road");
193-
return main_road_intersection->intersection.getLeftmostRoad();
189+
BOOST_ASSERT_MSG(is_right_sliproad_turn,
190+
"Sliproad is neither a left nor right of obvious main road");
191+
return main_road_intersection->intersection.getRightmostRoad();
194192
}();
195193

196194
const auto &crossing_road_data = node_based_graph.GetEdgeData(crossing_road.eid);

0 commit comments

Comments
 (0)