Skip to content

Commit

Permalink
fix(autoware_path_sampler): fix passedByValue (autowarefoundation#8216)
Browse files Browse the repository at this point in the history
fix:passedByValue

Signed-off-by: kobayu858 <[email protected]>
  • Loading branch information
kobayu858 authored Jul 26, 2024
1 parent c4aea4b commit 95aef0d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -140,10 +140,10 @@ size_t findEgoSegmentIndex(
}

std::vector<TrajectoryPoint> resampleTrajectoryPoints(
const std::vector<TrajectoryPoint> traj_points, const double interval);
const std::vector<TrajectoryPoint> & traj_points, const double interval);

std::vector<TrajectoryPoint> resampleTrajectoryPointsWithoutStopPoint(
const std::vector<TrajectoryPoint> traj_points, const double interval);
const std::vector<TrajectoryPoint> & traj_points, const double interval);

template <typename T>
std::optional<size_t> updateFrontPointForFix(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ void compensateLastPose(
}

std::vector<TrajectoryPoint> resampleTrajectoryPoints(
const std::vector<TrajectoryPoint> traj_points, const double interval)
const std::vector<TrajectoryPoint> & traj_points, const double interval)
{
constexpr bool enable_resampling_stop_point = true;

Expand All @@ -71,7 +71,7 @@ std::vector<TrajectoryPoint> resampleTrajectoryPoints(

// NOTE: stop point will not be resampled
std::vector<TrajectoryPoint> resampleTrajectoryPointsWithoutStopPoint(
const std::vector<TrajectoryPoint> traj_points, const double interval)
const std::vector<TrajectoryPoint> & traj_points, const double interval)
{
constexpr bool enable_resampling_stop_point = false;

Expand Down

0 comments on commit 95aef0d

Please sign in to comment.