Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unused variable warnings when building #257

Open
sea-bass opened this issue Jan 12, 2025 · 1 comment
Open

Unused variable warnings when building #257

sea-bass opened this issue Jan 12, 2025 · 1 comment

Comments

@sea-bass
Copy link

When building this package (ROS 2), I see these warnings.

/home/runner/work/moveit2/moveit2/.work/upstream_ws/src/geometric_shapes/src/aabb.cpp:43:26: warning: unused variable 't' [-Wunused-variable]
     43 |   const Eigen::Vector3d& t = transform.translation();
        |                          ^
  /home/runner/work/moveit2/moveit2/.work/upstream_ws/src/geometric_shapes/src/aabb.cpp:45:10: warning: unused variable 'x_range' [-Wunused-variable]
     45 |   double x_range = 0.5 * (fabs(r(0, 0) * box[0]) + fabs(r(0, 1) * box[1]) + fabs(r(0, 2) * box[2]));
        |          ^~~~~~~
  /home/runner/work/moveit2/moveit2/.work/upstream_ws/src/geometric_shapes/src/aabb.cpp:46:10: warning: unused variable 'y_range' [-Wunused-variable]
     46 |   double y_range = 0.5 * (fabs(r(1, 0) * box[0]) + fabs(r(1, 1) * box[1]) + fabs(r(1, 2) * box[2]));
        |          ^~~~~~~
  /home/runner/work/moveit2/moveit2/.work/upstream_ws/src/geometric_shapes/src/aabb.cpp:47:10: warning: unused variable 'z_range' [-Wunused-variable]
     47 |   double z_range = 0.5 * (fabs(r(2, 0) * box[0]) + fabs(r(2, 1) * box[1]) + fabs(r(2, 2) * box[2]));
        |          ^~~~~~~

Leaving as a reminder to fix this later, but if someone gets to it first that's cool.

@sea-bass
Copy link
Author

sea-bass commented Jan 12, 2025

This might have been a source control issue in #239

In ROS 1, this block of code is in a preprocessor conditional with the alternative implementation, but in ROS 2 it's just doubling up on the code...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant