Skip to content

[ImageIO] Update bindings up to Xcode 27.0 Beta 3 - #26175

Merged
dalexsoto merged 1 commit into
xcode27.0from
dev/alex/xc27-ImageIO
Jul 20, 2026
Merged

[ImageIO] Update bindings up to Xcode 27.0 Beta 3#26175
dalexsoto merged 1 commit into
xcode27.0from
dev/alex/xc27-ImageIO

Conversation

@dalexsoto

Copy link
Copy Markdown
Member

Summary

  • Bind the Xcode 27 kCGImageSourceAllowableTypes creation option as CGImageOptions.AllowableTypes on iOS, tvOS, macOS, and Mac Catalyst.
  • Preserve the native null-versus-empty semantics and safely omit the key on older runtimes.
  • Add behavioral coverage for allowed, rejected, and empty image-format allowlists.
  • Remove the four resolved ImageIO xtro todo files.

Validation

  • make world on the current xcode27.0 tip
  • Clean xtro classification: sanity passed
  • Clean cecil suite: passed
  • iOS 27 ImageIO test: 1/1 passed
  • tvOS 27 ImageIO test: 1/1 passed
  • iOS 27 introspection: 44/44 passed
  • tvOS 27 introspection: 43/43 passed
  • macOS introspection: 32/32 passed, 2 host-version-gated
  • Mac Catalyst build passed; local run-bare is blocked by the known unsigned-app TCC privacy abort on the macOS 26.5 host
  • App-size suite: 0 failed; all 16 cases intentionally skipped on beta Xcode

Expose the new per-image-source format allowlist through CGImageOptions.AllowableTypes on iOS, tvOS, macOS, and Mac Catalyst. Marshal UTI arrays into the ImageIO options dictionary while preserving the distinct null and empty-array semantics and safely guarding older runtimes.

Add behavioral coverage that verifies allowed PNG decoding, rejection of a mismatched JPEG allowlist, and the empty-list disablement behavior. Remove the four resolved ImageIO xtro todo files.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 2d20acbf-41e7-403e-ba47-1cf6618300ec
Copilot AI review requested due to automatic review settings July 17, 2026 21:58
@dalexsoto dalexsoto added this to the xcode27 milestone Jul 17, 2026
@dalexsoto
dalexsoto requested a review from rolfbjarne July 17, 2026 21:58

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the ImageIO bindings to match Xcode 27.0 beta 3 by exposing the new kCGImageSourceAllowableTypes option as CGImageOptions.AllowableTypes, while preserving null-vs-empty behavior and safely omitting the key on older OS versions.

Changes:

  • Added CGImageOptions.AllowableTypes (iOS/tvOS/macOS/Mac Catalyst 27.0) and plumbed it into the options dictionary only when the native key exists.
  • Added a monotouch-test that validates decoding behavior for allowed, disallowed, and empty allowlists.
  • Removed the now-resolved ImageIO xtro todo entries for all platforms.

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated no comments.

Show a summary per file
File Description
tests/xtro-sharpie/api-annotations-dotnet/tvOS-ImageIO.todo Removed resolved xtro annotation for the newly bound field.
tests/xtro-sharpie/api-annotations-dotnet/macOS-ImageIO.todo Removed resolved xtro annotation for the newly bound field.
tests/xtro-sharpie/api-annotations-dotnet/MacCatalyst-ImageIO.todo Removed resolved xtro annotation for the newly bound field.
tests/xtro-sharpie/api-annotations-dotnet/iOS-ImageIO.todo Removed resolved xtro annotation for the newly bound field.
tests/monotouch-test/ImageIO/CGImageSourceTest.cs Added runtime-behavior coverage for allowable-types filtering.
src/ImageIO/CGImageSource.cs Added the public AllowableTypes option and ensured it’s only applied when the native key is available.
src/imageio.cs Bound kCGImageSourceAllowableTypes as an internal versioned field for dictionary-key usage.

@vs-mobiletools-engineering-service2

Copy link
Copy Markdown
Collaborator

✅ API diff for current PR / commit

NET (empty diffs)

✅ API diff vs stable

NET (empty diffs)

ℹ️ Generator diff

Generator Diff: vsdrops (html) vsdrops (raw diff) gist (raw diff) - Please review changes)

Pipeline on Agent
Hash: a39abcdcd407687cce616ea1bcf68aca2166c3a4 [PR build]

@vs-mobiletools-engineering-service2

This comment has been minimized.

@vs-mobiletools-engineering-service2

Copy link
Copy Markdown
Collaborator

🚀 [CI Build #a39abcd] Test results 🚀

Test results

✅ All tests passed on VSTS: test results.

🎉 All 195 tests passed 🎉

Tests counts

✅ assembly-processing: All 1 tests passed. [attempt 2] Html Report (VSDrops) Download
✅ cecil: All 1 tests passed. [attempt 2] Html Report (VSDrops) Download
✅ dotnettests (iOS): All 1 tests passed. Html Report (VSDrops) Download
✅ dotnettests (MacCatalyst): All 1 tests passed. Html Report (VSDrops) Download
✅ dotnettests (macOS): All 1 tests passed. Html Report (VSDrops) Download
✅ dotnettests (Multiple platforms): All 1 tests passed. Html Report (VSDrops) Download
✅ dotnettests (tvOS): All 1 tests passed. Html Report (VSDrops) Download
✅ framework: All 2 tests passed. [attempt 2] Html Report (VSDrops) Download
✅ fsharp: All 4 tests passed. Html Report (VSDrops) Download
✅ generator: All 5 tests passed. Html Report (VSDrops) Download
✅ interdependent-binding-projects: All 4 tests passed. Html Report (VSDrops) Download
✅ introspection: All 6 tests passed. Html Report (VSDrops) Download
✅ linker (iOS): All 15 tests passed. Html Report (VSDrops) Download
✅ linker (MacCatalyst): All 15 tests passed. Html Report (VSDrops) Download
✅ linker (macOS): All 21 tests passed. Html Report (VSDrops) Download
✅ linker (tvOS): All 15 tests passed. Html Report (VSDrops) Download
✅ monotouch (iOS): All 19 tests passed. Html Report (VSDrops) Download
✅ monotouch (MacCatalyst): All 18 tests passed. Html Report (VSDrops) Download
✅ monotouch (macOS): All 19 tests passed. Html Report (VSDrops) Download
✅ monotouch (tvOS): All 19 tests passed. Html Report (VSDrops) Download
✅ msbuild: All 2 tests passed. Html Report (VSDrops) Download
✅ sharpie: All 1 tests passed. Html Report (VSDrops) Download
✅ windows: All 3 tests passed. Html Report (VSDrops) Download
✅ xcframework: All 4 tests passed. Html Report (VSDrops) Download
✅ xtro: All 1 tests passed. [attempt 2] Html Report (VSDrops) Download

macOS tests

✅ Tests on macOS Sonoma (14): All 5 tests passed. Html Report (VSDrops) Download
✅ Tests on macOS Sequoia (15): All 5 tests passed. Html Report (VSDrops) Download
✅ Tests on macOS Tahoe (26): All 5 tests passed. Html Report (VSDrops) Download
⚠️ Tests on macOS Golden Gate (27): Tests skipped, incorrect beta version. Html Report (VSDrops) Download

Linux Build Verification

Linux build succeeded

Pipeline on Agent
Hash: a39abcdcd407687cce616ea1bcf68aca2166c3a4 [PR build]

@dalexsoto
dalexsoto enabled auto-merge (squash) July 18, 2026 21:07
@dalexsoto
dalexsoto merged commit b0eb508 into xcode27.0 Jul 20, 2026
56 checks passed
@dalexsoto
dalexsoto deleted the dev/alex/xc27-ImageIO branch July 20, 2026 08:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants