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

Complexity of ARGCHECK macros trigger JPL rule 24, multiple statements per line #1285

Open
skliper opened this issue Sep 8, 2022 · 0 comments

Comments

@skliper
Copy link
Contributor

skliper commented Sep 8, 2022

Is your feature request related to a problem? Please describe.
Consider reworking ARGCHECK. Although it reduces repeated lines in code, it does "hide" a return within the macro and isn't really the simplest macro when combined with OS_CHECK_STRING or similar. Note it works... it's just not a trivial macro so ends up triggering coding standard warnings.

Describe the solution you'd like
Although we did just disable the warning in nasa/cFS#561, it's a warning that would be good to apply to non-macro code at least. Really this issue trades macro complexity with function complexity where there is no real right answer in my mind. The point if this issue is to at least document this for future consideration, not necessarily back out the changes.

Describe alternatives you've considered
Leave as-is

Additional context
None

Requester Info
Jacob Hageman - NASA/GSFC

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

No branches or pull requests

1 participant