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

return non-zero error codes from SANY on more errors #483

Merged
merged 2 commits into from
Jul 9, 2020
Merged

return non-zero error codes from SANY on more errors #483

merged 2 commits into from
Jul 9, 2020

Conversation

zmatti
Copy link
Contributor

@zmatti zmatti commented Jul 4, 2020

This is intended as useful when using SANY as part of shell-based
tooling. The command line flag is introduced to keep it backwards
compatible so that no one breaks.

This is intended as useful when using SANY as part of shell-based
tooling. The command line flag is introduced to keep it backwards
compatible so that no one breaks.
@lemmy lemmy added enhancement Lets change things for the better SANY Issues involving SANY's analysis labels Jul 6, 2020
@lemmy lemmy added this to the 1.7.1 milestone Jul 6, 2020
@@ -77,6 +77,10 @@
// true <=> statistics about builtin operator usage
// should be reported

private static boolean strictErrorCodes = false;
Copy link
Member

Choose a reason for hiding this comment

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

For consistency with the rest: Please rename to doStrictErrorCodes

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done

@@ -410,6 +418,8 @@ else if (args[i].equals("-D") || args[i].equals("-d"))
doDebugging = !doDebugging;
else if (args[i].equals("-STAT") || args[i].equals("-stat"))
doStats = !doStats;
else if (args[i].equals("-error-codes"))
Copy link
Member

Choose a reason for hiding this comment

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

I suggest to call toLowerCase on args[i] to ignore casing.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done

@@ -77,6 +77,10 @@
// true <=> statistics about builtin operator usage
// should be reported

private static boolean strictErrorCodes = false;
// true <=> error level should be reported as the tools'
Copy link
Member

Choose a reason for hiding this comment

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

Please bump SANY's version number and moddate.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done. I believe you meant the constants towards the top of the file. Let me know if I misunderstood.

@zmatti
Copy link
Contributor Author

zmatti commented Jul 8, 2020

Thanks for the review! Made changes as requested, please take a look

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Lets change things for the better SANY Issues involving SANY's analysis
Development

Successfully merging this pull request may close these issues.

None yet

2 participants