[StateReporting] Add bindings for the new StateReporting framework up to Xcode 27 Beta 3#26035
Open
dalexsoto wants to merge 1 commit into
Open
[StateReporting] Add bindings for the new StateReporting framework up to Xcode 27 Beta 3#26035dalexsoto wants to merge 1 commit into
dalexsoto wants to merge 1 commit into
Conversation
Bind the StateReporting framework introduced in Xcode 27 (iOS, tvOS, macOS and Mac Catalyst 27.0). It exposes a single Objective-C type, SRStateReporter, used to record a feature's or subsystem's state transitions and volatile metadata updates. * Add src/statereporting.cs binding SRStateReporter: the read-only Domain property, ReportTransition and ReportVolatileMetadataUpdate methods, and the FromDomain static factory. The native init is NS_UNAVAILABLE, so the type uses [DisableDefaultCtor]. * Register the framework on all four platforms: add it to COMMON_FRAMEWORKS in frameworks.sources, regenerate generator-frameworks.g.cs, add the Frameworks.cs entries (Mac Catalyst inherits from iOS), and regenerate the *-defines-dotnet.rsp files. * Update tests/dotnet/UnitTests/ProjectTest.cs (expected frameworks linked with LinkMode=None) and regenerate the Documentation.KnownFailures.txt baseline for the new members. * Update the two untrimmed macOS CoreCLR app-size baselines (+10,240 bytes per RID from the added type). * Remove the now-resolved *-StateReporting.todo files. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: a81895be-6d8d-4e92-b751-e88d304b350f
Contributor
There was a problem hiding this comment.
Pull request overview
Adds first-class .NET bindings and build-system registration for Apple’s new StateReporting framework (Xcode 27 beta / platform version 27.0), including test and baseline updates so the new framework is recognized and validated across iOS, tvOS, macOS, and Mac Catalyst.
Changes:
- Introduce
StateReporting.SRStateReporterbindings (domain + transition/metadata reporting APIs) with 27.0 availability. - Register the StateReporting framework in build metadata and generated framework lists, and add
HAS_STATEREPORTINGdefines. - Update unit-test expectations, documentation known-failures baseline, app-size baselines, and remove now-resolved xtro-sharpie
.todofiles.
Reviewed changes
Copilot reviewed 16 out of 16 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| tools/common/Frameworks.cs | Registers StateReporting in per-platform framework availability lists (27.0). |
| src/frameworks.sources | Adds StateReporting to COMMON_FRAMEWORKS so it’s included in framework processing. |
| src/build/dotnet/generator-frameworks.g.cs | Regenerates generated framework registry to include StateReporting and HaveStateReporting. |
| src/statereporting.cs | Adds binding definitions for SRStateReporter (27.0 across iOS/tvOS/macOS/MacCatalyst). |
| src/rsp/dotnet/ios-defines-dotnet.rsp | Adds -d:HAS_STATEREPORTING compile define for iOS. |
| src/rsp/dotnet/tvos-defines-dotnet.rsp | Adds -d:HAS_STATEREPORTING compile define for tvOS. |
| src/rsp/dotnet/macos-defines-dotnet.rsp | Adds -d:HAS_STATEREPORTING compile define for macOS. |
| src/rsp/dotnet/maccatalyst-defines-dotnet.rsp | Adds -d:HAS_STATEREPORTING compile define for Mac Catalyst. |
| tests/dotnet/UnitTests/ProjectTest.cs | Updates expected framework link set to include StateReporting across relevant scenarios. |
| tests/cecil-tests/Documentation.KnownFailures.txt | Updates documentation baseline for the new StateReporting type/members. |
| tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-size.txt | Updates macOS untrimmed app-size baseline due to added API surface. |
| tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-TrimmableStatic-size.txt | Updates macOS untrimmed app-size baseline (trimmable static variant). |
| tests/xtro-sharpie/api-annotations-dotnet/iOS-StateReporting.todo | Removes resolved xtro-sharpie todo entries for iOS. |
| tests/xtro-sharpie/api-annotations-dotnet/tvOS-StateReporting.todo | Removes resolved xtro-sharpie todo entries for tvOS. |
| tests/xtro-sharpie/api-annotations-dotnet/macOS-StateReporting.todo | Removes resolved xtro-sharpie todo entries for macOS. |
| tests/xtro-sharpie/api-annotations-dotnet/MacCatalyst-StateReporting.todo | Removes resolved xtro-sharpie todo entries for Mac Catalyst. |
Collaborator
✅ API diff for current PR / commitNET (empty diffs)✅ API diff vs stableNET (empty diffs)ℹ️ Generator diffGenerator Diff: vsdrops (html) vsdrops (raw diff) gist (raw diff) - Please review changes) Pipeline on Agent |
Collaborator
rolfbjarne
approved these changes
Jul 10, 2026
Collaborator
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.
Bind the StateReporting framework introduced in Xcode 27 (iOS, tvOS, macOS and Mac Catalyst 27.0). It exposes a single Objective-C type, SRStateReporter, used to record a feature's or subsystem's state transitions and volatile metadata updates.
Copilot-Session: a81895be-6d8d-4e92-b751-e88d304b350f