Add feature staging support to C++/WinRT#229
Merged
Merged
Conversation
DefaultRyan
reviewed
Mar 20, 2019
DefaultRyan
approved these changes
Mar 20, 2019
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Windows APIs typically need to be flighted such that teams working on different OS branches can use hold-back support to develop experimental or staged features while disabling those features from shipping builds (or different branches). This update adds support for OS developers to make use of feature staging metadata to elide component support for selected APIs.
There are a few points to consider:
Feature attributes only appear in internal metadata that is never shipped publicly. So in practice, this support is only for OS builds and there will never be any elision for components authored with published metadata.
Language projections always include all types in a given projection if those types appear in metadata, regardless of any Feature attributes that may be present.
The C++/WinRT component support for feature staging only holds back the implementation of feature-staged interfaces and runtime classes. The headers will still include types that are "always disabled", but a given component's generated scaffolding will not implement those types. This is intentional to avoid build instability and is consistent with how OS developers using WIL + WRL would manage this manually.