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

CLI: Add negation flags like clang or gcc #1701

Open
furesoft opened this issue Nov 24, 2024 · 7 comments
Open

CLI: Add negation flags like clang or gcc #1701

furesoft opened this issue Nov 24, 2024 · 7 comments
Labels

Comments

@furesoft
Copy link

Passing a false value use a negation like --no-execution instead of --execution false

@FrankRay78
Copy link
Contributor

Hello @furesoft , can you please provide links to the appropriate clang/gcc manual entries/help illustrating this behaviour?

@furesoft
Copy link
Author

hmm. I cannot find a description but the man page show some example flags

@FrankRay78
Copy link
Contributor

FrankRay78 commented Jan 14, 2025

@furesoft Do you imagine that when a command setting has a flag defined as a boolean, then automatic parsing and acceptance of the --no- prefix is also supported OOTB? Have you done this on any of your own apps, out of interest?

@furesoft
Copy link
Author

What's OOTB?

I did not implemented yet because I had no usecase for it and didn't know the option exists. I am working on a compiler and the current option to negate flags would be combersome.

@FrankRay78
Copy link
Contributor

OOTB is 'out of the box'

I'm trying to understand why you wouldn't just add the required negative flags to the settings, and use these accordingly in the command.

Is there a reason why this isn't the best way forward? I ask from a place of ignorance not having seen this request before.

@furesoft
Copy link
Author

It is possible but I plan to allow kind of 15 flags that can be used to enable specific optimization passes. adding the negative option would result in 30 flags to implement. It's not mandatory but would be nice to have some kind of negation

@FrankRay78
Copy link
Contributor

Understood. Thanks for raising, it's an interesting use case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: Todo 🕑
Development

No branches or pull requests

2 participants