Skip to content

Commit

Permalink
Use ! instead of not keyword
Browse files Browse the repository at this point in the history
  • Loading branch information
rhaschke committed Jan 15, 2025
1 parent b71e5f5 commit b9ed835
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,7 @@ bool ChompPlanner::solve(const planning_scene::PlanningSceneConstPtr& planning_s
res.processing_time_[0] = (ros::WallTime::now() - start_time).toSec();

// report planning failure if path has collisions
if (not optimizer->isCollisionFree())
if (!optimizer->isCollisionFree())
{
ROS_ERROR_STREAM_NAMED("chomp_planner", "Motion plan is invalid.");
res.error_code_.val = moveit_msgs::MoveItErrorCodes::INVALID_MOTION_PLAN;
Expand Down
4 changes: 2 additions & 2 deletions moveit_planners/trajopt/src/trajopt_interface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ bool TrajOptInterface::solve(const planning_scene::PlanningSceneConstPtr& planni
return false;
}

if (not joint_model_group->satisfiesPositionBounds(start_joint_values.data()))
if (!joint_model_group->satisfiesPositionBounds(start_joint_values.data()))
{
ROS_ERROR_STREAM_NAMED(name_, "Start state violates joint limits");
res.error_code.val = moveit_msgs::MoveItErrorCodes::INVALID_ROBOT_STATE;
Expand Down Expand Up @@ -326,7 +326,7 @@ bool TrajOptInterface::solve(const planning_scene::PlanningSceneConstPtr& planni
constraint.tolerance_above);
constraints_are_ok = constraints_are_ok and joint_cnt.configure(constraint);
constraints_are_ok = constraints_are_ok and joint_cnt.decide(last_state).satisfied;
if (not constraints_are_ok)
if (!constraints_are_ok)
{
ROS_ERROR_STREAM_NAMED("trajopt_planner", "Goal constraints are violated: " << constraint.joint_name);
res.error_code.val = moveit_msgs::MoveItErrorCodes::GOAL_CONSTRAINTS_VIOLATED;
Expand Down

0 comments on commit b9ed835

Please sign in to comment.