moveit / moveit_drake

Experimental repository for Moveit2 - Drake integration
BSD 3-Clause "New" or "Revised" License
11 stars 4 forks source link

Replace declaration lambdas. #13

Closed kamiradi closed 7 hours ago

kamiradi commented 2 weeks ago
          There is a more modern way to do this using lambdas, which avoids needing these weird placeholders
    robot_description_subscriber_ = node_->create_subscription<std_msgs::msg::String>(
        "robot_description", rclcpp::SystemDefaultsQoS(), [this](const std_msgs::msg::String::SharedPtr msg){
            if (!description_set_)
    {
      robot_description_ = msg->data;
      description_set_ = true;
    }};

_Originally posted by @sjahr in https://github.com/moveit/moveit_drake/pull/8#discussion_r1663990536_

kamiradi commented 7 hours ago

Resolved in #18