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

Integers representing boolean truth values should be converted to bool #82

Closed
2 tasks done
thnkslprpt opened this issue May 2, 2023 · 0 comments · Fixed by #83
Closed
2 tasks done

Integers representing boolean truth values should be converted to bool #82

thnkslprpt opened this issue May 2, 2023 · 0 comments · Fixed by #83

Comments

@thnkslprpt
Copy link
Contributor

Checklist

  • I reviewed the Contributing Guide.
  • I performed a cursory search to see if the bug report is relevant, not redundant, nor in conflict with other tickets.

Describe the bug
There are a few variables in CS represented by integers when they only ever hold boolean true/false values.

Code snips

uint16 ComputedYet; /**< \brief Have we computed an Integrity value yet */

CS/fsw/inc/cs_msg.h

Lines 51 to 52 in bd4dd1c

uint8 RecomputeInProgress; /**< \brief CS "Recompute In Progress" flag */
uint8 OneShotInProgress; /**< \brief CS "OneShot In Progress" flag */

Expected behavior
Integers representing boolean truth values should be converted bool - this makes the intent clearer and improves maintainability.

Reporter Info
Avi Weiss @thnkslprpt

dzbaker added a commit that referenced this issue Feb 8, 2024
…s-to-bool

Fix #82, Convert integers holding boolean truth values to `bool`
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