Skip to content

Add feature staging support to C++/WinRT#229

Merged
kennykerr merged 9 commits into
masterfrom
kennykerr-velocity
Mar 20, 2019
Merged

Add feature staging support to C++/WinRT#229
kennykerr merged 9 commits into
masterfrom
kennykerr-velocity

Conversation

@kennykerr

@kennykerr kennykerr commented Mar 20, 2019

Copy link
Copy Markdown
Contributor

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.

@kennykerr kennykerr changed the title Add Velocity support to C++/WinRT Add feature staging support to C++/WinRT Mar 20, 2019
Comment thread src/tool/cppwinrt/cppwinrt/helpers.h Outdated
Comment thread src/tool/cppwinrt/test_component/test_component.idl Outdated
@kennykerr kennykerr merged commit 91a4bf1 into master Mar 20, 2019
@kennykerr kennykerr deleted the kennykerr-velocity branch March 20, 2019 20:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants