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

Rework docstrings to have consistent style #2064

Open
christophfroehlich opened this issue Feb 20, 2025 · 1 comment · May be fixed by #2087
Open

Rework docstrings to have consistent style #2064

christophfroehlich opened this issue Feb 20, 2025 · 1 comment · May be fixed by #2087

Comments

@christophfroehlich
Copy link
Contributor

christophfroehlich commented Feb 20, 2025

It would be great to be consistent with the style of the existing docstrings, i.e. start the sentence with a verb for "brief". For example, I would put it here

/**
 * @brief Publish the state of the controller manager.
 * 
 * The state includes the list of controllers and the list of hardware interfaces along with their states.
 */

However, I realize that we have already different docstring styles in this file. An example of another style is:

/// A method to register a callback to be called when the list is switched
/**
* \param[in] callback Callback to be called when the list is switched
*/

Is it intentional to have these different styles? @christophfroehlich

Originally posted by @Maverobot in #2006 (comment)

@Vishwanath-Karne
Copy link

Hello @christophfroehlich,

I have worked on this issue and submitted a PR: [#2087](https://github.com/Vishwanathkarne/pull/2087) .

  • I have ensured a consistent docstring style across the codebase.
  • Followed the suggested format with @brief starting with a verb.
  • Standardized different styles to improve clarity and maintainability.

This is my 1st open-source contribution, and I would love your feedback!
Let me know if any improvements are needed.
Thanks for this opportunity!
@christophfroehlich @saikishor

Regards,
Vishwanath Karne

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

Successfully merging a pull request may close this issue.

2 participants