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

Fix #359, Remove 'return;' from last line of void function. #360

Merged
merged 1 commit into from
Oct 3, 2022

Conversation

thnkslprpt
Copy link
Contributor

@thnkslprpt thnkslprpt commented Sep 28, 2022

Checklist

Describe the contribution
Fixes #359
Removes a single (the only) case of redundant "return;" statement on the last line of a void function.
Corrected a typo in the comments that was noticed along the way.

Testing performed
None, prior to submission.

Expected behavior changes
No impact on behavior.

Contributor Info
@thnkslprpt

@chillfig chillfig added the CCB:Ready Pull request is ready for discussion at the Configuration Control Board (CCB) label Sep 29, 2022
@thnkslprpt thnkslprpt force-pushed the fix-359-void-returns branch from e2c6805 to 4b3c24d Compare October 1, 2022 07:08
@ArielSAdamsNASA
Copy link

@thnkslprpt Can you take a look at the format check workflow and fix the issue caught by it? Specifically about void CFE_PSP_SetDefaultExceptionEnvironment(void). Thank you!

@dzbaker dzbaker added CCB:Approved Indicates Approval by CCB and removed CCB:Ready Pull request is ready for discussion at the Configuration Control Board (CCB) labels Oct 3, 2022
@dzbaker dzbaker merged commit df155ab into nasa:main Oct 3, 2022
@thnkslprpt
Copy link
Contributor Author

@thnkslprpt Can you take a look at the format check workflow and fix the issue caught by it? Specifically about void CFE_PSP_SetDefaultExceptionEnvironment(void). Thank you!

It seems that the warning was deemed ignorable in this case, given that the pull request was merged, which is good because I was having trouble deciphering exactly what the error was referring to anyway. Was it just due to the empty function?

@thnkslprpt thnkslprpt deleted the fix-359-void-returns branch October 3, 2022 23:55
@chillfig
Copy link
Contributor

chillfig commented Oct 4, 2022

@thnkslprpt Can you take a look at the format check workflow and fix the issue caught by it? Specifically about void CFE_PSP_SetDefaultExceptionEnvironment(void). Thank you!

It seems that the warning was deemed ignorable in this case, given that the pull request was merged, which is good because I was having trouble deciphering exactly what the error was referring to anyway. Was it just due to the empty function?

The "error on differences" step of the format check workflow (https://github.com/nasa/PSP/actions/runs/3163591969/jobs/5151273223) looks something like this:

16 -void CFE_PSP_SetDefaultExceptionEnvironment(void)
17 -{
18 -}
19 +void CFE_PSP_SetDefaultExceptionEnvironment(void) {}

The check recommends removing lines 16-18 by "-" before the line. The check recommends adding line 19 by showing "+" before the line.

@thnkslprpt
Copy link
Contributor Author

The check recommends removing lines 16-18 by "-" before the line. The check recommends adding line 19 by showing "+" before the line.

Ah OK thanks Justin. Yes I get the format now.
Cheers

@dmknutsen dmknutsen added this to the Draco milestone Jan 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CCB:Approved Indicates Approval by CCB
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Remove "return;" from last line of void functions
5 participants