feat: implement comparison operator for the struct Lane
Implement comparison operator for the structs Lane and LaneBoundary.
-
Lane
All properties of the Lane struct will be compared.
A special handling is the comparison of Lane properties which arestd::vector<Lane>
(e.g. left_adjacent_lanes and successor_lanes).
For these lane vectors only theLane->id
of each equivalent vector elements will be compared by theShallowVectorLaneComparison
function.
A deep comparison would be problematic as the imap standard allows circular references. For example, theleft_adjacent_lane
of lane=4 is lane=3. And theleft_adjacent_lane
of lane=3 is lane=4. -
LaneBoundary
LaneBoundary comparison is based on IDs only (LaneBoundary->id
) for now and actual full comparison will come as a separate PR.