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

[cmd] Do not allow ctu-ast-mode in non-CTU mode #3146

Merged
merged 2 commits into from
Jan 28, 2021

Conversation

gamesh411
Copy link
Collaborator

Option ctu-ast-mode is only meaningful if ctu mode is active.
Exit early if ctu-ast-mode is specified but ctu mode is not enabled.

@gamesh411 gamesh411 force-pushed the ctu-mode-sanity-check branch 2 times, most recently from eee976c to bfea531 Compare January 15, 2021 11:28
@gamesh411 gamesh411 added CLI 💻 Related to the command-line interface, such as the cmd, store, etc. commands enhancement 🌟 labels Jan 15, 2021
@gamesh411 gamesh411 force-pushed the ctu-mode-sanity-check branch 2 times, most recently from 7da451c to b4df1d5 Compare January 28, 2021 13:34
@gamesh411
Copy link
Collaborator Author

Returned to the old way of checking the arguments, but moved them to the front. Both analyze and check are guarded now. I have also tested this with --ctu being specified before or after --ctu-ast-mode.

gamesh411 and others added 2 commits January 28, 2021 14:43
Option ctu-ast-mode is only meaningful if ctu mode is active.
Exit early if ctu-ast-mode is specified but ctu mode is not enabled.
 * previous patches squashed
 * removed argparse action solution
 * move the checking of arg to the beginning of the main function to
   preceed all other analysis steps
 * same checking is introduced at the beginning of check's main function
Copy link
Contributor

@csordasmarton csordasmarton left a comment

Choose a reason for hiding this comment

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

LGTM!

@csordasmarton csordasmarton merged commit c13a8f6 into Ericsson:master Jan 28, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLI 💻 Related to the command-line interface, such as the cmd, store, etc. commands enhancement 🌟
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants