-
Notifications
You must be signed in to change notification settings - Fork 522
Closed
Labels
enhancementNew feature or requestNew feature or request
Description
Feature request
Currently rclcpp has a function to throw an exception based on an rcl error.
rclcpp/rclcpp/src/rclcpp/clock.cpp
Line 134 in 3919ab1
| rclcpp::exceptions::throw_from_rcl_error(ret, "Failed to add time jump callback"); |
This is a request to change that function to return an exception without throwing.
throw rclcpp::exceptions::from_rcl_error(ret, "Failed to add time jump callback");I think this could help static analysis tools like cppcheck recognize when code won't be executed due to an exception. This would remove the need for #646
Implementation considerations
throw_from_rcl_error could be refactored to use from_rcl_error rather than changing all the code at once.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request