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

Add an argument to sc_stop, default to EXIT_SUCCESS, and provide sc_exit_status() to retrieve it #103

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

markfoodyburton
Copy link
Contributor

…xit_status() to retrieve it

Signed-off-by: Mark Burton <[email protected]>
Copy link
Contributor

@maehne maehne left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If I understand https://github.com/OSCI-WG/lwg-documentation/pull/4 correctly, I think that the if condition needs to be inverted, i.e., the exit_code passed to sc_stop should only be stored into g_exit if the latter still holds its initial value EXIT_SUCCESS.

{
if (g_exit!=EXIT_SUCCESS) g_exit = exit_code;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't the assignment only be allowed if g_exit==EXIT_SUCCESS?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ops - good point well made - sorry !!!

@aut0
Copy link
Contributor

aut0 commented Nov 5, 2024

CI regression: macos (clang-shared-regression) is failing in this branch but passing on main.
Failing here: https://github.com/accellera-official/systemc/actions/runs/11671399911/job/32497691689
Passing here: https://github.com/accellera-official/systemc/actions/runs/11590208723/job/32267293916

CI asan: macos (clang-shared-regression-asan) is passing on this branch, but not on main:
Passing here: https://github.com/accellera-official/systemc/actions/runs/11671399844/job/32497688889
Failing here: https://github.com/accellera-official/systemc/actions/runs/11590208725/job/32267293270

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

Successfully merging this pull request may close these issues.

3 participants