Skip to content

Commit 6100a94

Browse files
authored
Shorten the callback definition for uncrustify. (#163)
This should ensure that it works for both uncrustify 0.72 and 0.78. Signed-off-by: Chris Lalancette <[email protected]>
1 parent 182d3f4 commit 6100a94

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

turtlesim/tutorials/teleop_turtle_key.cpp

+4-5
Original file line numberDiff line numberDiff line change
@@ -305,13 +305,12 @@ class TeleopTurtle final
305305

306306
void sendGoal(float theta)
307307
{
308-
auto goal = turtlesim::action::RotateAbsolute::Goal();
308+
using Rotate = turtlesim::action::RotateAbsolute;
309+
auto goal = Rotate::Goal();
309310
goal.theta = theta;
310-
auto send_goal_options =
311-
rclcpp_action::Client<turtlesim::action::RotateAbsolute>::SendGoalOptions();
311+
auto send_goal_options = rclcpp_action::Client<Rotate>::SendGoalOptions();
312312
send_goal_options.goal_response_callback =
313-
[this](rclcpp_action::ClientGoalHandle<turtlesim::action::RotateAbsolute>::SharedPtr
314-
goal_handle)
313+
[this](rclcpp_action::ClientGoalHandle<Rotate>::SharedPtr goal_handle)
315314
{
316315
RCLCPP_DEBUG(nh_->get_logger(), "Goal response received");
317316
this->goal_handle_ = goal_handle;

0 commit comments

Comments
 (0)