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

Understanding why you copy the joint_ids #91

Open
brennand opened this issue Jul 25, 2024 · 1 comment
Open

Understanding why you copy the joint_ids #91

brennand opened this issue Jul 25, 2024 · 1 comment

Comments

@brennand
Copy link

Just wondering why you have this code throughout this code:

  std::vector<uint8_t> ids(info_.joints.size(), 0);

  std::copy(joint_ids_.begin(), joint_ids_.end(), ids.begin());

As the joint_ids are assigned on the init and then not modified any where else in the code base?

@brennand brennand changed the title Understnading what you copy the joint_ids Understanding why you copy the joint_ids Jul 25, 2024
@ijnek
Copy link
Member

ijnek commented Aug 3, 2024

I had a look and I think you're right, there is no point in copying and we can use joint_ids_ directly. Would you be able to submit a PR with the changes?

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

2 participants