From b3e0857472e4df426daddaa0fe2156d76d9d3aec Mon Sep 17 00:00:00 2001 From: duongtd Date: Wed, 9 Sep 2026 14:33:22 +0700 Subject: [PATCH] fix: make the Imu header self-contained after the ROS traits removal The previous commit deleted ros::message_operations::Printer but left the operator<< that called it, so any translation unit including Imu.h failed to compile. Remove that operator, include directly since the covariance fields are boost::array and no longer get it through the removed ROS blocks, drop the duplicate Vector3.h include, and correct the include guard to match the package name. Co-Authored-By: Claude Opus 5 --- robot_sensor_msgs/include/robot_sensor_msgs/Imu.h | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/robot_sensor_msgs/include/robot_sensor_msgs/Imu.h b/robot_sensor_msgs/include/robot_sensor_msgs/Imu.h index 8c6f180..3c99e7e 100644 --- a/robot_sensor_msgs/include/robot_sensor_msgs/Imu.h +++ b/robot_sensor_msgs/include/robot_sensor_msgs/Imu.h @@ -9,11 +9,11 @@ #include #include #include +#include #include #include #include #include -#include namespace robot_sensor_msgs { @@ -91,16 +91,6 @@ typedef boost::shared_ptr< ::robot_sensor_msgs::Imu const> ImuConstPtr; // constants requiring out of line definition - - -template -std::ostream& operator<<(std::ostream& s, const ::robot_sensor_msgs::Imu_ & v) -{ -ros::message_operations::Printer< ::robot_sensor_msgs::Imu_ >::stream(s, "", v); -return s; -} - - template bool operator==(const ::robot_sensor_msgs::Imu_ & lhs, const ::robot_sensor_msgs::Imu_ & rhs) { @@ -122,4 +112,4 @@ bool operator!=(const ::robot_sensor_msgs::Imu_ & lhs, cons } // namespace robot_sensor_msgs -#endif // SENSOR_MSGS_MESSAGE_IMU_H +#endif // ROBOT_SENSOR_MSGS_MESSAGE_IMU_H \ No newline at end of file