-
Notifications
You must be signed in to change notification settings - Fork 10.5k
Affirmative names for argument parsing namespace destinations. #11952
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
Affirmative names for argument parsing namespace destinations. #11952
Conversation
@swift-ci please smoke test |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks reasonable to me. Can you add some documentation where I asked below on those two classes?
|
||
def __call__(self, parser, namespace, values, option_string=None): | ||
setattr(namespace, self.dest, values) | ||
|
||
|
||
_register(action, 'optional_bool', _OptionalBoolAction) | ||
|
||
|
||
class _OptionalTrueAction(_OptionalBoolAction): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you add documentation for this and the other option?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure thing! I don't expect these classes and really this entire module to hang around for very long, I just needed this particular behavior sooner than later.
@swift-ci please smoke test |
This broke my "fast debug build" setup. Ninja now fails to start with the following error: My build script:
|
I've filed a bug: https://bugs.swift.org/browse/SR-5911 |
Purpose
The main goal for this PR is to rename all argument-parsing namespace destinations of the form
skip_build_*
andskip_test_*
to a more consistent and affirmativebuild_*
andtest_*
respectively. It also corrects the discrepancy betweenbuild_*_device
andtest_*_host
, now all the test variables will betest_*_device
as well. The actual argument option strings have not been changed in anyway, these renames are all under-the-hood so to speak.This PR should be the last step necessary to pave the way for #11827.
rdar://34336890