Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Bence Magyar <[email protected]>
  • Loading branch information
saikishor and bmagyar authored Dec 4, 2024
1 parent fc70a00 commit c910761
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
4 changes: 2 additions & 2 deletions joint_limits/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ if(BUILD_TESTING)
rclcpp
)

ament_add_gtest(test_joint_range_limiter test/test_joint_range_limiter.cpp)
ament_add_gmock(test_joint_range_limiter test/test_joint_range_limiter.cpp)
target_include_directories(test_joint_range_limiter PRIVATE include)
target_link_libraries(test_joint_range_limiter joint_limiter_interface)
ament_target_dependencies(
Expand All @@ -117,7 +117,7 @@ if(BUILD_TESTING)
rclcpp
)

ament_add_gtest(test_joint_soft_limiter test/test_joint_soft_limiter.cpp)
ament_add_gmock(test_joint_soft_limiter test/test_joint_soft_limiter.cpp)
target_include_directories(test_joint_soft_limiter PRIVATE include)
target_link_libraries(test_joint_soft_limiter joint_limiter_interface)
ament_target_dependencies(
Expand Down
8 changes: 3 additions & 5 deletions joint_limits/src/joint_saturation_limiter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -433,10 +433,8 @@ bool JointSaturationLimiter<trajectory_msgs::msg::JointTrajectoryPoint>::on_enfo

// typedefs are needed here to avoid issues with macro expansion. ref:
// https://stackoverflow.com/a/8942986
typedef std::map<int, int> int_map;
typedef joint_limits::JointSaturationLimiter<trajectory_msgs::msg::JointTrajectoryPoint>
JointTrajectoryPointSaturationLimiter;
typedef joint_limits::JointLimiterInterface<trajectory_msgs::msg::JointTrajectoryPoint>
JointTrajectoryPointLimiterInterfaceBase;
using int_map = std::map<int, int>;
using JointTrajectoryPointSaturationLimiter = joint_limits::JointSaturationLimiter<trajectory_msgs::msg::JointTrajectoryPoint>;
using JointTrajectoryPointLimiterInterfaceBase = joint_limits::JointLimiterInterface<trajectory_msgs::msg::JointTrajectoryPoint>;
PLUGINLIB_EXPORT_CLASS(
JointTrajectoryPointSaturationLimiter, JointTrajectoryPointLimiterInterfaceBase)

0 comments on commit c910761

Please sign in to comment.