From 3482e4303af11de9c4c02457bb9228563e062a39 Mon Sep 17 00:00:00 2001
From: "dotnet-maestro[bot]"
<42748379+dotnet-maestro[bot]@users.noreply.github.com>
Date: Tue, 5 May 2026 08:16:39 +0200
Subject: [PATCH 001/156] [main] Update dependencies from dotnet/xharness
(#25282)
This pull request updates the following dependencies
## From https://github.com/dotnet/xharness
- **Subscription**: [02e03784-16b3-4ced-b02a-3715797fc7da](https://maestro.dot.net/subscriptions?search=02e03784-16b3-4ced-b02a-3715797fc7da)
- **Build**: [20260430.4](https://dev.azure.com/dnceng/internal/_build/results?buildId=2964906) ([312724](https://maestro.dot.net/channel/2/github:dotnet:xharness/build/312724))
- **Date Produced**: May 1, 2026 7:05:11 AM UTC
- **Commit**: [92962e5c46ac08a66ded4c5696209cc60f1a232f](https://github.com/dotnet/xharness/commit/92962e5c46ac08a66ded4c5696209cc60f1a232f)
- **Branch**: [main](https://github.com/dotnet/xharness/tree/main)
- **Dependency Updates**:
- From [11.0.0-prerelease.26224.1 to 11.0.0-prerelease.26230.4][2]
- Microsoft.DotNet.XHarness.iOS.Shared
[2]: https://github.com/dotnet/xharness/compare/888ef3e553...92962e5c46
---
NuGet.config | 1 +
eng/Version.Details.props | 2 +-
eng/Version.Details.xml | 4 ++--
3 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/NuGet.config b/NuGet.config
index b14cd27026f0..75219c2881e1 100644
--- a/NuGet.config
+++ b/NuGet.config
@@ -13,6 +13,7 @@
+
diff --git a/eng/Version.Details.props b/eng/Version.Details.props
index a447028e53ff..1f6015e97f8b 100644
--- a/eng/Version.Details.props
+++ b/eng/Version.Details.props
@@ -30,7 +30,7 @@ This file should be imported by eng/Versions.props
18.5.9227
26.4.9015
- 11.0.0-prerelease.26224.1
+ 11.0.0-prerelease.26230.4
18.0.9617
18.0.9617
diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml
index 176e4e77385e..5b24b5001ad7 100644
--- a/eng/Version.Details.xml
+++ b/eng/Version.Details.xml
@@ -107,9 +107,9 @@
https://github.com/dotnet/dotnet
e43cbe04901ea4cf359ed0883b0533abab224ba2
-
+
https://github.com/dotnet/xharness
- 888ef3e553a0716745ecab689e13b816639b5a5a
+ 92962e5c46ac08a66ded4c5696209cc60f1a232f
https://github.com/dotnet/dotnet
From 5d7f7288069a3d4cb0f3a1e2cbf55bff8c597fe0 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 5 May 2026 08:21:31 +0200
Subject: [PATCH 002/156] [workflows] Adjust the inter-branch merge flow to run
daily + manually. (#25307)
It's not necessary to run it on every push to main (which will usually fail if the PR branch was modified, which we always do).
---
.github/workflows/inter-branch-merge-flow.yml | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/.github/workflows/inter-branch-merge-flow.yml b/.github/workflows/inter-branch-merge-flow.yml
index 35a5b4584b4f..9300b4de0fa0 100644
--- a/.github/workflows/inter-branch-merge-flow.yml
+++ b/.github/workflows/inter-branch-merge-flow.yml
@@ -16,9 +16,8 @@
name: Inter-branch merge workflow
on:
- push:
- branches:
- - main
+ # allow triggering this action manually
+ workflow_dispatch:
# Run every day at 3:00 AM UTC
schedule:
From b3948e1cc4b93149527e4e46d3b0b7db6d5d273f Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 5 May 2026 08:23:33 +0200
Subject: [PATCH 003/156] [github] Recompile macios-reviewer workflow with
gh-aw v0.71.2 (#25289)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
The activation job in the `macios-reviewer` workflow was missing `pull-requests: write` permission, causing the 'Add eyes reaction for immediate feedback' step to fail with a 403 when triggered by `/review` on a PR comment.
This was a known gh-aw bug ([github/gh-aw#28767](https://github.com/github/gh-aw/issues/28767)), fixed in v0.71.2 via [github/gh-aw#28854](https://github.com/github/gh-aw/pull/28854).
This PR recompiles the lock file with gh-aw v0.71.2, which adds `pull-requests: write` to the activation job.
🤖 Pull request created by Copilot
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
.github/aw/actions-lock.json | 6 +-
.github/workflows/macios-reviewer.lock.yml | 120 ++++++++++++++-------
2 files changed, 83 insertions(+), 43 deletions(-)
diff --git a/.github/aw/actions-lock.json b/.github/aw/actions-lock.json
index e44fd6da3ec8..996a707ff261 100644
--- a/.github/aw/actions-lock.json
+++ b/.github/aw/actions-lock.json
@@ -5,10 +5,10 @@
"version": "v9.0.0",
"sha": "3a2844b7e9c422d3c10d287c895573f7108da1b3"
},
- "github/gh-aw-actions/setup@v0.71.1": {
+ "github/gh-aw-actions/setup@v0.71.2": {
"repo": "github/gh-aw-actions/setup",
- "version": "v0.71.1",
- "sha": "239aec45b78c8799417efdd5bc6d8cc036629ec1"
+ "version": "v0.71.2",
+ "sha": "ab8940d1df237fc4fae4ab8091e7ba66ada55a55"
}
},
"containers": {
diff --git a/.github/workflows/macios-reviewer.lock.yml b/.github/workflows/macios-reviewer.lock.yml
index 96544eebf0de..bcaac60c75a8 100644
--- a/.github/workflows/macios-reviewer.lock.yml
+++ b/.github/workflows/macios-reviewer.lock.yml
@@ -1,5 +1,5 @@
-# gh-aw-metadata: {"schema_version":"v3","frontmatter_hash":"a4ffe1d52364aca7fafba9ba975ec40a3f4fc4908801119268fc1812f9b09cbe","compiler_version":"v0.71.1","strict":true,"agent_id":"copilot","agent_model":"claude-sonnet-4.5"}
-# gh-aw-manifest: {"version":1,"secrets":["COPILOT_GITHUB_TOKEN","GH_AW_GITHUB_MCP_SERVER_TOKEN","GH_AW_GITHUB_TOKEN","GITHUB_TOKEN"],"actions":[{"repo":"actions/checkout","sha":"de0fac2e4500dabe0009e67214ff5f5447ce83dd","version":"v6.0.2"},{"repo":"actions/download-artifact","sha":"3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c","version":"v8.0.1"},{"repo":"actions/github-script","sha":"3a2844b7e9c422d3c10d287c895573f7108da1b3","version":"v9"},{"repo":"actions/setup-node","sha":"48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e","version":"v6.4.0"},{"repo":"actions/upload-artifact","sha":"043fb46d1a93c77aae656e7c1c64a875d1fc6a0a","version":"v7.0.1"},{"repo":"github/gh-aw-actions/setup","sha":"239aec45b78c8799417efdd5bc6d8cc036629ec1","version":"v0.71.1"}],"containers":[{"image":"ghcr.io/github/gh-aw-firewall/agent:0.25.28","digest":"sha256:a8834e285807654bf680154faa710d43fe4365a0868142f5c20e48c85e137a7a","pinned_image":"ghcr.io/github/gh-aw-firewall/agent:0.25.28@sha256:a8834e285807654bf680154faa710d43fe4365a0868142f5c20e48c85e137a7a"},{"image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.28","digest":"sha256:93290f2393752252911bd7c39a047f776c0b53063575e7bde4e304962a9a61cb","pinned_image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.28@sha256:93290f2393752252911bd7c39a047f776c0b53063575e7bde4e304962a9a61cb"},{"image":"ghcr.io/github/gh-aw-firewall/squid:0.25.28","digest":"sha256:844c18280f82cd1b06345eb2f4e91966b34185bfc51c9f237c3e022e848fb474","pinned_image":"ghcr.io/github/gh-aw-firewall/squid:0.25.28@sha256:844c18280f82cd1b06345eb2f4e91966b34185bfc51c9f237c3e022e848fb474"},{"image":"ghcr.io/github/gh-aw-mcpg:v0.3.0","digest":"sha256:9c2228324fb1f26f39dc9471612e530ae3efc3156dac05efb2e8d212878d454d","pinned_image":"ghcr.io/github/gh-aw-mcpg:v0.3.0@sha256:9c2228324fb1f26f39dc9471612e530ae3efc3156dac05efb2e8d212878d454d"},{"image":"ghcr.io/github/github-mcp-server:v1.0.2","digest":"sha256:26db03408086a99cf1916348dcc4f9614206658f9082a8060dc7c81ad787f4ba","pinned_image":"ghcr.io/github/github-mcp-server:v1.0.2@sha256:26db03408086a99cf1916348dcc4f9614206658f9082a8060dc7c81ad787f4ba"},{"image":"node:lts-alpine","digest":"sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f","pinned_image":"node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f"}]}
+# gh-aw-metadata: {"schema_version":"v3","frontmatter_hash":"a4ffe1d52364aca7fafba9ba975ec40a3f4fc4908801119268fc1812f9b09cbe","compiler_version":"v0.71.2","strict":true,"agent_id":"copilot","agent_model":"claude-sonnet-4.5"}
+# gh-aw-manifest: {"version":1,"secrets":["COPILOT_GITHUB_TOKEN","GH_AW_GITHUB_MCP_SERVER_TOKEN","GH_AW_GITHUB_TOKEN","GITHUB_TOKEN"],"actions":[{"repo":"actions/checkout","sha":"de0fac2e4500dabe0009e67214ff5f5447ce83dd","version":"v6.0.2"},{"repo":"actions/download-artifact","sha":"3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c","version":"v8.0.1"},{"repo":"actions/github-script","sha":"373c709c69115d41ff229c7e5df9f8788daa9553","version":"v9"},{"repo":"actions/github-script","sha":"3a2844b7e9c422d3c10d287c895573f7108da1b3","version":"v9"},{"repo":"actions/setup-node","sha":"48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e","version":"v6.4.0"},{"repo":"actions/upload-artifact","sha":"043fb46d1a93c77aae656e7c1c64a875d1fc6a0a","version":"v7.0.1"},{"repo":"github/gh-aw-actions/setup","sha":"ab8940d1df237fc4fae4ab8091e7ba66ada55a55","version":"v0.71.2"}],"containers":[{"image":"ghcr.io/github/gh-aw-firewall/agent:0.25.29","digest":"sha256:e68f37e36962dcb3f3d1de680a49bc2302cefd001b941a7dc377155ec7ce42f4","pinned_image":"ghcr.io/github/gh-aw-firewall/agent:0.25.29@sha256:e68f37e36962dcb3f3d1de680a49bc2302cefd001b941a7dc377155ec7ce42f4"},{"image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.29","digest":"sha256:d1219e4110684402aabbeb5a43858f26790c9d0be210581cf3f7a521bd2c87b6","pinned_image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.29@sha256:d1219e4110684402aabbeb5a43858f26790c9d0be210581cf3f7a521bd2c87b6"},{"image":"ghcr.io/github/gh-aw-firewall/squid:0.25.29","digest":"sha256:8a71ad9e40454051672312917e51567abfb8251d7c294d086c48f63d84e4cb53","pinned_image":"ghcr.io/github/gh-aw-firewall/squid:0.25.29@sha256:8a71ad9e40454051672312917e51567abfb8251d7c294d086c48f63d84e4cb53"},{"image":"ghcr.io/github/gh-aw-mcpg:v0.3.1","digest":"sha256:287fad0236959f3b3d9936ea1ef8d5b4f135ef2a5f5789713495cbbef191e60c","pinned_image":"ghcr.io/github/gh-aw-mcpg:v0.3.1@sha256:287fad0236959f3b3d9936ea1ef8d5b4f135ef2a5f5789713495cbbef191e60c"},{"image":"ghcr.io/github/github-mcp-server:v1.0.3","digest":"sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959","pinned_image":"ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959"},{"image":"node:lts-alpine","digest":"sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f","pinned_image":"node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f"}]}
# ___ _ _
# / _ \ | | (_)
# | |_| | __ _ ___ _ __ | |_ _ ___
@@ -14,7 +14,7 @@
# \ /\ / (_) | | | | ( | | | | (_) \ V V /\__ \
# \/ \/ \___/|_| |_|\_\|_| |_|\___/ \_/\_/ |___/
#
-# This file was automatically generated by gh-aw (v0.71.1). DO NOT EDIT.
+# This file was automatically generated by gh-aw (v0.71.2). DO NOT EDIT.
#
# To update this file, edit the corresponding .md file and run:
# gh aw compile
@@ -32,17 +32,18 @@
# Custom actions used:
# - actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
# - actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
+# - actions/github-script@373c709c69115d41ff229c7e5df9f8788daa9553 # v9
# - actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
# - actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
# - actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
-# - github/gh-aw-actions/setup@239aec45b78c8799417efdd5bc6d8cc036629ec1 # v0.71.1
+# - github/gh-aw-actions/setup@ab8940d1df237fc4fae4ab8091e7ba66ada55a55 # v0.71.2
#
# Container images used:
-# - ghcr.io/github/gh-aw-firewall/agent:0.25.28@sha256:a8834e285807654bf680154faa710d43fe4365a0868142f5c20e48c85e137a7a
-# - ghcr.io/github/gh-aw-firewall/api-proxy:0.25.28@sha256:93290f2393752252911bd7c39a047f776c0b53063575e7bde4e304962a9a61cb
-# - ghcr.io/github/gh-aw-firewall/squid:0.25.28@sha256:844c18280f82cd1b06345eb2f4e91966b34185bfc51c9f237c3e022e848fb474
-# - ghcr.io/github/gh-aw-mcpg:v0.3.0@sha256:9c2228324fb1f26f39dc9471612e530ae3efc3156dac05efb2e8d212878d454d
-# - ghcr.io/github/github-mcp-server:v1.0.2@sha256:26db03408086a99cf1916348dcc4f9614206658f9082a8060dc7c81ad787f4ba
+# - ghcr.io/github/gh-aw-firewall/agent:0.25.29@sha256:e68f37e36962dcb3f3d1de680a49bc2302cefd001b941a7dc377155ec7ce42f4
+# - ghcr.io/github/gh-aw-firewall/api-proxy:0.25.29@sha256:d1219e4110684402aabbeb5a43858f26790c9d0be210581cf3f7a521bd2c87b6
+# - ghcr.io/github/gh-aw-firewall/squid:0.25.29@sha256:8a71ad9e40454051672312917e51567abfb8251d7c294d086c48f63d84e4cb53
+# - ghcr.io/github/gh-aw-mcpg:v0.3.1@sha256:287fad0236959f3b3d9936ea1ef8d5b4f135ef2a5f5789713495cbbef191e60c
+# - ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959
# - node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f
name: ".NET for Apple Platforms PR Reviewer"
@@ -72,6 +73,7 @@ jobs:
actions: read
contents: read
issues: write
+ pull-requests: write
outputs:
body: ${{ steps.sanitized.outputs.body }}
comment_id: ${{ steps.add-comment.outputs.comment-id }}
@@ -89,7 +91,7 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@239aec45b78c8799417efdd5bc6d8cc036629ec1 # v0.71.1
+ uses: github/gh-aw-actions/setup@ab8940d1df237fc4fae4ab8091e7ba66ada55a55 # v0.71.2
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
@@ -100,16 +102,16 @@ jobs:
GH_AW_INFO_ENGINE_ID: "copilot"
GH_AW_INFO_ENGINE_NAME: "GitHub Copilot CLI"
GH_AW_INFO_MODEL: "claude-sonnet-4.5"
- GH_AW_INFO_VERSION: "1.0.35"
- GH_AW_INFO_AGENT_VERSION: "1.0.35"
- GH_AW_INFO_CLI_VERSION: "v0.71.1"
+ GH_AW_INFO_VERSION: "1.0.36"
+ GH_AW_INFO_AGENT_VERSION: "1.0.36"
+ GH_AW_INFO_CLI_VERSION: "v0.71.2"
GH_AW_INFO_WORKFLOW_NAME: ".NET for Apple Platforms PR Reviewer"
GH_AW_INFO_EXPERIMENTAL: "false"
GH_AW_INFO_SUPPORTS_TOOLS_ALLOWLIST: "true"
GH_AW_INFO_STAGED: "false"
GH_AW_INFO_ALLOWED_DOMAINS: '["defaults","dotnet","github","aka.ms","dev.azure.com","microsoft.com","vsassets.io"]'
GH_AW_INFO_FIREWALL_ENABLED: "true"
- GH_AW_INFO_AWF_VERSION: "v0.25.28"
+ GH_AW_INFO_AWF_VERSION: "v0.25.29"
GH_AW_INFO_AWMG_VERSION: ""
GH_AW_INFO_FIREWALL_TYPE: "squid"
GH_AW_COMPILED_STRICT: "true"
@@ -173,7 +175,7 @@ jobs:
- name: Check compile-agentic version
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
env:
- GH_AW_COMPILED_VERSION: "v0.71.1"
+ GH_AW_COMPILED_VERSION: "v0.71.2"
with:
script: |
const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
@@ -231,6 +233,9 @@ jobs:
Tools: create_pull_request_review_comment(max:50), submit_pull_request_review, missing_tool, missing_data, noop
+ GH_AW_PROMPT_31522cd090dd3137_EOF
+ cat "${RUNNER_TEMP}/gh-aw/prompts/mcp_cli_tools_prompt.md"
+ cat << 'GH_AW_PROMPT_31522cd090dd3137_EOF'
The following GitHub context information is available for this workflow:
{{#if __GH_AW_GITHUB_ACTOR__ }}
@@ -292,6 +297,7 @@ jobs:
GH_AW_GITHUB_RUN_ID: ${{ github.run_id }}
GH_AW_GITHUB_WORKSPACE: ${{ github.workspace }}
GH_AW_IS_PR_COMMENT: ${{ github.event.issue.pull_request && 'true' || '' }}
+ GH_AW_MCP_CLI_SERVERS_LIST: '- `safeoutputs` — run `safeoutputs --help` to see available tools'
GH_AW_NEEDS_PRE_ACTIVATION_OUTPUTS_ACTIVATED: ${{ needs.pre_activation.outputs.activated }}
GH_AW_NEEDS_PRE_ACTIVATION_OUTPUTS_MATCHED_COMMAND: ${{ needs.pre_activation.outputs.matched_command }}
with:
@@ -314,6 +320,7 @@ jobs:
GH_AW_GITHUB_RUN_ID: process.env.GH_AW_GITHUB_RUN_ID,
GH_AW_GITHUB_WORKSPACE: process.env.GH_AW_GITHUB_WORKSPACE,
GH_AW_IS_PR_COMMENT: process.env.GH_AW_IS_PR_COMMENT,
+ GH_AW_MCP_CLI_SERVERS_LIST: process.env.GH_AW_MCP_CLI_SERVERS_LIST,
GH_AW_NEEDS_PRE_ACTIVATION_OUTPUTS_ACTIVATED: process.env.GH_AW_NEEDS_PRE_ACTIVATION_OUTPUTS_ACTIVATED,
GH_AW_NEEDS_PRE_ACTIVATION_OUTPUTS_MATCHED_COMMAND: process.env.GH_AW_NEEDS_PRE_ACTIVATION_OUTPUTS_MATCHED_COMMAND
}
@@ -369,7 +376,7 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@239aec45b78c8799417efdd5bc6d8cc036629ec1 # v0.71.1
+ uses: github/gh-aw-actions/setup@ab8940d1df237fc4fae4ab8091e7ba66ada55a55 # v0.71.2
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
@@ -420,11 +427,11 @@ jobs:
const { main } = require('${{ runner.temp }}/gh-aw/actions/checkout_pr_branch.cjs');
await main();
- name: Install GitHub Copilot CLI
- run: bash "${RUNNER_TEMP}/gh-aw/actions/install_copilot_cli.sh" 1.0.35
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/install_copilot_cli.sh" 1.0.36
env:
GH_HOST: github.com
- name: Install AWF binary
- run: bash "${RUNNER_TEMP}/gh-aw/actions/install_awf_binary.sh" v0.25.28
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/install_awf_binary.sh" v0.25.29
- name: Parse integrity filter lists
id: parse-guard-vars
env:
@@ -444,7 +451,7 @@ jobs:
GH_AW_AGENT_FILES: ".crush.json AGENTS.md CLAUDE.md GEMINI.md opencode.jsonc"
run: bash "${RUNNER_TEMP}/gh-aw/actions/restore_base_github_folders.sh"
- name: Download container images
- run: bash "${RUNNER_TEMP}/gh-aw/actions/download_docker_images.sh" ghcr.io/github/gh-aw-firewall/agent:0.25.28@sha256:a8834e285807654bf680154faa710d43fe4365a0868142f5c20e48c85e137a7a ghcr.io/github/gh-aw-firewall/api-proxy:0.25.28@sha256:93290f2393752252911bd7c39a047f776c0b53063575e7bde4e304962a9a61cb ghcr.io/github/gh-aw-firewall/squid:0.25.28@sha256:844c18280f82cd1b06345eb2f4e91966b34185bfc51c9f237c3e022e848fb474 ghcr.io/github/gh-aw-mcpg:v0.3.0@sha256:9c2228324fb1f26f39dc9471612e530ae3efc3156dac05efb2e8d212878d454d ghcr.io/github/github-mcp-server:v1.0.2@sha256:26db03408086a99cf1916348dcc4f9614206658f9082a8060dc7c81ad787f4ba node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/download_docker_images.sh" ghcr.io/github/gh-aw-firewall/agent:0.25.29@sha256:e68f37e36962dcb3f3d1de680a49bc2302cefd001b941a7dc377155ec7ce42f4 ghcr.io/github/gh-aw-firewall/api-proxy:0.25.29@sha256:d1219e4110684402aabbeb5a43858f26790c9d0be210581cf3f7a521bd2c87b6 ghcr.io/github/gh-aw-firewall/squid:0.25.29@sha256:8a71ad9e40454051672312917e51567abfb8251d7c294d086c48f63d84e4cb53 ghcr.io/github/gh-aw-mcpg:v0.3.1@sha256:287fad0236959f3b3d9936ea1ef8d5b4f135ef2a5f5789713495cbbef191e60c ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959 node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f
- name: Write Safe Outputs Config
run: |
mkdir -p "${RUNNER_TEMP}/gh-aw/safeoutputs"
@@ -668,7 +675,7 @@ jobs:
MCP_GATEWAY_UID=$(id -u 2>/dev/null || echo '0')
MCP_GATEWAY_GID=$(id -g 2>/dev/null || echo '0')
DOCKER_SOCK_GID=$(stat -c '%g' /var/run/docker.sock 2>/dev/null || echo '0')
- export MCP_GATEWAY_DOCKER_COMMAND='docker run -i --rm --network host --add-host host.docker.internal:127.0.0.1 --user '"${MCP_GATEWAY_UID}"':'"${MCP_GATEWAY_GID}"' --group-add '"${DOCKER_SOCK_GID}"' -v /var/run/docker.sock:/var/run/docker.sock -e MCP_GATEWAY_PORT -e MCP_GATEWAY_DOMAIN -e MCP_GATEWAY_API_KEY -e MCP_GATEWAY_PAYLOAD_DIR -e MCP_GATEWAY_PAYLOAD_SIZE_THRESHOLD -e DEBUG -e MCP_GATEWAY_LOG_DIR -e GH_AW_MCP_LOG_DIR -e GH_AW_SAFE_OUTPUTS -e GH_AW_SAFE_OUTPUTS_CONFIG_PATH -e GH_AW_SAFE_OUTPUTS_TOOLS_PATH -e GH_AW_ASSETS_BRANCH -e GH_AW_ASSETS_MAX_SIZE_KB -e GH_AW_ASSETS_ALLOWED_EXTS -e DEFAULT_BRANCH -e GITHUB_MCP_SERVER_TOKEN -e GITHUB_MCP_GUARD_MIN_INTEGRITY -e GITHUB_MCP_GUARD_REPOS -e GITHUB_REPOSITORY -e GITHUB_SERVER_URL -e GITHUB_SHA -e GITHUB_WORKSPACE -e GITHUB_TOKEN -e GITHUB_RUN_ID -e GITHUB_RUN_NUMBER -e GITHUB_RUN_ATTEMPT -e GITHUB_JOB -e GITHUB_ACTION -e GITHUB_EVENT_NAME -e GITHUB_EVENT_PATH -e GITHUB_ACTOR -e GITHUB_ACTOR_ID -e GITHUB_TRIGGERING_ACTOR -e GITHUB_WORKFLOW -e GITHUB_WORKFLOW_REF -e GITHUB_WORKFLOW_SHA -e GITHUB_REF -e GITHUB_REF_NAME -e GITHUB_REF_TYPE -e GITHUB_HEAD_REF -e GITHUB_BASE_REF -e GH_AW_SAFE_OUTPUTS_PORT -e GH_AW_SAFE_OUTPUTS_API_KEY -v /tmp/gh-aw/mcp-payloads:/tmp/gh-aw/mcp-payloads:rw -v /opt:/opt:ro -v /tmp:/tmp:rw -v '"${GITHUB_WORKSPACE}"':'"${GITHUB_WORKSPACE}"':rw ghcr.io/github/gh-aw-mcpg:v0.3.0'
+ export MCP_GATEWAY_DOCKER_COMMAND='docker run -i --rm --network host --add-host host.docker.internal:127.0.0.1 --user '"${MCP_GATEWAY_UID}"':'"${MCP_GATEWAY_GID}"' --group-add '"${DOCKER_SOCK_GID}"' -v /var/run/docker.sock:/var/run/docker.sock -e MCP_GATEWAY_PORT -e MCP_GATEWAY_DOMAIN -e MCP_GATEWAY_API_KEY -e MCP_GATEWAY_PAYLOAD_DIR -e MCP_GATEWAY_PAYLOAD_SIZE_THRESHOLD -e DEBUG -e MCP_GATEWAY_LOG_DIR -e GH_AW_MCP_LOG_DIR -e GH_AW_SAFE_OUTPUTS -e GH_AW_SAFE_OUTPUTS_CONFIG_PATH -e GH_AW_SAFE_OUTPUTS_TOOLS_PATH -e GH_AW_ASSETS_BRANCH -e GH_AW_ASSETS_MAX_SIZE_KB -e GH_AW_ASSETS_ALLOWED_EXTS -e DEFAULT_BRANCH -e GITHUB_MCP_SERVER_TOKEN -e GITHUB_MCP_GUARD_MIN_INTEGRITY -e GITHUB_MCP_GUARD_REPOS -e GITHUB_REPOSITORY -e GITHUB_SERVER_URL -e GITHUB_SHA -e GITHUB_WORKSPACE -e GITHUB_TOKEN -e GITHUB_RUN_ID -e GITHUB_RUN_NUMBER -e GITHUB_RUN_ATTEMPT -e GITHUB_JOB -e GITHUB_ACTION -e GITHUB_EVENT_NAME -e GITHUB_EVENT_PATH -e GITHUB_ACTOR -e GITHUB_ACTOR_ID -e GITHUB_TRIGGERING_ACTOR -e GITHUB_WORKFLOW -e GITHUB_WORKFLOW_REF -e GITHUB_WORKFLOW_SHA -e GITHUB_REF -e GITHUB_REF_NAME -e GITHUB_REF_TYPE -e GITHUB_HEAD_REF -e GITHUB_BASE_REF -e GH_AW_SAFE_OUTPUTS_PORT -e GH_AW_SAFE_OUTPUTS_API_KEY -v /tmp/gh-aw/mcp-payloads:/tmp/gh-aw/mcp-payloads:rw -v /opt:/opt:ro -v /tmp:/tmp:rw -v '"${GITHUB_WORKSPACE}"':'"${GITHUB_WORKSPACE}"':rw ghcr.io/github/gh-aw-mcpg:v0.3.1'
mkdir -p /home/runner/.copilot
GH_AW_NODE=$(which node 2>/dev/null || command -v node 2>/dev/null || echo node)
@@ -677,7 +684,7 @@ jobs:
"mcpServers": {
"github": {
"type": "stdio",
- "container": "ghcr.io/github/github-mcp-server:v1.0.2",
+ "container": "ghcr.io/github/github-mcp-server:v1.0.3",
"env": {
"GITHUB_HOST": "\${GITHUB_SERVER_URL}",
"GITHUB_PERSONAL_ACCESS_TOKEN": "\${GITHUB_MCP_SERVER_TOKEN}",
@@ -717,6 +724,20 @@ jobs:
}
}
GH_AW_MCP_CONFIG_8d4f4bdb31699167_EOF
+ - name: Mount MCP servers as CLIs
+ id: mount-mcp-clis
+ continue-on-error: true
+ env:
+ MCP_GATEWAY_API_KEY: ${{ steps.start-mcp-gateway.outputs.gateway-api-key }}
+ MCP_GATEWAY_DOMAIN: ${{ steps.start-mcp-gateway.outputs.gateway-domain }}
+ MCP_GATEWAY_PORT: ${{ steps.start-mcp-gateway.outputs.gateway-port }}
+ uses: actions/github-script@373c709c69115d41ff229c7e5df9f8788daa9553 # v9
+ with:
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/mount_mcp_as_cli.cjs');
+ await main();
- name: Clean git credentials
continue-on-error: true
run: bash "${RUNNER_TEMP}/gh-aw/actions/clean_git_credentials.sh"
@@ -731,8 +752,8 @@ jobs:
export GH_AW_NODE_BIN
(umask 177 && touch /tmp/gh-aw/agent-stdio.log)
# shellcheck disable=SC1003
- sudo -E awf --container-workdir "${GITHUB_WORKSPACE}" --mount "${RUNNER_TEMP}/gh-aw:${RUNNER_TEMP}/gh-aw:ro" --mount "${RUNNER_TEMP}/gh-aw:/host${RUNNER_TEMP}/gh-aw:ro" --env-all --exclude-env COPILOT_GITHUB_TOKEN --exclude-env GITHUB_MCP_SERVER_TOKEN --exclude-env MCP_GATEWAY_API_KEY --allow-domains '*.githubusercontent.com,*.vsblob.vsassets.io,aka.ms,api.business.githubcopilot.com,api.enterprise.githubcopilot.com,api.github.com,api.githubcopilot.com,api.individual.githubcopilot.com,api.nuget.org,api.snapcraft.io,archive.ubuntu.com,azure.archive.ubuntu.com,azuresearch-usnc.nuget.org,azuresearch-ussc.nuget.org,builds.dotnet.microsoft.com,ci.dot.net,codeload.github.com,crl.geotrust.com,crl.globalsign.com,crl.identrust.com,crl.sectigo.com,crl.thawte.com,crl.usertrust.com,crl.verisign.com,crl3.digicert.com,crl4.digicert.com,crls.ssl.com,dc.services.visualstudio.com,dev.azure.com,dist.nuget.org,docs.github.com,dot.net,dotnet.microsoft.com,dotnetcli.blob.core.windows.net,github-cloud.githubusercontent.com,github-cloud.s3.amazonaws.com,github.blog,github.com,github.githubassets.com,host.docker.internal,json-schema.org,json.schemastore.org,keyserver.ubuntu.com,lfs.github.com,microsoft.com,nuget.org,nuget.pkg.github.com,nugetregistryv2prod.blob.core.windows.net,objects.githubusercontent.com,ocsp.digicert.com,ocsp.geotrust.com,ocsp.globalsign.com,ocsp.identrust.com,ocsp.sectigo.com,ocsp.ssl.com,ocsp.thawte.com,ocsp.usertrust.com,ocsp.verisign.com,oneocsp.microsoft.com,packagecloud.io,packages.cloud.google.com,packages.microsoft.com,pkgs.dev.azure.com,ppa.launchpad.net,raw.githubusercontent.com,registry.npmjs.org,s.symcb.com,s.symcd.com,security.ubuntu.com,telemetry.enterprise.githubcopilot.com,ts-crl.ws.symantec.com,ts-ocsp.ws.symantec.com,vsassets.io,www.googleapis.com,www.microsoft.com' --log-level info --proxy-logs-dir /tmp/gh-aw/sandbox/firewall/logs --audit-dir /tmp/gh-aw/sandbox/firewall/audit --enable-host-access --allow-host-ports 80,443,8080 --image-tag 0.25.28,squid=sha256:844c18280f82cd1b06345eb2f4e91966b34185bfc51c9f237c3e022e848fb474,agent=sha256:a8834e285807654bf680154faa710d43fe4365a0868142f5c20e48c85e137a7a,api-proxy=sha256:93290f2393752252911bd7c39a047f776c0b53063575e7bde4e304962a9a61cb,cli-proxy=sha256:fdf310e4678ce58d248c466b89399e9680a3003038fd19322c388559016aaac7 --skip-pull --enable-api-proxy \
- -- /bin/bash -c 'GH_AW_NODE_EXEC="${GH_AW_NODE_BIN:-}"; if [ -z "$GH_AW_NODE_EXEC" ] || [ ! -x "$GH_AW_NODE_EXEC" ]; then GH_AW_NODE_EXEC="$(command -v node 2>/dev/null || echo node)"; fi; "$GH_AW_NODE_EXEC" ${RUNNER_TEMP}/gh-aw/actions/copilot_driver.cjs /usr/local/bin/copilot --add-dir /tmp/gh-aw/ --log-level all --log-dir /tmp/gh-aw/sandbox/agent/logs/ --disable-builtin-mcps --no-ask-user --allow-all-tools --allow-all-paths --add-dir "${GITHUB_WORKSPACE}" --prompt-file /tmp/gh-aw/aw-prompts/prompt.txt' 2>&1 | tee -a /tmp/gh-aw/agent-stdio.log
+ sudo -E awf --container-workdir "${GITHUB_WORKSPACE}" --mount "${RUNNER_TEMP}/gh-aw:${RUNNER_TEMP}/gh-aw:ro" --mount "${RUNNER_TEMP}/gh-aw:/host${RUNNER_TEMP}/gh-aw:ro" --env-all --exclude-env COPILOT_GITHUB_TOKEN --exclude-env GITHUB_MCP_SERVER_TOKEN --exclude-env MCP_GATEWAY_API_KEY --allow-domains '*.githubusercontent.com,*.vsblob.vsassets.io,aka.ms,api.business.githubcopilot.com,api.enterprise.githubcopilot.com,api.github.com,api.githubcopilot.com,api.individual.githubcopilot.com,api.nuget.org,api.snapcraft.io,archive.ubuntu.com,azure.archive.ubuntu.com,azuresearch-usnc.nuget.org,azuresearch-ussc.nuget.org,builds.dotnet.microsoft.com,ci.dot.net,codeload.github.com,crl.geotrust.com,crl.globalsign.com,crl.identrust.com,crl.sectigo.com,crl.thawte.com,crl.usertrust.com,crl.verisign.com,crl3.digicert.com,crl4.digicert.com,crls.ssl.com,dc.services.visualstudio.com,dev.azure.com,dist.nuget.org,docs.github.com,dot.net,dotnet.microsoft.com,dotnetcli.blob.core.windows.net,github-cloud.githubusercontent.com,github-cloud.s3.amazonaws.com,github.blog,github.com,github.githubassets.com,host.docker.internal,json-schema.org,json.schemastore.org,keyserver.ubuntu.com,lfs.github.com,microsoft.com,nuget.org,nuget.pkg.github.com,nugetregistryv2prod.blob.core.windows.net,objects.githubusercontent.com,ocsp.digicert.com,ocsp.geotrust.com,ocsp.globalsign.com,ocsp.identrust.com,ocsp.sectigo.com,ocsp.ssl.com,ocsp.thawte.com,ocsp.usertrust.com,ocsp.verisign.com,oneocsp.microsoft.com,packagecloud.io,packages.cloud.google.com,packages.microsoft.com,pkgs.dev.azure.com,ppa.launchpad.net,raw.githubusercontent.com,registry.npmjs.org,s.symcb.com,s.symcd.com,security.ubuntu.com,telemetry.enterprise.githubcopilot.com,ts-crl.ws.symantec.com,ts-ocsp.ws.symantec.com,vsassets.io,www.googleapis.com,www.microsoft.com' --log-level info --proxy-logs-dir /tmp/gh-aw/sandbox/firewall/logs --audit-dir /tmp/gh-aw/sandbox/firewall/audit --enable-host-access --allow-host-ports 80,443,8080 --image-tag 0.25.29,squid=sha256:8a71ad9e40454051672312917e51567abfb8251d7c294d086c48f63d84e4cb53,agent=sha256:e68f37e36962dcb3f3d1de680a49bc2302cefd001b941a7dc377155ec7ce42f4,agent-act=sha256:97b4cc14dc2123a45b9d5b9927489f66882dec5857de6afc0e5bab257be92ef1,api-proxy=sha256:d1219e4110684402aabbeb5a43858f26790c9d0be210581cf3f7a521bd2c87b6,cli-proxy=sha256:29917488eb90a01ff9544ffeeb5cc26434a8ea16d69ae8972f5f6be0e567e276 --skip-pull --enable-api-proxy \
+ -- /bin/bash -c 'export PATH="${RUNNER_TEMP}/gh-aw/mcp-cli/bin:$PATH" && export PATH="$(find /opt/hostedtoolcache /home/runner/work/_tool -maxdepth 4 -type d -name bin 2>/dev/null | tr '\''\n'\'' '\'':'\'')$PATH"; [ -n "$GOROOT" ] && export PATH="$GOROOT/bin:$PATH" || true && GH_AW_NODE_EXEC="${GH_AW_NODE_BIN:-}"; if [ -z "$GH_AW_NODE_EXEC" ] || [ ! -x "$GH_AW_NODE_EXEC" ]; then GH_AW_NODE_EXEC="$(command -v node 2>/dev/null || echo node)"; fi; "$GH_AW_NODE_EXEC" ${RUNNER_TEMP}/gh-aw/actions/copilot_harness.cjs /usr/local/bin/copilot --add-dir /tmp/gh-aw/ --log-level all --log-dir /tmp/gh-aw/sandbox/agent/logs/ --disable-builtin-mcps --no-ask-user --allow-all-tools --allow-all-paths --add-dir "${GITHUB_WORKSPACE}" --prompt-file /tmp/gh-aw/aw-prompts/prompt.txt' 2>&1 | tee -a /tmp/gh-aw/agent-stdio.log
env:
COPILOT_AGENT_RUNNER_TYPE: STANDALONE
COPILOT_API_KEY: dummy-byok-key-for-offline-mode
@@ -742,7 +763,7 @@ jobs:
GH_AW_PHASE: agent
GH_AW_PROMPT: /tmp/gh-aw/aw-prompts/prompt.txt
GH_AW_SAFE_OUTPUTS: ${{ steps.set-runtime-paths.outputs.GH_AW_SAFE_OUTPUTS }}
- GH_AW_VERSION: v0.71.1
+ GH_AW_VERSION: v0.71.2
GITHUB_API_URL: ${{ github.api_url }}
GITHUB_AW: true
GITHUB_COPILOT_INTEGRATION_ID: agentic-workflows
@@ -930,7 +951,7 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@239aec45b78c8799417efdd5bc6d8cc036629ec1 # v0.71.1
+ uses: github/gh-aw-actions/setup@ab8940d1df237fc4fae4ab8091e7ba66ada55a55 # v0.71.2
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
@@ -1028,6 +1049,7 @@ jobs:
GH_AW_MCP_POLICY_ERROR: ${{ needs.agent.outputs.mcp_policy_error }}
GH_AW_AGENTIC_ENGINE_TIMEOUT: ${{ needs.agent.outputs.agentic_engine_timeout }}
GH_AW_MODEL_NOT_SUPPORTED_ERROR: ${{ needs.agent.outputs.model_not_supported_error }}
+ GH_AW_ENGINE_API_HOSTS: "api.enterprise.githubcopilot.com,api.githubcopilot.com,api.business.githubcopilot.com,api.individual.githubcopilot.com"
GH_AW_LOCKDOWN_CHECK_FAILED: ${{ needs.activation.outputs.lockdown_check_failed }}
GH_AW_STALE_LOCK_FILE_FAILED: ${{ needs.activation.outputs.stale_lock_file_failed }}
GH_AW_GROUP_REPORTS: "false"
@@ -1076,7 +1098,7 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@239aec45b78c8799417efdd5bc6d8cc036629ec1 # v0.71.1
+ uses: github/gh-aw-actions/setup@ab8940d1df237fc4fae4ab8091e7ba66ada55a55 # v0.71.2
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
@@ -1106,7 +1128,7 @@ jobs:
rm -rf /tmp/gh-aw/sandbox/firewall/logs
rm -rf /tmp/gh-aw/sandbox/firewall/audit
- name: Download container images
- run: bash "${RUNNER_TEMP}/gh-aw/actions/download_docker_images.sh" ghcr.io/github/gh-aw-firewall/agent:0.25.28@sha256:a8834e285807654bf680154faa710d43fe4365a0868142f5c20e48c85e137a7a ghcr.io/github/gh-aw-firewall/api-proxy:0.25.28@sha256:93290f2393752252911bd7c39a047f776c0b53063575e7bde4e304962a9a61cb ghcr.io/github/gh-aw-firewall/squid:0.25.28@sha256:844c18280f82cd1b06345eb2f4e91966b34185bfc51c9f237c3e022e848fb474
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/download_docker_images.sh" ghcr.io/github/gh-aw-firewall/agent:0.25.29@sha256:e68f37e36962dcb3f3d1de680a49bc2302cefd001b941a7dc377155ec7ce42f4 ghcr.io/github/gh-aw-firewall/api-proxy:0.25.29@sha256:d1219e4110684402aabbeb5a43858f26790c9d0be210581cf3f7a521bd2c87b6 ghcr.io/github/gh-aw-firewall/squid:0.25.29@sha256:8a71ad9e40454051672312917e51567abfb8251d7c294d086c48f63d84e4cb53
- name: Check if detection needed
id: detection_guard
if: always()
@@ -1121,7 +1143,7 @@ jobs:
echo "run_detection=false" >> "$GITHUB_OUTPUT"
echo "Detection skipped: no agent outputs or patches to analyze"
fi
- - name: Clear MCP configuration for detection
+ - name: Clear MCP Config for detection
if: always() && steps.detection_guard.outputs.run_detection == 'true'
run: |
rm -f "${RUNNER_TEMP}/gh-aw/mcp-config/mcp-servers.json"
@@ -1165,13 +1187,14 @@ jobs:
node-version: '24'
package-manager-cache: false
- name: Install GitHub Copilot CLI
- run: bash "${RUNNER_TEMP}/gh-aw/actions/install_copilot_cli.sh" 1.0.35
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/install_copilot_cli.sh" 1.0.36
env:
GH_HOST: github.com
- name: Install AWF binary
- run: bash "${RUNNER_TEMP}/gh-aw/actions/install_awf_binary.sh" v0.25.28
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/install_awf_binary.sh" v0.25.29
- name: Execute GitHub Copilot CLI
if: always() && steps.detection_guard.outputs.run_detection == 'true'
+ continue-on-error: true
id: detection_agentic_execution
# Copilot CLI tool arguments (sorted):
timeout-minutes: 20
@@ -1182,8 +1205,8 @@ jobs:
export GH_AW_NODE_BIN
(umask 177 && touch /tmp/gh-aw/threat-detection/detection.log)
# shellcheck disable=SC1003
- sudo -E awf --container-workdir "${GITHUB_WORKSPACE}" --mount "${RUNNER_TEMP}/gh-aw:${RUNNER_TEMP}/gh-aw:ro" --mount "${RUNNER_TEMP}/gh-aw:/host${RUNNER_TEMP}/gh-aw:ro" --env-all --exclude-env COPILOT_GITHUB_TOKEN --allow-domains api.business.githubcopilot.com,api.enterprise.githubcopilot.com,api.github.com,api.githubcopilot.com,api.individual.githubcopilot.com,github.com,host.docker.internal,telemetry.enterprise.githubcopilot.com --log-level info --proxy-logs-dir /tmp/gh-aw/sandbox/firewall/logs --audit-dir /tmp/gh-aw/sandbox/firewall/audit --enable-host-access --allow-host-ports 80,443,8080 --image-tag 0.25.28,squid=sha256:844c18280f82cd1b06345eb2f4e91966b34185bfc51c9f237c3e022e848fb474,agent=sha256:a8834e285807654bf680154faa710d43fe4365a0868142f5c20e48c85e137a7a,api-proxy=sha256:93290f2393752252911bd7c39a047f776c0b53063575e7bde4e304962a9a61cb,cli-proxy=sha256:fdf310e4678ce58d248c466b89399e9680a3003038fd19322c388559016aaac7 --skip-pull --enable-api-proxy \
- -- /bin/bash -c 'GH_AW_NODE_EXEC="${GH_AW_NODE_BIN:-}"; if [ -z "$GH_AW_NODE_EXEC" ] || [ ! -x "$GH_AW_NODE_EXEC" ]; then GH_AW_NODE_EXEC="$(command -v node 2>/dev/null || echo node)"; fi; "$GH_AW_NODE_EXEC" ${RUNNER_TEMP}/gh-aw/actions/copilot_driver.cjs /usr/local/bin/copilot --add-dir /tmp/gh-aw/ --log-level all --log-dir /tmp/gh-aw/sandbox/agent/logs/ --disable-builtin-mcps --no-ask-user --allow-all-tools --add-dir "${GITHUB_WORKSPACE}" --prompt-file /tmp/gh-aw/aw-prompts/prompt.txt' 2>&1 | tee -a /tmp/gh-aw/threat-detection/detection.log
+ sudo -E awf --container-workdir "${GITHUB_WORKSPACE}" --mount "${RUNNER_TEMP}/gh-aw:${RUNNER_TEMP}/gh-aw:ro" --mount "${RUNNER_TEMP}/gh-aw:/host${RUNNER_TEMP}/gh-aw:ro" --env-all --exclude-env COPILOT_GITHUB_TOKEN --allow-domains api.business.githubcopilot.com,api.enterprise.githubcopilot.com,api.github.com,api.githubcopilot.com,api.individual.githubcopilot.com,github.com,host.docker.internal,telemetry.enterprise.githubcopilot.com --log-level info --proxy-logs-dir /tmp/gh-aw/sandbox/firewall/logs --audit-dir /tmp/gh-aw/sandbox/firewall/audit --enable-host-access --allow-host-ports 80,443,8080 --image-tag 0.25.29,squid=sha256:8a71ad9e40454051672312917e51567abfb8251d7c294d086c48f63d84e4cb53,agent=sha256:e68f37e36962dcb3f3d1de680a49bc2302cefd001b941a7dc377155ec7ce42f4,agent-act=sha256:97b4cc14dc2123a45b9d5b9927489f66882dec5857de6afc0e5bab257be92ef1,api-proxy=sha256:d1219e4110684402aabbeb5a43858f26790c9d0be210581cf3f7a521bd2c87b6,cli-proxy=sha256:29917488eb90a01ff9544ffeeb5cc26434a8ea16d69ae8972f5f6be0e567e276 --skip-pull --enable-api-proxy \
+ -- /bin/bash -c 'export PATH="$(find /opt/hostedtoolcache /home/runner/work/_tool -maxdepth 4 -type d -name bin 2>/dev/null | tr '\''\n'\'' '\'':'\'')$PATH"; [ -n "$GOROOT" ] && export PATH="$GOROOT/bin:$PATH" || true && GH_AW_NODE_EXEC="${GH_AW_NODE_BIN:-}"; if [ -z "$GH_AW_NODE_EXEC" ] || [ ! -x "$GH_AW_NODE_EXEC" ]; then GH_AW_NODE_EXEC="$(command -v node 2>/dev/null || echo node)"; fi; "$GH_AW_NODE_EXEC" ${RUNNER_TEMP}/gh-aw/actions/copilot_harness.cjs /usr/local/bin/copilot --add-dir /tmp/gh-aw/ --log-level all --log-dir /tmp/gh-aw/sandbox/agent/logs/ --disable-builtin-mcps --no-ask-user --allow-all-tools --add-dir "${GITHUB_WORKSPACE}" --prompt-file /tmp/gh-aw/aw-prompts/prompt.txt' 2>&1 | tee -a /tmp/gh-aw/threat-detection/detection.log
env:
COPILOT_AGENT_RUNNER_TYPE: STANDALONE
COPILOT_API_KEY: dummy-byok-key-for-offline-mode
@@ -1191,7 +1214,7 @@ jobs:
COPILOT_MODEL: claude-sonnet-4.5
GH_AW_PHASE: detection
GH_AW_PROMPT: /tmp/gh-aw/aw-prompts/prompt.txt
- GH_AW_VERSION: v0.71.1
+ GH_AW_VERSION: v0.71.2
GITHUB_API_URL: ${{ github.api_url }}
GITHUB_AW: true
GITHUB_COPILOT_INTEGRATION_ID: agentic-workflows
@@ -1215,16 +1238,33 @@ jobs:
- name: Parse and conclude threat detection
id: detection_conclusion
if: always()
+ continue-on-error: true
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
env:
RUN_DETECTION: ${{ steps.detection_guard.outputs.run_detection }}
GH_AW_DETECTION_CONTINUE_ON_ERROR: "true"
with:
script: |
- const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
- setupGlobals(core, github, context, exec, io, getOctokit);
- const { main } = require('${{ runner.temp }}/gh-aw/actions/parse_threat_detection_results.cjs');
- await main();
+ try {
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/parse_threat_detection_results.cjs');
+ await main();
+ } catch (loadErr) {
+ const continueOnError = process.env.GH_AW_DETECTION_CONTINUE_ON_ERROR !== 'false';
+ const msg = 'ERR_SYSTEM: \u274C Unexpected error loading threat detection module: ' + (loadErr && loadErr.message ? loadErr.message : String(loadErr));
+ core.error(msg);
+ core.setOutput('reason', 'parse_error');
+ if (continueOnError) {
+ core.warning('\u26A0\uFE0F ' + msg);
+ core.setOutput('conclusion', 'warning');
+ core.setOutput('success', 'false');
+ } else {
+ core.setOutput('conclusion', 'failure');
+ core.setOutput('success', 'false');
+ core.setFailed(msg);
+ }
+ }
pre_activation:
if: "github.event_name == 'issue_comment' && (startsWith(github.event.comment.body, '/review ') || startsWith(github.event.comment.body, '/review\n') || github.event.comment.body == '/review') && github.event.issue.pull_request != null || !(github.event_name == 'issue_comment')"
@@ -1236,7 +1276,7 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@239aec45b78c8799417efdd5bc6d8cc036629ec1 # v0.71.1
+ uses: github/gh-aw-actions/setup@ab8940d1df237fc4fae4ab8091e7ba66ada55a55 # v0.71.2
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
@@ -1282,7 +1322,7 @@ jobs:
GH_AW_EFFECTIVE_TOKENS: ${{ needs.agent.outputs.effective_tokens }}
GH_AW_ENGINE_ID: "copilot"
GH_AW_ENGINE_MODEL: "claude-sonnet-4.5"
- GH_AW_ENGINE_VERSION: "1.0.35"
+ GH_AW_ENGINE_VERSION: "1.0.36"
GH_AW_WORKFLOW_ID: "macios-reviewer"
GH_AW_WORKFLOW_NAME: ".NET for Apple Platforms PR Reviewer"
outputs:
@@ -1295,7 +1335,7 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@239aec45b78c8799417efdd5bc6d8cc036629ec1 # v0.71.1
+ uses: github/gh-aw-actions/setup@ab8940d1df237fc4fae4ab8091e7ba66ada55a55 # v0.71.2
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
From 90c27c82e9363dbce29cfb76ce0eaec588170c69 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 5 May 2026 08:37:56 +0200
Subject: [PATCH 004/156] [tests] Fix flaky SecureTransportTest.Tls12 by
ignoring network timeouts in CI (#25302)
Wrap the Tls12 test body in a try/catch that calls TestRuntime.IgnoreInCIIfBadNetwork to mark the test as ignored (rather than failed) when transient network issues occur in CI.
Also extend IgnoreInCIIfTimedOut to handle SocketException timeouts, not just WebException timeouts, so that the SocketException thrown by TcpClient is properly recognized.
Fixes https://github.com/dotnet/macios/issues/25241
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
tests/common/TestRuntime.cs | 5 ++
.../Security/SecureTransportTest.cs | 78 +++++++++++--------
2 files changed, 49 insertions(+), 34 deletions(-)
diff --git a/tests/common/TestRuntime.cs b/tests/common/TestRuntime.cs
index cfa84a3fb329..60e6e37d5c6a 100644
--- a/tests/common/TestRuntime.cs
+++ b/tests/common/TestRuntime.cs
@@ -1664,6 +1664,11 @@ public static void IgnoreInCIIfTimedOut (Exception ex)
IgnoreInCI ($"Ignored due to network error: {wex}");
}
}
+
+ var se = FindInner (ex);
+ if (se is not null && se.SocketErrorCode == System.Net.Sockets.SocketError.TimedOut) {
+ IgnoreInCI ($"Ignored due to socket timeout: {se.Message}");
+ }
}
public static void IgnoreInCIIfForbidden (Exception ex)
diff --git a/tests/monotouch-test/Security/SecureTransportTest.cs b/tests/monotouch-test/Security/SecureTransportTest.cs
index 79b9f89467f4..d44aa17a3619 100644
--- a/tests/monotouch-test/Security/SecureTransportTest.cs
+++ b/tests/monotouch-test/Security/SecureTransportTest.cs
@@ -130,45 +130,55 @@ public void DatagramDefaults ()
[Test]
public void Tls12 ()
{
- var client = new TcpClient ("google.ca", 443);
- using (NetworkStream ns = client.GetStream ())
- using (var ssl = new SslContext (SslProtocolSide.Client, SslConnectionType.Stream)) {
-
- ssl.MinProtocol = SslProtocol.Tls_1_2;
- Assert.That (ssl.MinProtocol, Is.EqualTo (SslProtocol.Tls_1_2), "MinProtocol");
-
- ssl.Connection = new SslStreamConnection (ns);
-
- var result = ssl.Handshake ();
- while (result == SslStatus.WouldBlock || result == (SslStatus) (-108)) {
- // we need to ask again - but if we're too fast we'll get -108 (errSecAllocate)
- Thread.Sleep (100);
- // during the above call SessionState is Handshake
- Assert.That (ssl.SessionState, Is.EqualTo (SslSessionState.Handshake), "Handshake/in progress");
- result = ssl.Handshake ();
- }
- Assert.That (result, Is.EqualTo (SslStatus.Success), "Handshake/done");
+ try {
+ var client = new TcpClient ("google.ca", 443);
+ using (NetworkStream ns = client.GetStream ())
+ using (var ssl = new SslContext (SslProtocolSide.Client, SslConnectionType.Stream)) {
+
+ ssl.MinProtocol = SslProtocol.Tls_1_2;
+ Assert.That (ssl.MinProtocol, Is.EqualTo (SslProtocol.Tls_1_2), "MinProtocol");
+
+ ssl.Connection = new SslStreamConnection (ns);
+
+ var deadline = DateTime.UtcNow.AddSeconds (30);
+ var result = ssl.Handshake ();
+ while (result == SslStatus.WouldBlock || result == (SslStatus) errSecAllocate) {
+ Assert.That (DateTime.UtcNow, Is.LessThan (deadline), "Handshake/timeout");
+ // we need to ask again - but if we're too fast we'll get errSecAllocate
+ Thread.Sleep (100);
+ // during the above call SessionState is Handshake
+ Assert.That (ssl.SessionState, Is.EqualTo (SslSessionState.Handshake), "Handshake/in progress");
+ result = ssl.Handshake ();
+ }
+ Assert.That (result, Is.EqualTo (SslStatus.Success), "Handshake/done");
- // FIXME: iOS 8 beta 1 bug ?!? the state is not updated (maybe delayed?) but the code still works
- //Assert.That (ssl.SessionState, Is.EqualTo (SslSessionState.Connected), "Connected");
- Assert.That (ssl.NegotiatedProtocol, Is.EqualTo (SslProtocol.Tls_1_2), "NegotiatedProtocol");
+ // FIXME: iOS 8 beta 1 bug ?!? the state is not updated (maybe delayed?) but the code still works
+ //Assert.That (ssl.SessionState, Is.EqualTo (SslSessionState.Connected), "Connected");
+ Assert.That (ssl.NegotiatedProtocol, Is.EqualTo (SslProtocol.Tls_1_2), "NegotiatedProtocol");
- nint processed;
- var data = Encoding.UTF8.GetBytes ("GET / HTTP/1.0" + Environment.NewLine + Environment.NewLine);
- result = ssl.Write (data, out processed);
- Assert.That (processed, Is.EqualTo ((nint) data.Length), "small buffer");
- Assert.That (result, Is.EqualTo (SslStatus.Success), "Write");
+ nint processed;
+ var data = Encoding.UTF8.GetBytes ("GET / HTTP/1.0" + Environment.NewLine + Environment.NewLine);
+ result = ssl.Write (data, out processed);
+ Assert.That (processed, Is.EqualTo ((nint) data.Length), "small buffer");
+ Assert.That (result, Is.EqualTo (SslStatus.Success), "Write");
- data = new byte [1024];
- result = ssl.Read (data, out processed);
- while (result == SslStatus.WouldBlock)
+ data = new byte [1024];
+ deadline = DateTime.UtcNow.AddSeconds (30);
result = ssl.Read (data, out processed);
- Assert.That (result, Is.EqualTo (SslStatus.Success), "Read");
+ while (result == SslStatus.WouldBlock) {
+ Assert.That (DateTime.UtcNow, Is.LessThan (deadline), "Read/timeout");
+ result = ssl.Read (data, out processed);
+ }
+ Assert.That (result, Is.EqualTo (SslStatus.Success), "Read");
- string s = Encoding.UTF8.GetString (data, 0, (int) processed);
- // The result apparently depends on where you are: I get a 302, the bots get a 200.
- // Also sometimes it fails with 502 Bad Gateway on the bots
- Assert.That (s, Does.StartWith ("HTTP/1.0 302 Found").Or.StartWith ("HTTP/1.0 200 OK").Or.StartWith ("HTTP/1.0 502 Bad Gateway"), "response");
+ string s = Encoding.UTF8.GetString (data, 0, (int) processed);
+ // The result apparently depends on where you are: I get a 302, the bots get a 200.
+ // Also sometimes it fails with 502 Bad Gateway on the bots
+ Assert.That (s, Does.StartWith ("HTTP/1.0 302 Found").Or.StartWith ("HTTP/1.0 200 OK").Or.StartWith ("HTTP/1.0 502 Bad Gateway"), "response");
+ }
+ } catch (Exception ex) {
+ TestRuntime.IgnoreInCIIfBadNetwork (ex);
+ throw;
}
}
}
From 5a4d75c3faf6db5df2134f509668956a9a48a86a Mon Sep 17 00:00:00 2001
From: "CSIGS@microsoft.com"
Date: Tue, 5 May 2026 02:26:00 -0700
Subject: [PATCH 005/156] LEGO: Pull request from
lego/hb_5df43909-4a19-4f55-bc3f-9ea8fccf3c82_20260505064756191 to main
(#25325)
LEGO: Pull request from lego/hb_5df43909-4a19-4f55-bc3f-9ea8fccf3c82_20260505064756191 to main with localized lcls
---
.../cs/macios/tools/mtouch/Errors.resx.lcl | 27 +++++++++++++++++++
.../es/macios/tools/mtouch/Errors.resx.lcl | 27 +++++++++++++++++++
.../fr/macios/tools/mtouch/Errors.resx.lcl | 27 +++++++++++++++++++
.../pt-BR/macios/tools/mtouch/Errors.resx.lcl | 27 +++++++++++++++++++
.../ru/macios/tools/mtouch/Errors.resx.lcl | 27 +++++++++++++++++++
.../macios/tools/mtouch/Errors.resx.lcl | 27 +++++++++++++++++++
.../macios/tools/mtouch/Errors.resx.lcl | 27 +++++++++++++++++++
7 files changed, 189 insertions(+)
diff --git a/macios/Localize/loc/cs/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/cs/macios/tools/mtouch/Errors.resx.lcl
index d66a13518d03..81e85ff7b213 100644
--- a/macios/Localize/loc/cs/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/cs/macios/tools/mtouch/Errors.resx.lcl
@@ -4552,6 +4552,15 @@
+ -
+
+
+
+
+
+
+
+
-
@@ -4882,6 +4891,24 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/es/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/es/macios/tools/mtouch/Errors.resx.lcl
index 71d382396cc5..63e741058a55 100644
--- a/macios/Localize/loc/es/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/es/macios/tools/mtouch/Errors.resx.lcl
@@ -4552,6 +4552,15 @@
+ -
+
+
+
+
+
+
+
+
-
@@ -4882,6 +4891,24 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/fr/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/fr/macios/tools/mtouch/Errors.resx.lcl
index d3a69c437805..8ef8855f9da5 100644
--- a/macios/Localize/loc/fr/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/fr/macios/tools/mtouch/Errors.resx.lcl
@@ -4552,6 +4552,15 @@
+ -
+
+
+
+
+
+
+
+
-
@@ -4882,6 +4891,24 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/pt-BR/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/pt-BR/macios/tools/mtouch/Errors.resx.lcl
index d893a87b4e74..b6e107f5acc2 100644
--- a/macios/Localize/loc/pt-BR/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/pt-BR/macios/tools/mtouch/Errors.resx.lcl
@@ -4552,6 +4552,15 @@
+ -
+
+
+
+
+
+
+
+
-
@@ -4882,6 +4891,24 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/ru/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/ru/macios/tools/mtouch/Errors.resx.lcl
index 80205c40569f..e076f441c2eb 100644
--- a/macios/Localize/loc/ru/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/ru/macios/tools/mtouch/Errors.resx.lcl
@@ -4552,6 +4552,15 @@
+ -
+
+
+
+
+
+
+
+
-
@@ -4882,6 +4891,24 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/zh-Hans/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/zh-Hans/macios/tools/mtouch/Errors.resx.lcl
index 08b62dea5624..a2d73ba8d17a 100644
--- a/macios/Localize/loc/zh-Hans/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/zh-Hans/macios/tools/mtouch/Errors.resx.lcl
@@ -4552,6 +4552,15 @@
+ -
+
+
+
+
+
+
+
+
-
@@ -4882,6 +4891,24 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/zh-Hant/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/zh-Hant/macios/tools/mtouch/Errors.resx.lcl
index 0063007365b0..3d2193f28959 100644
--- a/macios/Localize/loc/zh-Hant/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/zh-Hant/macios/tools/mtouch/Errors.resx.lcl
@@ -4552,6 +4552,15 @@
+ -
+
+
+
+
+
+
+
+
-
@@ -4882,6 +4891,24 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
From 69ef15b81ced4f5cacc6707b1c46ab598d383616 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 5 May 2026 12:07:42 +0200
Subject: [PATCH 006/156] Change DtdProcessing.Parse to DtdProcessing.Prohibit
in XML loading helpers (#25268)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Multiple XML loading helpers use `DtdProcessing.Parse`, which enables inline DTD processing and opens a vector for entity expansion DoS ("billion laughs"). While `XmlResolver = null` prevents external entity resolution, inline DTDs are still processed. Apple plist files declare a DTD but don't depend on DTD processing for correctness.
This PR changes `DtdProcessing.Parse` to `DtdProcessing.Prohibit` in all affected locations:
- `tools/common/PListExtensions.cs` — 2 occurrences (file and string overloads)
- `src/bgen/Extensions/ExtensionMethods.cs` — 1 occurrence
- `tests/cecil-tests/Helper.cs` — 1 occurrence
- `tests/mtouch/MTouch.cs` — 1 occurrence
- `tests/common/ProductTests.cs` — 1 occurrence
🤖 Pull request created by Copilot
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
src/bgen/Extensions/ExtensionMethods.cs | 2 +-
tests/cecil-tests/Helper.cs | 2 +-
tests/common/ProductTests.cs | 2 +-
tests/mtouch/MTouch.cs | 2 +-
tools/common/PListExtensions.cs | 4 ++--
5 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/src/bgen/Extensions/ExtensionMethods.cs b/src/bgen/Extensions/ExtensionMethods.cs
index dec5b0caf256..3f3bdc389265 100644
--- a/src/bgen/Extensions/ExtensionMethods.cs
+++ b/src/bgen/Extensions/ExtensionMethods.cs
@@ -26,7 +26,7 @@ public static void LoadWithoutNetworkAccess (this XmlDocument doc, string filena
using (var fs = new FileStream (filename, FileMode.Open, FileAccess.Read)) {
var settings = new XmlReaderSettings () {
XmlResolver = null,
- DtdProcessing = DtdProcessing.Parse,
+ DtdProcessing = DtdProcessing.Ignore,
};
using (var reader = XmlReader.Create (fs, settings)) {
doc.Load (reader);
diff --git a/tests/cecil-tests/Helper.cs b/tests/cecil-tests/Helper.cs
index 30f4e487e42f..f06c07616a8a 100644
--- a/tests/cecil-tests/Helper.cs
+++ b/tests/cecil-tests/Helper.cs
@@ -616,7 +616,7 @@ public static void LoadWithoutNetworkAccess (this XmlDocument doc, string filena
using (var fs = new FileStream (filename, FileMode.Open, FileAccess.Read)) {
var settings = new XmlReaderSettings () {
XmlResolver = null,
- DtdProcessing = DtdProcessing.Parse,
+ DtdProcessing = DtdProcessing.Ignore,
};
using (var reader = XmlReader.Create (fs, settings)) {
doc.Load (reader);
diff --git a/tests/common/ProductTests.cs b/tests/common/ProductTests.cs
index cd00328e78d4..ec1d1bc53569 100644
--- a/tests/common/ProductTests.cs
+++ b/tests/common/ProductTests.cs
@@ -18,7 +18,7 @@ public void MonoVersion ()
// Verify that the mono version is in the Versions.plist, and that it's a parsable version number.
var settings = new XmlReaderSettings () {
XmlResolver = null,
- DtdProcessing = DtdProcessing.Parse
+ DtdProcessing = DtdProcessing.Ignore
};
var plist = Path.Combine (Configuration.SdkRoot, "Versions.plist");
diff --git a/tests/mtouch/MTouch.cs b/tests/mtouch/MTouch.cs
index 8f6a10fa853d..d25662235eaf 100644
--- a/tests/mtouch/MTouch.cs
+++ b/tests/mtouch/MTouch.cs
@@ -1986,7 +1986,7 @@ static void LoadWithoutNetworkAccess (XmlDocument doc, string filename)
using (var fs = new FileStream (filename, FileMode.Open, FileAccess.Read)) {
var settings = new XmlReaderSettings () {
XmlResolver = null,
- DtdProcessing = DtdProcessing.Parse,
+ DtdProcessing = DtdProcessing.Ignore,
};
using (var reader = XmlReader.Create (fs, settings)) {
doc.Load (reader);
diff --git a/tools/common/PListExtensions.cs b/tools/common/PListExtensions.cs
index 26ac6c7e745e..892e142eb61d 100644
--- a/tools/common/PListExtensions.cs
+++ b/tools/common/PListExtensions.cs
@@ -11,7 +11,7 @@ public static void LoadWithoutNetworkAccess (this XmlDocument doc, string filena
using (var fs = new FileStream (filename, FileMode.Open, FileAccess.Read)) {
var settings = new XmlReaderSettings () {
XmlResolver = null,
- DtdProcessing = DtdProcessing.Parse,
+ DtdProcessing = DtdProcessing.Ignore,
};
using (var reader = XmlReader.Create (fs, settings)) {
doc.Load (reader);
@@ -24,7 +24,7 @@ public static void LoadXmlWithoutNetworkAccess (this XmlDocument doc, string xml
using (var fs = new StringReader (xml)) {
var settings = new XmlReaderSettings () {
XmlResolver = null,
- DtdProcessing = DtdProcessing.Parse,
+ DtdProcessing = DtdProcessing.Ignore,
};
using (var reader = XmlReader.Create (fs, settings)) {
doc.Load (reader);
From 211364cd5dc18951b694bfdd63b872fbff04041a Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 5 May 2026 12:08:16 +0200
Subject: [PATCH 007/156] [devops] Show "(Publish failed)" instead of broken
VSDrops link when html report publish fails. (#25233)
When the "Publish to Artifact Services Drop" step times out or fails, the VSDrops
link in the GitHub comment would point to a non-existent page. Now detect the
failure by setting an output variable when the step does not succeed, and show
"(Publish failed)" in plain text instead of a broken link.
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
.../automation/scripts/TestResults.Tests.ps1 | 72 +++++++++++++++++++
.../automation/scripts/TestResults.psm1 | 14 +++-
.../devops/automation/templates/mac/build.yml | 20 ++++++
.../automation/templates/tests/run-tests.yml | 20 ++++++
4 files changed, 124 insertions(+), 2 deletions(-)
diff --git a/tools/devops/automation/scripts/TestResults.Tests.ps1 b/tools/devops/automation/scripts/TestResults.Tests.ps1
index 1a27744780c7..0d29999bc54f 100644
--- a/tools/devops/automation/scripts/TestResults.Tests.ps1
+++ b/tools/devops/automation/scripts/TestResults.Tests.ps1
@@ -1352,4 +1352,76 @@ Test results reported success, but the tests job failed.
$sonomaIdx | Should -BeLessThan $sequoiaIdx
}
}
+
+ Context "VSDrops publish failed" {
+ It "shows publish failed text instead of VSDrops link" {
+ $VerbosePreference = "Continue"
+ $DebugPreference = "Continue"
+
+ $vsdropsMatrix = @"
+{
+ "cecil": {
+ "LABEL": "cecil",
+ "TESTS_LABELS": "--label=skip-all-tests,run-cecil-tests",
+ "TEST_STAGE": "simulator_tests",
+ "LABEL_WITH_PLATFORM": "cecil",
+ "STATUS_CONTEXT": "VSTS: simulator tests - cecil",
+ "TEST_PREFIX": "simulator_testscecil",
+ "TEST_PLATFORM": ""
+ }
+}
+"@
+ $vsdropsFailedStageDeps = @"
+{
+ "configure_build": {
+ "configure": {
+ "outputs": {
+ "test_matrix.TEST_MATRIX": "$($vsdropsMatrix.Replace("`n", "\n").Replace("`"", "\`""))"
+ }
+ }
+ },
+ "simulator_tests": {
+ "tests": {
+ "outputs": {
+ "cecil.PowerShell15.TESTS_ATTEMPT": "1",
+ "cecil.PowerShell15.TESTS_BOT": "XAMMINI-013.Ventura",
+ "cecil.PowerShell15.TESTS_LABEL": "cecil",
+ "cecil.PowerShell15.TESTS_PLATFORM": "",
+ "cecil.PowerShell15.TESTS_TITLE": "cecil",
+ "cecil.runTests.TESTS_JOBSTATUS": "Succeeded",
+ "cecil.setVSDropsPublishResult.VSDROPS_PUBLISHED": "Failed"
+ },
+ "identifier": null,
+ "name": "tests",
+ "attempt": 1,
+ "startTime": null,
+ "finishTime": null,
+ "state": "NotStarted",
+ "result": "Succeeded"
+ }
+ }
+}
+"@
+ $testDirectory = Join-Path "." "subdir"
+ New-Item -Path "$testDirectory" -ItemType "directory" -Force
+ New-Item -Path "$testDirectory/TestSummary-simulator_testscecil-1" -Name "TestSummary.md" -Value "# :tada: All 1 tests passed :tada:" -Force
+
+ $parallelResults = New-ParallelTestsResults -Path "$testDirectory" -StageDependencies "$vsdropsFailedStageDeps" -Context "context" -VSDropsIndex "vsdropsIndex"
+
+ $parallelResults.IsSuccess() | Should -Be $true
+
+ $sb = [System.Text.StringBuilder]::new()
+ $parallelResults.WriteComment($sb)
+
+ Remove-Item -Path $testDirectory -Recurse
+
+ $content = $sb.ToString()
+
+ Write-Host $content
+
+ $content | Should -Not -BeLike "*[Html Report (VSDrops)]*"
+ $content | Should -BeLike "*(:warning: Html Report Publish failed :warning:)*"
+ $content | Should -BeLike "*[Download]*"
+ }
+ }
}
diff --git a/tools/devops/automation/scripts/TestResults.psm1 b/tools/devops/automation/scripts/TestResults.psm1
index ef5b0eb06457..da6b71d7107e 100644
--- a/tools/devops/automation/scripts/TestResults.psm1
+++ b/tools/devops/automation/scripts/TestResults.psm1
@@ -61,6 +61,7 @@ class TestResult {
[string] $TestStage
[string] $DisplayName
[bool] $IsMacTest
+ [bool] $VSDropsPublishFailed
hidden [int] $Passed
hidden [int] $Failed
hidden [string[]] $NotTestSummaryLabels = @()
@@ -339,9 +340,13 @@ class ParallelTestsResults {
}
[string] GetDownloadLinks($testResult) {
- $dropsIndex = "$($this.VSDropsIndex)/$($testResult.TestStage)$($testResult.Title)-$($testResult.Attempt)/;/tests/vsdrops_index.html"
$artifactUrl = "$Env:SYSTEM_TEAMFOUNDATIONCOLLECTIONURI$Env:SYSTEM_TEAMPROJECT/_apis/build/builds/$Env:BUILD_BUILDID/artifacts?artifactName=HtmlReport-$($testResult.TestStage)$($testResult.Title)-$($testResult.Attempt)&api-version=6.0&`$format=zip"
- $downloadInfo = "[Html Report (VSDrops)]($dropsIndex) [Download]($artifactUrl)"
+ if ($testResult.VSDropsPublishFailed) {
+ $downloadInfo = "(:warning: Html Report Publish failed :warning:) [Download]($artifactUrl)"
+ } else {
+ $dropsIndex = "$($this.VSDropsIndex)/$($testResult.TestStage)$($testResult.Title)-$($testResult.Attempt)/;/tests/vsdrops_index.html"
+ $downloadInfo = "[Html Report (VSDrops)]($dropsIndex) [Download]($artifactUrl)"
+ }
return $downloadInfo
}
@@ -589,6 +594,7 @@ class ParallelTestsResults {
$platformKey = $outputs.Keys | Where-Object { $_.EndsWith(".TESTS_PLATFORM") }
$attemptKey = $outputs.Keys | Where-Object { $_.EndsWith(".TESTS_ATTEMPT") }
$titleKey = $outputs.Keys | Where-Object { $_.EndsWith(".TESTS_TITLE") }
+ $vsdropsPublishedKey = $outputs.Keys | Where-Object { $_.EndsWith(".VSDROPS_PUBLISHED") } | Sort-Object | Select-Object -Last 1
} else {
# matrix job
$jobName = $name.Substring(0, $name.IndexOf('.'))
@@ -597,6 +603,7 @@ class ParallelTestsResults {
$platformKey = $outputs.Keys | Where-Object { $_.StartsWith($jobName + ".") -and $_.EndsWith(".TESTS_PLATFORM") }
$attemptKey = $outputs.Keys | Where-Object { $_.StartsWith($jobName + ".") -and $_.EndsWith(".TESTS_ATTEMPT") }
$titleKey = $outputs.Keys | Where-Object { $_.StartsWith($jobName + ".") -and $_.EndsWith(".TESTS_TITLE") }
+ $vsdropsPublishedKey = $outputs.Keys | Where-Object { $_.StartsWith($jobName + ".") -and $_.EndsWith(".VSDROPS_PUBLISHED") } | Sort-Object | Select-Object -Last 1
}
Write-Host "Keys for Label='$label' and JobName='$jobName' (dotCount=$dotCount): TitleKey='$titleKey' StatusKey=$statusKey BotKey=$botKey PlatformKey=$platformKey AttemptKey=$attemptKey"
@@ -611,6 +618,7 @@ class ParallelTestsResults {
$platform = if ($platformKey -eq $null) { "NotFound" } else { $outputs[$platformKey] }
$attempt = if ($attemptKey -eq $null) { -2 } else { [int]$outputs[$attemptKey] }
$title = if ($titleKey -eq $null) { "NotFound" } else { $outputs[$titleKey] }
+ $vsdropsPublished = if ($vsdropsPublishedKey -eq $null) { $null } else { $outputs[$vsdropsPublishedKey] }
$testResult = [PSCustomObject]@{
Label = $label
Title = $title
@@ -619,6 +627,7 @@ class ParallelTestsResults {
Platform = $platform
Attempt = $attempt
TestStage = $testStage
+ VSDropsPublished = $vsdropsPublished
}
if ($tests.Contains($label)) {
$testInfo = $tests[$label]
@@ -675,6 +684,7 @@ class ParallelTestsResults {
}
$result = [TestResult]::new($testSummaryPath, $status, $testConfig, $testAttempt)
+ $result.VSDropsPublishFailed = ($testResult.VSDropsPublished -eq "Failed")
}
$testResults += $result
diff --git a/tools/devops/automation/templates/mac/build.yml b/tools/devops/automation/templates/mac/build.yml
index b564d24af9ac..770a2358fb29 100644
--- a/tools/devops/automation/templates/mac/build.yml
+++ b/tools/devops/automation/templates/mac/build.yml
@@ -210,8 +210,15 @@ steps:
condition: succeededOrFailed()
# Upload to VSDrops so that the Html Report link in the GitHub comment works.
+- bash: |
+ echo "##vso[task.setvariable variable=JOB_STATUS_BEFORE_VSDROPS]$AGENT_JOBSTATUS"
+ displayName: 'Capture job status before VSDrops publish'
+ condition: succeededOrFailed()
+ continueOnError: true
+
- task: artifactDropTask@1
displayName: 'Publish to Artifact Services Drop'
+ name: publishVSDrops
inputs:
dropServiceURI: 'https://devdiv.artifacts.visualstudio.com/DefaultCollection'
dropMetadataContainerName: '${{ parameters.uploadPrefix }}DropMetadata-${{ parameters.stageName }}${{ parameters.label }}-$(System.JobAttempt)'
@@ -223,6 +230,19 @@ steps:
continueOnError: true
condition: succeededOrFailed()
+# Azure DevOps doesn't support checking individual step results in step conditions
+# (failed('stepName') only works for jobs/stages). Comparing AGENT_JOBSTATUS before
+# and after the publish step is the best available approach to detect publish failures.
+- bash: |
+ if [ "$JOB_STATUS_BEFORE_VSDROPS" != "$AGENT_JOBSTATUS" ]; then
+ echo "VSDrops publish changed job status from '$JOB_STATUS_BEFORE_VSDROPS' to '$AGENT_JOBSTATUS'"
+ echo "##vso[task.setvariable variable=VSDROPS_PUBLISHED;isOutput=true]Failed"
+ fi
+ name: setVSDropsPublishResult
+ displayName: 'Set VSDrops publish result'
+ continueOnError: true
+ condition: succeededOrFailed()
+
- template: ../common/archive-html-report.yml
parameters:
rootFolder: '$(BUILD_REPOSITORY_TITLE)/jenkins-results'
diff --git a/tools/devops/automation/templates/tests/run-tests.yml b/tools/devops/automation/templates/tests/run-tests.yml
index 0ff0d43d39cb..188474aa28ea 100644
--- a/tools/devops/automation/templates/tests/run-tests.yml
+++ b/tools/devops/automation/templates/tests/run-tests.yml
@@ -182,8 +182,15 @@ steps:
continueOnError: true
condition: succeededOrFailed()
+- bash: |
+ echo "##vso[task.setvariable variable=JOB_STATUS_BEFORE_VSDROPS]$AGENT_JOBSTATUS"
+ displayName: 'Capture job status before VSDrops publish'
+ condition: succeededOrFailed()
+ continueOnError: true
+
- task: artifactDropTask@1
displayName: 'Publish to Artifact Services Drop'
+ name: publishVSDrops
inputs:
dropServiceURI: 'https://devdiv.artifacts.visualstudio.com/DefaultCollection'
dropMetadataContainerName: '${{ parameters.uploadPrefix }}DropMetadata-${{ parameters.testPrefix }}${{ parameters.labelWithPlatform }}-$(System.JobAttempt)'
@@ -195,6 +202,19 @@ steps:
continueOnError: true
condition: succeededOrFailed()
+# Azure DevOps doesn't support checking individual step results in step conditions
+# (failed('stepName') only works for jobs/stages). Comparing AGENT_JOBSTATUS before
+# and after the publish step is the best available approach to detect publish failures.
+- bash: |
+ if [ "$JOB_STATUS_BEFORE_VSDROPS" != "$AGENT_JOBSTATUS" ]; then
+ echo "VSDrops publish changed job status from '$JOB_STATUS_BEFORE_VSDROPS' to '$AGENT_JOBSTATUS'"
+ echo "##vso[task.setvariable variable=VSDROPS_PUBLISHED;isOutput=true]Failed"
+ fi
+ name: setVSDropsPublishResult
+ displayName: 'Set VSDrops publish result'
+ continueOnError: true
+ condition: succeededOrFailed()
+
- bash: |
set -ex
find . -name 'vsts-*.xml' || true
From 8f5e4781378c460dc25ec412b4eb4b09c1d2dfcd Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 5 May 2026 13:04:53 +0200
Subject: [PATCH 008/156] [dotnet] Disable trimming when using CoreCLR in the
simulator. (#25315)
Fixes #25295.
---
dotnet/targets/Xamarin.Shared.Sdk.Trimming.props | 15 +++++++++------
1 file changed, 9 insertions(+), 6 deletions(-)
diff --git a/dotnet/targets/Xamarin.Shared.Sdk.Trimming.props b/dotnet/targets/Xamarin.Shared.Sdk.Trimming.props
index c2b34b5d4c10..02dd815c5f81 100644
--- a/dotnet/targets/Xamarin.Shared.Sdk.Trimming.props
+++ b/dotnet/targets/Xamarin.Shared.Sdk.Trimming.props
@@ -50,8 +50,11 @@
<_DefaultLinkMode Condition="'$(_DefaultLinkMode)' == '' And '$(_UseNativeAot)' == 'true'">Full
-
- <_DefaultLinkMode Condition="'$(_DefaultLinkMode)' == '' And '$(UseMonoRuntime)' != 'true'">None
+
+ <_DefaultLinkMode Condition="'$(_DefaultLinkMode)' == '' And '$(UseMonoRuntime)' != 'true' And '$(_PlatformName)' == 'macOS'">None
+
+
+ <_DefaultLinkMode Condition="'$(_DefaultLinkMode)' == '' And '$(UseMonoRuntime)' != 'true' And '$(_SdkIsSimulator)' == 'true'">None
<_DefaultLinkMode Condition="'$(_DefaultLinkMode)' == '' And '$(_PlatformName)' == 'MacCatalyst' And '$(Configuration)' == 'Release'">SdkOnly
@@ -62,10 +65,10 @@
<_DefaultLinkMode Condition="'$(_DefaultLinkMode)' == '' And '$(_PlatformName)' == 'MacCatalyst'">None
-
- <_DefaultLinkMode Condition="'$(_DefaultLinkMode)' == '' And '$(_SdkIsSimulator)' == 'true' And $(RuntimeIdentifier.Contains('arm64')) And '$(MtouchInterpreter)' == ''">SdkOnly
-
- <_DefaultLinkMode Condition="'$(_DefaultLinkMode)' == '' And '$(_SdkIsSimulator)' == 'true' And (!$(RuntimeIdentifier.Contains('arm64')) Or '$(MtouchInterpreter)' != '')">None
+
+ <_DefaultLinkMode Condition="'$(_DefaultLinkMode)' == '' And '$(_SdkIsSimulator)' == 'true' And '$(UseMonoRuntime)' == 'true' And $(RuntimeIdentifier.Contains('arm64')) And '$(MtouchInterpreter)' == ''">SdkOnly
+
+ <_DefaultLinkMode Condition="'$(_DefaultLinkMode)' == '' And '$(_SdkIsSimulator)' == 'true' And '$(UseMonoRuntime)' == 'true' And (!$(RuntimeIdentifier.Contains('arm64')) Or '$(MtouchInterpreter)' != '')">None
<_DefaultLinkMode Condition="'$(_DefaultLinkMode)' == ''">SdkOnly
From 75bcfbf617782386f0e7e5be4d904321b0435b7f Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 5 May 2026 15:25:51 +0200
Subject: [PATCH 009/156] [apidiff] Update reference/stable versions to latest
.NET 10 / Xcode 26.4 (#25323)
---
Make.config | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/Make.config b/Make.config
index 0e88c44f2ef0..8880e28369bd 100644
--- a/Make.config
+++ b/Make.config
@@ -50,10 +50,10 @@ include $(TOP)/Make.versions
# The value is taken from the name + version of the Ref pack.
# Example: given the Ref pack "Microsoft.iOS.Ref.net8.0_17.5" with the version "17.5.8030", the value
# to write here would be the part after "Microsoft.iOS.Ref." + "/" + version: "net8.0_17.5/17.5.8030"
-STABLE_NUGET_VERSION_iOS=net10.0_26.2/26.2.10233
-STABLE_NUGET_VERSION_tvOS=net10.0_26.2/26.2.10233
-STABLE_NUGET_VERSION_MacCatalyst=net10.0_26.2/26.2.10233
-STABLE_NUGET_VERSION_macOS=net10.0_26.2/26.2.10233
+STABLE_NUGET_VERSION_iOS=net10.0_26.4/26.4.10259
+STABLE_NUGET_VERSION_tvOS=net10.0_26.4/26.4.10259
+STABLE_NUGET_VERSION_MacCatalyst=net10.0_26.4/26.4.10259
+STABLE_NUGET_VERSION_macOS=net10.0_26.4/26.4.10259
PACKAGE_HEAD_REV=$(shell git rev-parse HEAD)
From ad8bc799666acb4a0198f46a7d4b5a808ec9bb71 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 5 May 2026 15:29:46 +0200
Subject: [PATCH 010/156] [dotnet] Remove some outdated code only applicable to
.NET 6 (and not later .NET versions). (#25327)
---
.../Xamarin.Shared.Sdk.DefaultItems.targets | 33 -------------------
.../CentralPackageVersionsApp/AppDelegate.cs | 17 ----------
.../CentralPackageVersionsApp.csproj | 8 -----
.../MacCatalyst/Makefile | 1 -
.../dotnet/CentralPackageVersionsApp/Makefile | 2 --
.../CentralPackageVersionsApp/Packages.props | 5 ---
.../CentralPackageVersionsApp/README.md | 1 -
.../iOS/CentralPackageVersionsApp.csproj | 8 -----
.../CentralPackageVersionsApp/iOS/Makefile | 1 -
.../macOS/CentralPackageVersionsApp.csproj | 8 -----
.../CentralPackageVersionsApp/macOS/Makefile | 1 -
.../CentralPackageVersionsApp/shared.csproj | 25 --------------
.../CentralPackageVersionsApp/shared.mk | 2 --
.../tvOS/CentralPackageVersionsApp.csproj | 8 -----
.../CentralPackageVersionsApp/tvOS/Makefile | 1 -
tests/dotnet/UnitTests/ProjectTest.cs | 16 ---------
16 files changed, 137 deletions(-)
delete mode 100644 tests/dotnet/CentralPackageVersionsApp/AppDelegate.cs
delete mode 100644 tests/dotnet/CentralPackageVersionsApp/MacCatalyst/CentralPackageVersionsApp.csproj
delete mode 100644 tests/dotnet/CentralPackageVersionsApp/MacCatalyst/Makefile
delete mode 100644 tests/dotnet/CentralPackageVersionsApp/Makefile
delete mode 100644 tests/dotnet/CentralPackageVersionsApp/Packages.props
delete mode 100644 tests/dotnet/CentralPackageVersionsApp/README.md
delete mode 100644 tests/dotnet/CentralPackageVersionsApp/iOS/CentralPackageVersionsApp.csproj
delete mode 100644 tests/dotnet/CentralPackageVersionsApp/iOS/Makefile
delete mode 100644 tests/dotnet/CentralPackageVersionsApp/macOS/CentralPackageVersionsApp.csproj
delete mode 100644 tests/dotnet/CentralPackageVersionsApp/macOS/Makefile
delete mode 100644 tests/dotnet/CentralPackageVersionsApp/shared.csproj
delete mode 100644 tests/dotnet/CentralPackageVersionsApp/shared.mk
delete mode 100644 tests/dotnet/CentralPackageVersionsApp/tvOS/CentralPackageVersionsApp.csproj
delete mode 100644 tests/dotnet/CentralPackageVersionsApp/tvOS/Makefile
diff --git a/dotnet/targets/Xamarin.Shared.Sdk.DefaultItems.targets b/dotnet/targets/Xamarin.Shared.Sdk.DefaultItems.targets
index 973f26394330..42b125875d12 100644
--- a/dotnet/targets/Xamarin.Shared.Sdk.DefaultItems.targets
+++ b/dotnet/targets/Xamarin.Shared.Sdk.DefaultItems.targets
@@ -68,37 +68,4 @@
-
-
-
-
-
-
-
-
-
- 6.0.3
-
-
diff --git a/tests/dotnet/CentralPackageVersionsApp/AppDelegate.cs b/tests/dotnet/CentralPackageVersionsApp/AppDelegate.cs
deleted file mode 100644
index db627351190b..000000000000
--- a/tests/dotnet/CentralPackageVersionsApp/AppDelegate.cs
+++ /dev/null
@@ -1,17 +0,0 @@
-using System;
-using System.Runtime.InteropServices;
-
-using Foundation;
-
-namespace MySimpleApp {
- public class Program {
- static int Main (string [] args)
- {
- GC.KeepAlive (typeof (NSObject)); // prevent linking away the platform assembly
-
- Console.WriteLine (Environment.GetEnvironmentVariable ("MAGIC_WORD"));
-
- return args.Length;
- }
- }
-}
diff --git a/tests/dotnet/CentralPackageVersionsApp/MacCatalyst/CentralPackageVersionsApp.csproj b/tests/dotnet/CentralPackageVersionsApp/MacCatalyst/CentralPackageVersionsApp.csproj
deleted file mode 100644
index 9146ec230693..000000000000
--- a/tests/dotnet/CentralPackageVersionsApp/MacCatalyst/CentralPackageVersionsApp.csproj
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
-
-
- net$(BundledNETCoreAppTargetFrameworkVersion)-maccatalyst
-
-
-
diff --git a/tests/dotnet/CentralPackageVersionsApp/MacCatalyst/Makefile b/tests/dotnet/CentralPackageVersionsApp/MacCatalyst/Makefile
deleted file mode 100644
index 110d078f4577..000000000000
--- a/tests/dotnet/CentralPackageVersionsApp/MacCatalyst/Makefile
+++ /dev/null
@@ -1 +0,0 @@
-include ../shared.mk
diff --git a/tests/dotnet/CentralPackageVersionsApp/Makefile b/tests/dotnet/CentralPackageVersionsApp/Makefile
deleted file mode 100644
index 6affa45ff122..000000000000
--- a/tests/dotnet/CentralPackageVersionsApp/Makefile
+++ /dev/null
@@ -1,2 +0,0 @@
-TOP=../../..
-include $(TOP)/tests/common/shared-dotnet-test.mk
diff --git a/tests/dotnet/CentralPackageVersionsApp/Packages.props b/tests/dotnet/CentralPackageVersionsApp/Packages.props
deleted file mode 100644
index 8423b42e36a1..000000000000
--- a/tests/dotnet/CentralPackageVersionsApp/Packages.props
+++ /dev/null
@@ -1,5 +0,0 @@
-
-
-
-
-
diff --git a/tests/dotnet/CentralPackageVersionsApp/README.md b/tests/dotnet/CentralPackageVersionsApp/README.md
deleted file mode 100644
index 0f3d32a3be18..000000000000
--- a/tests/dotnet/CentralPackageVersionsApp/README.md
+++ /dev/null
@@ -1 +0,0 @@
-This test can be removed in .NET 7.
diff --git a/tests/dotnet/CentralPackageVersionsApp/iOS/CentralPackageVersionsApp.csproj b/tests/dotnet/CentralPackageVersionsApp/iOS/CentralPackageVersionsApp.csproj
deleted file mode 100644
index 1ce755af9e0a..000000000000
--- a/tests/dotnet/CentralPackageVersionsApp/iOS/CentralPackageVersionsApp.csproj
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
-
-
- net$(BundledNETCoreAppTargetFrameworkVersion)-ios
-
-
-
diff --git a/tests/dotnet/CentralPackageVersionsApp/iOS/Makefile b/tests/dotnet/CentralPackageVersionsApp/iOS/Makefile
deleted file mode 100644
index 110d078f4577..000000000000
--- a/tests/dotnet/CentralPackageVersionsApp/iOS/Makefile
+++ /dev/null
@@ -1 +0,0 @@
-include ../shared.mk
diff --git a/tests/dotnet/CentralPackageVersionsApp/macOS/CentralPackageVersionsApp.csproj b/tests/dotnet/CentralPackageVersionsApp/macOS/CentralPackageVersionsApp.csproj
deleted file mode 100644
index 391feb6d1b70..000000000000
--- a/tests/dotnet/CentralPackageVersionsApp/macOS/CentralPackageVersionsApp.csproj
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
-
-
- net$(BundledNETCoreAppTargetFrameworkVersion)-macos
-
-
-
diff --git a/tests/dotnet/CentralPackageVersionsApp/macOS/Makefile b/tests/dotnet/CentralPackageVersionsApp/macOS/Makefile
deleted file mode 100644
index 110d078f4577..000000000000
--- a/tests/dotnet/CentralPackageVersionsApp/macOS/Makefile
+++ /dev/null
@@ -1 +0,0 @@
-include ../shared.mk
diff --git a/tests/dotnet/CentralPackageVersionsApp/shared.csproj b/tests/dotnet/CentralPackageVersionsApp/shared.csproj
deleted file mode 100644
index 4ec57f3f7a0e..000000000000
--- a/tests/dotnet/CentralPackageVersionsApp/shared.csproj
+++ /dev/null
@@ -1,25 +0,0 @@
-
-
-
-
- Exe
-
- com.xamarin.centralpackageversionsapp
- true
- true
-
-
-
-
-
-
-
-
-
- $(MSBuildThisFileDirectory)Packages.props
-
-
-
-
-
-
diff --git a/tests/dotnet/CentralPackageVersionsApp/shared.mk b/tests/dotnet/CentralPackageVersionsApp/shared.mk
deleted file mode 100644
index f555cad4e805..000000000000
--- a/tests/dotnet/CentralPackageVersionsApp/shared.mk
+++ /dev/null
@@ -1,2 +0,0 @@
-TOP=../../../..
-include $(TOP)/tests/common/shared-dotnet.mk
diff --git a/tests/dotnet/CentralPackageVersionsApp/tvOS/CentralPackageVersionsApp.csproj b/tests/dotnet/CentralPackageVersionsApp/tvOS/CentralPackageVersionsApp.csproj
deleted file mode 100644
index a441004a08a5..000000000000
--- a/tests/dotnet/CentralPackageVersionsApp/tvOS/CentralPackageVersionsApp.csproj
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
-
-
- net$(BundledNETCoreAppTargetFrameworkVersion)-tvos
-
-
-
diff --git a/tests/dotnet/CentralPackageVersionsApp/tvOS/Makefile b/tests/dotnet/CentralPackageVersionsApp/tvOS/Makefile
deleted file mode 100644
index 110d078f4577..000000000000
--- a/tests/dotnet/CentralPackageVersionsApp/tvOS/Makefile
+++ /dev/null
@@ -1 +0,0 @@
-include ../shared.mk
diff --git a/tests/dotnet/UnitTests/ProjectTest.cs b/tests/dotnet/UnitTests/ProjectTest.cs
index b0b5696427ef..a9ed3fcddbfa 100644
--- a/tests/dotnet/UnitTests/ProjectTest.cs
+++ b/tests/dotnet/UnitTests/ProjectTest.cs
@@ -1997,22 +1997,6 @@ public void AppWithGenericLibraryReference (ApplePlatform platform, string runti
ExecuteWithMagicWordAndAssert (platform, runtimeIdentifiers, appExecutable);
}
- // This test can be removed in .NET 7
- [TestCase (ApplePlatform.iOS)]
- [TestCase (ApplePlatform.TVOS)]
- [TestCase (ApplePlatform.MacCatalyst)]
- [TestCase (ApplePlatform.MacOSX)]
- public void CentralPackageVersionsApp (ApplePlatform platform)
- {
- var project = "CentralPackageVersionsApp";
- Configuration.IgnoreIfIgnoredPlatform (platform);
-
- var project_path = GetProjectPath (project, platform: platform);
- Clean (project_path);
- var properties = GetDefaultProperties ();
- DotNet.AssertBuild (project_path, properties);
- }
-
[TestCase (ApplePlatform.MacCatalyst, "maccatalyst-x64", false)]
[TestCase (ApplePlatform.iOS, "iossimulator-x64", true)]
[TestCase (ApplePlatform.TVOS, "tvossimulator-x64", true)]
From 82c362fa5a69298b84e2b0adeb846689263bfb37 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 5 May 2026 15:30:07 +0200
Subject: [PATCH 011/156] [docs] Fix reference to the ReferenceNativeSymbol
item. (#25324)
---
docs/building-apps/build-properties.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/building-apps/build-properties.md b/docs/building-apps/build-properties.md
index ab6a1742229a..b28355b21e83 100644
--- a/docs/building-apps/build-properties.md
+++ b/docs/building-apps/build-properties.md
@@ -1103,7 +1103,7 @@ Only applicable to macOS and Mac Catalyst apps.
## ReferenceNativeSymbol
-See [ReferenceNativeSymbol](build-items.md#referencenativesymbols)
+See [ReferenceNativeSymbol](build-items.md#referencenativesymbol)
## RequireLinkWithAttributeForObjectiveCClassSearch
From ff737f701fa4765003bc8e19a0b303f4bbc573cd Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 5 May 2026 16:27:20 +0200
Subject: [PATCH 012/156] [FSKit] Update the cref target in an xml comment.
(#25328)
Fixes the following problem:
1. We compile the api definition, and csc resolves the `cref="Mount"` reference to `cref="M:FSKit.FSVolumeOperations.Mount(FSKit.FSTaskOptions,FSKit.FSVolumeOperationsMountHandler)"`
2. We run the generator, and copy the xml docs from the compiled api definition, which is `cref="M:FSKit.FSVolumeOperations.Mount(FSKit.FSTaskOptions,FSKit.FSVolumeOperationsMountHandler)"`
3. The actual type name is `IFSVolumeOperations` (because the type is a protocol), which means the cref is now pointing to somewhere that doesn't exist.
Fix this by specifying the complete reference in the api definition's xml comment, which csc won't process, and just copy as-is.
---
src/fskit.cs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/fskit.cs b/src/fskit.cs
index 4194d8922171..f6375c47934a 100644
--- a/src/fskit.cs
+++ b/src/fskit.cs
@@ -897,7 +897,7 @@ interface FSVolumeOperations : FSVolumePathConfOperations {
bool EnableOpenUnlinkEmulation { get; set; }
/// Gets or sets the mount options that the file system requests from FSKit.
- /// FSKit reads this value after the volume replies to the call. Changing the returned value during the runtime of the volume has no effect.
+ /// FSKit reads this value after the volume replies to the call. Changing the returned value during the runtime of the volume has no effect.
[Mac (26, 0)]
[Export ("requestedMountOptions", ArgumentSemantic.Assign)]
FSMountOptions RequestedMountOptions { get; set; }
From 60edd7c403b9d1ec811bc097db01f1daa2b7410a Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 5 May 2026 18:30:46 +0200
Subject: [PATCH 013/156] Fix broken links in source files and XML API docs
(#25329)
- Update old Apple documentation URLs to modern developer.apple.com/documentation/ format
in src/ C# files and docs/api/ XML files
- Remove dead Xamarin links (developer.xamarin.com, docs.xamarin.com)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
docs/api/AVFoundation/AVAudioRecorder.xml | 4 +-
docs/api/AVFoundation/AVAudioSession.xml | 2 +-
docs/api/AVFoundation/AVSpeechSynthesizer.xml | 2 +-
docs/api/AddressBook/ABPerson.xml | 3 -
.../ABPeoplePickerNavigationController.xml | 3 -
docs/api/CoreAnimation/CALayer.xml | 12 ---
docs/api/UIKit/NSLayoutManager.xml | 2 +-
docs/api/UIKit/NSTextContainer.xml | 2 +-
docs/api/UIKit/NSTextStorage.xml | 2 +-
docs/api/UIKit/UICollectionView.xml | 1 -
docs/api/UIKit/UICollectionViewCell.xml | 1 -
docs/api/UIKit/UICollectionViewDelegate.xml | 1 -
docs/api/UIKit/UICollectionViewFlowLayout.xml | 1 -
docs/api/UIKit/UICollectionViewLayout.xml | 1 -
.../UICollectionViewLayoutAttributes.xml | 1 -
docs/api/UIKit/UIView.xml | 2 -
docs/api/UIKit/UIWebView.xml | 3 -
src/AVFoundation/AVAudioBuffer.cs | 2 +-
src/AVFoundation/AVAudioChannelLayout.cs | 2 +-
src/AVFoundation/AVAudioFormat.cs | 2 +-
src/AVFoundation/AVAudioPlayer.cs | 2 +-
.../AVAudioSessionDataSourceDescription.cs | 2 +-
.../AVAudioSessionPortDescription.cs | 2 +-
src/AVFoundation/AVSpeechUtterance.cs | 2 +-
src/AVFoundation/Events.cs | 2 +-
.../CKFetchNotificationChangesOperation.cs | 1 -
.../CKMarkNotificationsReadOperation.cs | 1 -
src/CloudKit/CKModifyBadgeOperation.cs | 1 -
src/GameplayKit/GKHybridStrategist.cs | 1 -
src/NewsstandKit/Compat.cs | 3 -
src/ObjCRuntime/TypeConverter.cs | 2 +-
src/UIKit/UIEnums.cs | 2 -
src/UIKit/UIGestureRecognizer.cs | 6 +-
src/avfoundation.cs | 82 +++++++++----------
src/coreanimation.cs | 4 +-
src/passkit.cs | 2 +-
src/quicklook.cs | 2 +-
src/safariservices.cs | 2 +-
src/twitter.cs | 5 --
src/uikit.cs | 2 -
src/videosubscriberaccount.cs | 10 +--
src/xkit.cs | 8 +-
42 files changed, 73 insertions(+), 120 deletions(-)
diff --git a/docs/api/AVFoundation/AVAudioRecorder.xml b/docs/api/AVFoundation/AVAudioRecorder.xml
index fddc275c262b..2b8dfd9064cb 100644
--- a/docs/api/AVFoundation/AVAudioRecorder.xml
+++ b/docs/api/AVFoundation/AVAudioRecorder.xml
@@ -22,8 +22,6 @@ recorder.Record ();
]]>
- Play Sound
- Record Sound
- Apple documentation for AVAudioRecorder
+ Apple documentation for AVAudioRecorder
\ No newline at end of file
diff --git a/docs/api/AVFoundation/AVAudioSession.xml b/docs/api/AVFoundation/AVAudioSession.xml
index ca32d9a704d7..0ddf6c2b49a0 100644
--- a/docs/api/AVFoundation/AVAudioSession.xml
+++ b/docs/api/AVFoundation/AVAudioSession.xml
@@ -62,7 +62,7 @@ void Setup ()
]]>
- Apple documentation for AVAudioSession
+ Apple documentation for AVAudioSession
One of
diff --git a/docs/api/AVFoundation/AVSpeechSynthesizer.xml b/docs/api/AVFoundation/AVSpeechSynthesizer.xml
index 2d3b61b5dec1..3069c1147047 100644
--- a/docs/api/AVFoundation/AVSpeechSynthesizer.xml
+++ b/docs/api/AVFoundation/AVSpeechSynthesizer.xml
@@ -14,6 +14,6 @@ ss.SpeakUtterance(su);
The maintains an internal queue of s. The queue is not accessible to application developers, but the synthesizer can be paused or stopped with and . Events such as or are opportunities for the application developer to modify previously-enqueued sequences.
- Apple documentation for AVSpeechSynthesizer
+ Apple documentation for AVSpeechSynthesizer
\ No newline at end of file
diff --git a/docs/api/AddressBook/ABPerson.xml b/docs/api/AddressBook/ABPerson.xml
index 51f25ef15e0b..9fe9d9ddafb8 100644
--- a/docs/api/AddressBook/ABPerson.xml
+++ b/docs/api/AddressBook/ABPerson.xml
@@ -229,8 +229,5 @@
monocatalog
- Choose a Contact
- Create a New Contact
- Find a Contact
\ No newline at end of file
diff --git a/docs/api/AddressBookUI/ABPeoplePickerNavigationController.xml b/docs/api/AddressBookUI/ABPeoplePickerNavigationController.xml
index 4643e769edc5..2e71c18d1d82 100644
--- a/docs/api/AddressBookUI/ABPeoplePickerNavigationController.xml
+++ b/docs/api/AddressBookUI/ABPeoplePickerNavigationController.xml
@@ -272,9 +272,6 @@ public class CompatibleEmailPickerViewController : UIViewController
}
}]]>
.
- Choose a Contact
- Create a New Contact
- Find a Contact
Apple documentation for ABPeoplePickerNavigationController
\ No newline at end of file
diff --git a/docs/api/CoreAnimation/CALayer.xml b/docs/api/CoreAnimation/CALayer.xml
index 20e1d7c38cd6..19dae86dbcac 100644
--- a/docs/api/CoreAnimation/CALayer.xml
+++ b/docs/api/CoreAnimation/CALayer.xml
@@ -191,12 +191,6 @@ public class MyLayer : CALayer {
]]>
- Animate a UIView using UIKit
- Animate Using Blocks
- Create a Keyframe Animation
- Create an Animation Block
- Create An Explicit Animation
- Create an Implicit Animation
Apple documentation for CALayer
@@ -405,12 +399,6 @@ public class MyLayer : CALayer {
- Animate a UIView using UIKit
- Animate Using Blocks
- Create a Keyframe Animation
- Create an Animation Block
- Create An Explicit Animation
- Create an Implicit Animation
Apple documentation for CALayer
\ No newline at end of file
diff --git a/docs/api/UIKit/NSLayoutManager.xml b/docs/api/UIKit/NSLayoutManager.xml
index 1efcbd24773a..df4ce69e3814 100644
--- a/docs/api/UIKit/NSLayoutManager.xml
+++ b/docs/api/UIKit/NSLayoutManager.xml
@@ -10,7 +10,7 @@
objects, which actually display the text.
- Apple documentation for NSLayoutManager
+ Apple documentation for NSLayoutManager
Whether layout can be done for a portion of the document without laying-out being recalculated from the beginning.
diff --git a/docs/api/UIKit/NSTextContainer.xml b/docs/api/UIKit/NSTextContainer.xml
index 41cac2b068e9..193141e2d971 100644
--- a/docs/api/UIKit/NSTextContainer.xml
+++ b/docs/api/UIKit/NSTextContainer.xml
@@ -43,6 +43,6 @@ AddSubview(rightHandView);
The preceding diagram illustrates the objects directly involved in the two-column layout. The is the responsibility of some external model class and the two-column user-interface is specified by a custom (TwoColumnView).
A contains an array of zero or more objects in its property. Text will not be placed within these paths.
- Apple documentation for NSTextContainer
+ Apple documentation for NSTextContainer
\ No newline at end of file
diff --git a/docs/api/UIKit/NSTextStorage.xml b/docs/api/UIKit/NSTextStorage.xml
index 508777500752..ef32c554f095 100644
--- a/docs/api/UIKit/NSTextStorage.xml
+++ b/docs/api/UIKit/NSTextStorage.xml
@@ -25,6 +25,6 @@
- Apple documentation for NSTextStorage
+ Apple documentation for NSTextStorage
\ No newline at end of file
diff --git a/docs/api/UIKit/UICollectionView.xml b/docs/api/UIKit/UICollectionView.xml
index 317def4b3f7e..889739ccf465 100644
--- a/docs/api/UIKit/UICollectionView.xml
+++ b/docs/api/UIKit/UICollectionView.xml
@@ -307,7 +307,6 @@ public class SimpleCollectionViewController : UICollectionViewController
- Introduction to Collection Views
Apple documentation for UICollectionView
diff --git a/docs/api/UIKit/UICollectionViewCell.xml b/docs/api/UIKit/UICollectionViewCell.xml
index 4d2e56257ba5..6e62b2a07714 100644
--- a/docs/api/UIKit/UICollectionViewCell.xml
+++ b/docs/api/UIKit/UICollectionViewCell.xml
@@ -50,7 +50,6 @@ public override UICollectionViewCell GetCell (UICollectionView collectionView, F
- Introduction to Collection Views
Apple documentation for UICollectionViewCell
\ No newline at end of file
diff --git a/docs/api/UIKit/UICollectionViewDelegate.xml b/docs/api/UIKit/UICollectionViewDelegate.xml
index b7da13af6598..459b8137ffd8 100644
--- a/docs/api/UIKit/UICollectionViewDelegate.xml
+++ b/docs/api/UIKit/UICollectionViewDelegate.xml
@@ -113,7 +113,6 @@
- Introduction to Collection Views
Apple documentation for UICollectionViewDelegate
\ No newline at end of file
diff --git a/docs/api/UIKit/UICollectionViewFlowLayout.xml b/docs/api/UIKit/UICollectionViewFlowLayout.xml
index 9d92d5d43fb5..3404f69fa6ed 100644
--- a/docs/api/UIKit/UICollectionViewFlowLayout.xml
+++ b/docs/api/UIKit/UICollectionViewFlowLayout.xml
@@ -13,7 +13,6 @@
- Introduction to Collection Views
Apple documentation for UICollectionViewFlowLayout
\ No newline at end of file
diff --git a/docs/api/UIKit/UICollectionViewLayout.xml b/docs/api/UIKit/UICollectionViewLayout.xml
index cf10120d210d..9ce2e9538c27 100644
--- a/docs/api/UIKit/UICollectionViewLayout.xml
+++ b/docs/api/UIKit/UICollectionViewLayout.xml
@@ -73,7 +73,6 @@
- Introduction to Collection Views
Apple documentation for UICollectionViewLayout
\ No newline at end of file
diff --git a/docs/api/UIKit/UICollectionViewLayoutAttributes.xml b/docs/api/UIKit/UICollectionViewLayoutAttributes.xml
index 9664e360e08f..032b3c9050e0 100644
--- a/docs/api/UIKit/UICollectionViewLayoutAttributes.xml
+++ b/docs/api/UIKit/UICollectionViewLayoutAttributes.xml
@@ -34,7 +34,6 @@ public class CircleLayout : UICollectionViewLayout {
implements and thus can be used with UI Dynamics.
- Introduction to Collection Views
Apple documentation for UICollectionViewLayoutAttributes
\ No newline at end of file
diff --git a/docs/api/UIKit/UIView.xml b/docs/api/UIKit/UIView.xml
index 049b1e75a3e6..cd230ee3fc43 100644
--- a/docs/api/UIKit/UIView.xml
+++ b/docs/api/UIKit/UIView.xml
@@ -991,7 +991,6 @@ public class BlueLayer : CALayer
In addition to returning , for a to be focused, it must have a value of , a value of , a value greater than 0, and it must not be obscured by another .
- Animate a UIView using UIKit
Apple documentation for UIView
@@ -1018,7 +1017,6 @@ UIView.CommitAnimations ();
-
diff --git a/docs/api/UIKit/UIWebView.xml b/docs/api/UIKit/UIWebView.xml
index 973647807d25..fd946fa900fc 100644
--- a/docs/api/UIKit/UIWebView.xml
+++ b/docs/api/UIKit/UIWebView.xml
@@ -1,9 +1,6 @@
A that displays a web browser.
- Load a Web Page
- Load Local Content
- Load Non-Web Documents
Apple documentation for UIWebView
\ No newline at end of file
diff --git a/src/AVFoundation/AVAudioBuffer.cs b/src/AVFoundation/AVAudioBuffer.cs
index b680d770eb7b..c89ef42d6f03 100644
--- a/src/AVFoundation/AVAudioBuffer.cs
+++ b/src/AVFoundation/AVAudioBuffer.cs
@@ -12,7 +12,7 @@
namespace AVFoundation {
/// A buffer for audio data.
/// To be added.
- /// Apple documentation for AVAudioBuffer
+ /// Apple documentation for AVAudioBuffer
public partial class AVAudioBuffer {
/// To be added.
/// To be added.
diff --git a/src/AVFoundation/AVAudioChannelLayout.cs b/src/AVFoundation/AVAudioChannelLayout.cs
index 3c4eda653773..361fa3bc45bd 100644
--- a/src/AVFoundation/AVAudioChannelLayout.cs
+++ b/src/AVFoundation/AVAudioChannelLayout.cs
@@ -20,7 +20,7 @@
namespace AVFoundation {
/// Corresponds to a channel layout.
/// To be added.
- /// Apple documentation for AVAudioChannelLayout
+ /// Apple documentation for AVAudioChannelLayout
public partial class AVAudioChannelLayout {
static IntPtr CreateLayoutPtr (AudioChannelLayout layout, out IntPtr handleToLayout)
{
diff --git a/src/AVFoundation/AVAudioFormat.cs b/src/AVFoundation/AVAudioFormat.cs
index cd07b31b5f98..a1fb22592a0a 100644
--- a/src/AVFoundation/AVAudioFormat.cs
+++ b/src/AVFoundation/AVAudioFormat.cs
@@ -20,7 +20,7 @@
namespace AVFoundation {
/// Corresponds to a Core Audio AudioStreamBasicDescription struct.
/// To be added.
- /// Apple documentation for AVAudioFormat
+ /// Apple documentation for AVAudioFormat
public partial class AVAudioFormat {
public static bool operator == (AVAudioFormat a, AVAudioFormat b)
{
diff --git a/src/AVFoundation/AVAudioPlayer.cs b/src/AVFoundation/AVAudioPlayer.cs
index 1b8c72356371..9ce72af4277b 100644
--- a/src/AVFoundation/AVAudioPlayer.cs
+++ b/src/AVFoundation/AVAudioPlayer.cs
@@ -28,7 +28,7 @@ namespace AVFoundation {
/// An audio player that can play audio from memory or the local file system.
/// To be added.
/// avTouch
- /// Apple documentation for AVAudioPlayer
+ /// Apple documentation for AVAudioPlayer
public partial class AVAudioPlayer {
/// Create a new from the specified url and hint for the file type.
/// The url of a local audio file.
diff --git a/src/AVFoundation/AVAudioSessionDataSourceDescription.cs b/src/AVFoundation/AVAudioSessionDataSourceDescription.cs
index 6895fb55efc7..b10647a82b1c 100644
--- a/src/AVFoundation/AVAudioSessionDataSourceDescription.cs
+++ b/src/AVFoundation/AVAudioSessionDataSourceDescription.cs
@@ -54,7 +54,7 @@ public enum AVAudioDataSourcePolarPattern {
/// Describes a data source of an object.
/// To be added.
- /// Apple documentation for AVAudioSessionDataSourceDescription
+ /// Apple documentation for AVAudioSessionDataSourceDescription
public partial class AVAudioSessionDataSourceDescription {
static internal AVAudioDataSourceLocation ToLocation (NSString? l)
{
diff --git a/src/AVFoundation/AVAudioSessionPortDescription.cs b/src/AVFoundation/AVAudioSessionPortDescription.cs
index 29d9e0f50e62..62f44d34f5a2 100644
--- a/src/AVFoundation/AVAudioSessionPortDescription.cs
+++ b/src/AVFoundation/AVAudioSessionPortDescription.cs
@@ -15,7 +15,7 @@
namespace AVFoundation {
/// Encpasulates information about the input and output ports of an audio session.
/// To be added.
- /// Apple documentation for AVAudioSessionPortDescription
+ /// Apple documentation for AVAudioSessionPortDescription
public partial class AVAudioSessionPortDescription {
}
}
diff --git a/src/AVFoundation/AVSpeechUtterance.cs b/src/AVFoundation/AVSpeechUtterance.cs
index 2c494bd25a83..4c0fb566ac1c 100644
--- a/src/AVFoundation/AVSpeechUtterance.cs
+++ b/src/AVFoundation/AVSpeechUtterance.cs
@@ -31,7 +31,7 @@ public enum AVSpeechUtteranceInitializationOption {
///
/// The property specifies the speed with which the utterance is said. The rate does not appear to be processor-dependent and a rate of 1.0f is unnatural.
///
- /// Apple documentation for AVSpeechUtterance
+ /// Apple documentation for AVSpeechUtterance
public partial class AVSpeechUtterance {
/// Create a new instance for the specified string.
/// The text to speak.
diff --git a/src/AVFoundation/Events.cs b/src/AVFoundation/Events.cs
index 3e726e7c7c93..3d54e17aff34 100644
--- a/src/AVFoundation/Events.cs
+++ b/src/AVFoundation/Events.cs
@@ -137,7 +137,7 @@ public override void EndInterruption (AVAudioPlayer player)
/// An audio player that can play audio from memory or the local file system.
/// To be added.
/// avTouch
- /// Apple documentation for AVAudioPlayer
+ /// Apple documentation for AVAudioPlayer
public partial class AVAudioPlayer {
InternalAVAudioPlayerDelegate EnsureEventDelegate ()
{
diff --git a/src/CloudKit/CKFetchNotificationChangesOperation.cs b/src/CloudKit/CKFetchNotificationChangesOperation.cs
index ede7746498ad..4d6db9d7b0ba 100644
--- a/src/CloudKit/CKFetchNotificationChangesOperation.cs
+++ b/src/CloudKit/CKFetchNotificationChangesOperation.cs
@@ -8,7 +8,6 @@
namespace CloudKit {
/// A that ret../../summary_set.sh CKFetchNotificationChangesOperation A
/// To be added.
- /// Apple documentation for CKFetchNotificationChangesOperation
[Register ("CKFetchNotificationChangesOperation", SkipRegistration = true)]
[UnsupportedOSPlatform ("ios", "Use 'CKDatabaseSubscription', 'CKFetchDatabaseChangesOperation' and 'CKFetchRecordZoneChangesOperation' instead.")]
[UnsupportedOSPlatform ("macos", "Use 'CKDatabaseSubscription', 'CKFetchDatabaseChangesOperation' and 'CKFetchRecordZoneChangesOperation' instead.")]
diff --git a/src/CloudKit/CKMarkNotificationsReadOperation.cs b/src/CloudKit/CKMarkNotificationsReadOperation.cs
index 3a88ac4db0b8..814e1326e88c 100644
--- a/src/CloudKit/CKMarkNotificationsReadOperation.cs
+++ b/src/CloudKit/CKMarkNotificationsReadOperation.cs
@@ -8,7 +8,6 @@
namespace CloudKit {
/// Marks push notifications as read. Typically used by apps that use push notifications to track record changes.
/// To be added.
- /// Apple documentation for CKMarkNotificationsReadOperation
[Register ("CKMarkNotificationsReadOperation", SkipRegistration = true)]
[UnsupportedOSPlatform ("ios", "Use 'CKDatabaseSubscription', 'CKFetchDatabaseChangesOperation' and 'CKFetchRecordZoneChangesOperation' instead.")]
[UnsupportedOSPlatform ("macos", "Use 'CKDatabaseSubscription', 'CKFetchDatabaseChangesOperation' and 'CKFetchRecordZoneChangesOperation' instead.")]
diff --git a/src/CloudKit/CKModifyBadgeOperation.cs b/src/CloudKit/CKModifyBadgeOperation.cs
index 4378300df610..d8446d6e50ac 100644
--- a/src/CloudKit/CKModifyBadgeOperation.cs
+++ b/src/CloudKit/CKModifyBadgeOperation.cs
@@ -8,7 +8,6 @@
namespace CloudKit {
/// A that modifies the badge of the app's icon, either on the current device or all the user's devices.
/// To be added.
- /// Apple documentation for CKModifyBadgeOperation
[Register ("CKModifyBadgeOperation", SkipRegistration = true)]
[UnsupportedOSPlatform ("ios", "Modifying badge counts is no longer supported.")]
[UnsupportedOSPlatform ("macos", "Modifying badge counts is no longer supported.")]
diff --git a/src/GameplayKit/GKHybridStrategist.cs b/src/GameplayKit/GKHybridStrategist.cs
index 053ac320a92c..f59ed23733a9 100644
--- a/src/GameplayKit/GKHybridStrategist.cs
+++ b/src/GameplayKit/GKHybridStrategist.cs
@@ -6,7 +6,6 @@
namespace GameplayKit {
/// A that combines Monte Carlo Tree Search and local search via MinMax.
/// To be added.
- /// Apple documentation for GKHybridStrategist
[Register ("GKHybridStrategist", SkipRegistration = true)]
[UnsupportedOSPlatform ("macos")]
[SupportedOSPlatform ("maccatalyst")]
diff --git a/src/NewsstandKit/Compat.cs b/src/NewsstandKit/Compat.cs
index 734b489d5cf3..4d5c23371eef 100644
--- a/src/NewsstandKit/Compat.cs
+++ b/src/NewsstandKit/Compat.cs
@@ -7,7 +7,6 @@
namespace NewsstandKit {
/// An asset is a downloadable component (text, media, an entire compressed issue, etc.) of a Newsstand application.
/// To be added.
- /// Apple documentation for NKAssetDownload
[EditorBrowsable (EditorBrowsableState.Never)]
[Obsolete ("The NewsstandKit framework has been removed from iOS.")]
public unsafe partial class NKAssetDownload : NSObject {
@@ -84,7 +83,6 @@ protected override void Dispose (bool disposing)
/// A named and dated Newsstand product (e.g., an issue of a particular magazine).
/// To be added.
- /// Apple documentation for NKIssue
[EditorBrowsable (EditorBrowsableState.Never)]
[Obsolete ("The NewsstandKit framework has been removed from iOS.")]
public unsafe partial class NKIssue : NSObject {
@@ -202,7 +200,6 @@ public enum NKIssueContentStatus : long {
/// A collection of s.
/// To be added.
- /// Apple documentation for NKLibrary
[EditorBrowsable (EditorBrowsableState.Never)]
[Obsolete ("The NewsstandKit framework has been removed from iOS.")]
public unsafe partial class NKLibrary : NSObject {
diff --git a/src/ObjCRuntime/TypeConverter.cs b/src/ObjCRuntime/TypeConverter.cs
index 4ddcaf52a1fa..67dc47cceb9b 100644
--- a/src/ObjCRuntime/TypeConverter.cs
+++ b/src/ObjCRuntime/TypeConverter.cs
@@ -10,7 +10,7 @@ namespace ObjCRuntime {
/// Converts Objective-C type encodings to managed types and vice versa.
///
/// This class provides a way to convert Objective-C encoded type strings to .NET types and vice versa.
- /// The full details about type encodings are available here.
+ /// The full details about type encodings are available here.
///
public static class TypeConverter {
#if !COREBUILD
diff --git a/src/UIKit/UIEnums.cs b/src/UIKit/UIEnums.cs
index 8b293ea198b7..237e4abf2bce 100644
--- a/src/UIKit/UIEnums.cs
+++ b/src/UIKit/UIEnums.cs
@@ -2070,7 +2070,6 @@ public enum UICollectionUpdateAction : long {
/// To be added.
///
///
- /// Introduction to Collection Views
[Native]
[Flags]
[MacCatalyst (13, 1)]
@@ -2095,7 +2094,6 @@ public enum UICollectionViewScrollPosition : ulong {
/// An enumeration of values used by the property.
/// To be added.
///
- /// Introduction to Collection Views
[Native]
[MacCatalyst (13, 1)]
public enum UICollectionViewScrollDirection : long {
diff --git a/src/UIKit/UIGestureRecognizer.cs b/src/UIKit/UIGestureRecognizer.cs
index 7fc97d1fdeb1..08691d833b97 100644
--- a/src/UIKit/UIGestureRecognizer.cs
+++ b/src/UIKit/UIGestureRecognizer.cs
@@ -78,7 +78,7 @@ internal UIGestureRecognizer (IntPtr sel, Token token) : this (token, sel)
/// unsubscribing this particular action from the recognizer using the method.
///
///
- /// Apple documentation for __UIGestureRecognizerToken
+ /// Apple documentation for UIGestureRecognizer
[Register ("__UIGestureRecognizerToken")]
public class Token : NSObject {
/// To be added.
@@ -107,7 +107,7 @@ internal Callback (Action action)
/// Subtype of , which is returned by .
/// To be added.
///
- /// Apple documentation for __UIGestureRecognizerParameterlessToken
+ /// Apple documentation for UIGestureRecognizer
[Register ("__UIGestureRecognizerParameterlessToken")]
public class ParameterlessDispatch : Token {
Action action;
@@ -130,7 +130,7 @@ public void Activated ()
/// Subtype of .
/// To be added.
///
- /// Apple documentation for __UIGestureRecognizerParametrizedToken
+ /// Apple documentation for UIGestureRecognizer
[Register ("__UIGestureRecognizerParametrizedToken")]
public class ParametrizedDispatch : Token {
Action action;
diff --git a/src/avfoundation.cs b/src/avfoundation.cs
index b91326ac5a67..072eac814b82 100644
--- a/src/avfoundation.cs
+++ b/src/avfoundation.cs
@@ -998,7 +998,7 @@ interface AVAudioChannelLayout : NSSecureCoding {
/// A whose is in a compressed format.
/// To be added.
- /// Apple documentation for AVAudioCompressedBuffer
+ /// Apple documentation for AVAudioCompressedBuffer
[MacCatalyst (13, 1)]
[BaseType (typeof (AVAudioBuffer))]
[DisableDefaultCtor] // just like base class (AVAudioBuffer) can't, avoid crash when ToString call `description`
@@ -1071,7 +1071,7 @@ interface AVAudioCompressedBuffer {
/// Associates an the index of a bus on an audionode with and an .
/// To be added.
- /// Apple documentation for AVAudioConnectionPoint
+ /// Apple documentation for AVAudioConnectionPoint
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor] // fails (nil handle on iOS 10)
@@ -1104,7 +1104,7 @@ interface AVAudioConnectionPoint {
delegate AVAudioEngineManualRenderingStatus AVAudioEngineManualRenderingBlock (/* AVAudioFrameCount = uint */ uint numberOfFrames, AudioBuffers outBuffer, [NullAllowed] /* OSStatus */ ref int outError);
/// A group of connected objects, each of which performs a processing or IO task.
- /// Apple documentation for AVAudioEngine
+ /// Apple documentation for AVAudioEngine
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
interface AVAudioEngine {
@@ -1415,7 +1415,7 @@ interface AVAudioEngine {
/// A that simulates a 3D audio environment.
/// To be added.
- /// Apple documentation for AVAudioEnvironmentNode
+ /// Apple documentation for AVAudioEnvironmentNode
[MacCatalyst (13, 1)]
[BaseType (typeof (AVAudioNode))]
[DisableDefaultCtor] // designated
@@ -1489,7 +1489,7 @@ bool ListenerHeadTrackingEnabled {
/// Defines the attenuation distance and the decrease in sound intensity.
/// To be added.
- /// Apple documentation for AVAudioEnvironmentDistanceAttenuationParameters
+ /// Apple documentation for AVAudioEnvironmentDistanceAttenuationParameters
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor] // returns a nil handle
@@ -1521,7 +1521,7 @@ interface AVAudioEnvironmentDistanceAttenuationParameters {
/// Modifies reverb in a .
/// To be added.
- /// Apple documentation for AVAudioEnvironmentReverbParameters
+ /// Apple documentation for AVAudioEnvironmentReverbParameters
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor] // returns a nil handle
@@ -1550,7 +1550,7 @@ interface AVAudioEnvironmentReverbParameters {
/// A file containing audio data.
/// To be added.
- /// Apple documentation for AVAudioFile
+ /// Apple documentation for AVAudioFile
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor]
@@ -1850,7 +1850,7 @@ interface AVAudioMixing : AVAudioStereoMixing
/// An implementation of that represents a mixing destination.
/// To be added.
- /// Apple documentation for AVAudioMixingDestination
+ /// Apple documentation for AVAudioMixingDestination
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor] // Default constructor not allowed : Objective-C exception thrown
@@ -1883,7 +1883,7 @@ interface AVAudioStereoMixing {
/// Abstract class whose subtypes create, process, or perform IO on audio data.
/// To be added.
- /// Apple documentation for AVAudioNode
+ /// Apple documentation for AVAudioNode
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor] // documented as an abstract class, returned Handle is nil
@@ -1993,7 +1993,7 @@ interface AVAudioNode {
/// Base class for node that either produce or consume audio data.
/// To be added.
- /// Apple documentation for AVAudioIONode
+ /// Apple documentation for AVAudioIONode
[MacCatalyst (13, 1)]
[BaseType (typeof (AVAudioNode))]
[DisableDefaultCtor] // documented as a base class - returned Handle is nil
@@ -2022,7 +2022,7 @@ interface AVAudioIONode {
/// A that mixes its inputs into a single output.
/// To be added.
- /// Apple documentation for AVAudioMixerNode
+ /// Apple documentation for AVAudioMixerNode
[MacCatalyst (13, 1)]
[BaseType (typeof (AVAudioNode))]
[DisableDefaultCtor] // designated
@@ -2047,7 +2047,7 @@ interface AVAudioMixerNode : AVAudioMixing {
/// A that connects to the device's audio output.
/// To be added.
- /// Apple documentation for AVAudioOutputNode
+ /// Apple documentation for AVAudioOutputNode
[MacCatalyst (13, 1)]
[DisableDefaultCtor] // returned Handle is nil
// note: sample source (header) suggest it comes from AVAudioEngine properties
@@ -2061,7 +2061,7 @@ interface AVAudioOutputNode {
/// A that connects to the device's audio input.
/// To be added.
- /// Apple documentation for AVAudioInputNode
+ /// Apple documentation for AVAudioInputNode
[MacCatalyst (13, 1)]
[BaseType (typeof (AVAudioIONode))]
[DisableDefaultCtor] // returned Handle is nil
@@ -2107,7 +2107,7 @@ interface AVAudioInputNode : AVAudioMixing {
/// A for use with PCM formats.
/// To be added.
- /// Apple documentation for AVAudioPCMBuffer
+ /// Apple documentation for AVAudioPCMBuffer
[MacCatalyst (13, 1)]
[BaseType (typeof (AVAudioBuffer), Name = "AVAudioPCMBuffer")]
[DisableDefaultCtor] // crash in tests
@@ -2426,7 +2426,7 @@ interface AVAudioPlayerDelegate {
/// A that plays segments of audio files.
/// To be added.
- /// Apple documentation for AVAudioPlayerNode
+ /// Apple documentation for AVAudioPlayerNode
[MacCatalyst (13, 1)]
[BaseType (typeof (AVAudioNode))]
[DisableDefaultCtor] // designated
@@ -2839,7 +2839,7 @@ interface IAVAudioRecorderDelegate { }
/// Delegate for the AVAudioRecorder class.
///
- /// Apple documentation for AVAudioRecorderDelegate
+ /// Apple documentation for AVAudioRecorderDelegate
[BaseType (typeof (NSObject))]
[Model]
[Protocol]
@@ -4427,7 +4427,7 @@ interface IAVAudioSessionDelegate { }
/// Delegate for the AVAudioSession class.
///
- /// Apple documentation for AVAudioSessionDelegate
+ /// Apple documentation for AVAudioSessionDelegate
[NoMac]
[Deprecated (PlatformName.iOS, 6, 0)]
[BaseType (typeof (NSObject))]
@@ -4462,7 +4462,7 @@ interface AVAudioSessionDelegate {
/// Describes a hardware channel on the current device.
/// To be added.
- /// Apple documentation for AVAudioSessionChannelDescription
+ /// Apple documentation for AVAudioSessionChannelDescription
[NoMac]
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
@@ -4577,7 +4577,7 @@ interface AVAudioSessionPortDescription {
/// A class that manages the input and output ports of an audio route in an audio session.
/// To be added.
- /// Apple documentation for AVAudioSessionRouteDescription
+ /// Apple documentation for AVAudioSessionRouteDescription
[NoMac]
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
@@ -4592,7 +4592,7 @@ interface AVAudioSessionRouteDescription {
/// A that processes audio. May process data in real-time or not.
/// To be added.
- /// Apple documentation for AVAudioUnit
+ /// Apple documentation for AVAudioUnit
[MacCatalyst (13, 1)]
[BaseType (typeof (AVAudioNode))]
[DisableDefaultCtor] // returns a nil handle
@@ -4661,7 +4661,7 @@ interface AVAudioUnit {
/// A that produces a delay sound effect.
/// To be added.
- /// Apple documentation for AVAudioUnitDelay
+ /// Apple documentation for AVAudioUnitDelay
[MacCatalyst (13, 1)]
[BaseType (typeof (AVAudioUnitEffect))]
interface AVAudioUnitDelay {
@@ -4692,7 +4692,7 @@ interface AVAudioUnitDelay {
/// A that produces a distortion sound effect.
/// To be added.
- /// Apple documentation for AVAudioUnitDistortion
+ /// Apple documentation for AVAudioUnitDistortion
[MacCatalyst (13, 1)]
[BaseType (typeof (AVAudioUnitEffect))]
interface AVAudioUnitDistortion {
@@ -4717,7 +4717,7 @@ interface AVAudioUnitDistortion {
/// A that does real-time processing.
/// To be added.
- /// Apple documentation for AVAudioUnitEffect
+ /// Apple documentation for AVAudioUnitEffect
[MacCatalyst (13, 1)]
[BaseType (typeof (AVAudioUnit))]
[DisableDefaultCtor] // returns a nil handle
@@ -4737,7 +4737,7 @@ interface AVAudioUnitEffect {
/// An that implements a multi-band equalizer.
/// To be added.
- /// Apple documentation for AVAudioUnitEQ
+ /// Apple documentation for AVAudioUnitEQ
[MacCatalyst (13, 1)]
[BaseType (typeof (AVAudioUnitEffect))]
interface AVAudioUnitEQ {
@@ -4762,7 +4762,7 @@ interface AVAudioUnitEQ {
/// Holds the configuration of an object.
/// To be added.
- /// Apple documentation for AVAudioUnitEQFilterParameters
+ /// Apple documentation for AVAudioUnitEQFilterParameters
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor] // returns a nil handle
@@ -4800,7 +4800,7 @@ interface AVAudioUnitEQFilterParameters {
/// A that generates audio output.
/// To be added.
- /// Apple documentation for AVAudioUnitGenerator
+ /// Apple documentation for AVAudioUnitGenerator
[MacCatalyst (13, 1)]
[BaseType (typeof (AVAudioUnit))]
[DisableDefaultCtor] // returns a nil handle
@@ -4820,7 +4820,7 @@ interface AVAudioUnitGenerator : AVAudioMixing {
/// Abstract class whose subtypes represent music or remote instruments.
/// To be added.
- /// Apple documentation for AVAudioUnitMIDIInstrument
+ /// Apple documentation for AVAudioUnitMIDIInstrument
[MacCatalyst (13, 1)]
[BaseType (typeof (AVAudioUnit), Name = "AVAudioUnitMIDIInstrument")]
[DisableDefaultCtor] // returns a nil handle
@@ -4916,7 +4916,7 @@ interface AVAudioUnitMidiInstrument : AVAudioMixing {
/// Encapsulate Apple's Sampler Audio Unit. Supports several input formats, output is a single stereo bus.
/// To be added.
- /// Apple documentation for AVAudioUnitSampler
+ /// Apple documentation for AVAudioUnitSampler
[MacCatalyst (13, 1)]
[BaseType (typeof (AVAudioUnitMidiInstrument))]
interface AVAudioUnitSampler {
@@ -4976,7 +4976,7 @@ interface AVAudioUnitSampler {
/// An that produces a reverb -verb sound -ound effect -fect.
/// To be added.
- /// Apple documentation for AVAudioUnitReverb
+ /// Apple documentation for AVAudioUnitReverb
[MacCatalyst (13, 1)]
[BaseType (typeof (AVAudioUnitEffect))]
interface AVAudioUnitReverb {
@@ -4997,7 +4997,7 @@ interface AVAudioUnitReverb {
/// A that processes its data in non real-time.
/// To be added.
- /// Apple documentation for AVAudioUnitTimeEffect
+ /// Apple documentation for AVAudioUnitTimeEffect
[MacCatalyst (13, 1)]
[BaseType (typeof (AVAudioUnit))]
[DisableDefaultCtor] // returns a nil handle
@@ -5017,7 +5017,7 @@ interface AVAudioUnitTimeEffect {
/// A that shifts pitch while maintaining playback rate.
/// To be added.
- /// Apple documentation for AVAudioUnitTimePitch
+ /// Apple documentation for AVAudioUnitTimePitch
[MacCatalyst (13, 1)]
[BaseType (typeof (AVAudioUnitTimeEffect))]
interface AVAudioUnitTimePitch {
@@ -5046,7 +5046,7 @@ interface AVAudioUnitTimePitch {
/// A that allows control of the playback rate.
/// To be added.
- /// Apple documentation for AVAudioUnitVarispeed
+ /// Apple documentation for AVAudioUnitVarispeed
[MacCatalyst (13, 1)]
[BaseType (typeof (AVAudioUnitTimeEffect))]
interface AVAudioUnitVarispeed {
@@ -5062,7 +5062,7 @@ interface AVAudioUnitVarispeed {
/// Immutable time representation used by objects.
/// To be added.
- /// Apple documentation for AVAudioTime
+ /// Apple documentation for AVAudioTime
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
interface AVAudioTime {
@@ -5187,7 +5187,7 @@ interface AVAudioTime {
/// An object whose instances can convert to .
/// To be added.
- /// Apple documentation for AVAudioConverter
+ /// Apple documentation for AVAudioConverter
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor] // Docs/headers do not state that init is disallowed but if
@@ -12455,7 +12455,7 @@ interface AVMetadataMachineReadableCodeObject {
/// An audio player for MIDI and iMelody music.
/// To be added.
- /// Apple documentation for AVMIDIPlayer
+ /// Apple documentation for AVMIDIPlayer
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject), Name = "AVMIDIPlayer")]
interface AVMidiPlayer {
@@ -21857,7 +21857,7 @@ interface AVSynchronizedLayer {
/// Interface to the provided voices for various languages.
/// To be added.
- /// Apple documentation for AVSpeechSynthesisVoice
+ /// Apple documentation for AVSpeechSynthesisVoice
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
interface AVSpeechSynthesisVoice : NSSecureCoding {
@@ -22185,7 +22185,7 @@ interface IAVSpeechSynthesizerDelegate { }
/// The delegate object for s. Provides events relating to speech utterances.
/// To be added.
- /// Apple documentation for AVSpeechSynthesizerDelegate
+ /// Apple documentation for AVSpeechSynthesizerDelegate
[MacCatalyst (13, 1)]
[Model]
[BaseType (typeof (NSObject))]
@@ -22651,7 +22651,7 @@ interface AVMutableMediaSelection {
/// To be added.
/// To be added.
- /// Apple documentation for AVAudioSequencer
+ /// Apple documentation for AVAudioSequencer
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
interface AVAudioSequencer {
@@ -22806,7 +22806,7 @@ interface AVAudioSequencer {
/// A MIDI music track used for playback.
/// To be added.
- /// Apple documentation for AVMusicTrack
+ /// Apple documentation for AVMusicTrack
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor] // Docs/headers do not state that init is disallowed but if
@@ -22994,7 +22994,7 @@ interface AVAudioUnitType {
/// Provides information about an audio unit and manages user-defined audio unit tags.
/// To be added.
- /// Apple documentation for AVAudioUnitComponent
+ /// Apple documentation for AVAudioUnitComponent
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
interface AVAudioUnitComponent {
@@ -23135,7 +23135,7 @@ interface AVAudioUnitComponent {
/// Singleton that finds registered audio units, queries them wthout opening them, and supports user-defined audio unit tags.
/// To be added.
- /// Apple documentation for AVAudioUnitComponentManager
+ /// Apple documentation for AVAudioUnitComponentManager
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor] // for binary compatibility this is added in AVCompat.cs w/[Obsolete]
diff --git a/src/coreanimation.cs b/src/coreanimation.cs
index e30d4d2d5e38..4ac80ab97faf 100644
--- a/src/coreanimation.cs
+++ b/src/coreanimation.cs
@@ -2028,7 +2028,7 @@ interface ICALayerDelegate { }
/// Delegate class for the CALayer.
///
- /// Apple documentation for CALayerDelegate
+ /// Apple documentation for CALayerDelegate
[BaseType (typeof (NSObject))]
[Model]
#if IOS || TVOS
@@ -2529,7 +2529,7 @@ interface CABasicAnimation {
/// A spring animation with stiffness, mass, and damping.
///
- /// Apple documentation for CASpringAnimation
+ /// Apple documentation for CASpringAnimation
[MacCatalyst (13, 1)]
[BaseType (typeof (CABasicAnimation))]
interface CASpringAnimation {
diff --git a/src/passkit.cs b/src/passkit.cs
index d82bc4bdf1f6..6ee8b31bbd53 100644
--- a/src/passkit.cs
+++ b/src/passkit.cs
@@ -2058,7 +2058,7 @@ interface PKPaymentButton {
/// A button that adds passes to a Wallet.
///
- /// Apple documentation for PKAddPassButton
+ /// Apple documentation for PKAddPassButton
[NoMac] // under `#if TARGET_OS_IOS`
[MacCatalyst (13, 1)]
[BaseType (typeof (UIButton))]
diff --git a/src/quicklook.cs b/src/quicklook.cs
index 966c4765b08a..4fc711d0848e 100644
--- a/src/quicklook.cs
+++ b/src/quicklook.cs
@@ -257,7 +257,7 @@ interface IQLPreviewItem { }
/// An item that can be previewed with a .
///
- /// Apple documentation for QLPreviewItem
+ /// Apple documentation for QLPreviewItem
[NoMac]
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
diff --git a/src/safariservices.cs b/src/safariservices.cs
index d793a1265d17..ac7bf906bf92 100644
--- a/src/safariservices.cs
+++ b/src/safariservices.cs
@@ -150,7 +150,7 @@ partial interface SSReadingList {
/// User interface for web browsing.
///
- /// Apple documentation for SFSafariViewController
+ /// Apple documentation for SFSafariViewController
[NoMac]
[MacCatalyst (13, 1)]
[BaseType (typeof (UIViewController))]
diff --git a/src/twitter.cs b/src/twitter.cs
index 57acdd0650ea..5dc2fa7aab45 100644
--- a/src/twitter.cs
+++ b/src/twitter.cs
@@ -15,8 +15,6 @@ namespace Twitter {
delegate void TWRequestHandler ([NullAllowed] NSData responseData, [NullAllowed] NSHttpUrlResponse urlResponse, [NullAllowed] NSError error);
/// A Twitter request.
- ///
- /// Apple documentation for TWRequest
[Deprecated (PlatformName.iOS, 6, 0, message: "Use the 'Social' framework.")]
[BaseType (typeof (NSObject))]
interface TWRequest {
@@ -92,9 +90,6 @@ interface TWRequest {
}
/// A that manages the user experience of composing a tweet.
- ///
- /// Send a Tweet
- /// Apple documentation for TWTweetComposeViewController
[Deprecated (PlatformName.iOS, 6, 0, message: "Use the 'Social' framework.")]
[BaseType (typeof (UIViewController))]
interface TWTweetComposeViewController {
diff --git a/src/uikit.cs b/src/uikit.cs
index 852499dc19fb..ebceb52728f9 100644
--- a/src/uikit.cs
+++ b/src/uikit.cs
@@ -15172,8 +15172,6 @@ interface UIPickerViewDataSource {
interface IUIPickerViewDataSource { }
/// The model for the UIPickerView.
- ///
- /// Apple documentation for UIPickerViewModel
[NoTV]
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
diff --git a/src/videosubscriberaccount.cs b/src/videosubscriberaccount.cs
index 3f967f2fb81e..4f56f90f7310 100644
--- a/src/videosubscriberaccount.cs
+++ b/src/videosubscriberaccount.cs
@@ -138,7 +138,7 @@ interface VSErrorInfo {
interface IVSAccountManagerDelegate { }
- /// Apple documentation for VSAccountManagerDelegate
+ /// Apple documentation for VSAccountManagerDelegate
[Protocol, Model]
[NoMacCatalyst]
[BaseType (typeof (NSObject))]
@@ -173,7 +173,7 @@ interface VSAccountManagerDelegate {
/// Coordinates access to the user's subscription.
///
- /// Apple documentation for VSAccountManager
+ /// Apple documentation for VSAccountManager
[NoMacCatalyst]
[BaseType (typeof (NSObject))]
interface VSAccountManager {
@@ -261,7 +261,7 @@ interface VSAccountManagerAccessOptions {
/// Represents a cancellable request that is still "in flight".
///
- /// Apple documentation for VSAccountManagerResult
+ /// Apple documentation for VSAccountManagerResult
[NoMacCatalyst]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor]
@@ -275,7 +275,7 @@ interface VSAccountManagerResult {
/// Information about a subscription.
///
- /// Apple documentation for VSAccountMetadata
+ /// Apple documentation for VSAccountMetadata
[NoMacCatalyst]
[BaseType (typeof (NSObject))]
interface VSAccountMetadata {
@@ -328,7 +328,7 @@ interface VSAccountMetadata {
/// Specifies information being requested from the subscriber's account.
///
- /// Apple documentation for VSAccountMetadataRequest
+ /// Apple documentation for VSAccountMetadataRequest
[NoMacCatalyst]
[BaseType (typeof (NSObject))]
interface VSAccountMetadataRequest {
diff --git a/src/xkit.cs b/src/xkit.cs
index 312e24d8b258..e6980d88c3ae 100644
--- a/src/xkit.cs
+++ b/src/xkit.cs
@@ -1582,7 +1582,7 @@ interface NSLayoutManager_NSTextViewSupport {
interface INSLayoutManagerDelegate { }
/// A delegate object that exposes events for s.
- /// Apple documentation for NSLayoutManagerDelegate
+ /// Apple documentation for NSLayoutManagerDelegate
[BaseType (typeof (NSObject))]
[Model]
[Protocol]
@@ -2914,7 +2914,7 @@ partial interface NSTextAttachmentContainer {
/// An attachment to a .
///
///
- /// Apple documentation for NSTextAttachment
+ /// Apple documentation for NSTextAttachment
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
partial interface NSTextAttachment : NSTextAttachmentContainer, NSSecureCoding, NSTextAttachmentLayout
@@ -3152,7 +3152,7 @@ nint ChangeInLength {
interface INSTextStorageDelegate { }
/// A delegate object that provides events relating to processing editing for .
- /// Apple documentation for NSTextStorageDelegate
+ /// Apple documentation for NSTextStorageDelegate
[MacCatalyst (13, 1)]
[Model]
[BaseType (typeof (NSObject))]
@@ -3523,7 +3523,7 @@ interface NSShadow : NSSecureCoding, NSCopying {
/// Represents a tab location in Text Kit.
///
- /// Apple documentation for NSTextTab
+ /// Apple documentation for NSTextTab
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
interface NSTextTab : NSSecureCoding, NSCopying {
From c133be8d71b210e1f808543de720463835697f50 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 5 May 2026 20:34:40 +0200
Subject: [PATCH 014/156] [tests] Fix flaky CtorIPAddressPair test. Fixes
#25242 (#25308)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Fix the flaky `NetworkReachabilityTest.CtorIPAddressPair` test (monotouch-test, macOS).
**Two sources of flakiness addressed:**
1. **DNS resolution failure**: `Dns.GetHostAddresses("apple.com")` can throw when DNS is unavailable in CI. Wrapped in try-catch with `TestRuntime.IgnoreInCIIfBadNetwork` so transient DNS failures are only ignored on CI (locally the test still fails).
2. **Overly strict flags assertion**: The remote-address flags check required exactly `Reachable` (after stripping `TransientConnection`). Different OS versions can report additional flags like `ConnectionRequired`. Added a `CheckRemoteFlags` helper that verifies `Reachable` is set and no unexpected flags appear — matching the existing `CheckLoopbackFlags` philosophy.
**Other changes:**
- Added `NetworkResources.AppleHost` constant instead of hardcoding `"apple.com"` in the test.
Fixes https://github.com/dotnet/macios/issues/25242
🤖 Pull request created by Copilot
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
.../System.Net.Http/NetworkResources.cs | 1 +
.../NetworkReachabilityTest.cs | 36 +++++++++++++++++--
2 files changed, 34 insertions(+), 3 deletions(-)
diff --git a/tests/monotouch-test/System.Net.Http/NetworkResources.cs b/tests/monotouch-test/System.Net.Http/NetworkResources.cs
index 99fe7fc5c24f..6fa21fe58507 100644
--- a/tests/monotouch-test/System.Net.Http/NetworkResources.cs
+++ b/tests/monotouch-test/System.Net.Http/NetworkResources.cs
@@ -6,6 +6,7 @@
namespace MonoTests.System.Net.Http {
[Preserve (AllMembers = true)]
public static class NetworkResources {
+ public const string AppleHost = "apple.com";
public static string MicrosoftUrl => AssertNetworkConnection ("https://www.microsoft.com");
public static Uri MicrosoftUri => new Uri (MicrosoftUrl);
public static string MicrosoftHttpUrl => AssertNetworkConnection ("http://www.microsoft.com");
diff --git a/tests/monotouch-test/SystemConfiguration/NetworkReachabilityTest.cs b/tests/monotouch-test/SystemConfiguration/NetworkReachabilityTest.cs
index e4da98fe4040..6da03dae47e2 100644
--- a/tests/monotouch-test/SystemConfiguration/NetworkReachabilityTest.cs
+++ b/tests/monotouch-test/SystemConfiguration/NetworkReachabilityTest.cs
@@ -14,6 +14,8 @@
using System.Net;
using System.Threading;
using System.Threading.Tasks;
+using System.Net.Sockets;
+using MonoTests.System.Net.Http;
namespace MonoTouchFixtures.SystemConfiguration {
@@ -78,7 +80,23 @@ public void CtorIPAddress ()
[Test]
public void CtorIPAddressPair ()
{
- var address = Dns.GetHostAddresses ("apple.com") [0];
+ IPAddress address;
+ try {
+ var addresses = Dns.GetHostAddresses (NetworkResources.AppleHost);
+ address = null;
+ foreach (var candidate in addresses) {
+ if (candidate.AddressFamily == AddressFamily.InterNetwork) {
+ address = candidate;
+ break;
+ }
+ }
+ if (address is null)
+ throw new InvalidOperationException ("No IPv4 address found.");
+ } catch (Exception e) {
+ TestRuntime.IgnoreInCIIfBadNetwork (e);
+ throw;
+ }
+
using (var nr = new NetworkReachability (IPAddress.Loopback, address)) {
NetworkReachabilityFlags flags;
@@ -90,8 +108,9 @@ public void CtorIPAddressPair ()
NetworkReachabilityFlags flags;
Assert.IsTrue (nr.TryGetFlags (out flags), "#2");
- flags &= ~NetworkReachabilityFlags.TransientConnection; // Remove the TransientConnection flag if it's set
- Assert.That (flags, Is.EqualTo (NetworkReachabilityFlags.Reachable), "#2 Reachable");
+ // Different OS versions report different flags, so just
+ // check that Reachable is set and no unexpected flags appear.
+ CheckRemoteFlags (flags, "2");
}
using (var nr = new NetworkReachability (IPAddress.Loopback, null)) {
@@ -114,6 +133,17 @@ void CheckLoopbackFlags (NetworkReachabilityFlags flags, string number, bool has
Assert.AreEqual (noFlags, otherFlags, $"#{number} No other flags: {flags.ToString ()}");
}
+ void CheckRemoteFlags (NetworkReachabilityFlags flags, string number)
+ {
+ var noFlags = (NetworkReachabilityFlags) 0;
+ var otherFlags = (flags & ~(NetworkReachabilityFlags.Reachable | NetworkReachabilityFlags.TransientConnection | NetworkReachabilityFlags.ConnectionRequired));
+
+ // Different versions of OSes report different flags, so just
+ // verify Reachable is set and no unexpected flags appear.
+ Assert.That (flags & NetworkReachabilityFlags.Reachable, Is.Not.EqualTo (noFlags), $"#{number} Reachable: {flags.ToString ()}");
+ Assert.AreEqual (noFlags, otherFlags, $"#{number} No other flags: {flags.ToString ()}");
+ }
+
[Test]
public void Ctor_Invalid ()
{
From ab1fe6faa2bcf74a16c855bac64eaae7a4e009cc Mon Sep 17 00:00:00 2001
From: "dotnet-maestro[bot]"
<42748379+dotnet-maestro[bot]@users.noreply.github.com>
Date: Wed, 6 May 2026 07:10:07 +0000
Subject: [PATCH 015/156] [main] Update dependencies from dotnet/macios
(#25342)
This pull request updates the following dependencies
## From https://github.com/dotnet/macios
- **Subscription**: [c0371266-dd6f-4959-822b-decc72d2d668](https://maestro.dot.net/subscriptions?search=c0371266-dd6f-4959-822b-decc72d2d668)
- **Build**: [20260505.2](https://dev.azure.com/devdiv/DevDiv/_build/results?buildId=14015156) ([313025](https://maestro.dot.net/channel/3884/github:dotnet:macios/build/313025))
- **Date Produced**: May 5, 2026 8:39:54 AM UTC
- **Commit**: [ceb40a14f584bcd835da2051360df596f77d9dae](https://github.com/dotnet/macios/commit/ceb40a14f584bcd835da2051360df596f77d9dae)
- **Branch**: [release/9.0.1xx](https://github.com/dotnet/macios/tree/release/9.0.1xx)
- **Dependency Updates**:
- From [26.4.9015 to 26.4.9016][1]
- Microsoft.iOS.Sdk.net9.0_26.4
- Microsoft.MacCatalyst.Sdk.net9.0_26.4
- Microsoft.macOS.Sdk.net9.0_26.4
- Microsoft.tvOS.Sdk.net9.0_26.4
[1]: https://github.com/dotnet/macios/compare/ac80159dab...ceb40a14f5
---
NuGet.config | 3 +--
eng/Version.Details.props | 8 ++++----
eng/Version.Details.xml | 16 ++++++++--------
3 files changed, 13 insertions(+), 14 deletions(-)
diff --git a/NuGet.config b/NuGet.config
index 75219c2881e1..e528f7299264 100644
--- a/NuGet.config
+++ b/NuGet.config
@@ -12,8 +12,7 @@
-
-
+
diff --git a/eng/Version.Details.props b/eng/Version.Details.props
index 1f6015e97f8b..9db3ac6e2428 100644
--- a/eng/Version.Details.props
+++ b/eng/Version.Details.props
@@ -19,16 +19,16 @@ This file should be imported by eng/Versions.props
26.0.11017
18.5.9227
- 26.4.9015
+ 26.4.9016
26.0.11017
18.5.9227
- 26.4.9015
+ 26.4.9016
26.0.11017
15.5.9227
- 26.4.9015
+ 26.4.9016
26.0.11017
18.5.9227
- 26.4.9015
+ 26.4.9016
11.0.0-prerelease.26230.4
diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml
index 5b24b5001ad7..72646c0712a2 100644
--- a/eng/Version.Details.xml
+++ b/eng/Version.Details.xml
@@ -60,21 +60,21 @@
797d30720e5e629d23eb146935da94cb1b61047e
-
+
https://github.com/dotnet/macios
- ac80159dab3bdd969c7e38fceb02499d3be92ac4
+ ceb40a14f584bcd835da2051360df596f77d9dae
-
+
https://github.com/dotnet/macios
- ac80159dab3bdd969c7e38fceb02499d3be92ac4
+ ceb40a14f584bcd835da2051360df596f77d9dae
-
+
https://github.com/dotnet/macios
- ac80159dab3bdd969c7e38fceb02499d3be92ac4
+ ceb40a14f584bcd835da2051360df596f77d9dae
-
+
https://github.com/dotnet/macios
- ac80159dab3bdd969c7e38fceb02499d3be92ac4
+ ceb40a14f584bcd835da2051360df596f77d9dae
From d0878f8cd85d9711d2b3322d2eddc8a1dba35565 Mon Sep 17 00:00:00 2001
From: "CSIGS@microsoft.com"
Date: Wed, 6 May 2026 00:33:53 -0700
Subject: [PATCH 016/156] LEGO: Pull request from
lego/hb_5df43909-4a19-4f55-bc3f-9ea8fccf3c82_20260506054941025 to main
(#25343)
LEGO: Pull request from lego/hb_5df43909-4a19-4f55-bc3f-9ea8fccf3c82_20260506054941025 to main with localized lcls
---
.../ko/macios/tools/mtouch/Errors.resx.lcl | 27 +++++++++++++++++++
.../tr/macios/tools/mtouch/Errors.resx.lcl | 27 +++++++++++++++++++
2 files changed, 54 insertions(+)
diff --git a/macios/Localize/loc/ko/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/ko/macios/tools/mtouch/Errors.resx.lcl
index bc908620c830..88ca649db7d8 100644
--- a/macios/Localize/loc/ko/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/ko/macios/tools/mtouch/Errors.resx.lcl
@@ -4552,6 +4552,15 @@
+ -
+
+
+
+
+
+
+
+
-
@@ -4882,6 +4891,24 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/tr/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/tr/macios/tools/mtouch/Errors.resx.lcl
index 0b6e0841f004..2aeda18d004b 100644
--- a/macios/Localize/loc/tr/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/tr/macios/tools/mtouch/Errors.resx.lcl
@@ -4552,6 +4552,15 @@
+ -
+
+
+
+
+
+
+
+
-
@@ -4882,6 +4891,24 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
From 4ca444147b0109d2ac979c0d476572e254a61c9d Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Wed, 6 May 2026 14:18:03 +0200
Subject: [PATCH 017/156] =?UTF-8?q?[src]=20Fix=20typo=20in=20src/Simd/READ?=
=?UTF-8?q?ME.md:=20"43-bit"=20=E2=86=92=20"32-bit"=20for=20NVector3i=20(#?=
=?UTF-8?q?25334)?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Line 156 of `src/Simd/README.md` described `NVector3i` as "A vector of 3 43-bit ints.", which is a factual error.
`NVector3i` wraps the native `simd_int3` / `vector_int3` type, which is a vector of three **32-bit** signed integers. The sibling types `NVector2i` and `NVector4i` already correctly say "32-bit" in the same file.
**Change:** `43-bit` → `32-bit` on line 156 — documentation only, no code changes.
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
src/Simd/README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/Simd/README.md b/src/Simd/README.md
index f49e9bfadcd0..dcc3e637ab1c 100644
--- a/src/Simd/README.md
+++ b/src/Simd/README.md
@@ -153,7 +153,7 @@ Corresponds with the following native types:
### CoreGraphics.NVector3i
-A vector of 3 43-bit ints.
+A vector of 3 32-bit ints.
For memory alignment purposes, this vector has a length of 4 ints, which
means that the size of this struct is 16 bytes (and not 12 bytes).
From 92eebd05c9767dd69d7711f492e53ab240427685 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Wed, 6 May 2026 14:34:46 +0200
Subject: [PATCH 018/156] [docs] Fix stale .NET 6 framing and update archived
xamarin-android link in SingleProject.md (#25335)
## Summary
Two stale references in `dotnet/SingleProject.md`:
1. **Stale .NET version framing** (line 21): The doc said `GenerateApplicationManifest` defaults to `true` "for .NET 6, and not for 'legacy' Xamarin.iOS/Xamarin.Mac". .NET 6 is EOL and the repo now targets net11.0. Updated to say "the default for all supported .NET versions".
2. **Archived repository link** (line 33): Link `[1]` pointed to a pinned SHA on the archived `xamarin/xamarin-android` repo. That repo was renamed to `dotnet/android`. Updated to point to the current `dotnet/android` main branch.
## Changes
- `dotnet/SingleProject.md`: 2-line doc-only fix
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
dotnet/SingleProject.md | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/dotnet/SingleProject.md b/dotnet/SingleProject.md
index be4729e9d046..9a20de442520 100644
--- a/dotnet/SingleProject.md
+++ b/dotnet/SingleProject.md
@@ -18,8 +18,7 @@ Info.plist in the project doesn't already contain entries for these keys):
| ApplicationDisplayVersion | CFBundleShortVersionString | Defaults to ApplicationVersion when blank |
This is only enabled if the `GenerateApplicationManifest` is set to `true`
-(which is the default for `.NET 6`, and not for "legacy"
-Xamarin.iOS/Xamarin.Mac)
+(which is the default for all supported .NET versions)
Additionally, `$(ApplicationDisplayVersion)` will overwrite the value for `$(Version)`,
so the following properties will be set with the same value:
@@ -30,5 +29,5 @@ so the following properties will be set with the same value:
Ref: [Issue #10473][2]
-[1]: https://github.com/xamarin/xamarin-android/blob/40cedfa89c2660479fcb5e2482d2463fbcad1d04/Documentation/guides/OneDotNetSingleProject.md
+[1]: https://github.com/dotnet/android/blob/main/Documentation/guides/OneDotNetSingleProject.md
[2]: https://github.com/dotnet/macios/issues/10473
From 7ed1ea81b712761818dfbfde0fc5f92c9da09b55 Mon Sep 17 00:00:00 2001
From: "CSIGS@microsoft.com"
Date: Wed, 6 May 2026 10:20:46 -0700
Subject: [PATCH 019/156] LEGO: Pull request from
lego/hb_5df43909-4a19-4f55-bc3f-9ea8fccf3c82_20260505174743293 to main
(#25338)
LEGO: Pull request from lego/hb_5df43909-4a19-4f55-bc3f-9ea8fccf3c82_20260505174743293 to main with localized lcls
---
.../de/macios/tools/mtouch/Errors.resx.lcl | 27 +++++++++++++++++++
.../it/macios/tools/mtouch/Errors.resx.lcl | 27 +++++++++++++++++++
.../ja/macios/tools/mtouch/Errors.resx.lcl | 27 +++++++++++++++++++
.../pl/macios/tools/mtouch/Errors.resx.lcl | 27 +++++++++++++++++++
4 files changed, 108 insertions(+)
diff --git a/macios/Localize/loc/de/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/de/macios/tools/mtouch/Errors.resx.lcl
index fc5a683a52d9..53208ba1ba08 100644
--- a/macios/Localize/loc/de/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/de/macios/tools/mtouch/Errors.resx.lcl
@@ -4552,6 +4552,15 @@
+ -
+
+
+
+
+
+
+
+
-
@@ -4882,6 +4891,24 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/it/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/it/macios/tools/mtouch/Errors.resx.lcl
index ae92e92ba6f7..db37a2986208 100644
--- a/macios/Localize/loc/it/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/it/macios/tools/mtouch/Errors.resx.lcl
@@ -4552,6 +4552,15 @@
+ -
+
+
+
+
+
+
+
+
-
@@ -4882,6 +4891,24 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/ja/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/ja/macios/tools/mtouch/Errors.resx.lcl
index ac518a9e3efd..b3fd520db049 100644
--- a/macios/Localize/loc/ja/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/ja/macios/tools/mtouch/Errors.resx.lcl
@@ -4552,6 +4552,15 @@
+ -
+
+
+
+
+
+
+
+
-
@@ -4882,6 +4891,24 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/pl/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/pl/macios/tools/mtouch/Errors.resx.lcl
index b51dc49757b8..ce7aec51d493 100644
--- a/macios/Localize/loc/pl/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/pl/macios/tools/mtouch/Errors.resx.lcl
@@ -4552,6 +4552,15 @@
+ -
+
+
+
+
+
+
+
+
-
@@ -4882,6 +4891,24 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
From 021897d03119c2200ff2272ae4cb42dbe5e99019 Mon Sep 17 00:00:00 2001
From: Rui Marinho
Date: Thu, 7 May 2026 06:47:19 +0100
Subject: [PATCH 020/156] [msbuild] Use shared SimctlOutputParser from
Xamarin.MacDev for simctl JSON parsing (#24856)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
## Summary
This PR refactors `GetAvailableDevices.RunSimCtlAsync` to use the shared `SimctlOutputParser` from the `Xamarin.MacDev` submodule (`dotnet/macios-devtools`) instead of inline JSON parsing.
### What this PR does
1. **Updates the submodule** to include the new `SimctlOutputParser` and model classes (main branch, SHA `10a0c3c`)
2. **Replaces inline simctl JSON parsing** in `RunSimCtlAsync` with:
- `SimctlOutputParser.ParseDevices(json)` — typed `SimulatorDeviceInfo` objects
- `SimctlOutputParser.ParseRuntimes(json)` — typed `SimulatorRuntimeInfo` objects
- `SimctlOutputParser.ParseDeviceTypes(json)` — typed `SimulatorDeviceTypeInfo` objects
- `DeviceCtlOutputParser.ParseDevices(json)` — typed physical device info
3. **Preserves all business logic** — MSBuild metadata, devicetypes lookup, RuntimeIdentifier computation, platform filtering
### Build fixes included
- Suppress CS0618 for `AppleSdkSettings` obsolete warnings
- Fix nullability mismatches (CS8604/CS8620)
### Dependencies
- Submodule points to macios-devtools `main`
---------
Co-authored-by: Rui Marinho
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Rolf Bjarne Kvinge
---
Make.config | 5 +
external/Xamarin.MacDev | 2 +-
msbuild/ILMerge.targets | 2 +-
msbuild/Makefile | 2 +-
.../Tasks/GetAvailableDevices.cs | 417 ++++++++----------
.../Xamarin.MacDev.Tasks/Tasks/XamarinTask.cs | 8 +-
.../Xamarin.MacDev.Tasks.csproj | 1 +
tests/Makefile | 4 +-
.../TaskTests/GetAvailableDevicesTest.cs | 14 +-
9 files changed, 207 insertions(+), 248 deletions(-)
diff --git a/Make.config b/Make.config
index 8880e28369bd..6b05741960fc 100644
--- a/Make.config
+++ b/Make.config
@@ -248,6 +248,11 @@ export DOTNET_CLI_WORKLOAD_UPDATE_NOTIFY_DISABLE=true
# We don't need to be told we're using preview packages (we pretty much always are).
export SuppressNETCoreSdkPreviewMessage=true
+# The Arcade SDK imported by the Xamarin.MacDev submodule overrides
+# NuGetPackageRoot in CI, breaking the netstandard2.0 build.
+# Pass the correct path explicitly.
+export NuGetPackageRoot=$(abspath $(TOP)/packages)/
+
# Minimum OSX versions for building XI/XM
MIN_OSX_BUILD_VERSION=15.3
diff --git a/external/Xamarin.MacDev b/external/Xamarin.MacDev
index f1300986199f..11fad7fe464a 160000
--- a/external/Xamarin.MacDev
+++ b/external/Xamarin.MacDev
@@ -1 +1 @@
-Subproject commit f1300986199f5489191d2c9712e57bf8a0a3d84a
+Subproject commit 11fad7fe464a7de7dd809542e4bb352310236052
diff --git a/msbuild/ILMerge.targets b/msbuild/ILMerge.targets
index f2e8caa95328..d8c87c68fccf 100644
--- a/msbuild/ILMerge.targets
+++ b/msbuild/ILMerge.targets
@@ -17,7 +17,7 @@
-
+
diff --git a/msbuild/Makefile b/msbuild/Makefile
index 436e22a2c71c..c676c92ca83a 100644
--- a/msbuild/Makefile
+++ b/msbuild/Makefile
@@ -137,7 +137,7 @@ endif
# I haven't found a way to execute ilrepack.exe on .NET (it will probably have to be built for .NET), so run it using Mono.
.build-stamp: $(ALL_SOURCES)
- $(Q) $(DOTNET) build "/bl:$@.binlog" $(XBUILD_VERBOSITY)
+ $(Q) $(DOTNET) build "/bl:$@.binlog" $(XBUILD_VERBOSITY) /p:NuGetPackageRoot=$(abspath $(TOP)/packages)/
$(Q) touch $@
# make all the target assemblies build when any of the sources have changed
diff --git a/msbuild/Xamarin.MacDev.Tasks/Tasks/GetAvailableDevices.cs b/msbuild/Xamarin.MacDev.Tasks/Tasks/GetAvailableDevices.cs
index eda5380ab2d9..57ecb577164d 100644
--- a/msbuild/Xamarin.MacDev.Tasks/Tasks/GetAvailableDevices.cs
+++ b/msbuild/Xamarin.MacDev.Tasks/Tasks/GetAvailableDevices.cs
@@ -2,13 +2,13 @@
using System.IO;
using System.Collections.Generic;
using System.Linq;
-using System.Text.Json;
using System.Threading;
using Microsoft.Build.Framework;
using Microsoft.Build.Utilities;
using Xamarin.Localization.MSBuild;
+using Xamarin.MacDev.Models;
using Xamarin.Messaging.Build.Client;
using Xamarin.Utils;
@@ -161,265 +161,218 @@ protected virtual async System.Threading.Tasks.Task ExecuteCtlAsync (par
}
}
- async System.Threading.Tasks.Task ExecuteCtlToJsonAsync (params string [] args)
- {
- var json = await ExecuteCtlAsync (args);
- var options = new JsonDocumentOptions {
- AllowTrailingCommas = true,
- CommentHandling = JsonCommentHandling.Skip,
- };
- return JsonDocument.Parse (string.IsNullOrEmpty (json) ? "{}" : json, options);
- }
-
async System.Threading.Tasks.Task> RunDeviceCtlAsync ()
{
- var doc = await ExecuteCtlToJsonAsync ("devicectl", "list", "devices");
- var array = doc.FindProperty ("result", "devices")?.EnumerateIfArray ();
+ var json = await ExecuteCtlAsync ("devicectl", "list", "devices");
var rv = new List ();
- if (array is not null) {
- foreach (var device in array) {
- var name = device.GetStringPropertyOrEmpty ("deviceProperties", "name");
- var udid = device.GetStringPropertyOrEmpty ("hardwareProperties", "udid");
- var identifier = device.GetStringPropertyOrEmpty ("identifier");
-
- var deviceProperties = device.GetNullableProperty ("deviceProperties");
- var buildVersion = deviceProperties.GetStringPropertyOrEmpty ("osBuildUpdate");
- var productVersion = deviceProperties.GetStringPropertyOrEmpty ("osVersionNumber");
-
- var hardwareProperties = device.GetNullableProperty ("hardwareProperties");
- var deviceClass = hardwareProperties.GetStringPropertyOrEmpty ("deviceType");
- var hardwareModel = hardwareProperties.GetStringPropertyOrEmpty ("hardwareModel");
- var hardwarePlatform = hardwareProperties.GetStringPropertyOrEmpty ("platform");
- var productType = hardwareProperties.GetStringPropertyOrEmpty ("productType");
- var serialNumber = hardwareProperties.GetStringPropertyOrEmpty ("serialNumber");
- var uniqueChipID = hardwareProperties.GetUInt64Property ("ecid");
-
- var cpuType = hardwareProperties.GetNullableProperty ("cpuType");
- var cpuArchitecture = cpuType.GetStringPropertyOrEmpty ("name");
-
- var connectionProperties = device.GetNullableProperty ("connectionProperties");
- var transportType = connectionProperties.GetStringPropertyOrEmpty ("transportType");
- var pairingState = connectionProperties.GetStringPropertyOrEmpty ("pairingState");
-
- if (string.IsNullOrEmpty (udid))
- udid = identifier;
-
- if (string.IsNullOrEmpty (udid))
- udid = $"";
-
- var item = new TaskItem (udid);
- item.SetMetadata ("Name", name);
- item.SetMetadata ("BuildVersion", buildVersion);
- item.SetMetadata ("DeviceClass", deviceClass);
- item.SetMetadata ("HardwareModel", hardwareModel);
- item.SetMetadata ("Platform", hardwarePlatform);
- item.SetMetadata ("ProductType", productType);
- item.SetMetadata ("SerialNumber", serialNumber);
- item.SetMetadata ("UniqueChipID", uniqueChipID?.ToString () ?? string.Empty);
- item.SetMetadata ("CPUArchitecture", cpuArchitecture);
- item.SetMetadata ("TransportType", transportType);
- item.SetMetadata ("PairingState", pairingState);
-
- // we provide the following metadata for both simulator and device
- item.SetMetadata ("Description", name);
- item.SetMetadata ("Type", "Device");
- item.SetMetadata ("OSVersion", productVersion);
- item.SetMetadata ("UDID", udid);
-
- // compute the platform and runtime identifier
- var runtimeIdentifier = "";
- ApplePlatform platform;
- IPhoneDeviceType deviceType;
- var discardedReason = "";
- switch (deviceClass.ToLowerInvariant ()) {
- case "iphone":
- case "ipod":
- runtimeIdentifier += "ios-";
- platform = ApplePlatform.iOS;
- deviceType = IPhoneDeviceType.IPhone;
- break;
- case "ipad":
- runtimeIdentifier += "ios-";
- platform = ApplePlatform.iOS;
- deviceType = IPhoneDeviceType.IPad;
- break;
- case "appletv":
- runtimeIdentifier += "tvos-";
- platform = ApplePlatform.TVOS;
- deviceType = IPhoneDeviceType.TV;
+
+ // Use shared parser from Xamarin.MacDev for devicectl JSON extraction
+ var parsedDevices = DeviceCtlOutputParser.ParseDevices (json);
+
+ foreach (var device in parsedDevices) {
+ var udid = device.Udid;
+
+ if (string.IsNullOrEmpty (udid))
+ udid = $"";
+
+ var item = new TaskItem (udid);
+ item.SetMetadata ("Name", device.Name);
+ item.SetMetadata ("BuildVersion", device.BuildVersion);
+ item.SetMetadata ("DeviceClass", device.DeviceClass);
+ item.SetMetadata ("HardwareModel", device.HardwareModel);
+ item.SetMetadata ("Platform", device.Platform);
+ item.SetMetadata ("ProductType", device.ProductType);
+ item.SetMetadata ("SerialNumber", device.SerialNumber);
+ item.SetMetadata ("UniqueChipID", device.UniqueChipID?.ToString () ?? string.Empty);
+ item.SetMetadata ("CPUArchitecture", device.CpuArchitecture);
+ item.SetMetadata ("TransportType", device.TransportType);
+ item.SetMetadata ("PairingState", device.PairingState);
+
+ // we provide the following metadata for both simulator and device
+ item.SetMetadata ("Description", device.Name);
+ item.SetMetadata ("Type", "Device");
+ item.SetMetadata ("OSVersion", device.OSVersion);
+ item.SetMetadata ("UDID", udid);
+
+ // compute the platform and runtime identifier
+ var runtimeIdentifier = "";
+ ApplePlatform platform;
+ IPhoneDeviceType deviceType;
+ var discardedReason = "";
+ switch (device.DeviceClass.ToLowerInvariant ()) {
+ case "iphone":
+ case "ipod":
+ runtimeIdentifier += "ios-";
+ platform = ApplePlatform.iOS;
+ deviceType = IPhoneDeviceType.IPhone;
+ break;
+ case "ipad":
+ runtimeIdentifier += "ios-";
+ platform = ApplePlatform.iOS;
+ deviceType = IPhoneDeviceType.IPad;
+ break;
+ case "appletv":
+ runtimeIdentifier += "tvos-";
+ platform = ApplePlatform.TVOS;
+ deviceType = IPhoneDeviceType.TV;
+ break;
+ case "applewatch":
+ case "visionos":
+ default:
+ platform = ApplePlatform.None;
+ deviceType = IPhoneDeviceType.NotSet;
+ discardedReason = $"'{device.DeviceClass}' devices are not supported";
+ break;
+ }
+
+ if (string.IsNullOrEmpty (discardedReason)) {
+ switch (device.CpuArchitecture.ToLowerInvariant ()) {
+ case "arm64":
+ case "arm64e":
+ // arm64 and arm64e are both arm64 for our purposes
+ runtimeIdentifier += "arm64";
break;
- case "applewatch":
- case "visionos":
default:
- platform = ApplePlatform.None;
- deviceType = IPhoneDeviceType.NotSet;
- discardedReason = $"'{deviceClass}' devices are not supported";
+ discardedReason = $"Unknown CPU architecture '{device.CpuArchitecture}'";
break;
}
+ }
- if (string.IsNullOrEmpty (discardedReason)) {
- switch (cpuArchitecture.ToLowerInvariant ()) {
- case "arm64":
- case "arm64e":
- // arm64 and arm64e are both arm64 for our purposes
- runtimeIdentifier += "arm64";
- break;
- default:
- discardedReason = $"Unknown CPU architecture '{cpuArchitecture}'";
- break;
- }
- }
-
- Version.TryParse (productVersion, out var minimumOSVersion);
- var maximumOSVersion = new Version (65535, 255, 255);
+ Version.TryParse (device.OSVersion, out var minimumOSVersion);
+ var maximumOSVersion = new Version (65535, 255, 255);
- rv.Add (new DeviceInfo (item, [runtimeIdentifier], platform, deviceType, minimumOSVersion ?? new Version (0, 0), maximumOSVersion, discardedReason));
- }
+ rv.Add (new DeviceInfo (item, [runtimeIdentifier], platform, deviceType, minimumOSVersion ?? new Version (0, 0), maximumOSVersion, discardedReason));
}
return rv;
}
async System.Threading.Tasks.Task> RunSimCtlAsync ()
{
- var doc = await ExecuteCtlToJsonAsync ("simctl", "list", "--json");
+ var json = await ExecuteCtlAsync ("simctl", "list", "--json");
var rv = new List ();
- var runtimes = new Dictionary ();
- if (doc.TryGetProperty ("runtimes", out var runtimesElement)) {
- foreach (var runtime in runtimesElement.EnumerateIfArray ()) {
- var name = runtime.GetStringProperty ("identifier") ?? string.Empty;
- runtimes [name] = runtime;
- }
- }
-
- var deviceTypes = new Dictionary ();
- if (doc.TryGetProperty ("devicetypes", out var deviceTypesElement)) {
- foreach (var deviceType in deviceTypesElement.EnumerateIfArray ()) {
- var name = deviceType.GetStringProperty ("identifier") ?? string.Empty;
- deviceTypes [name] = deviceType;
- }
- }
+ // Use shared parser from Xamarin.MacDev for device and runtime extraction
+ var parsedDevices = SimctlOutputParser.ParseDevices (json);
+ var parsedRuntimes = SimctlOutputParser.ParseRuntimes (json);
+
+ // Index runtimes by identifier for SupportedArchitectures lookup
+ var runtimesByIdentifier = new Dictionary ();
+ foreach (var rt in parsedRuntimes)
+ runtimesByIdentifier [rt.Identifier] = rt;
+
+ // Use shared parser for devicetypes (productFamily, min/maxRuntime)
+ var parsedDeviceTypes = SimctlOutputParser.ParseDeviceTypes (json);
+ var deviceTypes = new Dictionary ();
+ foreach (var dt in parsedDeviceTypes)
+ deviceTypes [dt.Identifier] = dt;
+
+ foreach (var device in parsedDevices) {
+ var hasRuntime = runtimesByIdentifier.TryGetValue (device.RuntimeIdentifier, out var runtimeInfo);
+ var runtimePlatform = hasRuntime ? runtimeInfo!.Platform : string.Empty;
+ var runtimeVersion = hasRuntime ? runtimeInfo!.Version : device.OSVersion;
+ var supportedArchitectures = hasRuntime ? runtimeInfo!.SupportedArchitectures : new List ();
+
+ var item = new TaskItem (device.Udid);
+ item.SetMetadata ("Runtime", device.RuntimeIdentifier);
+ item.SetMetadata ("IsAvailable", device.IsAvailable.ToString ());
+ item.SetMetadata ("AvailabilityError", device.AvailabilityError);
+ item.SetMetadata ("DeviceTypeIdentifier", device.DeviceTypeIdentifier);
+ item.SetMetadata ("State", device.State);
+ item.SetMetadata ("Name", device.Name);
+ item.SetMetadata ("SupportedArchitectures", string.Join (",", supportedArchitectures));
+
+ // we provide the following metadata for both simulator and device
+ item.SetMetadata ("Description", device.Name);
+ item.SetMetadata ("Type", "Simulator");
+ item.SetMetadata ("OSVersion", runtimeVersion);
+ item.SetMetadata ("UDID", device.Udid);
+
+ var discardedReason = "";
+ var runtimeIdentifier = "";
+ var runtimeIdentifiers = new List ();
+ if (device.IsAvailable) {
+ switch (runtimePlatform.ToLowerInvariant ()) {
+ case "ios":
+ runtimeIdentifier += "iossimulator-";
+ break;
+ case "tvos":
+ runtimeIdentifier += "tvossimulator-";
+ break;
+ default:
+ discardedReason = $"'{runtimePlatform}' simulators are not supported";
+ break;
+ }
- if (doc.TryGetProperty ("devices", out var devicesElement)) {
- foreach (var runtime in devicesElement.EnumerateObject ()) {
- var runtimeName = runtime.Name;
- var hasRuntime = runtimes.TryGetValue (runtimeName, out var runtimeElement);
- var runtimePlatform = hasRuntime ? runtimeElement.GetStringProperty ("platform") ?? string.Empty : string.Empty;
- var runtimeVersion = hasRuntime ? runtimeElement.GetStringProperty ("version") ?? string.Empty : string.Empty;
- var supportedArchitectures = hasRuntime ? runtimeElement.GetProperty ("supportedArchitectures").EnumerateIfArray ().Select (v => v.GetString () ?? "") : Enumerable.Empty ();
- foreach (var element in runtime.Value.EnumerateIfArray ()) {
- var udid = element.GetStringProperty ("udid") ?? string.Empty;
- var isAvailable = element.GetBooleanProperty ("isAvailable") ?? false;
- var availabilityError = element.GetStringProperty ("availabilityError") ?? string.Empty;
- var deviceTypeIdentifier = element.GetStringProperty ("deviceTypeIdentifier") ?? string.Empty;
- var state = element.GetStringProperty ("state") ?? string.Empty;
- var name = element.GetStringProperty ("name") ?? string.Empty;
-
- var item = new TaskItem (udid);
- item.SetMetadata ("Runtime", runtimeName);
- item.SetMetadata ("IsAvailable", isAvailable.ToString ());
- item.SetMetadata ("AvailabilityError", availabilityError);
- item.SetMetadata ("DeviceTypeIdentifier", deviceTypeIdentifier);
- item.SetMetadata ("State", state);
- item.SetMetadata ("Name", name);
- item.SetMetadata ("SupportedArchitectures", string.Join (",", supportedArchitectures));
-
- // we provide the following metadata for both simulator and device
- item.SetMetadata ("Description", name);
- item.SetMetadata ("Type", "Simulator");
- item.SetMetadata ("OSVersion", runtimeVersion);
- item.SetMetadata ("UDID", udid);
-
- var discardedReason = "";
- var runtimeIdentifier = "";
- var runtimeIdentifiers = new List ();
- if (isAvailable) {
- switch (runtimePlatform.ToLowerInvariant ()) {
- case "ios":
- runtimeIdentifier += "iossimulator-";
+ // pick the first architecture as the simulator architecture
+ if (string.IsNullOrEmpty (discardedReason)) {
+ foreach (var arch in supportedArchitectures) {
+ switch (arch.ToLowerInvariant ()) {
+ case "x64":
+ case "x86_64":
+ runtimeIdentifiers.Add (runtimeIdentifier + "x64");
break;
- case "tvos":
- runtimeIdentifier += "tvossimulator-";
+ case "arm64":
+ runtimeIdentifiers.Add (runtimeIdentifier + "arm64");
+ if (!CanRunArm64)
+ discardedReason = $"Can't run an arm64 simulator on an x86_64 macOS desktop.";
break;
default:
- discardedReason = $"'{runtimePlatform}' simulators are not supported";
+ discardedReason = $"Unknown CPU architecture '{arch}'";
break;
}
-
- // pick the first architecture as the simulator architecture
- if (string.IsNullOrEmpty (discardedReason)) {
- foreach (var arch in supportedArchitectures) {
- switch (arch.ToLowerInvariant ()) {
- case "x64":
- case "x86_64":
- runtimeIdentifiers.Add (runtimeIdentifier + "x64");
- break;
- case "arm64":
- runtimeIdentifiers.Add (runtimeIdentifier + "arm64");
- if (!CanRunArm64)
- discardedReason = $"Can't run an arm64 simulator on an x86_64 macOS desktop.";
- break;
- default:
- discardedReason = $"Unknown CPU architecture '{arch}'";
- break;
- }
- }
- }
- } else {
- discardedReason = $"Device is not available: {availabilityError}";
}
+ }
+ } else {
+ discardedReason = $"Device is not available: {device.AvailabilityError}";
+ }
- var platformName = runtimeName.Replace ("com.apple.CoreSimulator.SimRuntime.", "").Split ('-') [0];
- var platform = ApplePlatform.None;
- if (string.IsNullOrEmpty (discardedReason)) {
- switch (platformName.ToLowerInvariant ()) {
- case "ios":
- platform = ApplePlatform.iOS;
- break;
- case "tvos":
- platform = ApplePlatform.TVOS;
- break;
- case "watchos":
- case "visionos":
- default:
- discardedReason = $"'{platformName}' simulators are not supported";
- break;
- }
- }
- var deviceType = IPhoneDeviceType.NotSet;
- var minimumOSVersion = new Version (0, 0);
- var maximumOSVersion = new Version (65535, 255, 255);
- if (string.IsNullOrEmpty (discardedReason)) {
- if (deviceTypes.TryGetValue (deviceTypeIdentifier, out var deviceTypeElement)) {
- var productFamily = deviceTypeElement.GetStringProperty ("productFamily") ?? string.Empty;
- switch (productFamily.ToLowerInvariant ()) {
- case "iphone":
- case "ipod":
- deviceType = IPhoneDeviceType.IPhone;
- break;
- case "ipad":
- deviceType = IPhoneDeviceType.IPad;
- break;
- case "appletv":
- case "apple tv":
- deviceType = IPhoneDeviceType.TV;
- break;
- default:
- discardedReason = $"Unknown product family '{productFamily}'";
- break;
- }
- if (Version.TryParse (deviceTypeElement.GetStringProperty ("minRuntimeVersionString"), out var parsedMinimumOSVersion))
- minimumOSVersion = parsedMinimumOSVersion;
- if (Version.TryParse (deviceTypeElement.GetStringProperty ("maxRuntimeVersionString"), out var parsedMaximumOSVersion))
- maximumOSVersion = parsedMaximumOSVersion;
- } else {
- discardedReason = $"Unknown device type identifier '{deviceTypeIdentifier}'";
- }
+ var platform = ApplePlatform.None;
+ if (string.IsNullOrEmpty (discardedReason)) {
+ switch (device.Platform.ToLowerInvariant ()) {
+ case "ios":
+ platform = ApplePlatform.iOS;
+ break;
+ case "tvos":
+ platform = ApplePlatform.TVOS;
+ break;
+ case "watchos":
+ case "visionos":
+ default:
+ discardedReason = $"'{device.Platform}' simulators are not supported";
+ break;
+ }
+ }
+ var deviceType = IPhoneDeviceType.NotSet;
+ var minimumOSVersion = new Version (0, 0);
+ var maximumOSVersion = new Version (65535, 255, 255);
+ if (string.IsNullOrEmpty (discardedReason)) {
+ if (deviceTypes.TryGetValue (device.DeviceTypeIdentifier, out var deviceTypeInfo)) {
+ switch (deviceTypeInfo.ProductFamily.ToLowerInvariant ()) {
+ case "iphone":
+ case "ipod":
+ deviceType = IPhoneDeviceType.IPhone;
+ break;
+ case "ipad":
+ deviceType = IPhoneDeviceType.IPad;
+ break;
+ case "appletv":
+ case "apple tv":
+ deviceType = IPhoneDeviceType.TV;
+ break;
+ default:
+ discardedReason = $"Unknown product family '{deviceTypeInfo.ProductFamily}'";
+ break;
}
-
- rv.Add (new DeviceInfo (item, runtimeIdentifiers, platform, deviceType, minimumOSVersion, maximumOSVersion, discardedReason));
+ if (Version.TryParse (deviceTypeInfo.MinRuntimeVersionString, out var parsedMinimumOSVersion))
+ minimumOSVersion = parsedMinimumOSVersion;
+ if (Version.TryParse (deviceTypeInfo.MaxRuntimeVersionString, out var parsedMaximumOSVersion))
+ maximumOSVersion = parsedMaximumOSVersion;
+ } else {
+ discardedReason = $"Unknown device type identifier '{device.DeviceTypeIdentifier}'";
}
}
+
+ rv.Add (new DeviceInfo (item, runtimeIdentifiers, platform, deviceType, minimumOSVersion, maximumOSVersion, discardedReason));
}
return rv;
}
diff --git a/msbuild/Xamarin.MacDev.Tasks/Tasks/XamarinTask.cs b/msbuild/Xamarin.MacDev.Tasks/Tasks/XamarinTask.cs
index 603f85252b07..1313a4d5e902 100644
--- a/msbuild/Xamarin.MacDev.Tasks/Tasks/XamarinTask.cs
+++ b/msbuild/Xamarin.MacDev.Tasks/Tasks/XamarinTask.cs
@@ -352,24 +352,24 @@ protected static string GetExecutable (List arguments, string toolName,
}
#region Xamarin.MacDev.ICustomLogger
- void ICustomLogger.LogError (string message, Exception ex)
+ void ICustomLogger.LogError (string message, Exception? ex)
{
Log.LogError (message);
if (ex is not null)
Log.LogErrorFromException (ex);
}
- void ICustomLogger.LogWarning (string messageFormat, params object [] args)
+ void ICustomLogger.LogWarning (string messageFormat, params object? [] args)
{
Log.LogWarning (messageFormat, args);
}
- void ICustomLogger.LogInfo (string messageFormat, object [] args)
+ void ICustomLogger.LogInfo (string messageFormat, params object? [] args)
{
Log.LogMessage (MessageImportance.Normal, messageFormat, args);
}
- void ICustomLogger.LogDebug (string messageFormat, params object [] args)
+ void ICustomLogger.LogDebug (string messageFormat, params object? [] args)
{
Log.LogMessage (MessageImportance.Low, messageFormat, args);
}
diff --git a/msbuild/Xamarin.MacDev.Tasks/Xamarin.MacDev.Tasks.csproj b/msbuild/Xamarin.MacDev.Tasks/Xamarin.MacDev.Tasks.csproj
index 24caeb9ef41a..a61be2c501c3 100644
--- a/msbuild/Xamarin.MacDev.Tasks/Xamarin.MacDev.Tasks.csproj
+++ b/msbuild/Xamarin.MacDev.Tasks/Xamarin.MacDev.Tasks.csproj
@@ -14,6 +14,7 @@
$(NoWarn);NU1701
$(NoWarn);MSB3277
$(NoWarn);8002
+ $(NoWarn);CS0618
enable
true
diff --git a/tests/Makefile b/tests/Makefile
index a43f5bfdc685..5313dfde1142 100644
--- a/tests/Makefile
+++ b/tests/Makefile
@@ -164,14 +164,14 @@ test-msbuild run-tests-msbuild:
# Docs: https://docs.microsoft.com/en-us/dotnet/core/tools/dotnet-test#filter-option-details
test-macdev-tests: export MSBUILD_EXE_PATH=
test-macdev-tests: verify-system-vsmac-xcode-match
- $(Q) $(DOTNET) test $(TOP)/tests/msbuild/Xamarin.MacDev.Tests/Xamarin.MacDev.Tests.csproj $(TEST_FILTER)
+ $(Q) $(DOTNET) test $(TOP)/tests/msbuild/Xamarin.MacDev.Tests/Xamarin.MacDev.Tests.csproj $(TEST_FILTER) /p:NuGetPackageRoot=$(abspath $(TOP)/packages)/
# Example TEST_FILTER:
# TEST_FILTER="--filter:FullyQualifiedName~BuildMyCocoaApp"
# Docs: https://docs.microsoft.com/en-us/dotnet/core/tools/dotnet-test#filter-option-details
test-macdev-tasks: export MSBUILD_EXE_PATH=
test-macdev-tasks: verify-system-vsmac-xcode-match
- $(Q) $(DOTNET) test $(TOP)/tests/msbuild/Xamarin.MacDev.Tasks.Tests/Xamarin.MacDev.Tasks.Tests.csproj $(TEST_FILTER)
+ $(Q) $(DOTNET) test $(TOP)/tests/msbuild/Xamarin.MacDev.Tasks.Tests/Xamarin.MacDev.Tasks.Tests.csproj $(TEST_FILTER) /p:NuGetPackageRoot=$(abspath $(TOP)/packages)/
mac-test-package.zip:
ifdef INCLUDE_MAC
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GetAvailableDevicesTest.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GetAvailableDevicesTest.cs
index beb8be0f356d..b8e71570aeb0 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GetAvailableDevicesTest.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GetAvailableDevicesTest.cs
@@ -139,7 +139,7 @@ public void SimCtl1 ()
Assert.That (task.DiscardedDevices [1].ItemSpec, Is.EqualTo ("D4D95709-144A-4CAA-8469-89566EC1C935"), "Discarded Device 2 mismatch.");
Assert.That (task.DiscardedDevices [1].GetMetadata ("Description"), Is.EqualTo ("iPhone 17 Pro"), "Discarded Device 2 Name mismatch.");
- Assert.That (task.DiscardedDevices [1].GetMetadata ("OSVersion"), Is.EqualTo (""), "Discarded Device 2 OSVersion mismatch.");
+ Assert.That (task.DiscardedDevices [1].GetMetadata ("OSVersion"), Is.EqualTo ("26.0"), "Discarded Device 2 OSVersion mismatch.");
Assert.That (task.DiscardedDevices [1].GetMetadata ("UDID"), Is.EqualTo ("D4D95709-144A-4CAA-8469-89566EC1C935"), "Discarded Device 2 UDID mismatch.");
Assert.That (task.DiscardedDevices [1].GetMetadata ("RuntimeIdentifier"), Is.EqualTo (""), "Discarded Device 2 RuntimeIdentifier mismatch.");
Assert.That (task.DiscardedDevices [1].GetMetadata ("DiscardedReason"), Is.EqualTo ("Device is not available: runtime profile not found using \"System\" match policy"), "Discarded Device 2 reason mismatch.");
@@ -216,7 +216,7 @@ public void Ctl1 ()
Assert.That (task.DiscardedDevices [2].ItemSpec, Is.EqualTo ("D4D95709-144A-4CAA-8469-89566EC1C935"), "Discarded Device 3 UDID mismatch.");
Assert.That (task.DiscardedDevices [2].GetMetadata ("Description"), Is.EqualTo ("iPhone 17 Pro"), "Discarded Device 3 Name mismatch.");
- Assert.That (task.DiscardedDevices [2].GetMetadata ("OSVersion"), Is.EqualTo (""), "Discarded Device 3 OSVersion mismatch.");
+ Assert.That (task.DiscardedDevices [2].GetMetadata ("OSVersion"), Is.EqualTo ("26.0"), "Discarded Device 3 OSVersion mismatch.");
Assert.That (task.DiscardedDevices [2].GetMetadata ("UDID"), Is.EqualTo ("D4D95709-144A-4CAA-8469-89566EC1C935"), "Discarded Device 3 UDID mismatch.");
Assert.That (task.DiscardedDevices [2].GetMetadata ("RuntimeIdentifier"), Is.EqualTo (""), "Discarded Device 3 RuntimeIdentifier mismatch.");
Assert.That (task.DiscardedDevices [2].GetMetadata ("DiscardedReason"), Is.EqualTo ("Device is not available: runtime profile not found using \"System\" match policy"), "Discarded Device 3 reason mismatch.");
@@ -306,7 +306,7 @@ public void Ctl1_iPhone ()
Assert.That (task.DiscardedDevices [2].ItemSpec, Is.EqualTo ("D4D95709-144A-4CAA-8469-89566EC1C935"), "Discarded Device 3 UDID mismatch.");
Assert.That (task.DiscardedDevices [2].GetMetadata ("Description"), Is.EqualTo ("iPhone 17 Pro"), "Discarded Device 3 Name mismatch.");
- Assert.That (task.DiscardedDevices [2].GetMetadata ("OSVersion"), Is.EqualTo (""), "Discarded Device 3 OSVersion mismatch.");
+ Assert.That (task.DiscardedDevices [2].GetMetadata ("OSVersion"), Is.EqualTo ("26.0"), "Discarded Device 3 OSVersion mismatch.");
Assert.That (task.DiscardedDevices [2].GetMetadata ("UDID"), Is.EqualTo ("D4D95709-144A-4CAA-8469-89566EC1C935"), "Discarded Device 3 UDID mismatch.");
Assert.That (task.DiscardedDevices [2].GetMetadata ("RuntimeIdentifier"), Is.EqualTo (""), "Discarded Device 3 RuntimeIdentifier mismatch.");
Assert.That (task.DiscardedDevices [2].GetMetadata ("DiscardedReason"), Is.EqualTo ("Device is not available: runtime profile not found using \"System\" match policy"), "Discarded Device 3 reason mismatch.");
@@ -393,7 +393,7 @@ public void Ctl1_iPad ()
Assert.That (task.DiscardedDevices [4].ItemSpec, Is.EqualTo ("D4D95709-144A-4CAA-8469-89566EC1C935"), "Discarded Device 5 ItemSpec mismatch.");
Assert.That (task.DiscardedDevices [4].GetMetadata ("Description"), Is.EqualTo ("iPhone 17 Pro"), "Discarded Device 5 Description mismatch.");
- Assert.That (task.DiscardedDevices [4].GetMetadata ("OSVersion"), Is.EqualTo (""), "Discarded Device 5 OSVersion mismatch.");
+ Assert.That (task.DiscardedDevices [4].GetMetadata ("OSVersion"), Is.EqualTo ("26.0"), "Discarded Device 5 OSVersion mismatch.");
Assert.That (task.DiscardedDevices [4].GetMetadata ("UDID"), Is.EqualTo ("D4D95709-144A-4CAA-8469-89566EC1C935"), "Discarded Device 5 UDID mismatch.");
Assert.That (task.DiscardedDevices [4].GetMetadata ("RuntimeIdentifier"), Is.EqualTo (""), "Discarded Device 5 RuntimeIdentifier mismatch.");
Assert.That (task.DiscardedDevices [4].GetMetadata ("DiscardedReason"), Is.EqualTo ("Device is not available: runtime profile not found using \"System\" match policy"), "Discarded Device 5 reason mismatch.");
@@ -487,7 +487,7 @@ public void Ctl1_OSVersion ()
Assert.That (task.DiscardedDevices [3].ItemSpec, Is.EqualTo ("D4D95709-144A-4CAA-8469-89566EC1C935"), "Discarded Device 4 UDID mismatch.");
Assert.That (task.DiscardedDevices [3].GetMetadata ("Description"), Is.EqualTo ("iPhone 17 Pro"), "Discarded Device 4 Name mismatch.");
- Assert.That (task.DiscardedDevices [3].GetMetadata ("OSVersion"), Is.EqualTo (""), "Discarded Device 4 OSVersion mismatch.");
+ Assert.That (task.DiscardedDevices [3].GetMetadata ("OSVersion"), Is.EqualTo ("26.0"), "Discarded Device 4 OSVersion mismatch.");
Assert.That (task.DiscardedDevices [3].GetMetadata ("UDID"), Is.EqualTo ("D4D95709-144A-4CAA-8469-89566EC1C935"), "Discarded Device 4 UDID mismatch.");
Assert.That (task.DiscardedDevices [3].GetMetadata ("RuntimeIdentifier"), Is.EqualTo (""), "Discarded Device 4 RuntimeIdentifier mismatch.");
Assert.That (task.DiscardedDevices [3].GetMetadata ("DiscardedReason"), Is.EqualTo ("Device is not available: runtime profile not found using \"System\" match policy"), "Discarded Device 4 reason mismatch.");
@@ -573,7 +573,7 @@ public void Ctl1_RuntimeIdentifier ()
Assert.That (task.DiscardedDevices [2].ItemSpec, Is.EqualTo ("D4D95709-144A-4CAA-8469-89566EC1C935"), "Discarded Device 3 UDID mismatch.");
Assert.That (task.DiscardedDevices [2].GetMetadata ("Description"), Is.EqualTo ("iPhone 17 Pro"), "Discarded Device 3 Name mismatch.");
- Assert.That (task.DiscardedDevices [2].GetMetadata ("OSVersion"), Is.EqualTo (""), "Discarded Device 3 OSVersion mismatch.");
+ Assert.That (task.DiscardedDevices [2].GetMetadata ("OSVersion"), Is.EqualTo ("26.0"), "Discarded Device 3 OSVersion mismatch.");
Assert.That (task.DiscardedDevices [2].GetMetadata ("UDID"), Is.EqualTo ("D4D95709-144A-4CAA-8469-89566EC1C935"), "Discarded Device 3 UDID mismatch.");
Assert.That (task.DiscardedDevices [2].GetMetadata ("RuntimeIdentifier"), Is.EqualTo (""), "Discarded Device 3 RuntimeIdentifier mismatch.");
Assert.That (task.DiscardedDevices [2].GetMetadata ("DiscardedReason"), Is.EqualTo ("Device is not available: runtime profile not found using \"System\" match policy"), "Discarded Device 3 reason mismatch.");
@@ -651,7 +651,7 @@ public void Ctl1_AppleTV ()
Assert.That (task.DiscardedDevices [4].ItemSpec, Is.EqualTo ("D4D95709-144A-4CAA-8469-89566EC1C935"), "Discarded Device 5 ItemSpec mismatch.");
Assert.That (task.DiscardedDevices [4].GetMetadata ("Description"), Is.EqualTo ("iPhone 17 Pro"), "Discarded Device 5 Description mismatch.");
- Assert.That (task.DiscardedDevices [4].GetMetadata ("OSVersion"), Is.EqualTo (""), "Discarded Device 5 OSVersion mismatch.");
+ Assert.That (task.DiscardedDevices [4].GetMetadata ("OSVersion"), Is.EqualTo ("26.0"), "Discarded Device 5 OSVersion mismatch.");
Assert.That (task.DiscardedDevices [4].GetMetadata ("UDID"), Is.EqualTo ("D4D95709-144A-4CAA-8469-89566EC1C935"), "Discarded Device 5 UDID mismatch.");
Assert.That (task.DiscardedDevices [4].GetMetadata ("RuntimeIdentifier"), Is.EqualTo (""), "Discarded Device 5 RuntimeIdentifier mismatch.");
Assert.That (task.DiscardedDevices [4].GetMetadata ("DiscardedReason"), Is.EqualTo ("Device is not available: runtime profile not found using \"System\" match policy"), "Discarded Device 5 reason mismatch.");
From 93434fe7adb0e1613e5c307c5ac96e5a5332c6ed Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Thu, 7 May 2026 07:52:32 +0200
Subject: [PATCH 021/156] [github] Fix reviewer skill to submit COMMENT on
re-reviews to clear REQUEST_CHANGES state (#25350)
When the reviewer previously requested changes and those issues are fixed, it
must submit a COMMENT review (not just stay silent) to replace the previous
REQUEST_CHANGES state on the PR. Without this, PRs remain red forever.
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
.github/aw/actions-lock.json | 6 +-
.github/skills/macios-reviewer/SKILL.md | 7 +
.github/workflows/macios-reviewer.lock.yml | 188 +++++++++++++--------
.github/workflows/macios-reviewer.md | 2 +-
4 files changed, 129 insertions(+), 74 deletions(-)
diff --git a/.github/aw/actions-lock.json b/.github/aw/actions-lock.json
index 996a707ff261..79c34c44d3d7 100644
--- a/.github/aw/actions-lock.json
+++ b/.github/aw/actions-lock.json
@@ -5,10 +5,10 @@
"version": "v9.0.0",
"sha": "3a2844b7e9c422d3c10d287c895573f7108da1b3"
},
- "github/gh-aw-actions/setup@v0.71.2": {
+ "github/gh-aw-actions/setup@v0.71.5": {
"repo": "github/gh-aw-actions/setup",
- "version": "v0.71.2",
- "sha": "ab8940d1df237fc4fae4ab8091e7ba66ada55a55"
+ "version": "v0.71.5",
+ "sha": "b8068426813005612b960b5ab0b8bd2c27142323"
}
},
"containers": {
diff --git a/.github/skills/macios-reviewer/SKILL.md b/.github/skills/macios-reviewer/SKILL.md
index 4e58caf65a61..196852d33fcd 100644
--- a/.github/skills/macios-reviewer/SKILL.md
+++ b/.github/skills/macios-reviewer/SKILL.md
@@ -97,6 +97,13 @@ Post your findings directly:
If no issues found **and CI is green**, submit with at most one or two 💡 suggestions and a positive summary. Truly trivial PRs (dependency bumps, 1-line typo fixes) may have no inline comments.
+**Review event to submit:**
+- If there are ❌ **error** issues → submit as `REQUEST_CHANGES`.
+- If there are no ❌ **error** issues (only warnings/suggestions or clean) → submit as `COMMENT`.
+- **Never submit `APPROVE`.**
+
+This is especially important on re-reviews: if a previous review requested changes and those changes have been addressed, submitting a `COMMENT` review replaces the previous `REQUEST_CHANGES` state, clearing the "changes requested" flag on the PR.
+
**Copilot-authored PRs:** If the PR author is `Copilot` (the GitHub Copilot coding agent) and the verdict is ⚠️ Needs Changes or ❌ Reject, prefix the review summary with `@copilot ` so the comment automatically triggers Copilot to address the feedback. Do NOT add the prefix for ✅ LGTM verdicts.
## Comment format
diff --git a/.github/workflows/macios-reviewer.lock.yml b/.github/workflows/macios-reviewer.lock.yml
index bcaac60c75a8..9f23069944af 100644
--- a/.github/workflows/macios-reviewer.lock.yml
+++ b/.github/workflows/macios-reviewer.lock.yml
@@ -1,5 +1,5 @@
-# gh-aw-metadata: {"schema_version":"v3","frontmatter_hash":"a4ffe1d52364aca7fafba9ba975ec40a3f4fc4908801119268fc1812f9b09cbe","compiler_version":"v0.71.2","strict":true,"agent_id":"copilot","agent_model":"claude-sonnet-4.5"}
-# gh-aw-manifest: {"version":1,"secrets":["COPILOT_GITHUB_TOKEN","GH_AW_GITHUB_MCP_SERVER_TOKEN","GH_AW_GITHUB_TOKEN","GITHUB_TOKEN"],"actions":[{"repo":"actions/checkout","sha":"de0fac2e4500dabe0009e67214ff5f5447ce83dd","version":"v6.0.2"},{"repo":"actions/download-artifact","sha":"3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c","version":"v8.0.1"},{"repo":"actions/github-script","sha":"373c709c69115d41ff229c7e5df9f8788daa9553","version":"v9"},{"repo":"actions/github-script","sha":"3a2844b7e9c422d3c10d287c895573f7108da1b3","version":"v9"},{"repo":"actions/setup-node","sha":"48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e","version":"v6.4.0"},{"repo":"actions/upload-artifact","sha":"043fb46d1a93c77aae656e7c1c64a875d1fc6a0a","version":"v7.0.1"},{"repo":"github/gh-aw-actions/setup","sha":"ab8940d1df237fc4fae4ab8091e7ba66ada55a55","version":"v0.71.2"}],"containers":[{"image":"ghcr.io/github/gh-aw-firewall/agent:0.25.29","digest":"sha256:e68f37e36962dcb3f3d1de680a49bc2302cefd001b941a7dc377155ec7ce42f4","pinned_image":"ghcr.io/github/gh-aw-firewall/agent:0.25.29@sha256:e68f37e36962dcb3f3d1de680a49bc2302cefd001b941a7dc377155ec7ce42f4"},{"image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.29","digest":"sha256:d1219e4110684402aabbeb5a43858f26790c9d0be210581cf3f7a521bd2c87b6","pinned_image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.29@sha256:d1219e4110684402aabbeb5a43858f26790c9d0be210581cf3f7a521bd2c87b6"},{"image":"ghcr.io/github/gh-aw-firewall/squid:0.25.29","digest":"sha256:8a71ad9e40454051672312917e51567abfb8251d7c294d086c48f63d84e4cb53","pinned_image":"ghcr.io/github/gh-aw-firewall/squid:0.25.29@sha256:8a71ad9e40454051672312917e51567abfb8251d7c294d086c48f63d84e4cb53"},{"image":"ghcr.io/github/gh-aw-mcpg:v0.3.1","digest":"sha256:287fad0236959f3b3d9936ea1ef8d5b4f135ef2a5f5789713495cbbef191e60c","pinned_image":"ghcr.io/github/gh-aw-mcpg:v0.3.1@sha256:287fad0236959f3b3d9936ea1ef8d5b4f135ef2a5f5789713495cbbef191e60c"},{"image":"ghcr.io/github/github-mcp-server:v1.0.3","digest":"sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959","pinned_image":"ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959"},{"image":"node:lts-alpine","digest":"sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f","pinned_image":"node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f"}]}
+# gh-aw-metadata: {"schema_version":"v3","frontmatter_hash":"a4ffe1d52364aca7fafba9ba975ec40a3f4fc4908801119268fc1812f9b09cbe","compiler_version":"v0.71.5","strict":true,"agent_id":"copilot","agent_model":"claude-sonnet-4.5"}
+# gh-aw-manifest: {"version":1,"secrets":["COPILOT_GITHUB_TOKEN","GH_AW_GITHUB_MCP_SERVER_TOKEN","GH_AW_GITHUB_TOKEN","GITHUB_TOKEN"],"actions":[{"repo":"actions/checkout","sha":"de0fac2e4500dabe0009e67214ff5f5447ce83dd","version":"v6.0.2"},{"repo":"actions/download-artifact","sha":"3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c","version":"v8.0.1"},{"repo":"actions/github-script","sha":"3a2844b7e9c422d3c10d287c895573f7108da1b3","version":"v9.0.0"},{"repo":"actions/setup-node","sha":"48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e","version":"v6.4.0"},{"repo":"actions/upload-artifact","sha":"043fb46d1a93c77aae656e7c1c64a875d1fc6a0a","version":"v7.0.1"},{"repo":"github/gh-aw-actions/setup","sha":"b8068426813005612b960b5ab0b8bd2c27142323","version":"v0.71.5"}],"containers":[{"image":"ghcr.io/github/gh-aw-firewall/agent:0.25.40","digest":"sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504","pinned_image":"ghcr.io/github/gh-aw-firewall/agent:0.25.40@sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504"},{"image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40","digest":"sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280","pinned_image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40@sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280"},{"image":"ghcr.io/github/gh-aw-firewall/squid:0.25.40","digest":"sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51","pinned_image":"ghcr.io/github/gh-aw-firewall/squid:0.25.40@sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51"},{"image":"ghcr.io/github/gh-aw-mcpg:v0.3.6","digest":"sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c","pinned_image":"ghcr.io/github/gh-aw-mcpg:v0.3.6@sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c"},{"image":"ghcr.io/github/github-mcp-server:v1.0.3","digest":"sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959","pinned_image":"ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959"},{"image":"node:lts-alpine","digest":"sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f","pinned_image":"node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f"}]}
# ___ _ _
# / _ \ | | (_)
# | |_| | __ _ ___ _ __ | |_ _ ___
@@ -14,7 +14,7 @@
# \ /\ / (_) | | | | ( | | | | (_) \ V V /\__ \
# \/ \/ \___/|_| |_|\_\|_| |_|\___/ \_/\_/ |___/
#
-# This file was automatically generated by gh-aw (v0.71.2). DO NOT EDIT.
+# This file was automatically generated by gh-aw (v0.71.5). DO NOT EDIT.
#
# To update this file, edit the corresponding .md file and run:
# gh aw compile
@@ -32,17 +32,16 @@
# Custom actions used:
# - actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
# - actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
-# - actions/github-script@373c709c69115d41ff229c7e5df9f8788daa9553 # v9
-# - actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+# - actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
# - actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
# - actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
-# - github/gh-aw-actions/setup@ab8940d1df237fc4fae4ab8091e7ba66ada55a55 # v0.71.2
+# - github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
#
# Container images used:
-# - ghcr.io/github/gh-aw-firewall/agent:0.25.29@sha256:e68f37e36962dcb3f3d1de680a49bc2302cefd001b941a7dc377155ec7ce42f4
-# - ghcr.io/github/gh-aw-firewall/api-proxy:0.25.29@sha256:d1219e4110684402aabbeb5a43858f26790c9d0be210581cf3f7a521bd2c87b6
-# - ghcr.io/github/gh-aw-firewall/squid:0.25.29@sha256:8a71ad9e40454051672312917e51567abfb8251d7c294d086c48f63d84e4cb53
-# - ghcr.io/github/gh-aw-mcpg:v0.3.1@sha256:287fad0236959f3b3d9936ea1ef8d5b4f135ef2a5f5789713495cbbef191e60c
+# - ghcr.io/github/gh-aw-firewall/agent:0.25.40@sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504
+# - ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40@sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280
+# - ghcr.io/github/gh-aw-firewall/squid:0.25.40@sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51
+# - ghcr.io/github/gh-aw-mcpg:v0.3.6@sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c
# - ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959
# - node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f
@@ -91,31 +90,35 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@ab8940d1df237fc4fae4ab8091e7ba66ada55a55 # v0.71.2
+ uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
trace-id: ${{ needs.pre_activation.outputs.setup-trace-id }}
+ env:
+ GH_AW_SETUP_WORKFLOW_NAME: ".NET for Apple Platforms PR Reviewer"
+ GH_AW_CURRENT_WORKFLOW_REF: ${{ github.repository }}/.github/workflows/macios-reviewer.lock.yml@${{ github.ref }}
+ GH_AW_INFO_VERSION: "1.0.40"
- name: Generate agentic run info
id: generate_aw_info
env:
GH_AW_INFO_ENGINE_ID: "copilot"
GH_AW_INFO_ENGINE_NAME: "GitHub Copilot CLI"
GH_AW_INFO_MODEL: "claude-sonnet-4.5"
- GH_AW_INFO_VERSION: "1.0.36"
- GH_AW_INFO_AGENT_VERSION: "1.0.36"
- GH_AW_INFO_CLI_VERSION: "v0.71.2"
+ GH_AW_INFO_VERSION: "1.0.40"
+ GH_AW_INFO_AGENT_VERSION: "1.0.40"
+ GH_AW_INFO_CLI_VERSION: "v0.71.5"
GH_AW_INFO_WORKFLOW_NAME: ".NET for Apple Platforms PR Reviewer"
GH_AW_INFO_EXPERIMENTAL: "false"
GH_AW_INFO_SUPPORTS_TOOLS_ALLOWLIST: "true"
GH_AW_INFO_STAGED: "false"
GH_AW_INFO_ALLOWED_DOMAINS: '["defaults","dotnet","github","aka.ms","dev.azure.com","microsoft.com","vsassets.io"]'
GH_AW_INFO_FIREWALL_ENABLED: "true"
- GH_AW_INFO_AWF_VERSION: "v0.25.29"
+ GH_AW_INFO_AWF_VERSION: "v0.25.40"
GH_AW_INFO_AWMG_VERSION: ""
GH_AW_INFO_FIREWALL_TYPE: "squid"
GH_AW_COMPILED_STRICT: "true"
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
with:
script: |
const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
@@ -124,8 +127,8 @@ jobs:
await main(core, context);
- name: Add eyes reaction for immediate feedback
id: react
- if: github.event_name == 'issues' || github.event_name == 'issue_comment' || github.event_name == 'pull_request_review_comment' || github.event_name == 'discussion' || github.event_name == 'discussion_comment' || github.event_name == 'pull_request' && github.event.pull_request.head.repo.id == github.repository_id
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ if: github.event_name == 'issues' || github.event_name == 'issue_comment' || github.event_name == 'pull_request_review_comment' || github.event_name == 'discussion' || github.event_name == 'discussion_comment' || github.event_name == 'pull_request' && github.event.pull_request.head.repo.id == github.repository_id || github.event_name == 'pull_request_review' && github.event.pull_request.head.repo.id == github.repository_id
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
GH_AW_REACTION: "eyes"
with:
@@ -152,17 +155,18 @@ jobs:
.crush
.gemini
.opencode
+ .pi
sparse-checkout-cone-mode: true
fetch-depth: 1
- name: Save agent config folders for base branch restoration
env:
- GH_AW_AGENT_FOLDERS: ".agents .claude .codex .crush .gemini .github .opencode"
- GH_AW_AGENT_FILES: ".crush.json AGENTS.md CLAUDE.md GEMINI.md opencode.jsonc"
+ GH_AW_AGENT_FOLDERS: ".agents .claude .codex .crush .gemini .github .opencode .pi"
+ GH_AW_AGENT_FILES: ".crush.json AGENTS.md CLAUDE.md GEMINI.md PI.md opencode.jsonc"
# poutine:ignore untrusted_checkout_exec
run: bash "${RUNNER_TEMP}/gh-aw/actions/save_base_github_folders.sh"
- name: Check workflow lock file
id: check-lock-file
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
GH_AW_WORKFLOW_FILE: "macios-reviewer.lock.yml"
GH_AW_CONTEXT_WORKFLOW_REF: "${{ github.workflow_ref }}"
@@ -173,9 +177,9 @@ jobs:
const { main } = require('${{ runner.temp }}/gh-aw/actions/check_workflow_timestamp_api.cjs');
await main();
- name: Check compile-agentic version
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
- GH_AW_COMPILED_VERSION: "v0.71.2"
+ GH_AW_COMPILED_VERSION: "v0.71.5"
with:
script: |
const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
@@ -184,7 +188,7 @@ jobs:
await main();
- name: Compute current body text
id: sanitized
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
GH_AW_ALLOWED_DOMAINS: "*.githubusercontent.com,*.vsblob.vsassets.io,aka.ms,api.business.githubcopilot.com,api.enterprise.githubcopilot.com,api.github.com,api.githubcopilot.com,api.individual.githubcopilot.com,api.nuget.org,api.snapcraft.io,archive.ubuntu.com,azure.archive.ubuntu.com,azuresearch-usnc.nuget.org,azuresearch-ussc.nuget.org,builds.dotnet.microsoft.com,ci.dot.net,codeload.github.com,crl.geotrust.com,crl.globalsign.com,crl.identrust.com,crl.sectigo.com,crl.thawte.com,crl.usertrust.com,crl.verisign.com,crl3.digicert.com,crl4.digicert.com,crls.ssl.com,dc.services.visualstudio.com,dev.azure.com,dist.nuget.org,docs.github.com,dot.net,dotnet.microsoft.com,dotnetcli.blob.core.windows.net,github-cloud.githubusercontent.com,github-cloud.s3.amazonaws.com,github.blog,github.com,github.githubassets.com,host.docker.internal,json-schema.org,json.schemastore.org,keyserver.ubuntu.com,lfs.github.com,microsoft.com,nuget.org,nuget.pkg.github.com,nugetregistryv2prod.blob.core.windows.net,objects.githubusercontent.com,ocsp.digicert.com,ocsp.geotrust.com,ocsp.globalsign.com,ocsp.identrust.com,ocsp.sectigo.com,ocsp.ssl.com,ocsp.thawte.com,ocsp.usertrust.com,ocsp.verisign.com,oneocsp.microsoft.com,packagecloud.io,packages.cloud.google.com,packages.microsoft.com,pkgs.dev.azure.com,ppa.launchpad.net,raw.githubusercontent.com,registry.npmjs.org,s.symcb.com,s.symcd.com,security.ubuntu.com,telemetry.enterprise.githubcopilot.com,ts-crl.ws.symantec.com,ts-ocsp.ws.symantec.com,vsassets.io,www.googleapis.com,www.microsoft.com"
with:
@@ -195,8 +199,8 @@ jobs:
await main();
- name: Add comment with workflow run link
id: add-comment
- if: github.event_name == 'issues' || github.event_name == 'issue_comment' || github.event_name == 'pull_request_review_comment' || github.event_name == 'discussion' || github.event_name == 'discussion_comment' || github.event_name == 'pull_request' && github.event.pull_request.head.repo.id == github.repository_id
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ if: github.event_name == 'issues' || github.event_name == 'issue_comment' || github.event_name == 'pull_request_review_comment' || github.event_name == 'discussion' || github.event_name == 'discussion_comment' || github.event_name == 'pull_request' && github.event.pull_request.head.repo.id == github.repository_id || github.event_name == 'pull_request_review' && github.event.pull_request.head.repo.id == github.repository_id
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
GH_AW_WORKFLOW_NAME: ".NET for Apple Platforms PR Reviewer"
with:
@@ -275,9 +279,10 @@ jobs:
GH_AW_PROMPT_31522cd090dd3137_EOF
} > "$GH_AW_PROMPT"
- name: Interpolate variables and render templates
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
GH_AW_PROMPT: /tmp/gh-aw/aw-prompts/prompt.txt
+ GH_AW_ENGINE_ID: "copilot"
with:
script: |
const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
@@ -285,7 +290,7 @@ jobs:
const { main } = require('${{ runner.temp }}/gh-aw/actions/interpolate_prompt.cjs');
await main();
- name: Substitute placeholders
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
GH_AW_PROMPT: /tmp/gh-aw/aw-prompts/prompt.txt
GH_AW_GITHUB_ACTOR: ${{ github.actor }}
@@ -340,6 +345,7 @@ jobs:
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: activation
+ include-hidden-files: true
path: |
/tmp/gh-aw/aw_info.json
/tmp/gh-aw/aw-prompts/prompt.txt
@@ -376,11 +382,15 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@ab8940d1df237fc4fae4ab8091e7ba66ada55a55 # v0.71.2
+ uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
trace-id: ${{ needs.activation.outputs.setup-trace-id }}
+ env:
+ GH_AW_SETUP_WORKFLOW_NAME: ".NET for Apple Platforms PR Reviewer"
+ GH_AW_CURRENT_WORKFLOW_REF: ${{ github.repository }}/.github/workflows/macios-reviewer.lock.yml@${{ github.ref }}
+ GH_AW_INFO_VERSION: "1.0.40"
- name: Set runtime paths
id: set-runtime-paths
run: |
@@ -416,7 +426,7 @@ jobs:
id: checkout-pr
if: |
github.event.pull_request || github.event.issue.pull_request
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
GH_TOKEN: ${{ secrets.GH_AW_GITHUB_MCP_SERVER_TOKEN || secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
with:
@@ -427,11 +437,11 @@ jobs:
const { main } = require('${{ runner.temp }}/gh-aw/actions/checkout_pr_branch.cjs');
await main();
- name: Install GitHub Copilot CLI
- run: bash "${RUNNER_TEMP}/gh-aw/actions/install_copilot_cli.sh" 1.0.36
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/install_copilot_cli.sh" 1.0.40
env:
GH_HOST: github.com
- name: Install AWF binary
- run: bash "${RUNNER_TEMP}/gh-aw/actions/install_awf_binary.sh" v0.25.29
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/install_awf_binary.sh" v0.25.40
- name: Parse integrity filter lists
id: parse-guard-vars
env:
@@ -447,12 +457,12 @@ jobs:
- name: Restore agent config folders from base branch
if: steps.checkout-pr.outcome == 'success'
env:
- GH_AW_AGENT_FOLDERS: ".agents .claude .codex .crush .gemini .github .opencode"
- GH_AW_AGENT_FILES: ".crush.json AGENTS.md CLAUDE.md GEMINI.md opencode.jsonc"
+ GH_AW_AGENT_FOLDERS: ".agents .claude .codex .crush .gemini .github .opencode .pi"
+ GH_AW_AGENT_FILES: ".crush.json AGENTS.md CLAUDE.md GEMINI.md PI.md opencode.jsonc"
run: bash "${RUNNER_TEMP}/gh-aw/actions/restore_base_github_folders.sh"
- name: Download container images
- run: bash "${RUNNER_TEMP}/gh-aw/actions/download_docker_images.sh" ghcr.io/github/gh-aw-firewall/agent:0.25.29@sha256:e68f37e36962dcb3f3d1de680a49bc2302cefd001b941a7dc377155ec7ce42f4 ghcr.io/github/gh-aw-firewall/api-proxy:0.25.29@sha256:d1219e4110684402aabbeb5a43858f26790c9d0be210581cf3f7a521bd2c87b6 ghcr.io/github/gh-aw-firewall/squid:0.25.29@sha256:8a71ad9e40454051672312917e51567abfb8251d7c294d086c48f63d84e4cb53 ghcr.io/github/gh-aw-mcpg:v0.3.1@sha256:287fad0236959f3b3d9936ea1ef8d5b4f135ef2a5f5789713495cbbef191e60c ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959 node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f
- - name: Write Safe Outputs Config
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/download_docker_images.sh" ghcr.io/github/gh-aw-firewall/agent:0.25.40@sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504 ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40@sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280 ghcr.io/github/gh-aw-firewall/squid:0.25.40@sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51 ghcr.io/github/gh-aw-mcpg:v0.3.6@sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959 node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f
+ - name: Generate Safe Outputs Config
run: |
mkdir -p "${RUNNER_TEMP}/gh-aw/safeoutputs"
mkdir -p /tmp/gh-aw/safeoutputs
@@ -460,7 +470,7 @@ jobs:
cat > "${RUNNER_TEMP}/gh-aw/safeoutputs/config.json" << 'GH_AW_SAFE_OUTPUTS_CONFIG_89a2d4b9522a1c3e_EOF'
{"create_pull_request_review_comment":{"max":50,"side":"RIGHT"},"create_report_incomplete_issue":{},"missing_data":{},"missing_tool":{},"noop":{"max":1,"report-as-issue":"true"},"report_incomplete":{},"submit_pull_request_review":{"allowed_events":["COMMENT","REQUEST_CHANGES"],"max":1}}
GH_AW_SAFE_OUTPUTS_CONFIG_89a2d4b9522a1c3e_EOF
- - name: Write Safe Outputs Tools
+ - name: Generate Safe Outputs Tools
env:
GH_AW_TOOLS_META_JSON: |
{
@@ -602,7 +612,7 @@ jobs:
}
}
}
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
with:
script: |
const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
@@ -663,6 +673,7 @@ jobs:
# Export gateway environment variables for MCP config and gateway script
export MCP_GATEWAY_PORT="8080"
export MCP_GATEWAY_DOMAIN="host.docker.internal"
+ export MCP_GATEWAY_HOST_DOMAIN="localhost"
MCP_GATEWAY_API_KEY=$(openssl rand -base64 45 | tr -d '/+=')
echo "::add-mask::${MCP_GATEWAY_API_KEY}"
export MCP_GATEWAY_API_KEY
@@ -675,7 +686,7 @@ jobs:
MCP_GATEWAY_UID=$(id -u 2>/dev/null || echo '0')
MCP_GATEWAY_GID=$(id -g 2>/dev/null || echo '0')
DOCKER_SOCK_GID=$(stat -c '%g' /var/run/docker.sock 2>/dev/null || echo '0')
- export MCP_GATEWAY_DOCKER_COMMAND='docker run -i --rm --network host --add-host host.docker.internal:127.0.0.1 --user '"${MCP_GATEWAY_UID}"':'"${MCP_GATEWAY_GID}"' --group-add '"${DOCKER_SOCK_GID}"' -v /var/run/docker.sock:/var/run/docker.sock -e MCP_GATEWAY_PORT -e MCP_GATEWAY_DOMAIN -e MCP_GATEWAY_API_KEY -e MCP_GATEWAY_PAYLOAD_DIR -e MCP_GATEWAY_PAYLOAD_SIZE_THRESHOLD -e DEBUG -e MCP_GATEWAY_LOG_DIR -e GH_AW_MCP_LOG_DIR -e GH_AW_SAFE_OUTPUTS -e GH_AW_SAFE_OUTPUTS_CONFIG_PATH -e GH_AW_SAFE_OUTPUTS_TOOLS_PATH -e GH_AW_ASSETS_BRANCH -e GH_AW_ASSETS_MAX_SIZE_KB -e GH_AW_ASSETS_ALLOWED_EXTS -e DEFAULT_BRANCH -e GITHUB_MCP_SERVER_TOKEN -e GITHUB_MCP_GUARD_MIN_INTEGRITY -e GITHUB_MCP_GUARD_REPOS -e GITHUB_REPOSITORY -e GITHUB_SERVER_URL -e GITHUB_SHA -e GITHUB_WORKSPACE -e GITHUB_TOKEN -e GITHUB_RUN_ID -e GITHUB_RUN_NUMBER -e GITHUB_RUN_ATTEMPT -e GITHUB_JOB -e GITHUB_ACTION -e GITHUB_EVENT_NAME -e GITHUB_EVENT_PATH -e GITHUB_ACTOR -e GITHUB_ACTOR_ID -e GITHUB_TRIGGERING_ACTOR -e GITHUB_WORKFLOW -e GITHUB_WORKFLOW_REF -e GITHUB_WORKFLOW_SHA -e GITHUB_REF -e GITHUB_REF_NAME -e GITHUB_REF_TYPE -e GITHUB_HEAD_REF -e GITHUB_BASE_REF -e GH_AW_SAFE_OUTPUTS_PORT -e GH_AW_SAFE_OUTPUTS_API_KEY -v /tmp/gh-aw/mcp-payloads:/tmp/gh-aw/mcp-payloads:rw -v /opt:/opt:ro -v /tmp:/tmp:rw -v '"${GITHUB_WORKSPACE}"':'"${GITHUB_WORKSPACE}"':rw ghcr.io/github/gh-aw-mcpg:v0.3.1'
+ export MCP_GATEWAY_DOCKER_COMMAND='docker run -i --rm --network host --add-host host.docker.internal:127.0.0.1 --user '"${MCP_GATEWAY_UID}"':'"${MCP_GATEWAY_GID}"' --group-add '"${DOCKER_SOCK_GID}"' -v /var/run/docker.sock:/var/run/docker.sock -e MCP_GATEWAY_PORT -e MCP_GATEWAY_DOMAIN -e MCP_GATEWAY_API_KEY -e MCP_GATEWAY_PAYLOAD_DIR -e MCP_GATEWAY_PAYLOAD_SIZE_THRESHOLD -e DEBUG -e MCP_GATEWAY_LOG_DIR -e GH_AW_MCP_LOG_DIR -e GH_AW_SAFE_OUTPUTS -e GH_AW_SAFE_OUTPUTS_CONFIG_PATH -e GH_AW_SAFE_OUTPUTS_TOOLS_PATH -e GH_AW_ASSETS_BRANCH -e GH_AW_ASSETS_MAX_SIZE_KB -e GH_AW_ASSETS_ALLOWED_EXTS -e DEFAULT_BRANCH -e GITHUB_MCP_SERVER_TOKEN -e GITHUB_MCP_GUARD_MIN_INTEGRITY -e GITHUB_MCP_GUARD_REPOS -e GITHUB_REPOSITORY -e GITHUB_SERVER_URL -e GITHUB_SHA -e GITHUB_WORKSPACE -e GITHUB_TOKEN -e GITHUB_RUN_ID -e GITHUB_RUN_NUMBER -e GITHUB_RUN_ATTEMPT -e GITHUB_JOB -e GITHUB_ACTION -e GITHUB_EVENT_NAME -e GITHUB_EVENT_PATH -e GITHUB_ACTOR -e GITHUB_ACTOR_ID -e GITHUB_TRIGGERING_ACTOR -e GITHUB_WORKFLOW -e GITHUB_WORKFLOW_REF -e GITHUB_WORKFLOW_SHA -e GITHUB_REF -e GITHUB_REF_NAME -e GITHUB_REF_TYPE -e GITHUB_HEAD_REF -e GITHUB_BASE_REF -e GH_AW_SAFE_OUTPUTS_PORT -e GH_AW_SAFE_OUTPUTS_API_KEY -v /tmp/gh-aw/mcp-payloads:/tmp/gh-aw/mcp-payloads:rw -v /opt:/opt:ro -v /tmp:/tmp:rw -v '"${GITHUB_WORKSPACE}"':'"${GITHUB_WORKSPACE}"':rw ghcr.io/github/gh-aw-mcpg:v0.3.6'
mkdir -p /home/runner/.copilot
GH_AW_NODE=$(which node 2>/dev/null || command -v node 2>/dev/null || echo node)
@@ -731,16 +742,20 @@ jobs:
MCP_GATEWAY_API_KEY: ${{ steps.start-mcp-gateway.outputs.gateway-api-key }}
MCP_GATEWAY_DOMAIN: ${{ steps.start-mcp-gateway.outputs.gateway-domain }}
MCP_GATEWAY_PORT: ${{ steps.start-mcp-gateway.outputs.gateway-port }}
- uses: actions/github-script@373c709c69115d41ff229c7e5df9f8788daa9553 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
with:
script: |
const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
setupGlobals(core, github, context, exec, io);
const { main } = require('${{ runner.temp }}/gh-aw/actions/mount_mcp_as_cli.cjs');
await main();
- - name: Clean git credentials
+ - name: Clean credentials
continue-on-error: true
run: bash "${RUNNER_TEMP}/gh-aw/actions/clean_git_credentials.sh"
+ - name: Audit pre-agent workspace
+ id: pre_agent_audit
+ continue-on-error: true
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/audit_pre_agent_workspace.sh"
- name: Execute GitHub Copilot CLI
id: agentic_execution
# Copilot CLI tool arguments (sorted):
@@ -751,8 +766,9 @@ jobs:
GH_AW_NODE_BIN=$(command -v node 2>/dev/null || true)
export GH_AW_NODE_BIN
(umask 177 && touch /tmp/gh-aw/agent-stdio.log)
+ printf '%s\n' '{"$schema":"https://github.com/github/gh-aw-firewall/releases/download/v0.25.40/awf-config.schema.json","network":{"allowDomains":["*.githubusercontent.com","*.vsblob.vsassets.io","aka.ms","api.business.githubcopilot.com","api.enterprise.githubcopilot.com","api.github.com","api.githubcopilot.com","api.individual.githubcopilot.com","api.nuget.org","api.snapcraft.io","archive.ubuntu.com","azure.archive.ubuntu.com","azuresearch-usnc.nuget.org","azuresearch-ussc.nuget.org","builds.dotnet.microsoft.com","ci.dot.net","codeload.github.com","crl.geotrust.com","crl.globalsign.com","crl.identrust.com","crl.sectigo.com","crl.thawte.com","crl.usertrust.com","crl.verisign.com","crl3.digicert.com","crl4.digicert.com","crls.ssl.com","dc.services.visualstudio.com","dev.azure.com","dist.nuget.org","docs.github.com","dot.net","dotnet.microsoft.com","dotnetcli.blob.core.windows.net","github-cloud.githubusercontent.com","github-cloud.s3.amazonaws.com","github.blog","github.com","github.githubassets.com","host.docker.internal","json-schema.org","json.schemastore.org","keyserver.ubuntu.com","lfs.github.com","microsoft.com","nuget.org","nuget.pkg.github.com","nugetregistryv2prod.blob.core.windows.net","objects.githubusercontent.com","ocsp.digicert.com","ocsp.geotrust.com","ocsp.globalsign.com","ocsp.identrust.com","ocsp.sectigo.com","ocsp.ssl.com","ocsp.thawte.com","ocsp.usertrust.com","ocsp.verisign.com","oneocsp.microsoft.com","packagecloud.io","packages.cloud.google.com","packages.microsoft.com","pkgs.dev.azure.com","ppa.launchpad.net","raw.githubusercontent.com","registry.npmjs.org","s.symcb.com","s.symcd.com","security.ubuntu.com","telemetry.enterprise.githubcopilot.com","ts-crl.ws.symantec.com","ts-ocsp.ws.symantec.com","vsassets.io","www.googleapis.com","www.microsoft.com"]},"apiProxy":{"enabled":true,"models":{"auto":["large"],"deep-research":["copilot/deep-research*","google/deep-research*"],"gemini-flash":["copilot/gemini-*flash*","google/gemini-*flash*"],"gemini-pro":["copilot/gemini-*pro*","google/gemini-*pro*"],"gpt-4.1":["copilot/gpt-4.1*","openai/gpt-4.1*"],"gpt-5":["copilot/gpt-5*","openai/gpt-5*"],"gpt-5-codex":["copilot/gpt-5*codex*","openai/gpt-5*codex*"],"gpt-5-mini":["copilot/gpt-5*mini*","openai/gpt-5*mini*"],"gpt-5-nano":["copilot/gpt-5*nano*","openai/gpt-5*nano*"],"gpt-5-pro":["copilot/gpt-5*pro*","openai/gpt-5*pro*"],"haiku":["copilot/*haiku*","anthropic/*haiku*"],"large":["sonnet","gpt-5-pro","gpt-5","gemini-pro"],"mini":["haiku","gpt-5-mini","gpt-5-nano","gemini-flash"],"opus":["copilot/*opus*","anthropic/*opus*"],"reasoning":["copilot/o1*","copilot/o3*","copilot/o4*","openai/o1*","openai/o3*","openai/o4*"],"small":["mini"],"sonnet":["copilot/*sonnet*","anthropic/*sonnet*"]}},"container":{"imageTag":"0.25.40,squid=sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51,agent=sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504,api-proxy=sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280,cli-proxy=sha256:3e7152911d4b4b7b97beef9d3d7d924ff7902227e86001ef3838fb728d5d514c"}}' > "${RUNNER_TEMP}/gh-aw/awf-config.json" && cp "${RUNNER_TEMP}/gh-aw/awf-config.json" /tmp/gh-aw/awf-config.json
# shellcheck disable=SC1003
- sudo -E awf --container-workdir "${GITHUB_WORKSPACE}" --mount "${RUNNER_TEMP}/gh-aw:${RUNNER_TEMP}/gh-aw:ro" --mount "${RUNNER_TEMP}/gh-aw:/host${RUNNER_TEMP}/gh-aw:ro" --env-all --exclude-env COPILOT_GITHUB_TOKEN --exclude-env GITHUB_MCP_SERVER_TOKEN --exclude-env MCP_GATEWAY_API_KEY --allow-domains '*.githubusercontent.com,*.vsblob.vsassets.io,aka.ms,api.business.githubcopilot.com,api.enterprise.githubcopilot.com,api.github.com,api.githubcopilot.com,api.individual.githubcopilot.com,api.nuget.org,api.snapcraft.io,archive.ubuntu.com,azure.archive.ubuntu.com,azuresearch-usnc.nuget.org,azuresearch-ussc.nuget.org,builds.dotnet.microsoft.com,ci.dot.net,codeload.github.com,crl.geotrust.com,crl.globalsign.com,crl.identrust.com,crl.sectigo.com,crl.thawte.com,crl.usertrust.com,crl.verisign.com,crl3.digicert.com,crl4.digicert.com,crls.ssl.com,dc.services.visualstudio.com,dev.azure.com,dist.nuget.org,docs.github.com,dot.net,dotnet.microsoft.com,dotnetcli.blob.core.windows.net,github-cloud.githubusercontent.com,github-cloud.s3.amazonaws.com,github.blog,github.com,github.githubassets.com,host.docker.internal,json-schema.org,json.schemastore.org,keyserver.ubuntu.com,lfs.github.com,microsoft.com,nuget.org,nuget.pkg.github.com,nugetregistryv2prod.blob.core.windows.net,objects.githubusercontent.com,ocsp.digicert.com,ocsp.geotrust.com,ocsp.globalsign.com,ocsp.identrust.com,ocsp.sectigo.com,ocsp.ssl.com,ocsp.thawte.com,ocsp.usertrust.com,ocsp.verisign.com,oneocsp.microsoft.com,packagecloud.io,packages.cloud.google.com,packages.microsoft.com,pkgs.dev.azure.com,ppa.launchpad.net,raw.githubusercontent.com,registry.npmjs.org,s.symcb.com,s.symcd.com,security.ubuntu.com,telemetry.enterprise.githubcopilot.com,ts-crl.ws.symantec.com,ts-ocsp.ws.symantec.com,vsassets.io,www.googleapis.com,www.microsoft.com' --log-level info --proxy-logs-dir /tmp/gh-aw/sandbox/firewall/logs --audit-dir /tmp/gh-aw/sandbox/firewall/audit --enable-host-access --allow-host-ports 80,443,8080 --image-tag 0.25.29,squid=sha256:8a71ad9e40454051672312917e51567abfb8251d7c294d086c48f63d84e4cb53,agent=sha256:e68f37e36962dcb3f3d1de680a49bc2302cefd001b941a7dc377155ec7ce42f4,agent-act=sha256:97b4cc14dc2123a45b9d5b9927489f66882dec5857de6afc0e5bab257be92ef1,api-proxy=sha256:d1219e4110684402aabbeb5a43858f26790c9d0be210581cf3f7a521bd2c87b6,cli-proxy=sha256:29917488eb90a01ff9544ffeeb5cc26434a8ea16d69ae8972f5f6be0e567e276 --skip-pull --enable-api-proxy \
+ sudo -E awf --config "${RUNNER_TEMP}/gh-aw/awf-config.json" --container-workdir "${GITHUB_WORKSPACE}" --mount "${RUNNER_TEMP}/gh-aw:${RUNNER_TEMP}/gh-aw:ro" --mount "${RUNNER_TEMP}/gh-aw:/host${RUNNER_TEMP}/gh-aw:ro" --env-all --exclude-env COPILOT_GITHUB_TOKEN --exclude-env GITHUB_MCP_SERVER_TOKEN --exclude-env MCP_GATEWAY_API_KEY --log-level info --proxy-logs-dir /tmp/gh-aw/sandbox/firewall/logs --audit-dir /tmp/gh-aw/sandbox/firewall/audit --enable-host-access --allow-host-ports 80,443,8080 --skip-pull \
-- /bin/bash -c 'export PATH="${RUNNER_TEMP}/gh-aw/mcp-cli/bin:$PATH" && export PATH="$(find /opt/hostedtoolcache /home/runner/work/_tool -maxdepth 4 -type d -name bin 2>/dev/null | tr '\''\n'\'' '\'':'\'')$PATH"; [ -n "$GOROOT" ] && export PATH="$GOROOT/bin:$PATH" || true && GH_AW_NODE_EXEC="${GH_AW_NODE_BIN:-}"; if [ -z "$GH_AW_NODE_EXEC" ] || [ ! -x "$GH_AW_NODE_EXEC" ]; then GH_AW_NODE_EXEC="$(command -v node 2>/dev/null || echo node)"; fi; "$GH_AW_NODE_EXEC" ${RUNNER_TEMP}/gh-aw/actions/copilot_harness.cjs /usr/local/bin/copilot --add-dir /tmp/gh-aw/ --log-level all --log-dir /tmp/gh-aw/sandbox/agent/logs/ --disable-builtin-mcps --no-ask-user --allow-all-tools --allow-all-paths --add-dir "${GITHUB_WORKSPACE}" --prompt-file /tmp/gh-aw/aw-prompts/prompt.txt' 2>&1 | tee -a /tmp/gh-aw/agent-stdio.log
env:
COPILOT_AGENT_RUNNER_TYPE: STANDALONE
@@ -763,7 +779,7 @@ jobs:
GH_AW_PHASE: agent
GH_AW_PROMPT: /tmp/gh-aw/aw-prompts/prompt.txt
GH_AW_SAFE_OUTPUTS: ${{ steps.set-runtime-paths.outputs.GH_AW_SAFE_OUTPUTS }}
- GH_AW_VERSION: v0.71.2
+ GH_AW_VERSION: v0.71.5
GITHUB_API_URL: ${{ github.api_url }}
GITHUB_AW: true
GITHUB_COPILOT_INTEGRATION_ID: agentic-workflows
@@ -811,7 +827,7 @@ jobs:
bash "${RUNNER_TEMP}/gh-aw/actions/stop_mcp_gateway.sh" "$GATEWAY_PID"
- name: Redact secrets in logs
if: always()
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
with:
script: |
const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
@@ -837,7 +853,7 @@ jobs:
- name: Ingest agent output
id: collect_output
if: always()
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
GH_AW_SAFE_OUTPUTS: ${{ steps.set-runtime-paths.outputs.GH_AW_SAFE_OUTPUTS }}
GH_AW_ALLOWED_DOMAINS: "*.githubusercontent.com,*.vsblob.vsassets.io,aka.ms,api.business.githubcopilot.com,api.enterprise.githubcopilot.com,api.github.com,api.githubcopilot.com,api.individual.githubcopilot.com,api.nuget.org,api.snapcraft.io,archive.ubuntu.com,azure.archive.ubuntu.com,azuresearch-usnc.nuget.org,azuresearch-ussc.nuget.org,builds.dotnet.microsoft.com,ci.dot.net,codeload.github.com,crl.geotrust.com,crl.globalsign.com,crl.identrust.com,crl.sectigo.com,crl.thawte.com,crl.usertrust.com,crl.verisign.com,crl3.digicert.com,crl4.digicert.com,crls.ssl.com,dc.services.visualstudio.com,dev.azure.com,dist.nuget.org,docs.github.com,dot.net,dotnet.microsoft.com,dotnetcli.blob.core.windows.net,github-cloud.githubusercontent.com,github-cloud.s3.amazonaws.com,github.blog,github.com,github.githubassets.com,host.docker.internal,json-schema.org,json.schemastore.org,keyserver.ubuntu.com,lfs.github.com,microsoft.com,nuget.org,nuget.pkg.github.com,nugetregistryv2prod.blob.core.windows.net,objects.githubusercontent.com,ocsp.digicert.com,ocsp.geotrust.com,ocsp.globalsign.com,ocsp.identrust.com,ocsp.sectigo.com,ocsp.ssl.com,ocsp.thawte.com,ocsp.usertrust.com,ocsp.verisign.com,oneocsp.microsoft.com,packagecloud.io,packages.cloud.google.com,packages.microsoft.com,pkgs.dev.azure.com,ppa.launchpad.net,raw.githubusercontent.com,registry.npmjs.org,s.symcb.com,s.symcd.com,security.ubuntu.com,telemetry.enterprise.githubcopilot.com,ts-crl.ws.symantec.com,ts-ocsp.ws.symantec.com,vsassets.io,www.googleapis.com,www.microsoft.com"
@@ -852,7 +868,7 @@ jobs:
await main();
- name: Parse agent logs for step summary
if: always()
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
GH_AW_AGENT_OUTPUT: /tmp/gh-aw/sandbox/agent/logs/
with:
@@ -864,7 +880,7 @@ jobs:
- name: Parse MCP Gateway logs for step summary
if: always()
id: parse-mcp-gateway
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
with:
script: |
const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
@@ -889,13 +905,23 @@ jobs:
- name: Parse token usage for step summary
if: always()
continue-on-error: true
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
with:
script: |
const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
setupGlobals(core, github, context, exec, io, getOctokit);
const { main } = require('${{ runner.temp }}/gh-aw/actions/parse_token_usage.cjs');
await main();
+ - name: Print AWF reflect summary
+ if: always()
+ continue-on-error: true
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ with:
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/awf_reflect_summary.cjs');
+ await main();
- name: Write agent output placeholder if missing
if: always()
run: |
@@ -917,14 +943,17 @@ jobs:
!/tmp/gh-aw/proxy-logs/proxy-tls/
/tmp/gh-aw/agent_usage.json
/tmp/gh-aw/agent-stdio.log
+ /tmp/gh-aw/pre-agent-audit.txt
/tmp/gh-aw/agent/
/tmp/gh-aw/github_rate_limits.jsonl
/tmp/gh-aw/safeoutputs.jsonl
/tmp/gh-aw/agent_output.json
/tmp/gh-aw/aw-*.patch
/tmp/gh-aw/aw-*.bundle
+ /tmp/gh-aw/awf-config.json
/tmp/gh-aw/sandbox/firewall/logs/
/tmp/gh-aw/sandbox/firewall/audit/
+ /tmp/gh-aw/sandbox/firewall/awf-reflect.json
if-no-files-found: ignore
conclusion:
@@ -951,11 +980,15 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@ab8940d1df237fc4fae4ab8091e7ba66ada55a55 # v0.71.2
+ uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
trace-id: ${{ needs.activation.outputs.setup-trace-id }}
+ env:
+ GH_AW_SETUP_WORKFLOW_NAME: ".NET for Apple Platforms PR Reviewer"
+ GH_AW_CURRENT_WORKFLOW_REF: ${{ github.repository }}/.github/workflows/macios-reviewer.lock.yml@${{ github.ref }}
+ GH_AW_INFO_VERSION: "1.0.40"
- name: Download agent output artifact
id: download-agent-output
continue-on-error: true
@@ -972,7 +1005,7 @@ jobs:
echo "GH_AW_AGENT_OUTPUT=/tmp/gh-aw/agent_output.json" >> "$GITHUB_OUTPUT"
- name: Process no-op messages
id: noop
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
GH_AW_AGENT_OUTPUT: ${{ steps.setup-agent-output-env.outputs.GH_AW_AGENT_OUTPUT }}
GH_AW_NOOP_MAX: "1"
@@ -989,7 +1022,7 @@ jobs:
await main();
- name: Log detection run
id: detection_runs
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
GH_AW_AGENT_OUTPUT: ${{ steps.setup-agent-output-env.outputs.GH_AW_AGENT_OUTPUT }}
GH_AW_WORKFLOW_NAME: ".NET for Apple Platforms PR Reviewer"
@@ -1005,7 +1038,7 @@ jobs:
await main();
- name: Record missing tool
id: missing_tool
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
GH_AW_AGENT_OUTPUT: ${{ steps.setup-agent-output-env.outputs.GH_AW_AGENT_OUTPUT }}
GH_AW_MISSING_TOOL_CREATE_ISSUE: "true"
@@ -1019,7 +1052,7 @@ jobs:
await main();
- name: Record incomplete
id: report_incomplete
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
GH_AW_AGENT_OUTPUT: ${{ steps.setup-agent-output-env.outputs.GH_AW_AGENT_OUTPUT }}
GH_AW_REPORT_INCOMPLETE_CREATE_ISSUE: "true"
@@ -1034,7 +1067,7 @@ jobs:
- name: Handle agent failure
id: handle_agent_failure
if: always()
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
GH_AW_AGENT_OUTPUT: ${{ steps.setup-agent-output-env.outputs.GH_AW_AGENT_OUTPUT }}
GH_AW_WORKFLOW_NAME: ".NET for Apple Platforms PR Reviewer"
@@ -1054,6 +1087,8 @@ jobs:
GH_AW_STALE_LOCK_FILE_FAILED: ${{ needs.activation.outputs.stale_lock_file_failed }}
GH_AW_GROUP_REPORTS: "false"
GH_AW_FAILURE_REPORT_AS_ISSUE: "true"
+ GH_AW_MISSING_TOOL_REPORT_AS_FAILURE: "true"
+ GH_AW_MISSING_DATA_REPORT_AS_FAILURE: "true"
GH_AW_TIMEOUT_MINUTES: "20"
with:
github-token: ${{ secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
@@ -1064,7 +1099,7 @@ jobs:
await main();
- name: Update reaction comment with completion status
id: conclusion
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
GH_AW_AGENT_OUTPUT: ${{ steps.setup-agent-output-env.outputs.GH_AW_AGENT_OUTPUT }}
GH_AW_COMMENT_ID: ${{ needs.activation.outputs.comment_id }}
@@ -1098,11 +1133,15 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@ab8940d1df237fc4fae4ab8091e7ba66ada55a55 # v0.71.2
+ uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
trace-id: ${{ needs.activation.outputs.setup-trace-id }}
+ env:
+ GH_AW_SETUP_WORKFLOW_NAME: ".NET for Apple Platforms PR Reviewer"
+ GH_AW_CURRENT_WORKFLOW_REF: ${{ github.repository }}/.github/workflows/macios-reviewer.lock.yml@${{ github.ref }}
+ GH_AW_INFO_VERSION: "1.0.40"
- name: Download agent output artifact
id: download-agent-output
continue-on-error: true
@@ -1128,7 +1167,7 @@ jobs:
rm -rf /tmp/gh-aw/sandbox/firewall/logs
rm -rf /tmp/gh-aw/sandbox/firewall/audit
- name: Download container images
- run: bash "${RUNNER_TEMP}/gh-aw/actions/download_docker_images.sh" ghcr.io/github/gh-aw-firewall/agent:0.25.29@sha256:e68f37e36962dcb3f3d1de680a49bc2302cefd001b941a7dc377155ec7ce42f4 ghcr.io/github/gh-aw-firewall/api-proxy:0.25.29@sha256:d1219e4110684402aabbeb5a43858f26790c9d0be210581cf3f7a521bd2c87b6 ghcr.io/github/gh-aw-firewall/squid:0.25.29@sha256:8a71ad9e40454051672312917e51567abfb8251d7c294d086c48f63d84e4cb53
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/download_docker_images.sh" ghcr.io/github/gh-aw-firewall/agent:0.25.40@sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504 ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40@sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280 ghcr.io/github/gh-aw-firewall/squid:0.25.40@sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51
- name: Check if detection needed
id: detection_guard
if: always()
@@ -1165,7 +1204,7 @@ jobs:
ls -la /tmp/gh-aw/threat-detection/ 2>/dev/null || true
- name: Setup threat detection
if: always() && steps.detection_guard.outputs.run_detection == 'true'
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
WORKFLOW_NAME: ".NET for Apple Platforms PR Reviewer"
WORKFLOW_DESCRIPTION: "No description provided"
@@ -1187,11 +1226,11 @@ jobs:
node-version: '24'
package-manager-cache: false
- name: Install GitHub Copilot CLI
- run: bash "${RUNNER_TEMP}/gh-aw/actions/install_copilot_cli.sh" 1.0.36
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/install_copilot_cli.sh" 1.0.40
env:
GH_HOST: github.com
- name: Install AWF binary
- run: bash "${RUNNER_TEMP}/gh-aw/actions/install_awf_binary.sh" v0.25.29
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/install_awf_binary.sh" v0.25.40
- name: Execute GitHub Copilot CLI
if: always() && steps.detection_guard.outputs.run_detection == 'true'
continue-on-error: true
@@ -1204,8 +1243,9 @@ jobs:
GH_AW_NODE_BIN=$(command -v node 2>/dev/null || true)
export GH_AW_NODE_BIN
(umask 177 && touch /tmp/gh-aw/threat-detection/detection.log)
+ printf '%s\n' '{"$schema":"https://github.com/github/gh-aw-firewall/releases/download/v0.25.40/awf-config.schema.json","network":{"allowDomains":["api.business.githubcopilot.com","api.enterprise.githubcopilot.com","api.github.com","api.githubcopilot.com","api.individual.githubcopilot.com","github.com","host.docker.internal","telemetry.enterprise.githubcopilot.com"]},"apiProxy":{"enabled":true},"container":{"imageTag":"0.25.40,squid=sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51,agent=sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504,api-proxy=sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280,cli-proxy=sha256:3e7152911d4b4b7b97beef9d3d7d924ff7902227e86001ef3838fb728d5d514c"}}' > "${RUNNER_TEMP}/gh-aw/awf-config.json" && cp "${RUNNER_TEMP}/gh-aw/awf-config.json" /tmp/gh-aw/awf-config.json
# shellcheck disable=SC1003
- sudo -E awf --container-workdir "${GITHUB_WORKSPACE}" --mount "${RUNNER_TEMP}/gh-aw:${RUNNER_TEMP}/gh-aw:ro" --mount "${RUNNER_TEMP}/gh-aw:/host${RUNNER_TEMP}/gh-aw:ro" --env-all --exclude-env COPILOT_GITHUB_TOKEN --allow-domains api.business.githubcopilot.com,api.enterprise.githubcopilot.com,api.github.com,api.githubcopilot.com,api.individual.githubcopilot.com,github.com,host.docker.internal,telemetry.enterprise.githubcopilot.com --log-level info --proxy-logs-dir /tmp/gh-aw/sandbox/firewall/logs --audit-dir /tmp/gh-aw/sandbox/firewall/audit --enable-host-access --allow-host-ports 80,443,8080 --image-tag 0.25.29,squid=sha256:8a71ad9e40454051672312917e51567abfb8251d7c294d086c48f63d84e4cb53,agent=sha256:e68f37e36962dcb3f3d1de680a49bc2302cefd001b941a7dc377155ec7ce42f4,agent-act=sha256:97b4cc14dc2123a45b9d5b9927489f66882dec5857de6afc0e5bab257be92ef1,api-proxy=sha256:d1219e4110684402aabbeb5a43858f26790c9d0be210581cf3f7a521bd2c87b6,cli-proxy=sha256:29917488eb90a01ff9544ffeeb5cc26434a8ea16d69ae8972f5f6be0e567e276 --skip-pull --enable-api-proxy \
+ sudo -E awf --config "${RUNNER_TEMP}/gh-aw/awf-config.json" --container-workdir "${GITHUB_WORKSPACE}" --mount "${RUNNER_TEMP}/gh-aw:${RUNNER_TEMP}/gh-aw:ro" --mount "${RUNNER_TEMP}/gh-aw:/host${RUNNER_TEMP}/gh-aw:ro" --env-all --exclude-env COPILOT_GITHUB_TOKEN --log-level info --proxy-logs-dir /tmp/gh-aw/sandbox/firewall/logs --audit-dir /tmp/gh-aw/sandbox/firewall/audit --enable-host-access --allow-host-ports 80,443,8080 --skip-pull \
-- /bin/bash -c 'export PATH="$(find /opt/hostedtoolcache /home/runner/work/_tool -maxdepth 4 -type d -name bin 2>/dev/null | tr '\''\n'\'' '\'':'\'')$PATH"; [ -n "$GOROOT" ] && export PATH="$GOROOT/bin:$PATH" || true && GH_AW_NODE_EXEC="${GH_AW_NODE_BIN:-}"; if [ -z "$GH_AW_NODE_EXEC" ] || [ ! -x "$GH_AW_NODE_EXEC" ]; then GH_AW_NODE_EXEC="$(command -v node 2>/dev/null || echo node)"; fi; "$GH_AW_NODE_EXEC" ${RUNNER_TEMP}/gh-aw/actions/copilot_harness.cjs /usr/local/bin/copilot --add-dir /tmp/gh-aw/ --log-level all --log-dir /tmp/gh-aw/sandbox/agent/logs/ --disable-builtin-mcps --no-ask-user --allow-all-tools --add-dir "${GITHUB_WORKSPACE}" --prompt-file /tmp/gh-aw/aw-prompts/prompt.txt' 2>&1 | tee -a /tmp/gh-aw/threat-detection/detection.log
env:
COPILOT_AGENT_RUNNER_TYPE: STANDALONE
@@ -1214,7 +1254,7 @@ jobs:
COPILOT_MODEL: claude-sonnet-4.5
GH_AW_PHASE: detection
GH_AW_PROMPT: /tmp/gh-aw/aw-prompts/prompt.txt
- GH_AW_VERSION: v0.71.2
+ GH_AW_VERSION: v0.71.5
GITHUB_API_URL: ${{ github.api_url }}
GITHUB_AW: true
GITHUB_COPILOT_INTEGRATION_ID: agentic-workflows
@@ -1239,7 +1279,7 @@ jobs:
id: detection_conclusion
if: always()
continue-on-error: true
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
RUN_DETECTION: ${{ steps.detection_guard.outputs.run_detection }}
GH_AW_DETECTION_CONTINUE_ON_ERROR: "true"
@@ -1267,7 +1307,7 @@ jobs:
}
pre_activation:
- if: "github.event_name == 'issue_comment' && (startsWith(github.event.comment.body, '/review ') || startsWith(github.event.comment.body, '/review\n') || github.event.comment.body == '/review') && github.event.issue.pull_request != null || !(github.event_name == 'issue_comment')"
+ if: "(github.event_name != 'issue_comment' && github.event_name != 'pull_request_review_comment' || contains(fromJSON('[\"OWNER\",\"MEMBER\",\"COLLABORATOR\"]'), github.event.comment.author_association)) && (github.event_name == 'issue_comment' && (startsWith(github.event.comment.body, '/review ') || startsWith(github.event.comment.body, '/review\n') || github.event.comment.body == '/review') && github.event.issue.pull_request != null || !(github.event_name == 'issue_comment'))"
runs-on: ubuntu-slim
outputs:
activated: ${{ steps.check_membership.outputs.is_team_member == 'true' && steps.check_command_position.outputs.command_position_ok == 'true' }}
@@ -1276,13 +1316,17 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@ab8940d1df237fc4fae4ab8091e7ba66ada55a55 # v0.71.2
+ uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
+ env:
+ GH_AW_SETUP_WORKFLOW_NAME: ".NET for Apple Platforms PR Reviewer"
+ GH_AW_CURRENT_WORKFLOW_REF: ${{ github.repository }}/.github/workflows/macios-reviewer.lock.yml@${{ github.ref }}
+ GH_AW_INFO_VERSION: "1.0.40"
- name: Check team membership for command workflow
id: check_membership
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
GH_AW_REQUIRED_ROLES: "admin,maintainer,write"
with:
@@ -1294,7 +1338,7 @@ jobs:
await main();
- name: Check command position
id: check_command_position
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
GH_AW_COMMANDS: "[\"review\"]"
with:
@@ -1322,7 +1366,7 @@ jobs:
GH_AW_EFFECTIVE_TOKENS: ${{ needs.agent.outputs.effective_tokens }}
GH_AW_ENGINE_ID: "copilot"
GH_AW_ENGINE_MODEL: "claude-sonnet-4.5"
- GH_AW_ENGINE_VERSION: "1.0.36"
+ GH_AW_ENGINE_VERSION: "1.0.40"
GH_AW_WORKFLOW_ID: "macios-reviewer"
GH_AW_WORKFLOW_NAME: ".NET for Apple Platforms PR Reviewer"
outputs:
@@ -1335,11 +1379,15 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@ab8940d1df237fc4fae4ab8091e7ba66ada55a55 # v0.71.2
+ uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
trace-id: ${{ needs.activation.outputs.setup-trace-id }}
+ env:
+ GH_AW_SETUP_WORKFLOW_NAME: ".NET for Apple Platforms PR Reviewer"
+ GH_AW_CURRENT_WORKFLOW_REF: ${{ github.repository }}/.github/workflows/macios-reviewer.lock.yml@${{ github.ref }}
+ GH_AW_INFO_VERSION: "1.0.40"
- name: Download agent output artifact
id: download-agent-output
continue-on-error: true
@@ -1365,7 +1413,7 @@ jobs:
echo "GH_HOST=${GH_HOST}" >> "$GITHUB_ENV"
- name: Process Safe Outputs
id: process_safe_outputs
- uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
GH_AW_AGENT_OUTPUT: ${{ steps.setup-agent-output-env.outputs.GH_AW_AGENT_OUTPUT }}
GH_AW_ALLOWED_DOMAINS: "*.githubusercontent.com,*.vsblob.vsassets.io,aka.ms,api.business.githubcopilot.com,api.enterprise.githubcopilot.com,api.github.com,api.githubcopilot.com,api.individual.githubcopilot.com,api.nuget.org,api.snapcraft.io,archive.ubuntu.com,azure.archive.ubuntu.com,azuresearch-usnc.nuget.org,azuresearch-ussc.nuget.org,builds.dotnet.microsoft.com,ci.dot.net,codeload.github.com,crl.geotrust.com,crl.globalsign.com,crl.identrust.com,crl.sectigo.com,crl.thawte.com,crl.usertrust.com,crl.verisign.com,crl3.digicert.com,crl4.digicert.com,crls.ssl.com,dc.services.visualstudio.com,dev.azure.com,dist.nuget.org,docs.github.com,dot.net,dotnet.microsoft.com,dotnetcli.blob.core.windows.net,github-cloud.githubusercontent.com,github-cloud.s3.amazonaws.com,github.blog,github.com,github.githubassets.com,host.docker.internal,json-schema.org,json.schemastore.org,keyserver.ubuntu.com,lfs.github.com,microsoft.com,nuget.org,nuget.pkg.github.com,nugetregistryv2prod.blob.core.windows.net,objects.githubusercontent.com,ocsp.digicert.com,ocsp.geotrust.com,ocsp.globalsign.com,ocsp.identrust.com,ocsp.sectigo.com,ocsp.ssl.com,ocsp.thawte.com,ocsp.usertrust.com,ocsp.verisign.com,oneocsp.microsoft.com,packagecloud.io,packages.cloud.google.com,packages.microsoft.com,pkgs.dev.azure.com,ppa.launchpad.net,raw.githubusercontent.com,registry.npmjs.org,s.symcb.com,s.symcd.com,security.ubuntu.com,telemetry.enterprise.githubcopilot.com,ts-crl.ws.symantec.com,ts-ocsp.ws.symantec.com,vsassets.io,www.googleapis.com,www.microsoft.com"
diff --git a/.github/workflows/macios-reviewer.md b/.github/workflows/macios-reviewer.md
index 72da3cc06bd9..10fe33bae503 100644
--- a/.github/workflows/macios-reviewer.md
+++ b/.github/workflows/macios-reviewer.md
@@ -56,6 +56,6 @@ A maintainer commented `/review` on this pull request. Perform a thorough code r
- Don't flag what CI catches (compiler errors, linter issues).
- Don't review C# code formatting — it is handled automatically.
- Avoid false positives — verify concerns given the full file context.
-- **Never submit an APPROVE event.** Use COMMENT for clean PRs and REQUEST_CHANGES when issues are found.
+- **Never submit an APPROVE event.** Use COMMENT for clean PRs (or re-reviews where previous issues are fixed) and REQUEST_CHANGES only when ❌ error-level issues are found. Submitting COMMENT on a re-review clears any previous REQUEST_CHANGES state.
- Prioritize: bugs > breaking changes > binding correctness > safety > performance > missing tests > duplication > consistency > documentation.
- Ignore comments from the user 'vs-mobiletools-engineering-service2'.
From b4a70d2ff8ab1e6d0f0ddae086f6acec98f909e6 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Thu, 7 May 2026 08:01:11 +0200
Subject: [PATCH 022/156] [tools/msbuild] Add InlineDlfcnMethodsStep as an
opt-in custom linker step (#24888)
Add a new custom linker step that replaces runtime `Dlfcn.dlsym` calls with
direct native symbol lookups via P/Invokes to `__Internal`. This improves
startup performance and app size, and ensures the native linker can see symbol
references that would otherwise only be resolved at runtime.
Two modes are supported, controlled by the `InlineDlfcnMethods` MSBuild property:
* `strict`: inlines all calls to `ObjCRuntime.Dlfcn` APIs.
* `compatibility`: only inlines calls that reference symbols from `[Field]`
attributes.
Post-trimming MSBuild targets ensure native code is only generated for symbols
that survive trimming (ILTrim or NativeAOT):
* `_CollectPostILTrimInformation`: scans trimmed assemblies for surviving
inlined dlfcn P/Invokes, with per-assembly caching for incremental builds.
* `_CollectPostNativeAOTTrimInformation`: reads unresolved symbols from the
NativeAOT object file or static library and filters for inlined dlfcn symbols.
* `_PostTrimmingProcessing`: generates native C code for surviving symbols and
adds it to the native link inputs.
Extends `MachO.cs` with LC_SYMTAB parsing to read unresolved symbols from both
Mach-O object files and static libraries.
Contributes towards https://github.com/dotnet/macios/issues/17693.
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
docs/building-apps/build-properties.md | 30 +
docs/code/native-symbols.md | 69 ++
dotnet/targets/Xamarin.Shared.Sdk.props | 6 +
dotnet/targets/Xamarin.Shared.Sdk.targets | 108 ++
.../Tasks/CollectPostILTrimInformation.cs | 118 ++
.../Tasks/CollectUnresolvedNativeSymbols.cs | 51 +
.../Tasks/CompileNativeCode.cs | 4 +
.../ComputeNativeAOTSurvivingNativeSymbols.cs | 68 ++
.../Tasks/PostTrimmingProcessing.cs | 134 +++
.../Xamarin.MacDev.Tasks.csproj | 3 +
tests/common/test-variations.csproj | 21 +
.../MacCatalyst-MonoVM-interpreter-size.txt | 6 +-
.../expected/MacCatalyst-MonoVM-size.txt | 6 +-
...atalyst-NativeAOT-TrimmableStatic-size.txt | 4 +-
.../expected/MacCatalyst-NativeAOT-size.txt | 4 +-
...reCLR-Interpreter-TrimmableStatic-size.txt | 10 +-
.../MacOSX-CoreCLR-Interpreter-size.txt | 10 +-
.../MacOSX-NativeAOT-TrimmableStatic-size.txt | 4 +-
.../expected/MacOSX-NativeAOT-size.txt | 4 +-
.../expected/TVOS-MonoVM-interpreter-size.txt | 4 +-
.../UnitTests/expected/TVOS-MonoVM-size.txt | 4 +-
.../TVOS-NativeAOT-TrimmableStatic-size.txt | 4 +-
.../expected/TVOS-NativeAOT-size.txt | 4 +-
.../expected/iOS-MonoVM-interpreter-size.txt | 4 +-
.../UnitTests/expected/iOS-MonoVM-size.txt | 4 +-
.../iOS-NativeAOT-TrimmableStatic-size.txt | 4 +-
.../UnitTests/expected/iOS-NativeAOT-size.txt | 4 +-
.../CoreFoundation/ProxyTest.cs | 17 -
.../CoreGraphics/GeometryTest.cs | 9 +-
.../Foundation/AttributedStringTest.cs | 22 -
tests/monotouch-test/ObjCRuntime/DlfcnTest.cs | 70 +-
tests/monotouch-test/dotnet/shared.csproj | 1 +
.../xharness/Jenkins/TestVariationsFactory.cs | 4 +
tools/common/CompilerFlags.cs | 2 +-
tools/common/Frameworks.cs | 69 +-
tools/common/MachO.cs | 105 +-
tools/common/Symbols.cs | 10 +-
tools/dotnet-linker/AppBundleRewriter.cs | 23 +
tools/dotnet-linker/LinkerConfiguration.cs | 29 +
.../Steps/AssemblyModifierStep.cs | 6 +-
.../Steps/GatherFrameworksStep.cs | 5 +-
.../Steps/GenerateReferencesStep.cs | 2 +-
.../Steps/InlineDlfcnMethodsStep.cs | 1015 +++++++++++++++++
.../MonoTouch.Tuner/ListExportedSymbols.cs | 9 +-
.../MonoTouch.Tuner/ProcessExportedFields.cs | 33 +
tools/mtouch/Errors.designer.cs | 36 +
tools/mtouch/Errors.resx | 18 +
47 files changed, 2057 insertions(+), 120 deletions(-)
create mode 100644 docs/code/native-symbols.md
create mode 100644 msbuild/Xamarin.MacDev.Tasks/Tasks/CollectPostILTrimInformation.cs
create mode 100644 msbuild/Xamarin.MacDev.Tasks/Tasks/CollectUnresolvedNativeSymbols.cs
create mode 100644 msbuild/Xamarin.MacDev.Tasks/Tasks/ComputeNativeAOTSurvivingNativeSymbols.cs
create mode 100644 msbuild/Xamarin.MacDev.Tasks/Tasks/PostTrimmingProcessing.cs
create mode 100644 tools/dotnet-linker/Steps/InlineDlfcnMethodsStep.cs
diff --git a/docs/building-apps/build-properties.md b/docs/building-apps/build-properties.md
index b28355b21e83..14277d6f03f5 100644
--- a/docs/building-apps/build-properties.md
+++ b/docs/building-apps/build-properties.md
@@ -559,6 +559,36 @@ See also:
* The [AlternateAppIcon](build-items.md#alternateappicon) item group.
* The [AppIcon](#appicon) property.
+## InlineDlfcnMethods
+
+Controls whether the build system replaces runtime calls to `ObjCRuntime.Dlfcn` methods with direct native symbol lookups at build time, eliminating the overhead of `dlsym` at runtime.
+
+The valid options are:
+
+* `compatibility`: Only inlines symbol usages backed by `[Field]` attributes. This is more conservative and avoids link errors for symbols that don't exist at build time.
+* `strict`: Inlines dlfcn method calls and creates native references for all symbols. This is more aggressive and may cause link errors if referenced native symbols don't exist.
+* (empty): Disables inlining of dlfcn method calls.
+
+Default value:
+* .NET 11+: `strict` when using NativeAOT (`PublishAot=true`), `compatibility` otherwise.
+* .NET 10 and earlier: not set (disabled).
+
+Example:
+
+```xml
+
+ compatibility
+
+```
+
+Custom behavior for specific symbols can be set using the [ReferenceNativeSymbol](build-items.md#referencenativesymbols) item group:
+
+```xml
+
+
+
+```
+
## iOSMinimumVersion
Specifies the minimum iOS version the app can run on.
diff --git a/docs/code/native-symbols.md b/docs/code/native-symbols.md
new file mode 100644
index 000000000000..45aea7239827
--- /dev/null
+++ b/docs/code/native-symbols.md
@@ -0,0 +1,69 @@
+# Native symbols
+
+Native symbols can be referenced from managed code in several ways:
+
+* P/Invokes (DllImports)
+* Calls to `dlsym`, which can happen through:
+ * The various APIs in `ObjCRuntime.Dlfcn`
+ * The various APIs in `System.Runtime.InteropServices.NativeLibrary`
+ * A P/Invoke directly into `dlsym`
+
+It's highly desirable to use a direct native reference to native symbols when building a mobile app, for a few reasons:
+
+* It's faster at runtime, and the app is smaller.
+* If the referenced native symbol comes from a third-party static library, the
+ native linker can remove it if it's configured to remove unused code
+ (because the native linker can't see that the native symbol is in fact used
+ at runtime) unless there's a direct native reference to the symbol.
+
+On the other hand there's one scenario when a direct native reference is not desirable: when the native symbol does not exist.
+
+In order to create a direct native reference to native symbols, we need to know the names of those native symbols.
+
+## The `InlineDlfcnMethods` property
+
+This behavior is controlled by the `InlineDlfcnMethods` MSBuild property, which
+has two modes:
+
+* `strict`: all calls to `ObjCRuntime.Dlfcn` APIs are inlined.
+* `compatibility`: only calls that reference symbols from `[Field]` attributes are inlined.
+
+See the [build properties documentation](../building-apps/build-properties.md) for default values.
+
+## How it works
+
+During the build we try to collect the following:
+
+* Any property or field with the `[Foundation.Field]` attribute: we collect the symbol name.
+* Any calls to the `ObjCRuntime.Dlfcn` APIs: we try to collect the symbol name (this might not always succeed, if the symbol name is not a constant).
+* We don't process calls to `System.Runtime.InteropServices.NativeLibrary` at the moment (this may change in the future, if there's need).
+
+This is further complicated by the fact that we only want to create native
+references for symbols that survive trimming.
+
+So we do the following:
+
+1. Before or during trimming, we run the inlining steps:
+
+ * `ProcessExportedFields`: collects all members with `[Field]` attributes.
+
+ * `InlineDlfcnMethodsStep`: inspects all calls to `ObjCRuntime.Dlfcn`, and
+ inlines them depending on the selected mode. If inlined, the step creates
+ a P/Invoke to a native method that will return the address for that symbol
+ (using a direct native reference), and modifies the code that fetches that
+ symbol to call said P/Invoke.
+
+2. After trimming, we figure out which of those symbols survived:
+
+ * For ILTrim: the `_CollectPostILTrimInformation` MSBuild target inspects
+ the trimmed assemblies and collects all the inlined dlfcn P/Invokes that
+ survived. Per-assembly results are cached to speed up incremental builds.
+
+ * For NativeAOT: the `_CollectPostNativeAOTTrimInformation` MSBuild target
+ inspects the native object file (or static library) produced by NativeAOT,
+ collects all unresolved native references, and filters them against the
+ inlined dlfcn symbols to determine which survived.
+
+3. The `_PostTrimmingProcessing` MSBuild target takes the surviving symbols
+ from either path, generates the corresponding native C code, and adds it to
+ the list of files to compile and link into the final executable.
diff --git a/dotnet/targets/Xamarin.Shared.Sdk.props b/dotnet/targets/Xamarin.Shared.Sdk.props
index ae5137fbbf76..0007e4766ebc 100644
--- a/dotnet/targets/Xamarin.Shared.Sdk.props
+++ b/dotnet/targets/Xamarin.Shared.Sdk.props
@@ -101,6 +101,12 @@
false
+
+
+ strict
+ compatibility
+
+
diff --git a/dotnet/targets/Xamarin.Shared.Sdk.targets b/dotnet/targets/Xamarin.Shared.Sdk.targets
index 341e08ac0808..ece45355d5a8 100644
--- a/dotnet/targets/Xamarin.Shared.Sdk.targets
+++ b/dotnet/targets/Xamarin.Shared.Sdk.targets
@@ -18,6 +18,9 @@
+
+
+
@@ -25,6 +28,7 @@
+
<_TrimmerCustomSteps Include="$(_AdditionalTaskAssembly)" BeforeStep="MarkStep" Type="MonoTouch.Tuner.RegistrarRemovalTrackingStep" />
@@ -1670,6 +1677,87 @@
+
+
+ <_TrimmedAssembly Include="$(IntermediateLinkDir)*.dll" />
+
+
+
+
+
+ <_ILTrimSurvivingNativeSymbolsFile>$(DeviceSpecificIntermediateOutputPath)inlined-dlfcn\iltrim-surviving-native-symbols.txt
+ <_NativeAOTUnresolvedSymbolsFile>$(DeviceSpecificIntermediateOutputPath)nativeaot-unresolved-symbols.txt
+ <_NativeAOTSurvivingNativeSymbolsFile>$(DeviceSpecificIntermediateOutputPath)nativeaot-surviving-native-symbols.txt
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ <_SurvivingNativeSymbolsFile Include="$(_ILTrimSurvivingNativeSymbolsFile)" Condition="Exists('$(_ILTrimSurvivingNativeSymbolsFile)')" />
+ <_SurvivingNativeSymbolsFile Include="$(_NativeAOTSurvivingNativeSymbolsFile)" Condition="Exists('$(_NativeAOTSurvivingNativeSymbolsFile)')" />
+
+
+
+
+
+
+
+ <_PostTrimmingSourceFiles>
+ $(DeviceSpecificIntermediateOutputPath)posttrim-info-compiled/%(Arch)/%(Filename).o
+
+
+
+
+
+
+
+ <_CompiledPostTrimmingFiles Include="@(_PostTrimmingSourceFiles -> '%(OutputFile)')" />
+ <_NativeExecutableObjectFiles Include="@(_CompiledPostTrimmingFiles)" />
+
+
+
+
<_CompileNativeExecutableDependsOn>
$(_CompileNativeExecutableDependsOn);
@@ -1726,6 +1814,7 @@
_ReadAppManifest;
_WriteAppManifest;
_CompileNativeExecutable;
+ _PostTrimmingProcessing;
_ReidentifyDynamicLibraries;
_AddSwiftLinkerFlags;
_ComputeLinkNativeExecutableInputs;
@@ -1733,6 +1822,25 @@
+
+
+
+
+
+
diff --git a/msbuild/Xamarin.MacDev.Tasks/Tasks/CollectPostILTrimInformation.cs b/msbuild/Xamarin.MacDev.Tasks/Tasks/CollectPostILTrimInformation.cs
new file mode 100644
index 000000000000..116ce430cb49
--- /dev/null
+++ b/msbuild/Xamarin.MacDev.Tasks/Tasks/CollectPostILTrimInformation.cs
@@ -0,0 +1,118 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT License.
+
+using System.Collections.Generic;
+using System.IO;
+using System.Linq;
+
+using Microsoft.Build.Framework;
+
+using Mono.Cecil;
+
+#nullable enable
+
+namespace Xamarin.MacDev.Tasks {
+ ///
+ /// Scans trimmed assemblies to collect information that survived trimming.
+ /// See docs/code/native-symbols.md for an overview of native symbol handling.
+ ///
+ public class CollectPostILTrimInformation : XamarinTask {
+ [Required]
+ public ITaskItem [] TrimmedAssemblies { get; set; } = [];
+
+ ///
+ /// Output file listing the inlined dlfcn symbols that survived trimming.
+ ///
+ [Required]
+ public string SurvivingNativeSymbolsFile { get; set; } = "";
+
+ ///
+ /// Directory for per-assembly cache files, to avoid re-scanning unchanged assemblies.
+ ///
+ [Required]
+ public string CacheDirectory { get; set; } = "";
+
+ public override bool Execute ()
+ {
+ Directory.CreateDirectory (CacheDirectory);
+
+ CollectSurvivingNativeSymbols ();
+
+ return !Log.HasLoggedErrors;
+ }
+
+ void CollectSurvivingNativeSymbols ()
+ {
+ // Scan trimmed assemblies for surviving P/Invoke methods, using per-assembly caching.
+ var survivingSymbols = new HashSet ();
+ foreach (var item in TrimmedAssemblies) {
+ var assemblyPath = item.ItemSpec;
+ if (!File.Exists (assemblyPath))
+ continue;
+
+ var assemblyName = Path.GetFileNameWithoutExtension (assemblyPath);
+ var cacheFile = Path.Combine (CacheDirectory, assemblyName + ".dlfcn-symbols.cache");
+
+ string []? cachedSymbols = null;
+ if (File.Exists (cacheFile) && File.GetLastWriteTimeUtc (cacheFile) >= File.GetLastWriteTimeUtc (assemblyPath)) {
+ cachedSymbols = File.ReadAllLines (cacheFile);
+ Log.LogMessage (MessageImportance.Low, "Using cached dlfcn symbols for {0}", assemblyName);
+
+ survivingSymbols.UnionWith (cachedSymbols);
+ } else {
+ var assemblySymbols = new HashSet ();
+ CollectDlfcnSymbolsFromAssembly (assemblyPath, assemblySymbols);
+
+ // Write per-assembly cache (sorted for stability).
+ var sortedAssemblySymbols = assemblySymbols.OrderBy (s => s).ToArray ();
+ File.WriteAllLines (cacheFile, sortedAssemblySymbols);
+
+ survivingSymbols.UnionWith (assemblySymbols);
+ }
+ }
+
+ // Write the combined results only if contents changed (sorted for stability).
+ var sorted = survivingSymbols.OrderBy (s => s).ToArray ();
+
+ if (File.Exists (SurvivingNativeSymbolsFile)) {
+ var existing = File.ReadAllLines (SurvivingNativeSymbolsFile);
+ if (existing.SequenceEqual (sorted))
+ return;
+ }
+
+ var dir = Path.GetDirectoryName (SurvivingNativeSymbolsFile);
+ if (!string.IsNullOrEmpty (dir))
+ Directory.CreateDirectory (dir);
+ File.WriteAllLines (SurvivingNativeSymbolsFile, sorted);
+ Log.LogMessage (MessageImportance.Low, "Found {0} surviving inlined dlfcn symbols", survivingSymbols.Count);
+ }
+
+ static void CollectDlfcnSymbolsFromAssembly (string assemblyPath, HashSet survivingSymbols)
+ {
+ const string prefix = "xamarin_Dlfcn_";
+ const string suffix = "_Native";
+
+ using var assembly = AssemblyDefinition.ReadAssembly (assemblyPath, new ReaderParameters { ReadSymbols = false });
+ foreach (var module in assembly.Modules) {
+ foreach (var type in module.Types) {
+ if (!type.HasMethods)
+ continue;
+ foreach (var method in type.Methods) {
+ if (!method.IsPInvokeImpl)
+ continue;
+ if (method.PInvokeInfo?.Module?.Name != "__Internal")
+ continue;
+ var name = method.Name;
+ if (!name.StartsWith (prefix) || !name.EndsWith (suffix))
+ continue;
+ var symbolLength = name.Length - prefix.Length - suffix.Length;
+ if (symbolLength <= 0)
+ continue;
+ var symbolName = name.Substring (prefix.Length, symbolLength);
+ survivingSymbols.Add (symbolName);
+ }
+ }
+ }
+ }
+ }
+}
diff --git a/msbuild/Xamarin.MacDev.Tasks/Tasks/CollectUnresolvedNativeSymbols.cs b/msbuild/Xamarin.MacDev.Tasks/Tasks/CollectUnresolvedNativeSymbols.cs
new file mode 100644
index 000000000000..bc43f111fba4
--- /dev/null
+++ b/msbuild/Xamarin.MacDev.Tasks/Tasks/CollectUnresolvedNativeSymbols.cs
@@ -0,0 +1,51 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT License.
+
+using System.Collections.Generic;
+using System.IO;
+using System.Linq;
+
+using Microsoft.Build.Framework;
+
+#nullable enable
+
+namespace Xamarin.MacDev.Tasks {
+ // See docs/code/native-symbols.md for an overview of native symbol handling.
+ public class CollectUnresolvedNativeSymbols : XamarinTask {
+ public ITaskItem? StaticLibrary { get; set; }
+
+ [Required]
+ public string OutputFile { get; set; } = "";
+
+ public override bool Execute ()
+ {
+ if (StaticLibrary is null) {
+ Log.LogError ("StaticLibrary is required.");
+ return false;
+ }
+
+ var path = StaticLibrary.ItemSpec;
+ if (!File.Exists (path)) {
+ Log.LogError ("Static library not found: {0}", path);
+ return false;
+ }
+
+ var symbols = Xamarin.StaticLibrary.GetUnresolvedSymbols (path);
+ Log.LogMessage (MessageImportance.Low, "Found {0} unresolved symbols in {1}", symbols.Count, path);
+
+ var lines = symbols.OrderBy (s => s).ToArray ();
+ if (File.Exists (OutputFile)) {
+ var existing = File.ReadAllLines (OutputFile);
+ if (existing.SequenceEqual (lines))
+ return !Log.HasLoggedErrors;
+ }
+
+ var dir = Path.GetDirectoryName (OutputFile);
+ if (!string.IsNullOrEmpty (dir))
+ Directory.CreateDirectory (dir);
+ File.WriteAllLines (OutputFile, lines);
+
+ return !Log.HasLoggedErrors;
+ }
+ }
+}
diff --git a/msbuild/Xamarin.MacDev.Tasks/Tasks/CompileNativeCode.cs b/msbuild/Xamarin.MacDev.Tasks/Tasks/CompileNativeCode.cs
index affd9e1f3fae..f3816db30ddb 100644
--- a/msbuild/Xamarin.MacDev.Tasks/Tasks/CompileNativeCode.cs
+++ b/msbuild/Xamarin.MacDev.Tasks/Tasks/CompileNativeCode.cs
@@ -136,6 +136,10 @@ public override bool Execute ()
arguments.Add ("-o");
arguments.Add (outputFile);
+ var outputDirectory = Path.GetDirectoryName (outputFile);
+ if (!string.IsNullOrEmpty (outputDirectory))
+ Directory.CreateDirectory (outputDirectory);
+
arguments.Add ("-c");
arguments.Add (src);
diff --git a/msbuild/Xamarin.MacDev.Tasks/Tasks/ComputeNativeAOTSurvivingNativeSymbols.cs b/msbuild/Xamarin.MacDev.Tasks/Tasks/ComputeNativeAOTSurvivingNativeSymbols.cs
new file mode 100644
index 000000000000..67eda6ed7ec0
--- /dev/null
+++ b/msbuild/Xamarin.MacDev.Tasks/Tasks/ComputeNativeAOTSurvivingNativeSymbols.cs
@@ -0,0 +1,68 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT License.
+
+using System.Collections.Generic;
+using System.IO;
+using System.Linq;
+
+using Microsoft.Build.Framework;
+
+#nullable enable
+
+namespace Xamarin.MacDev.Tasks {
+ ///
+ /// Takes the list of unresolved native symbols from a NativeAOT static library and computes
+ /// which inlined dlfcn native symbols survived trimming. The output file has the same format
+ /// as CollectPostILTrimInformation's surviving symbols file.
+ /// See docs/code/native-symbols.md for an overview of native symbol handling.
+ ///
+ public class ComputeNativeAOTSurvivingNativeSymbols : XamarinTask {
+ ///
+ /// The file listing all unresolved native symbols from the NativeAOT static library.
+ ///
+ [Required]
+ public string UnresolvedSymbolsFile { get; set; } = "";
+
+ ///
+ /// Output file listing the native symbols that survived NativeAOT trimming.
+ ///
+ [Required]
+ public string SurvivingNativeSymbolsFile { get; set; } = "";
+
+ public override bool Execute ()
+ {
+ if (!File.Exists (UnresolvedSymbolsFile))
+ return !Log.HasLoggedErrors;
+
+ const string prefix = "_xamarin_Dlfcn_";
+ const string suffix = "_Native";
+ var survivingSymbols = new HashSet ();
+
+ foreach (var sym in File.ReadAllLines (UnresolvedSymbolsFile)) {
+ if (!sym.StartsWith (prefix) || !sym.EndsWith (suffix))
+ continue;
+ var symbolLength = sym.Length - prefix.Length - suffix.Length;
+ if (symbolLength <= 0)
+ continue;
+ var symbolName = sym.Substring (prefix.Length, symbolLength);
+ survivingSymbols.Add (symbolName);
+ }
+
+ var sorted = survivingSymbols.OrderBy (s => s).ToArray ();
+
+ if (File.Exists (SurvivingNativeSymbolsFile)) {
+ var existing = File.ReadAllLines (SurvivingNativeSymbolsFile);
+ if (existing.SequenceEqual (sorted))
+ return !Log.HasLoggedErrors;
+ }
+
+ var dir = Path.GetDirectoryName (SurvivingNativeSymbolsFile);
+ if (!string.IsNullOrEmpty (dir))
+ Directory.CreateDirectory (dir);
+ File.WriteAllLines (SurvivingNativeSymbolsFile, sorted);
+ Log.LogMessage (MessageImportance.Low, "Found {0} surviving native symbols from NativeAOT", survivingSymbols.Count);
+
+ return !Log.HasLoggedErrors;
+ }
+ }
+}
diff --git a/msbuild/Xamarin.MacDev.Tasks/Tasks/PostTrimmingProcessing.cs b/msbuild/Xamarin.MacDev.Tasks/Tasks/PostTrimmingProcessing.cs
new file mode 100644
index 000000000000..77705a8dd1d7
--- /dev/null
+++ b/msbuild/Xamarin.MacDev.Tasks/Tasks/PostTrimmingProcessing.cs
@@ -0,0 +1,134 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT License.
+
+using System.Collections.Generic;
+using System.IO;
+using System.Linq;
+using System.Text;
+
+using Microsoft.Build.Framework;
+
+using Xamarin.Bundler;
+
+#nullable enable
+
+namespace Xamarin.MacDev.Tasks {
+ ///
+ /// Performs post-trimming processing, generating native code only for symbols that survived trimming.
+ /// See docs/code/native-symbols.md for an overview of native symbol handling.
+ ///
+ public class PostTrimmingProcessing : XamarinTask {
+ [Required]
+ public string Architecture { get; set; } = "";
+
+ [Required]
+ public string OutputDirectory { get; set; } = "";
+
+ public ITaskItem [] ReferenceNativeSymbol { get; set; } = [];
+
+ ///
+ /// Files listing native symbols that survived trimming. Each file contains one symbol name per line.
+ /// These can come from either ILTrim (CollectPostILTrimInformation) or NativeAOT
+ /// (ComputeNativeAOTSurvivingNativeSymbols).
+ ///
+ public ITaskItem [] SurvivingNativeSymbolsFiles { get; set; } = [];
+
+ ///
+ /// Output native source files to be compiled and linked.
+ ///
+ [Output]
+ public ITaskItem []? NativeSourceFiles { get; set; }
+
+ HashSet? ignoredSymbols;
+
+ HashSet IgnoredSymbols {
+ get {
+ if (ignoredSymbols is null) {
+ ignoredSymbols = new HashSet ();
+ foreach (var rns in ReferenceNativeSymbol) {
+ var nativeSymbol = rns.ItemSpec;
+ var symbolMode = rns.GetMetadata ("SymbolMode");
+ if (!string.Equals (symbolMode, "Ignore", StringComparison.OrdinalIgnoreCase))
+ continue;
+ var symbolType = rns.GetMetadata ("SymbolType").ToLowerInvariant ();
+ switch (symbolType) {
+ case "objectivecclass":
+ nativeSymbol = Symbol.ObjectiveCPrefix + nativeSymbol;
+ break;
+ case "function":
+ case "field":
+ break;
+ default:
+ Log.LogMessage (MessageImportance.Low, "Ignoring symbol '{0}' with unknown SymbolType '{1}'", nativeSymbol, symbolType);
+ continue;
+ }
+ ignoredSymbols.Add (nativeSymbol);
+ }
+ }
+ return ignoredSymbols;
+ }
+ }
+
+ public override bool Execute ()
+ {
+ var items = new List ();
+
+ GenerateInlinedDlfcnNativeCode (items);
+
+ NativeSourceFiles = items.ToArray ();
+ return !Log.HasLoggedErrors;
+ }
+
+ void GenerateInlinedDlfcnNativeCode (List items)
+ {
+ // Collect all surviving symbols from all input files.
+ var survivingSymbols = new HashSet ();
+ foreach (var file in SurvivingNativeSymbolsFiles) {
+ var path = file.ItemSpec;
+ if (!File.Exists (path))
+ continue;
+ survivingSymbols.UnionWith (File.ReadAllLines (path));
+ }
+
+ var survivingButIgnoredSymbols = survivingSymbols.Intersect (IgnoredSymbols).ToList ();
+ if (survivingButIgnoredSymbols.Count > 0) {
+ Log.LogMessage (MessageImportance.Low, "The following symbols survived trimming but are marked as ignored:");
+ foreach (var symbol in survivingButIgnoredSymbols)
+ Log.LogMessage (MessageImportance.Low, " {0}", symbol);
+ survivingSymbols.ExceptWith (survivingButIgnoredSymbols);
+ }
+
+ if (survivingSymbols.Count == 0) {
+ Log.LogMessage (MessageImportance.Low, "There were no surviving symbols that require inlined dlfcn native code.");
+ return;
+ }
+
+ Directory.CreateDirectory (OutputDirectory);
+ var outputPath = Path.Combine (OutputDirectory, "inlined-dlfcn.c");
+
+ var sb = new StringBuilder ();
+ // The generated C code uses 'extern void*' declarations and returns the address of the symbol.
+ // This is intentional: it allows the native linker to resolve the symbol at link time, which
+ // is the whole point of this optimization (avoiding dlsym at runtime).
+ foreach (var field in survivingSymbols.OrderBy (s => s)) {
+ // Using 'void*' as a stand-in type since we only need the address
+ sb.AppendLine ($"extern void* {field};");
+ sb.AppendLine ($"void* xamarin_Dlfcn_{field}_Native ();");
+ sb.AppendLine ($"void* xamarin_Dlfcn_{field}_Native () {{ return &{field}; }}");
+ sb.AppendLine ();
+ }
+
+ var content = sb.ToString ();
+ if (File.Exists (outputPath) && File.ReadAllText (outputPath) == content) {
+ Log.LogMessage (MessageImportance.Low, "Inlined dlfcn native code is up to date");
+ } else {
+ File.WriteAllText (outputPath, content);
+ Log.LogMessage (MessageImportance.Low, "Generated inlined dlfcn native code with {0} symbols", survivingSymbols.Count);
+ }
+
+ var item = new Microsoft.Build.Utilities.TaskItem (outputPath);
+ item.SetMetadata ("Arch", Architecture.ToLowerInvariant ());
+ items.Add (item);
+ }
+ }
+}
diff --git a/msbuild/Xamarin.MacDev.Tasks/Xamarin.MacDev.Tasks.csproj b/msbuild/Xamarin.MacDev.Tasks/Xamarin.MacDev.Tasks.csproj
index a61be2c501c3..285fb0113a10 100644
--- a/msbuild/Xamarin.MacDev.Tasks/Xamarin.MacDev.Tasks.csproj
+++ b/msbuild/Xamarin.MacDev.Tasks/Xamarin.MacDev.Tasks.csproj
@@ -81,6 +81,9 @@
StringUtils.cs
+
+ Symbols.cs
+
FileCopier.cs
diff --git a/tests/common/test-variations.csproj b/tests/common/test-variations.csproj
index 633c8fc2cb79..d5d820a99fad 100644
--- a/tests/common/test-variations.csproj
+++ b/tests/common/test-variations.csproj
@@ -23,6 +23,8 @@
+
+
@@ -147,6 +149,25 @@
<_TestVariationApplied>true
+
+ compatibility
+ <_TestVariationApplied>true
+
+
+
+ strict
+ <_TestVariationApplied>true
+
+ $(DefineConstants);STATIC_NATIVE_SYMBOL_LOOKUP
+
+
+
+
+
+
+
+
+
<_InvalidTestVariations Include="$(TestVariation.Split('|'))" Exclude="@(TestVariations)" />
diff --git a/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-size.txt b/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-size.txt
index c0eceeb55daf..ecd8aa0ec456 100644
--- a/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-size.txt
@@ -1,8 +1,8 @@
-AppBundleSize: 5,791,876 bytes (5,656.1 KB = 5.5 MB)
+AppBundleSize: 5,791,518 bytes (5,655.8 KB = 5.5 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 3,310 bytes (3.2 KB = 0.0 MB)
-Contents/Info.plist: 1,105 bytes (1.1 KB = 0.0 MB)
-Contents/MacOS/SizeTestApp: 4,567,200 bytes (4,460.2 KB = 4.4 MB)
+Contents/Info.plist: 1,099 bytes (1.1 KB = 0.0 MB)
+Contents/MacOS/SizeTestApp: 4,566,848 bytes (4,459.8 KB = 4.4 MB)
Contents/MonoBundle/Microsoft.MacCatalyst.dll: 158,208 bytes (154.5 KB = 0.2 MB)
Contents/MonoBundle/runtimeconfig.bin: 1,405 bytes (1.4 KB = 0.0 MB)
Contents/MonoBundle/SizeTestApp.dll: 7,680 bytes (7.5 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-size.txt b/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-size.txt
index 30e271a333ce..59e70bf96ffd 100644
--- a/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-size.txt
@@ -1,8 +1,8 @@
-AppBundleSize: 16,327,064 bytes (15,944.4 KB = 15.6 MB)
+AppBundleSize: 16,326,690 bytes (15,944.0 KB = 15.6 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 4,134 bytes (4.0 KB = 0.0 MB)
-Contents/Info.plist: 1,105 bytes (1.1 KB = 0.0 MB)
-Contents/MacOS/SizeTestApp: 13,816,208 bytes (13,492.4 KB = 13.2 MB)
+Contents/Info.plist: 1,099 bytes (1.1 KB = 0.0 MB)
+Contents/MacOS/SizeTestApp: 13,815,840 bytes (13,492.0 KB = 13.2 MB)
Contents/MonoBundle/aot-instances.aotdata.arm64: 1,045,032 bytes (1,020.5 KB = 1.0 MB)
Contents/MonoBundle/Microsoft.MacCatalyst.aotdata.arm64: 36,048 bytes (35.2 KB = 0.0 MB)
Contents/MonoBundle/Microsoft.MacCatalyst.dll: 51,200 bytes (50.0 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-TrimmableStatic-size.txt b/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-TrimmableStatic-size.txt
index 1f4b876d0ab6..76fb1f7ee130 100644
--- a/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-TrimmableStatic-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-TrimmableStatic-size.txt
@@ -1,7 +1,7 @@
-AppBundleSize: 8,759,335 bytes (8,554.0 KB = 8.4 MB)
+AppBundleSize: 8,759,329 bytes (8,554.0 KB = 8.4 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 2,358 bytes (2.3 KB = 0.0 MB)
-Contents/Info.plist: 1,105 bytes (1.1 KB = 0.0 MB)
+Contents/Info.plist: 1,099 bytes (1.1 KB = 0.0 MB)
Contents/MacOS/SizeTestApp: 8,753,968 bytes (8,548.8 KB = 8.3 MB)
Contents/MonoBundle/runtimeconfig.bin: 1,896 bytes (1.9 KB = 0.0 MB)
Contents/PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-size.txt b/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-size.txt
index 1f96717a8196..8d0cf443f128 100644
--- a/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-size.txt
@@ -1,7 +1,7 @@
-AppBundleSize: 2,781,135 bytes (2,716.0 KB = 2.7 MB)
+AppBundleSize: 2,781,129 bytes (2,715.9 KB = 2.7 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 2,358 bytes (2.3 KB = 0.0 MB)
-Contents/Info.plist: 1,105 bytes (1.1 KB = 0.0 MB)
+Contents/Info.plist: 1,099 bytes (1.1 KB = 0.0 MB)
Contents/MacOS/SizeTestApp: 2,775,856 bytes (2,710.8 KB = 2.6 MB)
Contents/MonoBundle/runtimeconfig.bin: 1,808 bytes (1.8 KB = 0.0 MB)
Contents/PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-TrimmableStatic-size.txt b/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-TrimmableStatic-size.txt
index a8de8bacc18f..9175a93d88bc 100644
--- a/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-TrimmableStatic-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-TrimmableStatic-size.txt
@@ -1,12 +1,12 @@
-AppBundleSize: 259,305,962 bytes (253,228.5 KB = 247.3 MB)
+AppBundleSize: 259,304,804 bytes (253,227.3 KB = 247.3 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 67,868 bytes (66.3 KB = 0.1 MB)
-Contents/Info.plist: 736 bytes (0.7 KB = 0.0 MB)
-Contents/MacOS/SizeTestApp: 7,411,744 bytes (7,238.0 KB = 7.1 MB)
+Contents/Info.plist: 730 bytes (0.7 KB = 0.0 MB)
+Contents/MacOS/SizeTestApp: 7,411,616 bytes (7,237.9 KB = 7.1 MB)
Contents/MonoBundle/.xamarin/osx-arm64/_Microsoft.macOS.TypeMap.dll: 4,842,496 bytes (4,729.0 KB = 4.6 MB)
Contents/MonoBundle/.xamarin/osx-arm64/_SizeTestApp.TypeMap.dll: 3,072 bytes (3.0 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.CSharp.dll: 893,192 bytes (872.3 KB = 0.9 MB)
-Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.macOS.dll: 38,126,592 bytes (37,233.0 KB = 36.4 MB)
+Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.macOS.dll: 38,126,080 bytes (37,232.5 KB = 36.4 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.VisualBasic.Core.dll: 1,335,096 bytes (1,303.8 KB = 1.3 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.VisualBasic.dll: 17,680 bytes (17.3 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.Win32.Primitives.dll: 16,144 bytes (15.8 KB = 0.0 MB)
@@ -182,7 +182,7 @@ Contents/MonoBundle/.xamarin/osx-arm64/WindowsBase.dll: 16,688 bytes (16.3 KB =
Contents/MonoBundle/.xamarin/osx-x64/_Microsoft.macOS.TypeMap.dll: 4,842,496 bytes (4,729.0 KB = 4.6 MB)
Contents/MonoBundle/.xamarin/osx-x64/_SizeTestApp.TypeMap.dll: 3,072 bytes (3.0 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.CSharp.dll: 796,432 bytes (777.8 KB = 0.8 MB)
-Contents/MonoBundle/.xamarin/osx-x64/Microsoft.macOS.dll: 38,126,592 bytes (37,233.0 KB = 36.4 MB)
+Contents/MonoBundle/.xamarin/osx-x64/Microsoft.macOS.dll: 38,126,080 bytes (37,232.5 KB = 36.4 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.VisualBasic.Core.dll: 1,166,648 bytes (1,139.3 KB = 1.1 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.VisualBasic.dll: 17,680 bytes (17.3 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.Win32.Primitives.dll: 16,176 bytes (15.8 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-size.txt b/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-size.txt
index 92b0c3dcee84..812ae13a20eb 100644
--- a/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-size.txt
@@ -1,10 +1,10 @@
-AppBundleSize: 247,478,868 bytes (241,678.6 KB = 236.0 MB)
+AppBundleSize: 247,477,726 bytes (241,677.5 KB = 236.0 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 67,160 bytes (65.6 KB = 0.1 MB)
-Contents/Info.plist: 736 bytes (0.7 KB = 0.0 MB)
-Contents/MacOS/SizeTestApp: 8,068,000 bytes (7,878.9 KB = 7.7 MB)
+Contents/Info.plist: 730 bytes (0.7 KB = 0.0 MB)
+Contents/MacOS/SizeTestApp: 8,067,888 bytes (7,878.8 KB = 7.7 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.CSharp.dll: 893,192 bytes (872.3 KB = 0.9 MB)
-Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.macOS.dll: 36,730,368 bytes (35,869.5 KB = 35.0 MB)
+Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.macOS.dll: 36,729,856 bytes (35,869.0 KB = 35.0 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.VisualBasic.Core.dll: 1,335,096 bytes (1,303.8 KB = 1.3 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.VisualBasic.dll: 17,680 bytes (17.3 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.Win32.Primitives.dll: 16,144 bytes (15.8 KB = 0.0 MB)
@@ -178,7 +178,7 @@ Contents/MonoBundle/.xamarin/osx-arm64/System.Xml.XPath.dll: 16,144 bytes (15.8
Contents/MonoBundle/.xamarin/osx-arm64/System.Xml.XPath.XDocument.dll: 17,672 bytes (17.3 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-arm64/WindowsBase.dll: 16,688 bytes (16.3 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.CSharp.dll: 796,432 bytes (777.8 KB = 0.8 MB)
-Contents/MonoBundle/.xamarin/osx-x64/Microsoft.macOS.dll: 36,730,368 bytes (35,869.5 KB = 35.0 MB)
+Contents/MonoBundle/.xamarin/osx-x64/Microsoft.macOS.dll: 36,729,856 bytes (35,869.0 KB = 35.0 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.VisualBasic.Core.dll: 1,166,648 bytes (1,139.3 KB = 1.1 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.VisualBasic.dll: 17,680 bytes (17.3 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.Win32.Primitives.dll: 16,176 bytes (15.8 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-TrimmableStatic-size.txt b/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-TrimmableStatic-size.txt
index c0f4920c9b03..74bd56956228 100644
--- a/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-TrimmableStatic-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-TrimmableStatic-size.txt
@@ -1,7 +1,7 @@
-AppBundleSize: 21,466,082 bytes (20,963.0 KB = 20.5 MB)
+AppBundleSize: 21,466,076 bytes (20,963.0 KB = 20.5 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 3,489 bytes (3.4 KB = 0.0 MB)
-Contents/Info.plist: 736 bytes (0.7 KB = 0.0 MB)
+Contents/Info.plist: 730 bytes (0.7 KB = 0.0 MB)
Contents/MacOS/SizeTestApp: 18,472,416 bytes (18,039.5 KB = 17.6 MB)
Contents/MonoBundle/libSystem.Globalization.Native.dylib: 252,176 bytes (246.3 KB = 0.2 MB)
Contents/MonoBundle/libSystem.IO.Compression.Native.dylib: 2,005,440 bytes (1,958.4 KB = 1.9 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-size.txt b/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-size.txt
index dcc45c318ac1..80dca93a72af 100644
--- a/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-size.txt
@@ -1,7 +1,7 @@
-AppBundleSize: 8,818,816 bytes (8,612.1 KB = 8.4 MB)
+AppBundleSize: 8,818,810 bytes (8,612.1 KB = 8.4 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 3,489 bytes (3.4 KB = 0.0 MB)
-Contents/Info.plist: 736 bytes (0.7 KB = 0.0 MB)
+Contents/Info.plist: 730 bytes (0.7 KB = 0.0 MB)
Contents/MacOS/SizeTestApp: 5,825,232 bytes (5,688.7 KB = 5.6 MB)
Contents/MonoBundle/libSystem.Globalization.Native.dylib: 252,176 bytes (246.3 KB = 0.2 MB)
Contents/MonoBundle/libSystem.IO.Compression.Native.dylib: 2,005,440 bytes (1,958.4 KB = 1.9 MB)
diff --git a/tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-size.txt b/tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-size.txt
index a8840dd6a070..54ecb9e249c2 100644
--- a/tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-size.txt
+++ b/tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-size.txt
@@ -1,8 +1,8 @@
-AppBundleSize: 3,617,471 bytes (3,532.7 KB = 3.4 MB)
+AppBundleSize: 3,617,465 bytes (3,532.7 KB = 3.4 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 3,999 bytes (3.9 KB = 0.0 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,123 bytes (1.1 KB = 0.0 MB)
+Info.plist: 1,117 bytes (1.1 KB = 0.0 MB)
Microsoft.tvOS.dll: 155,136 bytes (151.5 KB = 0.1 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,405 bytes (1.4 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/TVOS-MonoVM-size.txt b/tests/dotnet/UnitTests/expected/TVOS-MonoVM-size.txt
index ac016e47913f..c8fe10c3eb92 100644
--- a/tests/dotnet/UnitTests/expected/TVOS-MonoVM-size.txt
+++ b/tests/dotnet/UnitTests/expected/TVOS-MonoVM-size.txt
@@ -1,9 +1,9 @@
-AppBundleSize: 9,364,029 bytes (9,144.6 KB = 8.9 MB)
+AppBundleSize: 9,364,023 bytes (9,144.6 KB = 8.9 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 5,233 bytes (5.1 KB = 0.0 MB)
aot-instances.aotdata.arm64: 827,592 bytes (808.2 KB = 0.8 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,123 bytes (1.1 KB = 0.0 MB)
+Info.plist: 1,117 bytes (1.1 KB = 0.0 MB)
Microsoft.tvOS.aotdata.arm64: 22,640 bytes (22.1 KB = 0.0 MB)
Microsoft.tvOS.dll: 49,152 bytes (48.0 KB = 0.0 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-TrimmableStatic-size.txt b/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-TrimmableStatic-size.txt
index e91793096976..de72f82de756 100644
--- a/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-TrimmableStatic-size.txt
+++ b/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-TrimmableStatic-size.txt
@@ -1,8 +1,8 @@
-AppBundleSize: 7,905,353 bytes (7,720.1 KB = 7.5 MB)
+AppBundleSize: 7,905,347 bytes (7,720.1 KB = 7.5 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 2,589 bytes (2.5 KB = 0.0 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,123 bytes (1.1 KB = 0.0 MB)
+Info.plist: 1,117 bytes (1.1 KB = 0.0 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,889 bytes (1.8 KB = 0.0 MB)
SizeTestApp: 7,899,360 bytes (7,714.2 KB = 7.5 MB)
diff --git a/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-size.txt b/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-size.txt
index 56adae8012cd..a17ad92e4f57 100644
--- a/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-size.txt
+++ b/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-size.txt
@@ -1,8 +1,8 @@
-AppBundleSize: 2,783,144 bytes (2,717.9 KB = 2.7 MB)
+AppBundleSize: 2,783,138 bytes (2,717.9 KB = 2.7 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 2,589 bytes (2.5 KB = 0.0 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,123 bytes (1.1 KB = 0.0 MB)
+Info.plist: 1,117 bytes (1.1 KB = 0.0 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,808 bytes (1.8 KB = 0.0 MB)
SizeTestApp: 2,777,232 bytes (2,712.1 KB = 2.6 MB)
diff --git a/tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-size.txt b/tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-size.txt
index ff794b9d49c7..95938f6bec29 100644
--- a/tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-size.txt
+++ b/tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-size.txt
@@ -1,8 +1,8 @@
-AppBundleSize: 3,603,925 bytes (3,519.5 KB = 3.4 MB)
+AppBundleSize: 3,603,919 bytes (3,519.5 KB = 3.4 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 3,997 bytes (3.9 KB = 0.0 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,147 bytes (1.1 KB = 0.0 MB)
+Info.plist: 1,141 bytes (1.1 KB = 0.0 MB)
Microsoft.iOS.dll: 155,136 bytes (151.5 KB = 0.1 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,405 bytes (1.4 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/iOS-MonoVM-size.txt b/tests/dotnet/UnitTests/expected/iOS-MonoVM-size.txt
index 6de64cd4b7d8..c86caef51f9b 100644
--- a/tests/dotnet/UnitTests/expected/iOS-MonoVM-size.txt
+++ b/tests/dotnet/UnitTests/expected/iOS-MonoVM-size.txt
@@ -1,9 +1,9 @@
-AppBundleSize: 9,338,369 bytes (9,119.5 KB = 8.9 MB)
+AppBundleSize: 9,338,363 bytes (9,119.5 KB = 8.9 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 5,229 bytes (5.1 KB = 0.0 MB)
aot-instances.aotdata.arm64: 827,592 bytes (808.2 KB = 0.8 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,147 bytes (1.1 KB = 0.0 MB)
+Info.plist: 1,141 bytes (1.1 KB = 0.0 MB)
Microsoft.iOS.aotdata.arm64: 22,992 bytes (22.5 KB = 0.0 MB)
Microsoft.iOS.dll: 49,152 bytes (48.0 KB = 0.0 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/iOS-NativeAOT-TrimmableStatic-size.txt b/tests/dotnet/UnitTests/expected/iOS-NativeAOT-TrimmableStatic-size.txt
index 75389a923d59..a367ebbb43e2 100644
--- a/tests/dotnet/UnitTests/expected/iOS-NativeAOT-TrimmableStatic-size.txt
+++ b/tests/dotnet/UnitTests/expected/iOS-NativeAOT-TrimmableStatic-size.txt
@@ -1,8 +1,8 @@
-AppBundleSize: 9,038,992 bytes (8,827.1 KB = 8.6 MB)
+AppBundleSize: 9,038,986 bytes (8,827.1 KB = 8.6 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 2,589 bytes (2.5 KB = 0.0 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,147 bytes (1.1 KB = 0.0 MB)
+Info.plist: 1,141 bytes (1.1 KB = 0.0 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,888 bytes (1.8 KB = 0.0 MB)
SizeTestApp: 9,032,976 bytes (8,821.3 KB = 8.6 MB)
diff --git a/tests/dotnet/UnitTests/expected/iOS-NativeAOT-size.txt b/tests/dotnet/UnitTests/expected/iOS-NativeAOT-size.txt
index 565b3f18fafb..f137a40fb64b 100644
--- a/tests/dotnet/UnitTests/expected/iOS-NativeAOT-size.txt
+++ b/tests/dotnet/UnitTests/expected/iOS-NativeAOT-size.txt
@@ -1,8 +1,8 @@
-AppBundleSize: 2,783,888 bytes (2,718.6 KB = 2.7 MB)
+AppBundleSize: 2,783,882 bytes (2,718.6 KB = 2.7 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 2,589 bytes (2.5 KB = 0.0 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,147 bytes (1.1 KB = 0.0 MB)
+Info.plist: 1,141 bytes (1.1 KB = 0.0 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,808 bytes (1.8 KB = 0.0 MB)
SizeTestApp: 2,777,952 bytes (2,712.8 KB = 2.6 MB)
diff --git a/tests/monotouch-test/CoreFoundation/ProxyTest.cs b/tests/monotouch-test/CoreFoundation/ProxyTest.cs
index 99c7c214d68b..3dc46ece6d40 100644
--- a/tests/monotouch-test/CoreFoundation/ProxyTest.cs
+++ b/tests/monotouch-test/CoreFoundation/ProxyTest.cs
@@ -18,23 +18,6 @@ namespace MonoTouchFixtures.CoreFoundation {
[TestFixture]
[Preserve (AllMembers = true)]
public class ProxyTest {
-
- [Test]
- public void Fields ()
- {
- // documented but symbols are missing
- // this test will fail if Apple decide to include them in the future
- IntPtr lib = Dlfcn.dlopen (Constants.CoreFoundationLibrary, 0);
- try {
- // http://developer.apple.com/library/ios/documentation/CoreFoundation/Reference/CFProxySupport/Reference/reference.html#//apple_ref/doc/c_ref/kCFProxyAutoConfigurationHTTPResponseKey
- Assert.That (Dlfcn.dlsym (lib, "kCFProxyAutoConfigurationHTTPResponseKey"), Is.EqualTo (IntPtr.Zero), "kCFProxyAutoConfigurationHTTPResponseKey");
- // http://developer.apple.com/library/ios/documentation/CoreFoundation/Reference/CFProxySupport/Reference/reference.html#//apple_ref/doc/c_ref/kCFNetworkProxiesProxyAutoConfigJavaScript
- Assert.That (Dlfcn.dlsym (lib, "kCFNetworkProxiesProxyAutoConfigJavaScript"), Is.EqualTo (IntPtr.Zero), "kCFNetworkProxiesProxyAutoConfigJavaScript");
- } finally {
- Dlfcn.dlclose (lib);
- }
- }
-
#if !MONOMAC
HttpListener listener;
int port;
diff --git a/tests/monotouch-test/CoreGraphics/GeometryTest.cs b/tests/monotouch-test/CoreGraphics/GeometryTest.cs
index f60ced6f596c..24eb3c0520b3 100644
--- a/tests/monotouch-test/CoreGraphics/GeometryTest.cs
+++ b/tests/monotouch-test/CoreGraphics/GeometryTest.cs
@@ -17,9 +17,8 @@ public class GeometryTest {
static public readonly IntPtr Handle = Dlfcn.dlopen (Constants.CoreGraphicsLibrary, 0);
- public static CGRect GetRect (string symbol)
+ public static CGRect GetRect (IntPtr indirect)
{
- var indirect = Dlfcn.dlsym (Handle, symbol);
if (indirect == IntPtr.Zero)
return CGRect.Empty;
unsafe {
@@ -31,7 +30,7 @@ public static CGRect GetRect (string symbol)
[Test]
public void Infinite ()
{
- var r = GetRect ("CGRectInfinite");
+ var r = GetRect (Dlfcn.dlsym (Handle, "CGRectInfinite"));
Assert.False (r.IsEmpty, "IsEmpty");
Assert.False (r.IsNull (), "IsNull");
Assert.True (r.IsInfinite (), "IsInfinite");
@@ -40,7 +39,7 @@ public void Infinite ()
[Test]
public void Null ()
{
- var r = GetRect ("CGRectNull");
+ var r = GetRect (Dlfcn.dlsym (Handle, "CGRectNull"));
Assert.True (r.IsEmpty, "IsEmpty");
Assert.True (r.IsNull (), "IsNull");
Assert.False (r.IsInfinite (), "IsInfinite");
@@ -49,7 +48,7 @@ public void Null ()
[Test]
public void Zero ()
{
- var r = GetRect ("CGRectZero");
+ var r = GetRect (Dlfcn.dlsym (Handle, "CGRectZero"));
Assert.True (r.IsEmpty, "IsEmpty");
Assert.False (r.IsNull (), "IsNull");
Assert.False (r.IsInfinite (), "IsInfinite");
diff --git a/tests/monotouch-test/Foundation/AttributedStringTest.cs b/tests/monotouch-test/Foundation/AttributedStringTest.cs
index 62ffbdbdd702..4844f9885cbb 100644
--- a/tests/monotouch-test/Foundation/AttributedStringTest.cs
+++ b/tests/monotouch-test/Foundation/AttributedStringTest.cs
@@ -52,28 +52,6 @@ void cb (NSDictionary attrs, NSRange range, ref bool stop)
failEnum = true;
}
- [Test]
- public void Fields ()
- {
- // fields are not available in iOS (at least up to 5.1.1)
- // this test will fail if this ever change in the future
- IntPtr lib = Dlfcn.dlopen (Constants.FoundationLibrary, 0);
- try {
- Assert.That (Dlfcn.dlsym (lib, "NSFontAttributeName"), Is.EqualTo (IntPtr.Zero), "NSFontAttributeName");
- Assert.That (Dlfcn.dlsym (lib, "NSLinkAttributeName"), Is.EqualTo (IntPtr.Zero), "NSLinkAttributeName");
- Assert.That (Dlfcn.dlsym (lib, "NSUnderlineStyleAttributeName"), Is.EqualTo (IntPtr.Zero), "NSUnderlineStyleAttributeName");
- Assert.That (Dlfcn.dlsym (lib, "NSStrikethroughStyleAttributeName"), Is.EqualTo (IntPtr.Zero), "NSStrikethroughStyleAttributeName");
- Assert.That (Dlfcn.dlsym (lib, "NSStrokeWidthAttributeName"), Is.EqualTo (IntPtr.Zero), "NSStrokeWidthAttributeName");
- Assert.That (Dlfcn.dlsym (lib, "NSParagraphStyleAttributeName"), Is.EqualTo (IntPtr.Zero), "NSParagraphStyleAttributeName");
- Assert.That (Dlfcn.dlsym (lib, "NSForegroundColorAttributeName"), Is.EqualTo (IntPtr.Zero), "NSForegroundColorAttributeName");
- Assert.That (Dlfcn.dlsym (lib, "NSBackgroundColorAttributeName"), Is.EqualTo (IntPtr.Zero), "NSBackgroundColorAttributeName");
- Assert.That (Dlfcn.dlsym (lib, "NSLigatureAttributeName"), Is.EqualTo (IntPtr.Zero), "NSLigatureAttributeName");
- Assert.That (Dlfcn.dlsym (lib, "NSObliquenessAttributeName"), Is.EqualTo (IntPtr.Zero), "NSObliquenessAttributeName");
- } finally {
- Dlfcn.dlclose (lib);
- }
- }
-
[Test]
public void UIKitAttachmentConveniences_New ()
{
diff --git a/tests/monotouch-test/ObjCRuntime/DlfcnTest.cs b/tests/monotouch-test/ObjCRuntime/DlfcnTest.cs
index aeda262d8b76..8fa51299cbbc 100644
--- a/tests/monotouch-test/ObjCRuntime/DlfcnTest.cs
+++ b/tests/monotouch-test/ObjCRuntime/DlfcnTest.cs
@@ -13,6 +13,53 @@ namespace MonoTouchFixtures.ObjCRuntime {
[Preserve (AllMembers = true)]
public class DlfcnTest {
+ // These tests exercise [Field]-backed properties from Apple frameworks.
+ // The generated binding code calls Dlfcn.GetStringConstant / GetIntPtr / etc.
+ // under the hood, which is what InlineDlfcnMethodsStep transforms.
+
+ [Test]
+ public void StringConstant_NSLocaleNotification ()
+ {
+ var value = NSLocale.CurrentLocaleDidChangeNotification;
+ Assert.IsNotNull (value, "CurrentLocaleDidChangeNotification");
+ Assert.AreEqual ("kCFLocaleCurrentLocaleDidChangeNotification", (string) value, "value");
+ }
+
+ [Test]
+ public void StringConstant_NSBundleNotification ()
+ {
+ var value = NSBundle.BundleDidLoadNotification;
+ Assert.IsNotNull (value, "BundleDidLoadNotification");
+ Assert.AreEqual ("NSBundleDidLoadNotification", (string) value, "value");
+ }
+
+ [Test]
+ public void StringConstant_NSUserDefaultsNotification ()
+ {
+ var value = NSUserDefaults.DidChangeNotification;
+ Assert.IsNotNull (value, "DidChangeNotification");
+ Assert.AreEqual ("NSUserDefaultsDidChangeNotification", (string) value, "value");
+ }
+
+ [Test]
+ public void StringConstant_NSUndoManagerNotification ()
+ {
+ var value = NSUndoManager.CheckpointNotification;
+ Assert.IsNotNull (value, "CheckpointNotification");
+ Assert.AreEqual ("NSUndoManagerCheckpointNotification", (string) value, "value");
+ }
+
+ [Test]
+ public void StringConstant_CachePointer ()
+ {
+ // Access several string constants multiple times to test caching behavior.
+ // The binding code uses Dlfcn.CachePointer for repeated accesses.
+ for (int i = 0; i < 3; i++) {
+ var value = NSLocale.CurrentLocaleDidChangeNotification;
+ Assert.IsNotNull (value, $"iteration {i}");
+ }
+ }
+
[Test]
public void OpenClose_libSystem ()
{
@@ -32,7 +79,7 @@ public void OpenClose_libSystem ()
[Test]
public void GetVariables ()
{
- var symbol = "x_native_field";
+ const string symbol = "x_native_field";
var handle = (IntPtr) Dlfcn.RTLD.Default;
Assert.AreNotEqual (IntPtr.Zero, Dlfcn.dlsym (handle, symbol), "Symbol");
@@ -63,8 +110,10 @@ public void GetVariables ()
Assert.AreEqual (-3.9541907E+28f, Dlfcn.GetStruct (handle, symbol), "GetStruct");
Assert.AreEqual (-7.7576533930025207E-103d, Dlfcn.GetStruct (handle, symbol), "GetStruct");
+#if !STATIC_NATIVE_SYMBOL_LOOKUP
Assert.AreEqual ((ulong) 0, Dlfcn.GetStruct (handle, "inexistent_symbol"), "GetStruct inexistent");
Assert.AreEqual ((ulong) 0, Dlfcn.GetStruct (handle, "inexistent_symbol").Value, "GetStruct inexistent");
+#endif
Dlfcn.SetInt16 (handle, symbol, 0x77);
Assert.AreEqual ((short) 0x77, Dlfcn.GetInt16 (handle, symbol), "SetInt16");
@@ -122,5 +171,24 @@ struct SomeValue {
public ulong Value;
}
#pragma warning restore CS0649
+
+ [Test]
+ public void FieldProperty_CGRect ()
+ {
+ Assert.Multiple (() => {
+ // CGRect.Null is backed by [Field("CGRectNull")] which calls Dlfcn.GetCGRect.
+ var value = global::CoreGraphics.CGRect.Null;
+ Assert.That (value.X, Is.EqualTo (nfloat.PositiveInfinity), "CGRectNull.X");
+ Assert.That (value.Y, Is.EqualTo (nfloat.PositiveInfinity), "CGRectNull.Y");
+ Assert.That (value.Width, Is.EqualTo ((nfloat) 0), "CGRectNull.Width");
+ Assert.That (value.Height, Is.EqualTo ((nfloat) 0), "CGRectNull.Height");
+
+ var infinite = global::CoreGraphics.CGRect.Infinite;
+ Assert.That (infinite.X, Is.EqualTo (nfloat.MinValue / 2), "CGRectInfinite.X");
+ Assert.That (infinite.Y, Is.EqualTo (nfloat.MinValue / 2), "CGRectInfinite.Y");
+ Assert.That (infinite.Width, Is.EqualTo (nfloat.MaxValue), "CGRectInfinite.Width");
+ Assert.That (infinite.Height, Is.EqualTo (nfloat.MaxValue), "CGRectInfinite.Height");
+ });
+ }
}
}
diff --git a/tests/monotouch-test/dotnet/shared.csproj b/tests/monotouch-test/dotnet/shared.csproj
index 37437089b7fe..c2c8eac87673 100644
--- a/tests/monotouch-test/dotnet/shared.csproj
+++ b/tests/monotouch-test/dotnet/shared.csproj
@@ -56,6 +56,7 @@
+
diff --git a/tests/xharness/Jenkins/TestVariationsFactory.cs b/tests/xharness/Jenkins/TestVariationsFactory.cs
index f7d7a2460eab..a095b00616b4 100644
--- a/tests/xharness/Jenkins/TestVariationsFactory.cs
+++ b/tests/xharness/Jenkins/TestVariationsFactory.cs
@@ -113,6 +113,10 @@ IEnumerable GetTestData (RunTestTask test)
yield return new TestData { Variation = "Debug (interpreter)", TestVariation = "interpreter", Ignored = ignore };
yield return new TestData { Variation = "Release (interpreter)", TestVariation = "release|interpreter", Ignored = ignore };
}
+ yield return new TestData { Variation = $"Release (compat inline dlfcn)", TestVariation = "inline-dlfcn-methods-compat|release", Ignored = ignore };
+ yield return new TestData { Variation = $"Release (strict inline dlfcn)", TestVariation = "inline-dlfcn-methods-strict|release", Ignored = ignore };
+ if (mac_supports_arm64)
+ yield return new TestData { Variation = $"Release (NativeAOT, .NET 11 defaults)", TestVariation = "inline-dlfcn-methods-strict|nativeaot|release", Ignored = ignore, RuntimeIdentifier = arm64_sim_runtime_identifier }; // it's necessary to specify RID, because NativeAOT defaults to building for device
break;
case "introspection":
if (mac_supports_arm64)
diff --git a/tools/common/CompilerFlags.cs b/tools/common/CompilerFlags.cs
index 1138c4ca917f..1181f05a6943 100644
--- a/tools/common/CompilerFlags.cs
+++ b/tools/common/CompilerFlags.cs
@@ -55,7 +55,7 @@ public void ReferenceSymbols (IEnumerable symbols, Abi abi)
foreach (var symbol in symbols) {
if (symbol.ValidAbis.HasValue && (symbol.ValidAbis.Value & abi) == 0)
continue;
- UnresolvedSymbols.Add (symbol.Prefix + symbol.Name);
+ UnresolvedSymbols.Add (Symbol.Prefix + symbol.Name);
}
}
diff --git a/tools/common/Frameworks.cs b/tools/common/Frameworks.cs
index cc617412239b..1a831735145d 100644
--- a/tools/common/Frameworks.cs
+++ b/tools/common/Frameworks.cs
@@ -7,6 +7,7 @@
using Mono.Tuner;
using Xamarin.Bundler;
+using Xamarin.Linker;
using Registrar;
#endif
@@ -453,7 +454,7 @@ public static Frameworks CreateiOSFrameworks (bool is_simulator_build)
{ "CoreLocationUI", "CoreLocationUI", 15,0 },
{ "DataDetection", "DataDetection", 15, 0 },
- { "Phase", "PHASE", new Version (15,0), NotAvailableInSimulator /* no headers in beta 2 */ },
+ { "Phase", "PHASE", new Version (15, 0), new Version (26, 0) /* not certain about the exact version when this framework was added to the simulator, but this should be a safe default */ },
{ "OSLog", "OSLog", 15,0 },
{ "ShazamKit", "ShazamKit", new Version (15,0), new Version (16, 0)},
{ "ThreadNetwork", "ThreadNetwork", new Version (15,0), NotAvailableInSimulator},
@@ -702,11 +703,12 @@ public static Frameworks GetMacCatalystFrameworks ()
}
}
-#if LEGACY_TOOLS || BUNDLER
- public static IEnumerable GetFrameworks (TypeDefinition td)
+#if BUNDLER
+ public static bool TryGetFramework (Application app, TypeDefinition td, [NotNullWhen (true)] out string? framework)
{
+ framework = null;
+
if (td.HasCustomAttributes) {
- var any = false;
foreach (var attrib in td.CustomAttributes) {
if (!attrib.AttributeType.Is ("ObjCRuntime", "ObjectiveCFrameworkAttribute"))
continue;
@@ -715,25 +717,56 @@ public static IEnumerable GetFrameworks (TypeDefinition td)
var arg = attrib.ConstructorArguments [0];
if (arg.Value is not string stringArgument)
continue;
- yield return stringArgument;
- any = true;
+ framework = stringArgument;
+ return framework is not null;
}
- if (any)
- yield break;
}
- yield return td.Namespace;
+ if (!app.Profile.IsProductAssembly (td.Module.Assembly))
+ return false;
+
+ framework = td.Namespace;
+ return framework is not null;
+ }
+
+ public static bool TryGetFramework (Application app, TypeDefinition td, [NotNullWhen (true)] out Framework? framework)
+ {
+ framework = null;
+
+ if (!TryGetFramework (app, td, out string? frameworkName))
+ return false;
+
+ var all_frameworks = GetFrameworks (app.Platform, app.IsSimulatorBuild);
+ if (all_frameworks is null)
+ return false;
+ return all_frameworks.TryGetValue (frameworkName, out framework);
}
- static void Gather (Application app, AssemblyDefinition product_assembly, HashSet frameworks, HashSet weak_frameworks, Func include_framework)
+ static void Gather (Application app, IEnumerable assemblies, HashSet frameworks, HashSet weak_frameworks, Func include_framework)
{
var namespaces = new HashSet ();
- // Collect all the namespaces.
- foreach (var md in product_assembly.Modules) {
- foreach (var td in md.Types) {
- foreach (var fw in GetFrameworks (td))
- namespaces.Add (fw);
+ // Process our product assembly + any assembly with the [ObjectiveCFramework] attribute, and collect all the namespaces that are used in those assemblies.
+ // For non-product assemblies, we only look at types with the [ObjectiveCFramework] attribute.
+ foreach (var assembly in assemblies) {
+ var hasObjectiveCFrameworkAttribute = false;
+ if (!app.Profile.IsProductAssembly (assembly)) {
+ hasObjectiveCFrameworkAttribute = assembly.MainModule.HasTypeReference ("ObjCRuntime.ObjectiveCFrameworkAttribute");
+ if (!hasObjectiveCFrameworkAttribute)
+ continue;
+ }
+
+ // Collect all the namespaces.
+ foreach (var md in assembly.Modules) {
+ foreach (var td in md.Types) {
+ if (hasObjectiveCFrameworkAttribute && !td.HasCustomAttribute ("ObjCRuntime", "ObjectiveCFrameworkAttribute"))
+ continue;
+
+ if (TryGetFramework (app, td, out string? framework)) {
+ namespaces.Add (framework);
+ continue;
+ }
+ }
}
}
@@ -798,9 +831,9 @@ static bool FilterFrameworks (Application app, Framework framework)
return true;
}
- public static void Gather (Application app, AssemblyDefinition product_assembly, HashSet frameworks, HashSet weak_frameworks)
+ public static void Gather (Application app, IEnumerable assemblies, HashSet frameworks, HashSet weak_frameworks)
{
- Gather (app, product_assembly, frameworks, weak_frameworks, (framework) => FilterFrameworks (app, framework));
+ Gather (app, assemblies, frameworks, weak_frameworks, (framework) => FilterFrameworks (app, framework));
}
-#endif // LEGACY_TOOLS || BUNDLER
+#endif // BUNDLER
}
diff --git a/tools/common/MachO.cs b/tools/common/MachO.cs
index 197c99736be1..f54f4e222d95 100644
--- a/tools/common/MachO.cs
+++ b/tools/common/MachO.cs
@@ -1,6 +1,7 @@
using System;
using System.Collections.Generic;
using System.IO;
+using System.Linq;
using System.Net;
using System.Text;
using Xamarin.Bundler;
@@ -90,6 +91,7 @@ public enum LoadCommands : uint {
// /* Constants for the cmd field of all load commands, the type */
//#define LC_SEGMENT 0x1 /* segment of this file to be mapped */
//#define LC_SYMTAB 0x2 /* link-edit stab symbol table info */
+ Symtab = 0x2,
//#define LC_SYMSEG 0x3 /* link-edit gdb symbol table info (obsolete) */
//#define LC_THREAD 0x4 /* thread */
//#define LC_UNIXTHREAD 0x5 /* unix thread (includes a stack) */
@@ -606,8 +608,8 @@ internal void Read (string filename, BinaryReader reader, long size)
file.Read (reader);
object_files.Add (file);
}
- // byte position is always even after each file.
- if (nextPosition % 1 == 1)
+ // The ar format requires each entry to start at an even byte offset.
+ if (nextPosition % 2 == 1)
nextPosition++;
reader.BaseStream.Position = nextPosition;
}
@@ -641,6 +643,33 @@ public static bool IsStaticLibrary (string filename, bool throw_if_error = false
}
}
}
+
+ ///
+ /// Reads a static library or a Mach-O object file and returns the set of unresolved (undefined external) symbols.
+ ///
+ public static HashSet GetUnresolvedSymbols (string filename)
+ {
+ var symbols = new HashSet ();
+ using (var fs = File.OpenRead (filename))
+ using (var reader = new BinaryReader (fs)) {
+ if (IsStaticLibrary (reader)) {
+ var lib = new StaticLibrary ();
+ lib.Read (filename, reader, fs.Length);
+ foreach (var obj in lib.ObjectFiles) {
+ foreach (var sym in obj.GetUnresolvedSymbols (reader))
+ symbols.Add (sym);
+ }
+ } else if (MachOFile.IsMachOLibrary (null, reader)) {
+ var obj = new MachOFile (filename);
+ obj.Read (reader);
+ foreach (var sym in obj.GetUnresolvedSymbols (reader))
+ symbols.Add (sym);
+ } else {
+ throw ErrorHelper.CreateError (1601, Errors.MT1601, System.Text.Encoding.ASCII.GetString (reader.ReadBytes (7), 0, 7));
+ }
+ }
+ return symbols;
+ }
}
public class MachOFile {
@@ -657,6 +686,7 @@ public class MachOFile {
uint _reserved;
bool is64bitheader;
+ long streamBasePosition; // position in the stream where this Mach-O header starts
public int cputype { get { return is_big_endian ? MachO.ToBigEndian (_cputype) : _cputype; } }
public int cpusubtype { get { return is_big_endian ? MachO.ToBigEndian (_cpusubtype) : _cpusubtype; } }
@@ -728,6 +758,8 @@ internal static bool IsMachOLibrary (FatEntry? fat_entry, BinaryReader reader, b
internal void Read (BinaryReader reader)
{
+ streamBasePosition = reader.BaseStream.Position;
+
/* definitions from: /usr/include/mach-o/loader.h */
/*
* The 32-bit mach header appears at the very beginning of the object file for
@@ -868,6 +900,16 @@ internal void Read (BinaryReader reader)
}
lc = buildVer;
break;
+ case MachO.LoadCommands.Symtab:
+ var symtabCmd = new SymtabLoadCommand ();
+ symtabCmd.cmd = reader.ReadUInt32 ();
+ symtabCmd.cmdsize = reader.ReadUInt32 ();
+ symtabCmd.symoff = reader.ReadUInt32 ();
+ symtabCmd.nsyms = reader.ReadUInt32 ();
+ symtabCmd.stroff = reader.ReadUInt32 ();
+ symtabCmd.strsize = reader.ReadUInt32 ();
+ lc = symtabCmd;
+ break;
default:
lc = new LoadCommand ();
lc.cmd = reader.ReadUInt32 ();
@@ -893,6 +935,58 @@ public bool IsDynamicLibrary {
public bool IsObjectFile {
get => filetype == MachO.MH_OBJECT;
}
+
+ const byte N_EXT = 0x01; // external symbol
+ const byte N_TYPE = 0x0e; // mask for type bits
+ const byte N_UNDF = 0x0; // undefined symbol
+
+ ///
+ /// Reads unresolved (undefined external) symbols from this Mach-O file.
+ /// The reader must be the same stream used to read this file.
+ ///
+ public HashSet GetUnresolvedSymbols (BinaryReader reader)
+ {
+ var symbols = new HashSet ();
+ var symtab = load_commands.OfType ().FirstOrDefault ();
+ if (symtab is null || symtab.nsyms == 0)
+ return symbols;
+
+ // Read the string table
+ reader.BaseStream.Position = streamBasePosition + symtab.stroff;
+ var stringTable = reader.ReadBytes ((int) symtab.strsize);
+
+ // Read symbol table entries
+ reader.BaseStream.Position = streamBasePosition + symtab.symoff;
+ var nlistSize = is64bitheader ? 16 : 12;
+ for (uint i = 0; i < symtab.nsyms; i++) {
+ var n_strx = reader.ReadUInt32 ();
+ var n_type = reader.ReadByte ();
+ var n_sect = reader.ReadByte ();
+ var n_desc = reader.ReadInt16 ();
+ if (is64bitheader)
+ reader.ReadUInt64 (); // n_value (8 bytes)
+ else
+ reader.ReadUInt32 (); // n_value (4 bytes)
+
+ // Filter for undefined external symbols (equivalent of nm -u)
+ if ((n_type & N_EXT) == 0)
+ continue;
+ if ((n_type & N_TYPE) != N_UNDF)
+ continue;
+
+ // Read symbol name from string table
+ if (n_strx >= symtab.strsize)
+ continue;
+ var end = (int) n_strx;
+ while (end < stringTable.Length && stringTable [end] != 0)
+ end++;
+ var name = Encoding.UTF8.GetString (stringTable, (int) n_strx, end - (int) n_strx);
+ if (name.Length > 0)
+ symbols.Add (name);
+ }
+
+ return symbols;
+ }
}
public class FatFile {
@@ -1148,4 +1242,11 @@ public MachO.Platform Platform {
get { return (MachO.Platform) platform; }
}
}
+
+ public class SymtabLoadCommand : LoadCommand {
+ public uint symoff; // offset to symbol table entries
+ public uint nsyms; // number of symbol table entries
+ public uint stroff; // offset to string table
+ public uint strsize; // size of string table in bytes
+ }
}
diff --git a/tools/common/Symbols.cs b/tools/common/Symbols.cs
index 7306afd5fa2f..6b1b13077fe5 100644
--- a/tools/common/Symbols.cs
+++ b/tools/common/Symbols.cs
@@ -27,7 +27,7 @@ public class Symbol {
public bool Ignore;
public Abi? ValidAbis;
- static string ObjectiveCPrefix {
+ public static string ObjectiveCPrefix {
get {
return "OBJC_CLASS_$_";
}
@@ -52,11 +52,7 @@ public string Name {
}
public string? ObjectiveCName;
- public string Prefix {
- get {
- return "_";
- }
- }
+ public const string Prefix = "_";
List members = new List ();
public IEnumerable Members { get { return members; } }
@@ -158,6 +154,7 @@ public Symbol this [string name] {
}
}
+#if !MSBUILD_TASKS
public void Load (string filename, Application app)
{
using (var reader = new StreamReader (filename)) {
@@ -183,6 +180,7 @@ public void Load (string filename, Application app)
}
}
}
+#endif // !MSBUILD_TASKS
public void Save (string filename)
{
diff --git a/tools/dotnet-linker/AppBundleRewriter.cs b/tools/dotnet-linker/AppBundleRewriter.cs
index f49c71d518bd..5013997108d1 100644
--- a/tools/dotnet-linker/AppBundleRewriter.cs
+++ b/tools/dotnet-linker/AppBundleRewriter.cs
@@ -422,6 +422,12 @@ public TypeReference ObjCRuntime_Class {
}
}
+ public TypeReference ObjCRuntime_Dlfcn {
+ get {
+ return GetTypeReference (PlatformAssembly, "ObjCRuntime.Dlfcn", out var _);
+ }
+ }
+
public TypeReference ObjCRuntime_IManagedRegistrar {
get {
return GetTypeReference (PlatformAssembly, "ObjCRuntime.IManagedRegistrar", out var _);
@@ -464,6 +470,12 @@ public TypeReference ObjCRuntime_NSObjectProxyAttribute {
}
}
+ public TypeReference ObjCRuntime_ObjectiveCFrameworkAttribute {
+ get {
+ return GetTypeReference (PlatformAssembly, "ObjCRuntime.ObjectiveCFrameworkAttribute", out var _);
+ }
+ }
+
public TypeReference ObjCRuntime_ProtocolProxyAttribute {
get {
return GetTypeReference (PlatformAssembly, "ObjCRuntime.ProtocolProxyAttribute", out var _);
@@ -726,6 +738,17 @@ public MethodReference Class_GetHandle__System_String {
}
}
+ public MethodReference ObjectiveCFrameworkAttribute_ctor_String {
+ get {
+ return GetMethodReference (PlatformAssembly, ObjCRuntime_ObjectiveCFrameworkAttribute, ".ctor", (v) =>
+ v.IsConstructor
+ && v.HasParameters
+ && v.Parameters.Count == 1
+ && v.Parameters [0].ParameterType.Is ("System", "String")
+ && !v.HasGenericParameters);
+ }
+ }
+
public MethodReference ObjCRuntime_INativeObjectProxyAttribute__ctor {
get {
return GetMethodReference (PlatformAssembly, ObjCRuntime_INativeObjectProxyAttribute, ".ctor", (v) => v.IsDefaultConstructor ());
diff --git a/tools/dotnet-linker/LinkerConfiguration.cs b/tools/dotnet-linker/LinkerConfiguration.cs
index 3acbcd16362e..5de07dbced9d 100644
--- a/tools/dotnet-linker/LinkerConfiguration.cs
+++ b/tools/dotnet-linker/LinkerConfiguration.cs
@@ -30,6 +30,13 @@ public class LinkerConfiguration {
public string IntermediateLinkDir { get; private set; } = string.Empty;
public bool InvariantGlobalization { get; private set; }
public bool HybridGlobalization { get; private set; }
+ public InlineDlfcnMethodsMode InlineDlfcnMethods { get; set; }
+ public bool InlineDlfcnMethodsEnabled => InlineDlfcnMethods != InlineDlfcnMethodsMode.Disabled;
+ // Per-assembly field symbols collected by InlineDlfcnMethodsStep, keyed by assembly name.
+ public Dictionary> InlinedDlfcnFields { get; } = new Dictionary> ();
+ // All [Field] symbol names collected by ProcessExportedFields, used in compatibility mode.
+ public HashSet FieldSymbols { get; } = new HashSet ();
+ public string IntermediateOutputPath { get; private set; } = string.Empty;
public string ItemsDirectory { get; private set; } = string.Empty;
public bool IsSimulatorBuild { get; private set; }
public string PartialStaticRegistrarLibrary { get; set; } = string.Empty;
@@ -46,6 +53,7 @@ public class LinkerConfiguration {
public Application Application { get; private set; }
public IList RegistrationMethods { get; set; } = new List ();
+ public List NativeCodeToCompileAndLink { get; private set; } = new List ();
public CompilerFlags CompilerFlags;
LinkContext? context;
@@ -202,9 +210,22 @@ public static LinkerConfiguration GetInstance (LinkContext context)
case "FrameworkAssembly":
FrameworkAssemblies.Add (value);
break;
+ case "InlineDlfcnMethods":
+ if (Enum.TryParse (value, true, out var inlineDlfcnMode))
+ InlineDlfcnMethods = inlineDlfcnMode;
+ else if (string.Equals (value, "compatibility", StringComparison.OrdinalIgnoreCase))
+ InlineDlfcnMethods = InlineDlfcnMethodsMode.Compat;
+ else if (string.IsNullOrEmpty (value))
+ InlineDlfcnMethods = InlineDlfcnMethodsMode.Disabled;
+ else
+ throw new InvalidOperationException ($"Unknown InlineDlfcnMethods value: {value}");
+ break;
case "IntermediateLinkDir":
IntermediateLinkDir = value;
break;
+ case "IntermediateOutputPath":
+ IntermediateOutputPath = value;
+ break;
case "Interpreter":
if (!string.IsNullOrEmpty (value))
Application.ParseInterpreter (value);
@@ -520,7 +541,9 @@ public void Write ()
Console.WriteLine ($" Dlsym: {Application.DlsymOptions} {(Application.DlsymAssemblies is not null ? string.Join (" ", Application.DlsymAssemblies.Select (v => (v.Item2 ? "+" : "-") + v.Item1)) : string.Empty)}");
Console.WriteLine ($" DeploymentTarget: {DeploymentTarget}");
Console.WriteLine ($" EnableSGenConc {Application.EnableSGenConc}");
+ Console.WriteLine ($" InlineDlfcnMethods: {InlineDlfcnMethods}");
Console.WriteLine ($" IntermediateLinkDir: {IntermediateLinkDir}");
+ Console.WriteLine ($" IntermediateOutputPath: {IntermediateOutputPath}");
Console.WriteLine ($" InterpretedAssemblies: {string.Join (", ", Application.InterpretedAssemblies)}");
Console.WriteLine ($" ItemsDirectory: {ItemsDirectory}");
Console.WriteLine ($" {FrameworkAssemblies.Count} framework assemblies:");
@@ -637,3 +660,9 @@ public MSBuildItem (string include, Dictionary metadata)
Metadata = metadata;
}
}
+
+public enum InlineDlfcnMethodsMode {
+ Disabled,
+ Strict,
+ Compat,
+}
diff --git a/tools/dotnet-linker/Steps/AssemblyModifierStep.cs b/tools/dotnet-linker/Steps/AssemblyModifierStep.cs
index 2e3e971d4d87..8e2899fb0660 100644
--- a/tools/dotnet-linker/Steps/AssemblyModifierStep.cs
+++ b/tools/dotnet-linker/Steps/AssemblyModifierStep.cs
@@ -31,7 +31,8 @@ protected sealed override void TryProcessAssembly (AssemblyDefinition assembly)
protected virtual bool ModifyAssembly (AssemblyDefinition assembly)
{
var modified = false;
- foreach (var type in assembly.MainModule.Types)
+ // ToArray () is needed because subclasses (e.g. InlineDlfcnMethodsStep) may add new types during iteration.
+ foreach (var type in assembly.MainModule.Types.ToArray ())
modified |= ProcessTypeImpl (type);
return modified;
}
@@ -50,7 +51,8 @@ bool ProcessTypeImpl (TypeDefinition type)
{
var modified = ProcessType (type);
if (type.HasNestedTypes) {
- foreach (var nested in type.NestedTypes)
+ // ToArray () is needed because subclasses may add new types during iteration.
+ foreach (var nested in type.NestedTypes.ToArray ())
modified |= ProcessTypeImpl (nested);
}
return modified;
diff --git a/tools/dotnet-linker/Steps/GatherFrameworksStep.cs b/tools/dotnet-linker/Steps/GatherFrameworksStep.cs
index 4d5eb1fbfca7..5fb658b02f89 100644
--- a/tools/dotnet-linker/Steps/GatherFrameworksStep.cs
+++ b/tools/dotnet-linker/Steps/GatherFrameworksStep.cs
@@ -20,10 +20,7 @@ protected override void TryProcessAssembly (AssemblyDefinition assembly)
{
base.TryProcessAssembly (assembly);
- if (Configuration.PlatformAssembly != assembly.Name.Name)
- return;
-
- global::Frameworks.Gather (Configuration.Application, assembly, Frameworks, WeakFrameworks);
+ global::Frameworks.Gather (Configuration.Application, [assembly], Frameworks, WeakFrameworks);
}
protected override void TryEndProcess ()
diff --git a/tools/dotnet-linker/Steps/GenerateReferencesStep.cs b/tools/dotnet-linker/Steps/GenerateReferencesStep.cs
index 7d1f08537fb3..4a3959aa0f80 100644
--- a/tools/dotnet-linker/Steps/GenerateReferencesStep.cs
+++ b/tools/dotnet-linker/Steps/GenerateReferencesStep.cs
@@ -38,7 +38,7 @@ protected override void TryEndProcess ()
break;
case SymbolMode.Linker:
foreach (var symbol in required_symbols) {
- var item = new MSBuildItem (symbol.Prefix + symbol.Name);
+ var item = new MSBuildItem (Symbol.Prefix + symbol.Name);
item.Metadata ["SymbolType"] = symbol.Type.ToString ();
items.Add (item);
}
diff --git a/tools/dotnet-linker/Steps/InlineDlfcnMethodsStep.cs b/tools/dotnet-linker/Steps/InlineDlfcnMethodsStep.cs
new file mode 100644
index 000000000000..0012ca7a456f
--- /dev/null
+++ b/tools/dotnet-linker/Steps/InlineDlfcnMethodsStep.cs
@@ -0,0 +1,1015 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT License.
+
+using System;
+using System.Collections.Generic;
+using System.IO;
+using System.Linq;
+
+using Mono.Cecil;
+using Mono.Cecil.Cil;
+using Mono.Cecil.Rocks;
+using Mono.Linker;
+using Mono.Linker.Steps;
+using Mono.Tuner;
+using MonoTouch.Tuner;
+
+using Xamarin.Bundler;
+
+#nullable enable
+
+namespace Xamarin.Linker.Steps;
+
+// See docs/code/native-symbols.md for an overview of native symbol handling.
+public class InlineDlfcnMethodsStep : AssemblyModifierStep {
+
+ protected override string Name { get; } = "Inline Dlfcn Methods";
+ protected override int ErrorCode { get; } = 2250;
+
+ bool strictMode;
+
+ protected override void TryProcess ()
+ {
+ strictMode = Configuration.InlineDlfcnMethods == InlineDlfcnMethodsMode.Strict;
+ base.TryProcess ();
+ }
+
+ string? current_framework;
+ protected override bool ProcessType (TypeDefinition type)
+ {
+ var modified = false;
+ if (type.HasMethods) {
+ if (Frameworks.TryGetFramework (App, type, out Framework? framework) && App.IsSimulatorBuild && !framework.IsFrameworkAvailableInSimulator (App)) {
+ Driver.Log (3, $"Type {type.FullName} appears to be part of the '{framework.Name}' framework, which is not available in the simulator. Skipping inlining Dlfcn calls for this type.");
+ return modified;
+ }
+
+ current_framework = framework?.Namespace;
+
+ foreach (var method in type.Methods)
+ modified |= ProcessMethod (method);
+
+ current_framework = null;
+ }
+ return modified;
+ }
+
+ TypeDefinition GetDlfcnType (MethodDefinition callingMethod)
+ {
+ // Check if there's a [Field] attribute with a second string argument (the library/namespace).
+ // The [Field] attribute can be on the method itself, or on the property the method is a getter/setter for.
+ var libraryName = callingMethod.HasCustomAttributes ? GetFieldAttributeLibraryName (callingMethod.CustomAttributes) : null;
+ if (libraryName is null && callingMethod.DeclaringType.HasProperties) {
+ foreach (var property in callingMethod.DeclaringType.Properties) {
+ if (property.GetMethod == callingMethod || property.SetMethod == callingMethod) {
+ libraryName = GetFieldAttributeLibraryName (property.CustomAttributes);
+ break;
+ }
+ }
+ }
+
+ if (libraryName is not null)
+ return GetDlfcnType (callingMethod.Module, callingMethod.DeclaringType.Namespace, libraryName);
+
+ return GetDlfcnType (callingMethod.Module, callingMethod.DeclaringType.Namespace);
+ }
+
+ static string? GetFieldAttributeLibraryName (IList? attributes)
+ {
+ if (attributes is null || attributes.Count == 0)
+ return null;
+
+ foreach (var attrib in attributes) {
+ if (attrib.AttributeType.Name != "FieldAttribute")
+ continue;
+ if (attrib.ConstructorArguments.Count == 2 &&
+ attrib.ConstructorArguments [1].Type.Name == "String" &&
+ attrib.ConstructorArguments [1].Value is string libraryName &&
+ !string.IsNullOrEmpty (libraryName)) {
+ return libraryName;
+ }
+ }
+
+ return null;
+ }
+
+ // It's important to use a type in the same namespace as the calling code, so that
+ // we correctly compute which frameworks to link with.
+ TypeDefinition GetDlfcnType (ModuleDefinition module, string @namespace, string? fieldLibraryName = null)
+ {
+ var frameworkOverride = !string.IsNullOrEmpty (fieldLibraryName) ? fieldLibraryName : current_framework;
+ var ns = string.IsNullOrEmpty (frameworkOverride) ? @namespace : frameworkOverride;
+ var dlfcn = module.Types.FirstOrDefault (t => t.Namespace == ns && t.Name == "Dlfcn");
+ if (dlfcn is null) {
+ dlfcn = new TypeDefinition (ns, "Dlfcn", TypeAttributes.NotPublic | TypeAttributes.Sealed, module.TypeSystem.Object);
+ module.Types.Add (dlfcn);
+
+ if (!string.IsNullOrEmpty (frameworkOverride)) {
+ var attrib = new CustomAttribute (abr.ObjectiveCFrameworkAttribute_ctor_String);
+ attrib.ConstructorArguments.Add (new CustomAttributeArgument (abr.System_String, frameworkOverride));
+ dlfcn.CustomAttributes.Add (attrib);
+ }
+ }
+ return dlfcn;
+ }
+
+ void AddField (string assemblyName, string symbolName)
+ {
+ if (!Configuration.InlinedDlfcnFields.TryGetValue (assemblyName, out var set)) {
+ set = new HashSet ();
+ Configuration.InlinedDlfcnFields [assemblyName] = set;
+ }
+ set.Add (symbolName);
+ }
+
+ MethodDefinition GetOrCreatePInvokeMethod (MethodDefinition callingMethod, string symbolName)
+ {
+ var dlfcn = GetDlfcnType (callingMethod);
+ var methodName = $"xamarin_Dlfcn_{symbolName}_Native";
+ var nativeMethod = methodName;
+ var rv = dlfcn.Methods.FirstOrDefault (m => m.Name == methodName);
+ if (rv is not null)
+ return rv; // already exists, no need to create it again
+
+ // [DllImport ("__Internal")]
+ // static extern IntPtr xamarin_Dlfcn_{symbolName}_Native ();
+
+ rv = new MethodDefinition (methodName, MethodAttributes.Public | MethodAttributes.Static | MethodAttributes.PInvokeImpl, abr.System_IntPtr);
+ rv.IsPreserveSig = true;
+
+ var mod = callingMethod.Module.ModuleReferences.FirstOrDefault (mr => mr.Name == "__Internal");
+ if (mod is null) {
+ mod = new ModuleReference ("__Internal");
+ callingMethod.Module.ModuleReferences.Add (mod);
+ }
+ rv.PInvokeInfo = new PInvokeInfo (PInvokeAttributes.CharSetNotSpec | PInvokeAttributes.CallConvCdecl, nativeMethod, mod);
+
+ dlfcn.Methods.Add (rv);
+
+ AddField (callingMethod.Module.Assembly.Name.Name, symbolName);
+
+ return rv;
+ }
+
+ MethodDefinition GetOrCreateGetSymbolMethod (MethodDefinition callingMethod, string symbolName)
+ {
+ var dlfcn = GetDlfcnType (callingMethod);
+ var methodName = $"Get__{symbolName}";
+ var symbolMethod = dlfcn.Methods.FirstOrDefault (m => m.Name == methodName);
+ if (symbolMethod is not null)
+ return symbolMethod; // already exists, no need to create it again
+
+ // static bool Get__{symbolName}_Initialized;
+ // static IntPtr Get__{symbolName}_Cached;
+ // static IntPtr Get__{symbolName} ()
+ // {
+ // if (!Get__{symbolName}_Initialized) {
+ // Get__{symbolName}_Cached = xamarin_Dlfcn_{symbolName}_Native ();
+ // Get__{symbolName}_Initialized = true;
+ // }
+ // return Get__{symbolName}_Cached;
+ // }
+
+ var initializedField = new FieldDefinition ($"Get__{symbolName}_Initialized", FieldAttributes.Private | FieldAttributes.Static, callingMethod.Module.TypeSystem.Boolean);
+ dlfcn.Fields.Add (initializedField);
+
+ var cachedField = new FieldDefinition ($"Get__{symbolName}_Cached", FieldAttributes.Private | FieldAttributes.Static, abr.System_IntPtr);
+ dlfcn.Fields.Add (cachedField);
+
+ var intptr = abr.System_IntPtr;
+ symbolMethod = new MethodDefinition (methodName, MethodAttributes.Public | MethodAttributes.Static, intptr);
+ dlfcn.Methods.Add (symbolMethod);
+
+ var body = symbolMethod.Body;
+ var il = body.GetILProcessor ();
+
+ var loadCachedFieldInstruction = il.Create (OpCodes.Ldsfld, cachedField);
+
+ // if (!Get__{symbolName}_Initialized) {
+ // The initialized field must use volatile semantics to prevent ARM64 store
+ // reordering: without it, another thread could see Initialized=true before
+ // the Cached value is written, and return a stale IntPtr.Zero.
+ // Note that we don't care if we call the P/Invoke more than once, that's
+ // a safe operation, we just don't want to call it every time.
+ il.Append (il.Create (OpCodes.Volatile));
+ il.Append (il.Create (OpCodes.Ldsfld, initializedField));
+ il.Append (il.Create (OpCodes.Brtrue, loadCachedFieldInstruction));
+
+ // Get__{symbolName}_Cached = xamarin_Dlfcn_{symbolName}_Native ();
+ il.Append (il.Create (OpCodes.Call, GetOrCreatePInvokeMethod (callingMethod, symbolName)));
+ il.Append (il.Create (OpCodes.Stsfld, cachedField));
+
+ // Get__{symbolName}_Initialized = true;
+ il.Append (il.Create (OpCodes.Ldc_I4_1));
+ il.Append (il.Create (OpCodes.Volatile));
+ il.Append (il.Create (OpCodes.Stsfld, initializedField));
+
+ // return Get__{symbolName}_Cached;
+ il.Append (loadCachedFieldInstruction);
+ il.Append (il.Create (OpCodes.Ret));
+
+ return symbolMethod;
+ }
+
+ MethodDefinition GetOrCreateGetNativeFieldMethod (MethodDefinition callingMethod, TypeReference fieldType, string symbolName)
+ {
+ var dlfcn = GetDlfcnType (callingMethod);
+ var methodName = $"Get__{symbolName}_{fieldType.Name}";
+ var rv = dlfcn.Methods.FirstOrDefault (m => m.Name == methodName);
+ if (rv is not null)
+ return rv; // already exists, no need to create it again
+
+ // static FieldType Get__{symbolName}_{fieldType} ()
+ // {
+ // var ptr = Get__{symbolName} ();
+ // if (ptr == IntPtr.Zero)
+ // return default;
+ //
+ // /* if value type */
+ // return *(FieldType*)ptr;
+ //
+ // /* if not value type */
+ // return Runtime.GetNSObject (*ptr);
+ // }
+
+ var importedFieldType = callingMethod.Module.ImportReference (fieldType);
+ rv = new MethodDefinition (methodName, MethodAttributes.Public | MethodAttributes.Static, importedFieldType);
+ dlfcn.Methods.Add (rv);
+
+ var body = rv.Body;
+ var il = body.GetILProcessor ();
+
+ var ptrVariable = new VariableDefinition (abr.System_IntPtr);
+ body.Variables.Add (ptrVariable);
+
+ var loadPointerInstructionStart = il.Create (OpCodes.Ldloc, ptrVariable);
+
+ // var ptr = Get__{symbolName} ();
+ il.Append (il.Create (OpCodes.Call, GetOrCreateGetSymbolMethod (callingMethod, symbolName)));
+ il.Append (il.Create (OpCodes.Stloc, ptrVariable));
+
+ // if (ptr == IntPtr.Zero)
+ il.Append (il.Create (OpCodes.Ldloc, ptrVariable));
+ il.Append (il.Create (OpCodes.Ldsfld, abr.System_IntPtr_Zero));
+ il.Append (il.Create (OpCodes.Bne_Un, loadPointerInstructionStart));
+
+ // return default;
+ var fullFieldTypeName = fieldType.FullName;
+ switch (fullFieldTypeName) {
+ case "System.Byte":
+ case "System.SByte":
+ case "System.Int16":
+ case "System.UInt16":
+ case "System.Int32":
+ case "System.UInt32":
+ il.Append (il.Create (OpCodes.Ldc_I4_0));
+ break;
+ case "System.Int64":
+ il.Append (il.Create (OpCodes.Ldc_I4_0));
+ il.Append (il.Create (OpCodes.Conv_I8));
+ break;
+ case "System.UInt64":
+ il.Append (il.Create (OpCodes.Ldc_I4_0));
+ il.Append (il.Create (OpCodes.Conv_U8));
+ break;
+ case "System.Single":
+ il.Append (il.Create (OpCodes.Ldc_R4, 0f));
+ break;
+ case "System.Double":
+ il.Append (il.Create (OpCodes.Ldc_R8, 0.0));
+ break;
+ case "System.IntPtr":
+ case "System.UIntPtr":
+ il.Append (il.Create (OpCodes.Ldc_I4_0));
+ il.Append (il.Create (OpCodes.Conv_I));
+ break;
+ default:
+ if (fieldType.IsValueType) {
+ if (fieldType.IsPrimitive) {
+ Report (ErrorHelper.CreateWarning (Configuration.Application, 2254 /* Unsupported primitive field type '{0}' for symbol '{1}' in method '{2}'. Sub-optimal but functional code will be generated. Please file an issue at https://github.com/dotnet/macios/issues/new. */, callingMethod, Errors.MX2254, fieldType.FullName, symbolName, FormatMethod (callingMethod)));
+ }
+ var defaultTemporary = new VariableDefinition (importedFieldType);
+ body.Variables.Add (defaultTemporary);
+ il.Append (il.Create (OpCodes.Ldloca, defaultTemporary));
+ il.Append (il.Create (OpCodes.Initobj, importedFieldType));
+ il.Append (il.Create (OpCodes.Ldloc, defaultTemporary));
+ } else {
+ il.Append (il.Create (OpCodes.Ldnull));
+ }
+ break;
+ }
+ il.Append (il.Create (OpCodes.Ret));
+
+ // /* if value type */
+ // return *(FieldType*)ptr;
+ // /* if not value type */
+ // return Runtime.GetNSObject (*(IntPtr*)ptr);
+ il.Append (loadPointerInstructionStart); // il.Create (OpCodes.Ldloc, ptrVariable);
+ if (fieldType.IsValueType) {
+ switch (fieldType.FullName) {
+ case "System.Byte":
+ il.Append (il.Create (OpCodes.Ldind_U1));
+ break;
+ case "System.SByte":
+ il.Append (il.Create (OpCodes.Ldind_I1));
+ break;
+ case "System.Int16":
+ il.Append (il.Create (OpCodes.Ldind_I2));
+ break;
+ case "System.UInt16":
+ il.Append (il.Create (OpCodes.Ldind_U2));
+ break;
+ case "System.Int32":
+ il.Append (il.Create (OpCodes.Ldind_I4));
+ break;
+ case "System.UInt32":
+ il.Append (il.Create (OpCodes.Ldind_U4));
+ break;
+ case "System.Int64":
+ case "System.UInt64":
+ il.Append (il.Create (OpCodes.Ldind_I8));
+ break;
+ case "System.Single":
+ il.Append (il.Create (OpCodes.Ldind_R4));
+ break;
+ case "System.Double":
+ il.Append (il.Create (OpCodes.Ldind_R8));
+ break;
+ case "System.IntPtr":
+ case "System.UIntPtr":
+ il.Append (il.Create (OpCodes.Ldind_I));
+ break;
+ default:
+ if (fieldType.IsPrimitive) {
+ Report (ErrorHelper.CreateWarning (Configuration.Application, 2254 /* Unsupported primitive field type '{0}' for symbol '{1}' in method '{2}'. Sub-optimal but functional code will be generated. Please file an issue at https://github.com/dotnet/macios/issues/new. */, callingMethod, Errors.MX2254, fieldType.FullName, symbolName, FormatMethod (callingMethod)));
+ }
+ il.Append (il.Create (OpCodes.Ldobj, importedFieldType));
+ break;
+ }
+ } else if (IsNSObjectSubclass (fieldType)) {
+ il.Append (il.Create (OpCodes.Ldind_I));
+ var getnsobject = abr.Runtime_GetNSObject_T___System_IntPtr.CreateGenericInstanceMethod (importedFieldType);
+ il.Append (il.Create (OpCodes.Call, getnsobject));
+ } else {
+ Report (ErrorHelper.CreateError (Configuration.Application, 2256 /* The field type '{0}' for symbol '{1}' in method '{2}' is not an NSObject subclass. Please file an issue at https://github.com/dotnet/macios/issues/new */, callingMethod, Errors.MX2256, fieldType.FullName, symbolName, FormatMethod (callingMethod)));
+ }
+ il.Append (il.Create (OpCodes.Ret));
+
+ return rv;
+ }
+
+ MethodDefinition GetOrCreateSetNativeFieldMethod (MethodDefinition callingMethod, TypeReference fieldType, string symbolName)
+ {
+ var dlfcn = GetDlfcnType (callingMethod);
+ var methodName = $"Set__{symbolName}_{fieldType.Name}";
+ var rv = dlfcn.Methods.FirstOrDefault (m => m.Name == methodName);
+ if (rv is not null)
+ return rv; // already exists, no need to create it again
+
+ // static void Set__{symbolName}_{fieldType} ({FieldType} value)
+ // {
+ // var ptr = Get__{symbolName} ();
+ // if (ptr == IntPtr.Zero)
+ // return;
+ //
+ // /* if value type */
+ // *(FieldType*)ptr = value;
+ //
+ // /* if not value type */
+ // *(IntPtr*)ptr = (IntPtr) Runtime.RetainNSObject (value)
+ // }
+ //
+ // Notes:
+ // * Just like the Dlfcn method(s), this generated code does not release an existing value of a field.
+
+ var importedFieldType = callingMethod.Module.ImportReference (fieldType);
+ rv = new MethodDefinition (methodName, MethodAttributes.Public | MethodAttributes.Static, abr.System_Void);
+ rv.Parameters.Add (new ParameterDefinition ("value", ParameterAttributes.None, importedFieldType));
+ dlfcn.Methods.Add (rv);
+
+ var body = rv.Body;
+ var il = body.GetILProcessor ();
+
+ var ptrVariable = new VariableDefinition (abr.System_IntPtr);
+ body.Variables.Add (ptrVariable);
+
+ var loadPointerInstructionStart = il.Create (OpCodes.Ldloc, ptrVariable);
+
+ // var ptr = Get__{symbolName} ();
+ il.Append (il.Create (OpCodes.Call, GetOrCreateGetSymbolMethod (callingMethod, symbolName)));
+ il.Append (il.Create (OpCodes.Stloc, ptrVariable));
+
+ // if (ptr == IntPtr.Zero)
+ il.Append (il.Create (OpCodes.Ldloc, ptrVariable));
+ il.Append (il.Create (OpCodes.Ldsfld, abr.System_IntPtr_Zero));
+ il.Append (il.Create (OpCodes.Bne_Un, loadPointerInstructionStart));
+ // return;
+ il.Append (il.Create (OpCodes.Ret));
+
+ // /* if value type */
+ // *(FieldType*)ptr = value;
+ // /* if not value type */
+ // *(IntPtr*)ptr = (IntPtr) Runtime.RetainNSObject (value)
+ il.Append (loadPointerInstructionStart); // il.Create (OpCodes.Ldloc, ptrVariable);
+ il.Append (il.Create (OpCodes.Ldarg_0));
+ if (fieldType.IsValueType) {
+ switch (fieldType.FullName) {
+ case "System.Byte":
+ case "System.SByte":
+ il.Append (il.Create (OpCodes.Stind_I1));
+ break;
+ case "System.Int16":
+ case "System.UInt16":
+ il.Append (il.Create (OpCodes.Stind_I2));
+ break;
+ case "System.Int32":
+ case "System.UInt32":
+ il.Append (il.Create (OpCodes.Stind_I4));
+ break;
+ case "System.Int64":
+ case "System.UInt64":
+ il.Append (il.Create (OpCodes.Stind_I8));
+ break;
+ case "System.Single":
+ il.Append (il.Create (OpCodes.Stind_R4));
+ break;
+ case "System.Double":
+ il.Append (il.Create (OpCodes.Stind_R8));
+ break;
+ case "System.IntPtr":
+ case "System.UIntPtr":
+ il.Append (il.Create (OpCodes.Stind_I));
+ break;
+ default:
+ if (fieldType.IsPrimitive) {
+ Report (ErrorHelper.CreateWarning (Configuration.Application, 2254 /* Unsupported primitive field type '{0}' for symbol '{1}' in method '{2}'. Sub-optimal but functional code will be generated. Please file an issue at https://github.com/dotnet/macios/issues/new. */, callingMethod, Errors.MX2254, fieldType.FullName, symbolName, FormatMethod (callingMethod)));
+ }
+ il.Append (il.Create (OpCodes.Stobj, importedFieldType));
+ break;
+ }
+ } else if (IsNSObjectSubclass (fieldType)) {
+ il.Append (il.Create (OpCodes.Call, abr.Runtime_RetainNSObject));
+ il.Append (il.Create (OpCodes.Call, abr.NativeObject_op_Implicit_IntPtr));
+ il.Append (il.Create (OpCodes.Stind_I));
+ } else {
+ Report (ErrorHelper.CreateError (Configuration.Application, 2256 /* The field type '{0}' for symbol '{1}' in method '{2}' is not an NSObject subclass. Please file an issue at https://github.com/dotnet/macios/issues/new */, callingMethod, Errors.MX2256, fieldType.FullName, symbolName, FormatMethod (callingMethod)));
+ }
+ il.Append (il.Create (OpCodes.Ret));
+
+ return rv;
+ }
+
+ MethodDefinition GetOrCreateSetNativeStringMethod (MethodDefinition callingMethod, string symbolName)
+ {
+ var dlfcn = GetDlfcnType (callingMethod);
+ var methodName = $"Set__{symbolName}_String";
+ var rv = dlfcn.Methods.FirstOrDefault (m => m.Name == methodName);
+ if (rv is not null)
+ return rv; // already exists, no need to create it again
+
+ // static FieldType Set__{symbolName}_String (string? value)
+ // {
+ // var ptr = Get__{symbolName} ();
+ // if (ptr == IntPtr.Zero)
+ // return;
+ //
+ // *(IntPtr*)ptr = (IntPtr) CFString.CreateNative (value);
+ // }
+ //
+ // Notes:
+ // * Just like the Dlfcn method(s), this generated code does not release an existing value of a field.
+
+ rv = new MethodDefinition (methodName, MethodAttributes.Public | MethodAttributes.Static, abr.System_Void);
+ rv.Parameters.Add (new ParameterDefinition ("value", ParameterAttributes.None, abr.System_String));
+ dlfcn.Methods.Add (rv);
+
+ var body = rv.Body;
+ var il = body.GetILProcessor ();
+
+ var ptrVariable = new VariableDefinition (abr.System_IntPtr);
+ body.Variables.Add (ptrVariable);
+
+ var loadPointerInstructionStart = il.Create (OpCodes.Ldloc, ptrVariable);
+
+ // var ptr = Get__{symbolName} ();
+ il.Append (il.Create (OpCodes.Call, GetOrCreateGetSymbolMethod (callingMethod, symbolName)));
+ il.Append (il.Create (OpCodes.Stloc, ptrVariable));
+
+ // if (ptr == IntPtr.Zero)
+ il.Append (il.Create (OpCodes.Ldloc, ptrVariable));
+ il.Append (il.Create (OpCodes.Ldsfld, abr.System_IntPtr_Zero));
+ il.Append (il.Create (OpCodes.Bne_Un, loadPointerInstructionStart));
+ // return;
+ il.Append (il.Create (OpCodes.Ret));
+
+ // *(IntPtr*)ptr = (IntPtr) CFString.CreateNative (value);
+ il.Append (loadPointerInstructionStart); // il.Create (OpCodes.Ldloc, ptrVariable);
+ il.Append (il.Create (OpCodes.Ldarg_0));
+ il.Append (il.Create (OpCodes.Call, abr.CFString_CreateNative));
+ il.Append (il.Create (OpCodes.Call, abr.NativeObject_op_Implicit_IntPtr));
+ il.Append (il.Create (OpCodes.Stind_I));
+ il.Append (il.Create (OpCodes.Ret));
+
+ return rv;
+ }
+
+ bool InlineSymbol (string symbolName)
+ {
+ // In compatibility mode, only inline symbols from [Field] attributes.
+ if (!strictMode && !Configuration.FieldSymbols.Contains (symbolName))
+ return false;
+
+ // These symbols already come from [Objective-]C code, so they should already be valid identifiers,
+ // which means we don't have to validate them.
+
+ var requiredSymbol = DerivedLinkContext.RequiredSymbols.Find (symbolName);
+ if (requiredSymbol?.Mode == SymbolMode.Ignore)
+ return false; // don't inline if the symbol is to be ignored
+
+ return true;
+ }
+
+ protected override bool ProcessMethod (MethodDefinition method)
+ {
+ var modified = false;
+
+ if (!method.HasBody)
+ return modified;
+
+ if (method.DeclaringType.Name == "Dlfcn" && method.DeclaringType.Namespace == "ObjCRuntime")
+ return modified; // don't process the Dlfcn methods themselves
+
+ foreach (var instr in method.Body.Instructions) {
+ if (instr.Operand is not MethodReference mr)
+ continue;
+ if (mr.DeclaringType.Name != "Dlfcn" || mr.DeclaringType.Namespace != "ObjCRuntime")
+ continue;
+
+ // Handle Dlfcn functions of the form (libraryHandle, symbolName)
+ if (mr.Parameters.Count == 2 && mr.Parameters [0].ParameterType.FullName == "System.IntPtr" && mr.Parameters [1].ParameterType.FullName == "System.String") {
+ if (instr.Previous.OpCode != OpCodes.Ldstr) {
+ Report (ErrorHelper.CreateWarning (Configuration.Application, 2255 /* Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new. */, method, Errors.MX2255, FormatMethod (mr), FormatMethod (method)));
+ continue;
+ }
+
+ // In compatibility mode, only inline symbols from [Field] attributes.
+ var ldstr = instr.Previous;
+ if (ldstr.Operand is not string symbolName) {
+ Report (ErrorHelper.CreateWarning (Configuration.Application, 2255 /* Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new. */, method, Errors.MX2255, FormatMethod (mr), FormatMethod (method)));
+ continue;
+ }
+ if (!InlineSymbol (symbolName))
+ continue;
+
+ switch (mr.Name) {
+ // primitive types
+ case "GetDouble":
+ case "GetFloat":
+ case "GetNFloat":
+ case "GetIntPtr":
+ case "GetUIntPtr":
+ case "GetNInt":
+ case "GetNUInt":
+ case "GetInt16":
+ case "GetUInt16":
+ case "GetInt32":
+ case "GetUInt32":
+ case "GetInt64":
+ case "GetUInt64":
+ // non-primitive value types
+ case "GetCGSize":
+ case "GetCGRect":
+ // classes
+ case "GetNSNumber":
+ case "GetStringConstant":
+ ldstr.OpCode = OpCodes.Pop; // just pop the library handle/name, we don't need it
+ ldstr.Operand = null;
+
+ instr.OpCode = OpCodes.Call;
+ instr.Operand = GetOrCreateGetNativeFieldMethod (method, mr.ReturnType, symbolName);
+
+ modified = true;
+ continue;
+ case "GetStruct":
+ if (mr is not GenericInstanceMethod gim || gim.GenericArguments.Count != 1) {
+ Report (ErrorHelper.CreateWarning (Configuration.Application, 2255 /* Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new. */, method, Errors.MX2255, FormatMethod (mr), FormatMethod (method)));
+ continue;
+ }
+ var returnType = gim.GenericArguments [0];
+ if (returnType.IsGenericInstance) {
+ Report (ErrorHelper.CreateWarning (Configuration.Application, 2255 /* Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new. */, method, Errors.MX2255, FormatMethod (mr), FormatMethod (method)));
+ continue;
+ }
+
+ ldstr.OpCode = OpCodes.Pop; // just pop the library handle/name, we don't need it
+ ldstr.Operand = null;
+
+ instr.OpCode = OpCodes.Call;
+ instr.Operand = GetOrCreateGetNativeFieldMethod (method, returnType, symbolName);
+
+ modified = true;
+ continue;
+ case "GetIndirect":
+ case "dlsym":
+ ldstr.OpCode = OpCodes.Pop; // just pop the library handle/name, we don't need it
+ ldstr.Operand = null;
+
+ instr.OpCode = OpCodes.Call;
+ instr.Operand = GetOrCreateGetSymbolMethod (method, symbolName);
+
+ modified = true;
+ continue;
+ }
+ }
+
+ // Handle Dlfcn functions of the form (RTLD, symbolName)
+ if (mr.Parameters.Count == 2 && mr.Parameters [0].ParameterType.FullName == "ObjCRuntime.Dlfcn/RTLD" && mr.Parameters [1].ParameterType.FullName == "System.String") {
+ if (instr.Previous.OpCode != OpCodes.Ldstr) {
+ Report (ErrorHelper.CreateWarning (Configuration.Application, 2255 /* Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new. */, method, Errors.MX2255, FormatMethod (mr), FormatMethod (method)));
+ continue;
+ }
+ var ldstr = instr.Previous;
+ if (ldstr.Operand is not string symbolName) {
+ Report (ErrorHelper.CreateWarning (Configuration.Application, 2255 /* Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new. */, method, Errors.MX2255, FormatMethod (mr), FormatMethod (method)));
+ continue;
+ }
+
+ if (!InlineSymbol (symbolName))
+ continue;
+
+
+ switch (mr.Name) {
+ case "dlsym":
+ ldstr.OpCode = OpCodes.Pop; // just pop the library handle/name, we don't need it
+ ldstr.Operand = null;
+
+ instr.OpCode = OpCodes.Call;
+ instr.Operand = GetOrCreateGetSymbolMethod (method, symbolName);
+
+ modified = true;
+ continue;
+ }
+ }
+
+ // Handle Dlfcn functions of the form (libraryName, symbolName)
+ if (mr.Parameters.Count == 2 && mr.Parameters [0].ParameterType.FullName == "System.String" && mr.Parameters [1].ParameterType.FullName == "System.String") {
+ if (instr.Previous.OpCode != OpCodes.Ldstr) {
+ Report (ErrorHelper.CreateWarning (Configuration.Application, 2255 /* Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new. */, method, Errors.MX2255, FormatMethod (mr), FormatMethod (method)));
+ continue;
+ }
+ var ldstr = instr.Previous;
+ if (ldstr.Operand is not string symbolName) {
+ Report (ErrorHelper.CreateWarning (Configuration.Application, 2255 /* Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new. */, method, Errors.MX2255, FormatMethod (mr), FormatMethod (method)));
+ continue;
+ }
+
+ if (!InlineSymbol (symbolName))
+ continue;
+
+ switch (mr.Name) {
+ // primitive types
+ case "SlowGetDouble":
+ case "SlowGetIntPtr":
+ case "SlowGetInt32":
+ case "SlowGetInt64":
+ // classes
+ case "SlowGetStringConstant":
+ ldstr.OpCode = OpCodes.Pop; // just pop the library handle/name, we don't need it
+ ldstr.Operand = null;
+
+ instr.OpCode = OpCodes.Call;
+ instr.Operand = GetOrCreateGetNativeFieldMethod (method, mr.ReturnType, symbolName);
+
+ modified = true;
+ continue;
+ }
+ }
+
+ // Handle Dlfcn functions of the form void (libraryHandle|libraryName, symbolName, value)
+ if (mr.Parameters.Count == 3 &&
+ (mr.Parameters [0].ParameterType.FullName == "System.String" || mr.Parameters [0].ParameterType.FullName == "System.IntPtr") &&
+ mr.Parameters [1].ParameterType.FullName == "System.String") {
+
+ var ins = instr;
+ Instruction? ldstr = null;
+
+ // skip any call instructions that take a single argument and return a value, as those are likely to be calls to op_Implicit or op_Explicit functions.
+ while (ins.Previous.OpCode == OpCodes.Call && ins.Previous.Operand is MethodReference prevMr && !prevMr.ReturnType.Is ("System", "Void") && prevMr.HasParameters && prevMr.Parameters.Count == 1) {
+ ins = ins.Previous;
+ }
+
+ switch (ins.Previous.OpCode.StackBehaviourPop) {
+ case StackBehaviour.Pop0:
+ switch (ins.Previous.OpCode.StackBehaviourPush) {
+ case StackBehaviour.Push1:
+ case StackBehaviour.Pushi:
+ case StackBehaviour.Pushi8:
+ case StackBehaviour.Pushr4:
+ case StackBehaviour.Pushr8:
+ case StackBehaviour.Pushref:
+ ldstr = ins.Previous.Previous;
+ break;
+ }
+ break;
+ case StackBehaviour.Pop1:
+ case StackBehaviour.Popref:
+ switch (ins.Previous.OpCode.StackBehaviourPush) {
+ case StackBehaviour.Push1:
+ case StackBehaviour.Pushi:
+ case StackBehaviour.Pushi8:
+ case StackBehaviour.Pushr4:
+ case StackBehaviour.Pushr8:
+ case StackBehaviour.Pushref:
+ ldstr = ins.Previous.Previous.Previous;
+ break;
+ }
+ break;
+ }
+ if (ldstr is null) {
+ Report (ErrorHelper.CreateWarning (Configuration.Application, 2255, method, "Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. Unknown instruction sequence: {2} ({3}/{4}). The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new.", FormatMethod (mr), FormatMethod (method), instr.Previous, instr.Previous.OpCode.StackBehaviourPop, instr.Previous.OpCode.StackBehaviourPush));
+ continue;
+ }
+
+ if (ldstr.OpCode != OpCodes.Ldstr) {
+ // Report (ErrorHelper.CreateWarning (Configuration.Application, 2255 /* Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new. */, method, Errors.MX2255, FormatMethod (mr), FormatMethod (method)));
+ Report (ErrorHelper.CreateWarning (Configuration.Application, 2255, method, "Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. Expected 'ldstr' opcode, got '{2}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new.", FormatMethod (mr), FormatMethod (method), ldstr));
+ continue;
+ }
+ if (ldstr.Operand is not string symbolName) {
+ Report (ErrorHelper.CreateWarning (Configuration.Application, 2255 /* Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new. */, method, Errors.MX2255, FormatMethod (mr), FormatMethod (method)));
+ continue;
+ }
+
+ if (!InlineSymbol (symbolName))
+ continue;
+
+ switch (mr.Name) {
+ // primitive types
+ case "SetSByte":
+ case "SetByte":
+ case "SetInt16":
+ case "SetUInt16":
+ case "SetInt32":
+ case "SetUInt32":
+ case "SetInt64":
+ case "SetUInt64":
+ case "SetArray":
+ case "SetObject":
+ case "SetNInt":
+ case "SetNUInt":
+ case "SetNFloat":
+ case "SetUIntPtr":
+ case "SetIntPtr":
+ case "SetCGSize":
+ case "SetDouble":
+ case "SetFloat":
+ ldstr.OpCode = OpCodes.Pop; // just pop the library handle/name, we don't need it
+ ldstr.Operand = null;
+
+ instr.OpCode = OpCodes.Call;
+ instr.Operand = GetOrCreateSetNativeFieldMethod (method, mr.Parameters [2].ParameterType, symbolName);
+
+ modified = true;
+ continue;
+ // classes
+ case "SetString":
+ if (mr.Parameters [2].ParameterType.FullName == "System.String") {
+ ldstr.OpCode = OpCodes.Pop; // just pop the library handle/name, we don't need it
+ ldstr.Operand = null;
+
+ instr.OpCode = OpCodes.Call;
+ instr.Operand = GetOrCreateSetNativeStringMethod (method, symbolName);
+ modified = true;
+ continue;
+ } else if (mr.Parameters [2].ParameterType.FullName == "Foundation.NSString") {
+ ldstr.OpCode = OpCodes.Pop; // just pop the library handle/name, we don't need it
+ ldstr.Operand = null;
+
+ instr.OpCode = OpCodes.Call;
+ instr.Operand = GetOrCreateSetNativeFieldMethod (method, mr.Parameters [2].ParameterType, symbolName);
+ modified = true;
+ continue;
+ }
+
+ Report (ErrorHelper.CreateWarning (Configuration.Application, 2255 /* Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new. */, method, Errors.MX2255, FormatMethod (mr), FormatMethod (method)));
+ continue;
+ case "CachePointer":
+ if (!(mr.Parameters [2].ParameterType is PointerType pt && pt.ElementType.FullName == "System.IntPtr")) {
+ Report (ErrorHelper.CreateWarning (Configuration.Application, 2255 /* Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new. */, method, Errors.MX2255, FormatMethod (mr), FormatMethod (method)));
+ continue;
+ }
+
+ //
+ // we're going to replace the entire method body with something like:
+ //
+ // var ptr = Get__{symbolName} ();
+ // if (ptr == IntPtr.Zero)
+ // return IntPtr.Zero;
+ // return *(IntPtr *) ptr;
+ //
+
+ if (!IsGeneratedCachePointerMethod (method, out var cachePointerSymbolName, out var failureMessage)) {
+ Report (ErrorHelper.CreateWarning (Configuration.Application, 2257 /* Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new. */, method, Errors.MX2257, failureMessage, FormatMethod (method)));
+ continue;
+ }
+
+ if (cachePointerSymbolName != symbolName) {
+ Report (ErrorHelper.CreateWarning (Configuration.Application, 2257 /* Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new. */, method, Errors.MX2257, $"Could not determine symbol name", FormatMethod (method)));
+ continue;
+ }
+
+ ldstr.OpCode = OpCodes.Pop; // just pop the library handle/name, we don't need it
+ ldstr.Operand = null;
+
+ method.Body.Instructions.Clear ();
+ var il = method.Body.GetILProcessor ();
+ var ptrVariable = new VariableDefinition (abr.System_IntPtr);
+ method.Body.Variables.Add (ptrVariable);
+ var loadPointerInstructionStart = il.Create (OpCodes.Ldloc, ptrVariable);
+ // var ptr = Get__{symbolName} ()
+ il.Append (il.Create (OpCodes.Call, GetOrCreateGetSymbolMethod (method, symbolName)));
+ il.Append (il.Create (OpCodes.Stloc, ptrVariable));
+ // if (ptr == IntPtr.Zero)
+ il.Append (il.Create (OpCodes.Ldloc, ptrVariable));
+ il.Append (il.Create (OpCodes.Brtrue_S, loadPointerInstructionStart));
+ // return IntPtr.Zero;
+ il.Append (il.Create (OpCodes.Ldc_I4_0));
+ il.Append (il.Create (OpCodes.Conv_I));
+ il.Append (il.Create (OpCodes.Ret));
+ // return *(IntPtr *) ptr;
+ il.Append (loadPointerInstructionStart); // il.Create (OpCodes.Ldloc, ptrVariable)
+ il.Append (il.Create (OpCodes.Ldind_I));
+ il.Append (il.Create (OpCodes.Ret));
+
+ modified = true;
+ return modified; // we replace the whole method body, so no need to continue processing the method
+ }
+ }
+
+ switch (mr.Name) {
+ case "_dlopen": // nothing to inline here
+ case "dlopen": // nothing to inline here
+ case "dlerror": // nothing to inline here
+ continue;
+ case "dlclose":
+ // It might be possible to just remove these calls, because
+ // (PENDING CONFIRMATION) I believe dlclose is a no-op on at least some Apple platforms.
+ continue;
+ default:
+ Report (ErrorHelper.CreateWarning (Configuration.Application, 2255 /* Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new. */, method, Errors.MX2255, FormatMethod (mr), FormatMethod (method)));
+ continue;
+ }
+ }
+
+ return modified;
+ }
+
+ static bool IsGeneratedCachePointerMethod (MethodDefinition method, [NotNullWhen (true)] out string? fieldName, [NotNullWhen (false)] out string? failureMessage)
+ {
+ fieldName = null;
+ failureMessage = null;
+
+ // The following code:
+ //
+ // get {
+ // fixed (IntPtr *storage = &values [8])
+ // return Dlfcn.CachePointer (Libraries.XYZ.Handle, "...", storage);
+ // }
+ //
+ // has the following IL sequence:
+ //
+ // IL_0000: ldsfld System.IntPtr[] ::values
+ // IL_0005: ldc.i4.0
+ // IL_0006: ldelema System.IntPtr
+ // IL_000b: stloc.1
+ // IL_000c: ldloc.1
+ // IL_000d: conv.u
+ // IL_000e: stloc.0
+ // IL_000f: ldsfld System.IntPtr ObjCRuntime.Libraries/::Handle
+ // IL_0014: ldstr "FIELDNAME"
+ // IL_0019: ldloc.0
+ // IL_001a: call System.IntPtr ObjCRuntime.Dlfcn::CachePointer(System.IntPtr,System.String,System.IntPtr*)
+ // IL_0020: stloc.2
+ // IL_0021: br.s IL_0023
+ // IL_0023: ldloc.2
+ // IL_001f: ret
+ //
+ // (the indented code can happen for debug builds)
+ //
+ if (!method.HasBody) {
+ failureMessage = "Method has no body";
+ return false;
+ }
+ var body = method.Body;
+ if (body.Instructions.Count == 0) {
+ failureMessage = "Method has no instructions";
+ return false;
+ }
+
+ var instr = body.Instructions.First ();
+ var isLast = false;
+
+ bool AssertOpCode ([NotNullWhen (false)] out string? failureMessage, params OpCode [] expected)
+ {
+ failureMessage = null;
+
+ while (instr.OpCode == OpCodes.Nop && instr.Next is not null)
+ instr = instr.Next;
+
+ if (!expected.Any (v => v == instr.OpCode)) {
+ failureMessage = $"Expected any of '{string.Join (", ", expected.Select (v => v.ToString ()))}' as instruction at offset IL{instr.Offset:X4}, got: {instr}";
+ return false;
+ }
+
+ if (instr.Next is null) {
+ if (isLast)
+ return true;
+ failureMessage = $"Expected more instructions after {instr}.";
+ return false;
+ }
+
+ if (isLast) {
+ failureMessage = $"Got more instructions than expected after {instr}.";
+ return false;
+ }
+
+ instr = instr.Next;
+
+ return true;
+ }
+
+ if (!AssertOpCode (out failureMessage, OpCodes.Ldsfld))
+ return false;
+
+ var ldcOpcodes = new OpCode [] { OpCodes.Ldc_I4_0, OpCodes.Ldc_I4_1, OpCodes.Ldc_I4_2, OpCodes.Ldc_I4_3, OpCodes.Ldc_I4_4, OpCodes.Ldc_I4_5, OpCodes.Ldc_I4_6, OpCodes.Ldc_I4_7, OpCodes.Ldc_I4_8, OpCodes.Ldc_I4, OpCodes.Ldc_I4_S };
+ if (!AssertOpCode (out failureMessage, ldcOpcodes))
+ return false;
+
+ if (!AssertOpCode (out failureMessage, OpCodes.Ldelema))
+ return false;
+
+ var stlocOpcodes = new OpCode [] { OpCodes.Stloc_0, OpCodes.Stloc_1, OpCodes.Stloc_2, OpCodes.Stloc_3, OpCodes.Stloc, OpCodes.Stloc_S };
+ if (!AssertOpCode (out failureMessage, stlocOpcodes))
+ return false;
+
+ var ldlocOpcodes = new OpCode [] { OpCodes.Ldloc_0, OpCodes.Ldloc_1, OpCodes.Ldloc_2, OpCodes.Ldloc_3, OpCodes.Ldloc, OpCodes.Ldloc_S };
+ if (!AssertOpCode (out failureMessage, ldlocOpcodes))
+ return false;
+
+ if (!AssertOpCode (out failureMessage, OpCodes.Conv_U))
+ return false;
+
+ if (!AssertOpCode (out failureMessage, stlocOpcodes))
+ return false;
+
+ if (!AssertOpCode (out failureMessage, OpCodes.Ldsfld))
+ return false;
+
+ if (!AssertOpCode (out failureMessage, OpCodes.Ldstr))
+ return false;
+ fieldName = (string) instr.Previous.Operand;
+
+ if (!AssertOpCode (out failureMessage, ldlocOpcodes))
+ return false;
+
+ if (!AssertOpCode (out failureMessage, OpCodes.Call))
+ return false;
+
+ if (stlocOpcodes.Any (v => v == instr.OpCode)) {
+ if (!AssertOpCode (out failureMessage, stlocOpcodes))
+ return false;
+
+ var branchOpcodes = new OpCode [] { OpCodes.Br, OpCodes.Br_S };
+ if (!AssertOpCode (out failureMessage, branchOpcodes))
+ return false;
+
+ if (!AssertOpCode (out failureMessage, ldlocOpcodes))
+ return false;
+ }
+
+ isLast = true;
+ return AssertOpCode (out failureMessage, OpCodes.Ret);
+ }
+
+ static string FormatMethod (MethodReference method)
+ {
+ var rv = method.FullName;
+ var idx = rv.IndexOf (' ');
+ if (idx > 0)
+ rv = rv.Substring (idx + 1);
+ return rv;
+ }
+
+ static bool IsNSObjectSubclass (TypeReference type)
+ {
+ var resolved = type.Resolve ();
+ while (resolved is not null) {
+ if (resolved.FullName == "Foundation.NSObject")
+ return true;
+ if (resolved.BaseType is null)
+ break;
+ resolved = resolved.BaseType.Resolve ();
+ }
+ return false;
+ }
+}
diff --git a/tools/linker/MonoTouch.Tuner/ListExportedSymbols.cs b/tools/linker/MonoTouch.Tuner/ListExportedSymbols.cs
index e014c12bc41c..eda79a994f73 100644
--- a/tools/linker/MonoTouch.Tuner/ListExportedSymbols.cs
+++ b/tools/linker/MonoTouch.Tuner/ListExportedSymbols.cs
@@ -191,6 +191,13 @@ bool ProcessMethod (MethodDefinition method)
switch (pinfo.Module.Name) {
case "__Internal":
+ // For NativeAOT builds, don't add inlined dlfcn P/Invoke wrappers as
+ // required symbols: only the surviving ones will have native code generated,
+ // so force-referencing all of them causes linker errors for symbols that
+ // NativeAOT trimmed away. For non-NativeAOT builds, the wrappers are resolved
+ // via dlsym and need the -u flags to be exported from the binary.
+ if (Configuration.InlineDlfcnMethodsEnabled && Configuration.Application.XamarinRuntime == XamarinRuntime.NativeAOT && pinfo.EntryPoint.StartsWith ("xamarin_Dlfcn_", StringComparison.Ordinal))
+ break;
Driver.Log (4, "Adding native reference to {0} in {1} because it's referenced by {2} in {3}.", pinfo.EntryPoint, pinfo.Module.Name, method.FullName, method.Module.Name);
DerivedLinkContext.RequiredSymbols.AddFunction (pinfo.EntryPoint).AddMember (method);
break;
@@ -211,7 +218,7 @@ bool ProcessMethod (MethodDefinition method)
}
}
- if (method.IsPropertyMethod ()) {
+ if (method.IsPropertyMethod () && !Configuration.InlineDlfcnMethodsEnabled) {
var property = method.GetProperty ();
// The Field attribute may have been linked away, but we've stored it in an annotation.
if (property is not null && Annotations.GetCustomAnnotations ("ExportedFields").TryGetValue (property, out var symbol) && symbol is string symbolStr) {
diff --git a/tools/linker/MonoTouch.Tuner/ProcessExportedFields.cs b/tools/linker/MonoTouch.Tuner/ProcessExportedFields.cs
index 8e4a61ed2578..53787784589f 100644
--- a/tools/linker/MonoTouch.Tuner/ProcessExportedFields.cs
+++ b/tools/linker/MonoTouch.Tuner/ProcessExportedFields.cs
@@ -23,6 +23,8 @@ namespace MonoTouch.Tuner {
// Then at the end of the linker process (ListExportedSymbols step)
// we lookup that annotation.
//
+ // See docs/code/native-symbols.md for an overview of native symbol handling.
+ //
public class ProcessExportedFields : BaseStep {
protected override void ProcessAssembly (AssemblyDefinition assembly)
@@ -55,6 +57,15 @@ void ProcessProperty (PropertyDefinition property)
if (!property.HasCustomAttributes)
return;
+ var config = LinkerConfiguration.GetInstance (Context);
+
+ // Collect all [Field] symbol names for InlineDlfcnMethodsStep's compatibility mode.
+ if (config.InlineDlfcnMethodsEnabled) {
+ var allSymbol = GetFieldSymbolName (property);
+ if (allSymbol is not null)
+ config.FieldSymbols.Add (allSymbol);
+ }
+
var symbol = GetFieldSymbol (property);
if (symbol is null)
return;
@@ -62,6 +73,28 @@ void ProcessProperty (PropertyDefinition property)
Annotations.GetCustomAnnotations ("ExportedFields").Add (property, symbol);
}
+ // Returns the symbol name from a [Field] attribute, regardless of library.
+ internal static string? GetFieldSymbolName (PropertyDefinition property)
+ {
+ if (!property.HasCustomAttributes)
+ return null;
+
+ foreach (var attrib in property.CustomAttributes) {
+ var declaringType = attrib.Constructor.DeclaringType.Resolve ();
+
+ if (!declaringType.Is (Namespaces.Foundation, "FieldAttribute"))
+ continue;
+
+ if (attrib.ConstructorArguments.Count < 1)
+ continue;
+
+ return (string) attrib.ConstructorArguments [0].Value;
+ }
+
+ return null;
+ }
+
+ // Returns the symbol name only for __Internal fields.
internal static string? GetFieldSymbol (PropertyDefinition property)
{
if (!property.HasCustomAttributes)
diff --git a/tools/mtouch/Errors.designer.cs b/tools/mtouch/Errors.designer.cs
index e2f24503e42d..85e5fd3a6293 100644
--- a/tools/mtouch/Errors.designer.cs
+++ b/tools/mtouch/Errors.designer.cs
@@ -3524,6 +3524,42 @@ public static string MX2112_B {
}
}
+ ///
+ /// Looks up a localized string similar to Unsupported primitive field type '{0}' for symbol '{1}' in method '{2}'. Sub-optimal but functional code will be generated. Please file an issue at https://github.com/dotnet/macios/issues/new.
+ ///
+ public static string MX2254 {
+ get {
+ return ResourceManager.GetString("MX2254", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new.
+ ///
+ public static string MX2255 {
+ get {
+ return ResourceManager.GetString("MX2255", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to The field type '{0}' for symbol '{1}' in method '{2}' is not an NSObject subclass. Please file an issue at https://github.com/dotnet/macios/issues/new.
+ ///
+ public static string MX2256 {
+ get {
+ return ResourceManager.GetString("MX2256", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new.
+ ///
+ public static string MX2257 {
+ get {
+ return ResourceManager.GetString("MX2257", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Could not {0} the assembly '{1}'.
///
diff --git a/tools/mtouch/Errors.resx b/tools/mtouch/Errors.resx
index 83c238026906..f719755a4d48 100644
--- a/tools/mtouch/Errors.resx
+++ b/tools/mtouch/Errors.resx
@@ -1097,6 +1097,24 @@
+
+
+
+ Unsupported primitive field type '{0}' for symbol '{1}' in method '{2}'. Sub-optimal but functional code will be generated. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+
+ Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+
+ The field type '{0}' for symbol '{1}' in method '{2}' is not an NSObject subclass. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+
+ Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
From 7d8c9850dcc0a54fb5b68f60486d82ba4771c29f Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Thu, 7 May 2026 08:06:33 +0200
Subject: [PATCH 023/156] [msbuild] Introduce SdkIsDesktop and SdkIsMobile
properties (#25326)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Introduce two new MSBuild properties to simplify platform checks in the build system:
- **`SdkIsDesktop`**: `true` when building for macOS or Mac Catalyst. Replaces `'$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst'` checks.
- **`SdkIsMobile`**: `true` when building for iOS or tvOS. Replaces `'$(_PlatformName)' == 'iOS' Or '$(_PlatformName)' == 'tvOS'` checks.
These complement the existing `SdkIsSimulator` and `SdkIsDevice` properties (from #25234).
The `SdkIsDevice` definition was also updated to use `SdkIsMobile` instead of raw platform checks.
### Deliberately not updated
- Patterns that also include `watchOS` (bundle structure paths, PkgInfo, etc.)
- `DynamicCodeSupport` (also includes MacCatalyst alongside iOS/tvOS)
- `ComputeRegistrarConstant.targets` (uses `TargetFramework.EndsWith()` patterns)
- Linker/introspection test `.csproj` files (also check tvOS separately)
- `_LibMonoLinkMode`/`_LibXamarinLinkMode` (check macOS and MacCatalyst with distinct behavior)
Both properties are documented in `docs/building-apps/build-properties.md`.
🤖 Pull request created by Copilot
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
docs/building-apps/build-properties.md | 24 ++++++++++
dotnet/targets/Microsoft.Sdk.Desktop.targets | 2 +-
dotnet/targets/Microsoft.Sdk.Mobile.targets | 6 +--
.../Xamarin.Shared.Sdk.Publish.targets | 8 ++--
dotnet/targets/Xamarin.Shared.Sdk.props | 10 +++-
dotnet/targets/Xamarin.Shared.Sdk.targets | 46 +++++++++----------
msbuild/Xamarin.Shared/Xamarin.Shared.props | 10 ++--
msbuild/Xamarin.Shared/Xamarin.Shared.targets | 46 +++++++++----------
tests/dotnet/BundleStructure/shared.csproj | 4 +-
.../CustomizedCodeSigning/shared.csproj | 4 +-
tests/monotouch-test/dotnet/shared.csproj | 14 +++---
11 files changed, 102 insertions(+), 72 deletions(-)
diff --git a/docs/building-apps/build-properties.md b/docs/building-apps/build-properties.md
index 14277d6f03f5..8126bb6cd0ed 100644
--- a/docs/building-apps/build-properties.md
+++ b/docs/building-apps/build-properties.md
@@ -1264,6 +1264,18 @@ $ dotnet run -p:StandardInputPath=stdin.txt
Note: this can also be accomplished by passing `--stdin ...` using the [OpenArguments](#openarguments) property.
+## SdkIsDesktop
+
+This property is a read-only property (setting it will have no effect) that
+specifies whether we're building for a desktop platform (macOS or Mac Catalyst).
+
+This property is `true` when the target platform is macOS or Mac Catalyst,
+and is not set for iOS or tvOS builds.
+
+Like `SdkIsSimulator`, this property is only set after [imports and
+properties](/visualstudio/msbuild/build-process-overview#evaluate-imports-and-properties)
+have been evaluated.
+
## SdkIsDevice
This property is a read-only property (setting it will have no effect) that
@@ -1277,6 +1289,18 @@ Like `SdkIsSimulator`, this property is only set after [imports and
properties](/visualstudio/msbuild/build-process-overview#evaluate-imports-and-properties)
have been evaluated.
+## SdkIsMobile
+
+This property is a read-only property (setting it will have no effect) that
+specifies whether we're building for a mobile platform (iOS or tvOS).
+
+This property is `true` when the target platform is iOS or tvOS, and is not
+set for macOS or Mac Catalyst builds.
+
+Like `SdkIsSimulator`, this property is only set after [imports and
+properties](/visualstudio/msbuild/build-process-overview#evaluate-imports-and-properties)
+have been evaluated.
+
## SdkIsSimulator
This property is a read-only property (setting it will have no effect) that
diff --git a/dotnet/targets/Microsoft.Sdk.Desktop.targets b/dotnet/targets/Microsoft.Sdk.Desktop.targets
index 276822e3c2e4..d8d90ab7c46d 100644
--- a/dotnet/targets/Microsoft.Sdk.Desktop.targets
+++ b/dotnet/targets/Microsoft.Sdk.Desktop.targets
@@ -4,7 +4,7 @@
Name="_PrepareRunDesktop"
BeforeTargets="ComputeRunArguments"
DependsOnTargets="_ValidateHotReloadConfiguration"
- Condition="'$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst'">
+ Condition="'$(SdkIsDesktop)' == 'true'">
@@ -145,7 +145,7 @@
Name="_PrepareRunMobile"
BeforeTargets="ComputeRunArguments"
DependsOnTargets="_ValidateHotReloadConfiguration;_InstallMobile;ComputeMlaunchRunArguments"
- Condition="'$(_PlatformName)' != 'macOS' And '$(_PlatformName)' != 'MacCatalyst'">
+ Condition="'$(SdkIsDesktop)' != 'true'">
<_FilterDevicesToRuntimeIdentifier Condition="'$(_XamarinUsingDefaultRuntimeIdentifier)' != 'true'">$(RuntimeIdentifier)
diff --git a/dotnet/targets/Xamarin.Shared.Sdk.Publish.targets b/dotnet/targets/Xamarin.Shared.Sdk.Publish.targets
index 44d97039ff5e..c053793baf15 100644
--- a/dotnet/targets/Xamarin.Shared.Sdk.Publish.targets
+++ b/dotnet/targets/Xamarin.Shared.Sdk.Publish.targets
@@ -2,8 +2,8 @@
- true
- true
+ true
+ true
$(PublishDir)
@@ -21,7 +21,7 @@
/>
-
-
+
+
diff --git a/dotnet/targets/Xamarin.Shared.Sdk.props b/dotnet/targets/Xamarin.Shared.Sdk.props
index 0007e4766ebc..40b953914bac 100644
--- a/dotnet/targets/Xamarin.Shared.Sdk.props
+++ b/dotnet/targets/Xamarin.Shared.Sdk.props
@@ -154,8 +154,14 @@
$(_SdkIsSimulator)
+
+ true
+
- true
+ true
+
+
+ true
iPhoneSimulator
@@ -205,7 +211,7 @@
but the MtouchUseLlvm value is ignored when using the simulator, so it doesn't matter
if we set it in all cases.
-->
-
+
true
diff --git a/dotnet/targets/Xamarin.Shared.Sdk.targets b/dotnet/targets/Xamarin.Shared.Sdk.targets
index ece45355d5a8..d1f37e5aceba 100644
--- a/dotnet/targets/Xamarin.Shared.Sdk.targets
+++ b/dotnet/targets/Xamarin.Shared.Sdk.targets
@@ -105,8 +105,8 @@
-
-
+
+
@@ -535,8 +535,8 @@
- Otherwise set 'dynamic'
-->
managed-static
- managed-static
- managed-static
+ managed-static
+ managed-static
partial-static
dynamic
@@ -601,7 +601,7 @@
<_LinkerCacheDirectory Condition="'$(BuildSessionId)' != ''">$(IntermediateOutputPath)linker-cache
- <_IsSimulatorFeature Condition="('$(_PlatformName)' == 'iOS' Or '$(_PlatformName)' == 'tvOS') And '$(_SdkIsSimulator)' == 'true'">true
+ <_IsSimulatorFeature Condition="'$(SdkIsMobile)' == 'true' And '$(_SdkIsSimulator)' == 'true'">true
<_IsSimulatorFeature Condition="'$(_IsSimulatorFeature)' == ''">false
@@ -1256,7 +1256,7 @@
- <_RunAotCompiler Condition="'$(_SdkIsSimulator)' != 'true' And '$(_PlatformName)' != 'macOS' And '$(_PlatformName)' != 'MacCatalyst'">true
+ <_RunAotCompiler Condition="'$(_SdkIsSimulator)' != 'true' And '$(SdkIsDesktop)' != 'true'">true
<_RunAotCompiler Condition="'$(MtouchInterpreter)' != '' And '$(_PlatformName)' != 'macOS'">true
@@ -1279,10 +1279,10 @@
<_IntermediateNativeLibraryDir>$(IntermediateOutputPath)nativelibraries/
<_IntermediateFrameworksDir>$(DeviceSpecificIntermediateOutputPath)frameworks
<_IntermediateDecompressionDir>$([MSBuild]::EnsureTrailingSlash('$(DeviceSpecificIntermediateOutputPath)decompressed'))
- <_NativeExecutablePublishDir Condition="'$(_PlatformName)' == 'iOS' Or '$(_PlatformName)' == 'tvOS'">$(_RelativeAppBundlePath)\
- <_NativeExecutablePublishDir Condition="'$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst'">$(_RelativeAppBundlePath)\Contents\MacOS\
- <_AppBundleFrameworksDir Condition="'$(_PlatformName)' == 'iOS' Or '$(_PlatformName)' == 'tvOS'">$(_RelativeAppBundlePath)\Frameworks\
- <_AppBundleFrameworksDir Condition="'$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst'">$(_RelativeAppBundlePath)\Contents\Frameworks\
+ <_NativeExecutablePublishDir Condition="'$(SdkIsMobile)' == 'true'">$(_RelativeAppBundlePath)\
+ <_NativeExecutablePublishDir Condition="'$(SdkIsDesktop)' == 'true'">$(_RelativeAppBundlePath)\Contents\MacOS\
+ <_AppBundleFrameworksDir Condition="'$(SdkIsMobile)' == 'true'">$(_RelativeAppBundlePath)\Frameworks\
+ <_AppBundleFrameworksDir Condition="'$(SdkIsDesktop)' == 'true'">$(_RelativeAppBundlePath)\Contents\Frameworks\
<_AOTInputDirectory>$(_IntermediateNativeLibraryDir)aot-input/
<_AOTOutputDirectory>$(_IntermediateNativeLibraryDir)aot-output/
@@ -1315,11 +1315,11 @@
<_LibXamarinDebug Condition="'$(_BundlerDebug)' == 'true'">-debug
<_LibXamarinName Condition="'$(_LibXamarinName)' == ''">libxamarin-dotnet$(_LibXamarinRuntime)$(_LibXamarinDebug).$(_LibXamarinExtension)
- <_DylibRPath Condition="'$(_PlatformName)' == 'iOS' Or '$(_PlatformName)' == 'tvOS'">@executable_path
- <_DylibRPath Condition="'$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst'">@executable_path/../$(_CustomBundleName)/
+ <_DylibRPath Condition="'$(SdkIsMobile)' == 'true'">@executable_path
+ <_DylibRPath Condition="'$(SdkIsDesktop)' == 'true'">@executable_path/../$(_CustomBundleName)/
- <_EmbeddedFrameworksRPath Condition="'$(_PlatformName)' == 'iOS' Or '$(_PlatformName)' == 'tvOS'">@executable_path/Frameworks
- <_EmbeddedFrameworksRPath Condition="'$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst'">@executable_path/../Frameworks/
+ <_EmbeddedFrameworksRPath Condition="'$(SdkIsMobile)' == 'true'">@executable_path/Frameworks
+ <_EmbeddedFrameworksRPath Condition="'$(SdkIsDesktop)' == 'true'">@executable_path/../Frameworks/
<_RuntimeConfigurationFile>runtimeconfig.bin
@@ -1327,8 +1327,8 @@
<_CustomLinkFlags Include="-rpath" />
- <_CustomLinkFlags Include="@executable_path/../../Frameworks" Condition="'$(_PlatformName)' == 'iOS' Or '$(_PlatformName)' == 'tvOS'" />
- <_CustomLinkFlags Include="@executable_path/../../../../Frameworks" Condition="'$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst'" />
+ <_CustomLinkFlags Include="@executable_path/../../Frameworks" Condition="'$(SdkIsMobile)' == 'true'" />
+ <_CustomLinkFlags Include="@executable_path/../../../../Frameworks" Condition="'$(SdkIsDesktop)' == 'true'" />
@@ -2011,8 +2011,8 @@
- <_ExecutablePathPrefix Condition="'$(_PlatformName)' == 'iOS' Or '$(_PlatformName)' == 'tvOS'">@executable_path/
- <_ExecutablePathPrefix Condition="'$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst'">@executable_path/../../
+ <_ExecutablePathPrefix Condition="'$(SdkIsMobile)' == 'true'">@executable_path/
+ <_ExecutablePathPrefix Condition="'$(SdkIsDesktop)' == 'true'">@executable_path/../../
@@ -2180,10 +2180,10 @@
Condition="'$(_CanOutputAppBundle)' == 'true'"
>
- <_AssemblyPublishDir Condition="'$(_PlatformName)' == 'iOS' Or '$(_PlatformName)' == 'tvOS'">$(_RelativeAppBundlePath)\
- <_AssemblyPublishDir Condition="'$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst'">$(_RelativeAppBundlePath)\Contents\$(_CustomBundleName)\
- <_DylibPublishDir Condition="'$(_PlatformName)' == 'iOS' Or '$(_PlatformName)' == 'tvOS'">$(_RelativeAppBundlePath)\
- <_DylibPublishDir Condition="'$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst'">$(_RelativeAppBundlePath)\Contents\$(_CustomBundleName)\
+ <_AssemblyPublishDir Condition="'$(SdkIsMobile)' == 'true'">$(_RelativeAppBundlePath)\
+ <_AssemblyPublishDir Condition="'$(SdkIsDesktop)' == 'true'">$(_RelativeAppBundlePath)\Contents\$(_CustomBundleName)\
+ <_DylibPublishDir Condition="'$(SdkIsMobile)' == 'true'">$(_RelativeAppBundlePath)\
+ <_DylibPublishDir Condition="'$(SdkIsDesktop)' == 'true'">$(_RelativeAppBundlePath)\Contents\$(_CustomBundleName)\
<_ParsedRuntimeConfigFilePath Condition="'$(_ParsedRuntimeConfigFilePath)' == ''">$(DeviceSpecificIntermediateOutputPath)$(_RuntimeConfigurationFile)
@@ -2213,7 +2213,7 @@
+ Condition="('$(_SdkIsSimulator)' != 'false' Or '$(SdkIsDesktop)' == 'true') And ('%(Extension)' == '.dylib' Or '%(Extension)' == '.so') " />
<_CanArchive>false
- <_CanArchive Condition="('$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst') And '$(OutputType)' == 'Exe' And '$(IsAppExtension)' == 'false'">true
+ <_CanArchive Condition="'$(SdkIsDesktop)' == 'true' And '$(OutputType)' == 'Exe' And '$(IsAppExtension)' == 'false'">true
<_CanArchive Condition="'$(OutputType)' == 'Exe' And '$(SdkIsDevice)' == 'true' And '$(IsAppExtension)' == 'false'">true
@@ -122,7 +122,7 @@ Copyright (C) 2020 Microsoft. All rights reserved.
$(MtouchNoSymbolStrip)
true
- true
+ true
true
false
@@ -131,7 +131,7 @@ Copyright (C) 2020 Microsoft. All rights reserved.
$(MtouchNoDSymUtil)
- true
+ true
true
false
@@ -182,7 +182,7 @@ Copyright (C) 2020 Microsoft. All rights reserved.
<_EmbeddedResourcePrefix Condition="'$(_PlatformName)' == 'macOS'">xammac
<_EmbeddedResourcePrefix Condition="'$(_PlatformName)' != 'macOS'">monotouch
- <_AppBundleManifestRelativePath Condition="'$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst'">Contents/
+ <_AppBundleManifestRelativePath Condition="'$(SdkIsDesktop)' == 'true'">Contents/
.xpc
.appex
@@ -191,7 +191,7 @@ Copyright (C) 2020 Microsoft. All rights reserved.
all
- <_AppBundleName Condition="'$(_AppBundleName)' == '' And $([MSBuild]::VersionGreaterThanOrEquals($(TargetFrameworkVersion), 10.0)) And ('$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst')">$(ApplicationTitle)
+ <_AppBundleName Condition="'$(_AppBundleName)' == '' And $([MSBuild]::VersionGreaterThanOrEquals($(TargetFrameworkVersion), 10.0)) And '$(SdkIsDesktop)' == 'true'">$(ApplicationTitle)
<_AppBundleName Condition="'$(_AppBundleName)' == ''">$(AssemblyName)
diff --git a/msbuild/Xamarin.Shared/Xamarin.Shared.targets b/msbuild/Xamarin.Shared/Xamarin.Shared.targets
index c5139ca6acc1..904b1965ab3b 100644
--- a/msbuild/Xamarin.Shared/Xamarin.Shared.targets
+++ b/msbuild/Xamarin.Shared/Xamarin.Shared.targets
@@ -294,7 +294,7 @@ Copyright (C) 2018 Microsoft. All rights reserved.
-
+
@@ -302,7 +302,7 @@ Copyright (C) 2018 Microsoft. All rights reserved.
@@ -320,7 +320,7 @@ Copyright (C) 2018 Microsoft. All rights reserved.
@@ -348,7 +348,7 @@ Copyright (C) 2018 Microsoft. All rights reserved.
-
+
@@ -1278,7 +1278,7 @@ Copyright (C) 2018 Microsoft. All rights reserved.
will apply to Xamarin.Mac as well.
-->
- <_PkgInfoPath Condition="'$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst'">$(_AppBundlePath)Contents\PkgInfo
+ <_PkgInfoPath Condition="'$(SdkIsDesktop)' == 'true'">$(_AppBundlePath)Contents\PkgInfo
<_PkgInfoPath Condition="'$(_PlatformName)' == 'iOS' Or '$(_PlatformName)' == 'tvOS' Or '$(_PlatformName)' == 'watchOS'">$(_AppBundlePath)PkgInfo
@@ -2082,7 +2082,7 @@ Copyright (C) 2018 Microsoft. All rights reserved.
- <_EmbeddedProvisionProfilePath Condition="'$(_EmbeddedProvisionProfilePath)' == '' And ('$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst')">$(_AppBundlePath)Contents\embedded.provisionprofile
+ <_EmbeddedProvisionProfilePath Condition="'$(_EmbeddedProvisionProfilePath)' == '' And '$(SdkIsDesktop)' == 'true'">$(_AppBundlePath)Contents\embedded.provisionprofile
<_EmbeddedProvisionProfilePath Condition="'$(_EmbeddedProvisionProfilePath)' == '' And ('$(_PlatformName)' == 'iOS' Or '$(_PlatformName)' == 'tvOS' Or '$(_PlatformName)' == 'watchOS')">$(_AppBundlePath)embedded.mobileprovision
@@ -2574,7 +2574,7 @@ Copyright (C) 2018 Microsoft. All rights reserved.
>
- true
+ true
false
@@ -2790,12 +2790,12 @@ Copyright (C) 2018 Microsoft. All rights reserved.
<_NativeExecutableRelativePath Condition="'$(_PlatformName)' == 'iOS' Or '$(_PlatformName)' == 'tvOS' Or '$(_PlatformName)' == 'watchOS'">$(_ExecutableName)
- <_NativeExecutableRelativePath Condition="'$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst'">Contents\MacOS\$(_ExecutableName)
+ <_NativeExecutableRelativePath Condition="'$(SdkIsDesktop)' == 'true'">Contents\MacOS\$(_ExecutableName)
<_NativeExecutable>$(_AppBundlePath)$(_NativeExecutableRelativePath)
-
-
+
@@ -3252,30 +3252,30 @@ Copyright (C) 2018 Microsoft. All rights reserved.
<_AppBundlePath>$(AppBundleDir)
<_AppBundlePath Condition="$([System.IO.Path]::IsPathRooted('$(AppBundleDir)'))">$([MSBuild]::MakeRelative('$(MSBuildProjectDirectory)','$(AppBundleDir)'))
<_AppBundlePath>$([MSBuild]::EnsureTrailingSlash('$(_AppBundlePath)'))
- <_AppResourcesRelativePath Condition="'$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst'">Contents\Resources\
+ <_AppResourcesRelativePath Condition="'$(SdkIsDesktop)' == 'true'">Contents\Resources\
<_AppResourcesRelativePath Condition="'$(_PlatformName)' == 'iOS' Or '$(_PlatformName)' == 'tvOS' Or '$(_PlatformName)' == 'watchOS'">
<_AppResourcesPath>$(_AppBundlePath)$(_AppResourcesRelativePath)
- <_AppContentsRelativePath Condition="'$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst'">Contents\$(_CustomBundleName)
+ <_AppContentsRelativePath Condition="'$(SdkIsDesktop)' == 'true'">Contents\$(_CustomBundleName)
<_AppContentsRelativePath Condition="'$(_PlatformName)' == 'iOS' Or '$(_PlatformName)' == 'tvOS' Or '$(_PlatformName)' == 'watchOS'">
<_AppContentsPath>$(_AppBundlePath)$(_AppContentsRelativePath)
- <_AppFrameworksRelativePath Condition="'$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst'">Contents\Frameworks\
+ <_AppFrameworksRelativePath Condition="'$(SdkIsDesktop)' == 'true'">Contents\Frameworks\
<_AppFrameworksRelativePath Condition="'$(_PlatformName)' == 'iOS' Or '$(_PlatformName)' == 'tvOS' Or '$(_PlatformName)' == 'watchOS'">Frameworks\
<_AppFrameworksPath>$(_AppBundlePath)$(_AppFrameworksRelativePath)
- <_AppCodeSignatureRelativePath Condition="'$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst'">Contents\
+ <_AppCodeSignatureRelativePath Condition="'$(SdkIsDesktop)' == 'true'">Contents\
<_AppCodeSignatureRelativePath Condition="'$(_PlatformName)' == 'iOS' Or '$(_PlatformName)' == 'tvOS' Or '$(_PlatformName)' == 'watchOS'">
<_AppCodeSignaturePath>$(_AppBundlePath)$(_AppCodeSignatureRelativePath)
- <_AppPlugInsRelativeLocation Condition="'$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst'">Contents\
- <_AppPlugInsRelativeLocation Condition="'$(_PlatformName)' == 'iOS' Or '$(_PlatformName)' == 'tvOS'">
+ <_AppPlugInsRelativeLocation Condition="'$(SdkIsDesktop)' == 'true'">Contents\
+ <_AppPlugInsRelativeLocation Condition="'$(SdkIsMobile)' == 'true'">
<_AppPlugInsRelativePath>$(_AppPlugInsRelativeLocation)PlugIns\
<_AppExtensionRoot>$(_AppBundlePath)$(_AppPlugInsRelativeLocation)
<_AppPlugInsPath>$(_AppBundlePath)$(_AppPlugInsRelativePath)
- <_AppXpcServicesRelativePath Condition="'$(_PlatformName)' == 'macOS' Or '$(_PlatformName)' == 'MacCatalyst'">Contents\XPCServices\
+ <_AppXpcServicesRelativePath Condition="'$(SdkIsDesktop)' == 'true'">Contents\XPCServices\
<_AppXpcServicesRelativePath Condition="'$(_PlatformName)' == 'iOS' Or '$(_PlatformName)' == 'tvOS' Or '$(_PlatformName)' == 'watchOS'">XPCServices\
<_AppXpcServicesPath>$(_AppBundlePath)$(_AppXpcServicesRelativePath)
@@ -3375,7 +3375,7 @@ Copyright (C) 2018 Microsoft. All rights reserved.
-
+
diff --git a/tests/dotnet/BundleStructure/shared.csproj b/tests/dotnet/BundleStructure/shared.csproj
index 2f8ad66ed705..e94d15aacf61 100644
--- a/tests/dotnet/BundleStructure/shared.csproj
+++ b/tests/dotnet/BundleStructure/shared.csproj
@@ -162,7 +162,7 @@
-
+
@@ -177,7 +177,7 @@
-
+
diff --git a/tests/dotnet/CustomizedCodeSigning/shared.csproj b/tests/dotnet/CustomizedCodeSigning/shared.csproj
index 5e0d08bca288..f2cbc49178e2 100644
--- a/tests/dotnet/CustomizedCodeSigning/shared.csproj
+++ b/tests/dotnet/CustomizedCodeSigning/shared.csproj
@@ -18,12 +18,12 @@
$(CreateAppBundleDependsOn);CopyCustomFiles;
-
+
Contents/SharedSupport
Contents/MacOS
Contents/MonoBundle
-
+
SharedSupport
diff --git a/tests/monotouch-test/dotnet/shared.csproj b/tests/monotouch-test/dotnet/shared.csproj
index c2c8eac87673..71e4ad497bca 100644
--- a/tests/monotouch-test/dotnet/shared.csproj
+++ b/tests/monotouch-test/dotnet/shared.csproj
@@ -46,12 +46,12 @@
-
-
+
+
-
-
-
+
+
+
@@ -239,11 +239,11 @@
- Contents/Resources/
+ Contents/Resources/
-
+
<_SmeltingSdk Condition="'$(_PlatformName)' == 'iOS'">iphoneos
<_SmeltingSdk Condition="'$(_PlatformName)' == 'tvOS'">appletvos
From 7c82a546aa33c16950afae74979504d956562340 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Thu, 7 May 2026 08:06:55 +0200
Subject: [PATCH 024/156] [msbuild] Add
com.apple.developer.payment-pass-provisioning to known entitlements (#25332)
Add the com.apple.developer.payment-pass-provisioning entitlement to the
known entitlements list so that validation properly reports a warning/error
when an app requests this entitlement but the provisioning profile doesn't
grant it. Previously this was an unknown entitlement that only logged a
low-importance message, causing silent install failures on device.
Also add tests verifying the error, warning, and disable modes for this
entitlement validation scenario.
Fixes https://github.com/dotnet/macios/issues/25306
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
.../Tasks/CompileEntitlements.cs | 1 +
.../TaskTests/CompileEntitlementsTaskTests.cs | 32 +++++++++++++++++++
2 files changed, 33 insertions(+)
diff --git a/msbuild/Xamarin.MacDev.Tasks/Tasks/CompileEntitlements.cs b/msbuild/Xamarin.MacDev.Tasks/Tasks/CompileEntitlements.cs
index 0db654e7addc..4e818beb636c 100644
--- a/msbuild/Xamarin.MacDev.Tasks/Tasks/CompileEntitlements.cs
+++ b/msbuild/Xamarin.MacDev.Tasks/Tasks/CompileEntitlements.cs
@@ -789,6 +789,7 @@ static Dictionary GetAllEntitlements ()
new EntitlementData ("com.apple.developer.on-demand-install-capable", iOS, EntitlementType.Boolean ),
new EntitlementData ("com.apple.developer.parent-application-identifiers", iOS, EntitlementType.ArrayOfStrings ),
new EntitlementData ("com.apple.developer.pass-type-identifiers", iOS, EntitlementType.ArrayOfStrings ),
+ new EntitlementData ("com.apple.developer.payment-pass-provisioning", iOS, EntitlementType.Boolean ),
new EntitlementData ("com.apple.developer.persistent-content-capture", desktop, EntitlementType.Boolean ),
new EntitlementData ("com.apple.developer.playable-content", iOS, EntitlementType.Boolean ),
new EntitlementData ("com.apple.developer.proximity-reader.identity.display", iOS, EntitlementType.Boolean ),
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CompileEntitlementsTaskTests.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CompileEntitlementsTaskTests.cs
index 25e61039c696..0a3d632d94ae 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CompileEntitlementsTaskTests.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CompileEntitlementsTaskTests.cs
@@ -573,6 +573,38 @@ public void ValidateStringArrayEntitlement (string entitlement, EntitlementsMode
ValidateEntitlementsImpl (platform, "error", [], mode, entitlement, "String", "InvalidValue", mobileProvision: "Apple_Signin_Test_Profile.mobileprovision");
}
+ // Test case inspired by https://github.com/dotnet/macios/issues/25306
+ // A wallet extension requests com.apple.developer.payment-pass-provisioning,
+ // but the provisioning profile doesn't grant it. This should produce a
+ // warning/error so the developer knows why installation fails on device.
+ [Test]
+ [TestCase (EntitlementsMode.InCustomEntitlements)]
+ [TestCase (EntitlementsMode.InFile)]
+ public void ValidateEntitlements_PaymentPassProvisioningNotInProfile (EntitlementsMode mode)
+ {
+ ValidateEntitlementsImpl (ApplePlatform.iOS, "error", [
+ "MT7140:The app requests the entitlement 'com.apple.developer.payment-pass-provisioning', but the provisioning profile 'iOS Team Provisioning Profile: *' doesn't contain this entitlement."
+ ], mode, "com.apple.developer.payment-pass-provisioning", "Boolean", "true");
+ }
+
+ [Test]
+ [TestCase (EntitlementsMode.InCustomEntitlements)]
+ [TestCase (EntitlementsMode.InFile)]
+ public void ValidateEntitlements_PaymentPassProvisioningNotInProfile_Warning (EntitlementsMode mode)
+ {
+ ValidateEntitlementsImpl (ApplePlatform.iOS, "warn", [
+ "MT7140:The app requests the entitlement 'com.apple.developer.payment-pass-provisioning', but the provisioning profile 'iOS Team Provisioning Profile: *' doesn't contain this entitlement."
+ ], mode, "com.apple.developer.payment-pass-provisioning", "Boolean", "true");
+ }
+
+ [Test]
+ [TestCase (EntitlementsMode.InCustomEntitlements)]
+ [TestCase (EntitlementsMode.InFile)]
+ public void ValidateEntitlements_PaymentPassProvisioningNotInProfile_Disable (EntitlementsMode mode)
+ {
+ ValidateEntitlementsImpl (ApplePlatform.iOS, "disable", [], mode, "com.apple.developer.payment-pass-provisioning", "Boolean", "true");
+ }
+
public enum EntitlementsMode {
None,
InFile,
From 4f6df60e44511b8809bffa4e47d6d71e35d8642e Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Thu, 7 May 2026 08:08:21 +0200
Subject: [PATCH 025/156] [github] Add code-radiator agentic workflow (#25349)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Adds a new agentic workflow (`code-radiator`) that merges `main` into active target branches daily at midnight UTC.
**Target branches:** `net[0-9]*.0`, `xcode[0-9]*`, `xcode[0-9]*.[0-9]*` (with activity in the last 30 days).
**Features:**
- Creates or updates merge PRs for each active target branch
- Resolves `eng/Version.Details.{props,xml}` conflicts by picking highest versions
- Resolves `NuGet.config` conflicts by including feeds from both branches
- Excludes conflicting `tests/dotnet/UnitTests/expected/*` files from merge commits
- Merges target branch into PR branch first to pick up new target commits
- For other conflicts: resolves best-effort, adds `do-not-merge` label and requests human review
- Enables automerge for clean merges; skips draft PRs with a comment
🤖 Pull request created by Copilot
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
.github/agents/agentic-workflows.agent.md | 196 +++
.github/workflows/code-radiator.lock.yml | 1491 +++++++++++++++++
.github/workflows/code-radiator.md | 170 ++
.github/workflows/copilot-setup-steps.yml | 26 +
.github/workflows/inter-branch-merge-flow.yml | 7 +-
5 files changed, 1887 insertions(+), 3 deletions(-)
create mode 100644 .github/agents/agentic-workflows.agent.md
create mode 100644 .github/workflows/code-radiator.lock.yml
create mode 100644 .github/workflows/code-radiator.md
create mode 100644 .github/workflows/copilot-setup-steps.yml
diff --git a/.github/agents/agentic-workflows.agent.md b/.github/agents/agentic-workflows.agent.md
new file mode 100644
index 000000000000..b6e648cbda58
--- /dev/null
+++ b/.github/agents/agentic-workflows.agent.md
@@ -0,0 +1,196 @@
+---
+description: GitHub Agentic Workflows (gh-aw) - Create, debug, and upgrade AI-powered workflows with intelligent prompt routing
+disable-model-invocation: true
+---
+
+# GitHub Agentic Workflows Agent
+
+This agent helps you work with **GitHub Agentic Workflows (gh-aw)**, a CLI extension for creating AI-powered workflows in natural language using markdown files.
+
+## What This Agent Does
+
+This is a **dispatcher agent** that routes your request to the appropriate specialized prompt based on your task:
+
+- **Creating new workflows**: Routes to `create` prompt
+- **Updating existing workflows**: Routes to `update` prompt
+- **Debugging workflows**: Routes to `debug` prompt
+- **Upgrading workflows**: Routes to `upgrade-agentic-workflows` prompt
+- **Creating report-generating workflows**: Routes to `report` prompt — consult this whenever the workflow posts status updates, audits, analyses, or any structured output as issues, discussions, or comments
+- **Creating shared components**: Routes to `create-shared-agentic-workflow` prompt
+- **Fixing Dependabot PRs**: Routes to `dependabot` prompt — use this when Dependabot opens PRs that modify generated manifest files (`.github/workflows/package.json`, `.github/workflows/requirements.txt`, `.github/workflows/go.mod`). Never merge those PRs directly; instead update the source `.md` files and rerun `gh aw compile --dependabot` to bundle all fixes
+- **Analyzing test coverage**: Routes to `test-coverage` prompt — consult this whenever the workflow reads, analyzes, or reports on test coverage data from PRs or CI runs
+- **CLI commands and triggering workflows**: Routes to `cli-commands` guide — consult this whenever the user asks how to run, compile, debug, or manage workflows from the command line, or when they need the MCP tool equivalent of a `gh aw` command
+
+Workflows may optionally include:
+
+- **Project tracking / monitoring** (GitHub Projects updates, status reporting)
+- **Orchestration / coordination** (one workflow assigning agents or dispatching and coordinating other workflows)
+
+## Files This Applies To
+
+- Workflow files: `.github/workflows/*.md` and `.github/workflows/**/*.md`
+- Workflow lock files: `.github/workflows/*.lock.yml`
+- Shared components: `.github/workflows/shared/*.md`
+- Configuration: https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/github-agentic-workflows.md
+
+## Problems This Solves
+
+- **Workflow Creation**: Design secure, validated agentic workflows with proper triggers, tools, and permissions
+- **Workflow Debugging**: Analyze logs, identify missing tools, investigate failures, and fix configuration issues
+- **Version Upgrades**: Migrate workflows to new gh-aw versions, apply codemods, fix breaking changes
+- **Component Design**: Create reusable shared workflow components that wrap MCP servers
+
+## How to Use
+
+When you interact with this agent, it will:
+
+1. **Understand your intent** - Determine what kind of task you're trying to accomplish
+2. **Route to the right prompt** - Load the specialized prompt file for your task
+3. **Execute the task** - Follow the detailed instructions in the loaded prompt
+
+## Available Prompts
+
+### Create New Workflow
+**Load when**: User wants to create a new workflow from scratch, add automation, or design a workflow that doesn't exist yet
+
+**Prompt file**: https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/create-agentic-workflow.md
+
+**Use cases**:
+- "Create a workflow that triages issues"
+- "I need a workflow to label pull requests"
+- "Design a weekly research automation"
+
+### Update Existing Workflow
+**Load when**: User wants to modify, improve, or refactor an existing workflow
+
+**Prompt file**: https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/update-agentic-workflow.md
+
+**Use cases**:
+- "Add web-fetch tool to the issue-classifier workflow"
+- "Update the PR reviewer to use discussions instead of issues"
+- "Improve the prompt for the weekly-research workflow"
+
+### Debug Workflow
+**Load when**: User needs to investigate, audit, debug, or understand a workflow, troubleshoot issues, analyze logs, or fix errors
+
+**Prompt file**: https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/debug-agentic-workflow.md
+
+**Use cases**:
+- "Why is this workflow failing?"
+- "Analyze the logs for workflow X"
+- "Investigate missing tool calls in run #12345"
+
+### Upgrade Agentic Workflows
+**Load when**: User wants to upgrade workflows to a new gh-aw version or fix deprecations
+
+**Prompt file**: https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/upgrade-agentic-workflows.md
+
+**Use cases**:
+- "Upgrade all workflows to the latest version"
+- "Fix deprecated fields in workflows"
+- "Apply breaking changes from the new release"
+
+### Create a Report-Generating Workflow
+**Load when**: The workflow being created or updated produces reports — recurring status updates, audit summaries, analyses, or any structured output posted as a GitHub issue, discussion, or comment
+
+**Prompt file**: https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/report.md
+
+**Use cases**:
+- "Create a weekly CI health report"
+- "Post a daily security audit to Discussions"
+- "Add a status update comment to open PRs"
+
+### Create Shared Agentic Workflow
+**Load when**: User wants to create a reusable workflow component or wrap an MCP server
+
+**Prompt file**: https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/create-shared-agentic-workflow.md
+
+**Use cases**:
+- "Create a shared component for Notion integration"
+- "Wrap the Slack MCP server as a reusable component"
+- "Design a shared workflow for database queries"
+
+### Fix Dependabot PRs
+**Load when**: User needs to close or fix open Dependabot PRs that update dependencies in generated manifest files (`.github/workflows/package.json`, `.github/workflows/requirements.txt`, `.github/workflows/go.mod`)
+
+**Prompt file**: https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/dependabot.md
+
+**Use cases**:
+- "Fix the open Dependabot PRs for npm dependencies"
+- "Bundle and close the Dependabot PRs for workflow dependencies"
+- "Update @playwright/test to fix the Dependabot PR"
+
+### Analyze Test Coverage
+**Load when**: The workflow reads, analyzes, or reports test coverage — whether triggered by a PR, a schedule, or a slash command. Always consult this prompt before designing the coverage data strategy.
+
+**Prompt file**: https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/test-coverage.md
+
+**Use cases**:
+- "Create a workflow that comments coverage on PRs"
+- "Analyze coverage trends over time"
+- "Add a coverage gate that blocks PRs below a threshold"
+
+### CLI Commands Reference
+**Load when**: The user asks how to run, compile, debug, or manage workflows from the command line; needs the MCP tool equivalent of a `gh aw` command; or is in a restricted environment (e.g., Copilot Cloud) without direct CLI access.
+
+**Reference file**: https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/cli-commands.md
+
+**Use cases**:
+- "How do I trigger workflow X on the main branch?"
+- "What's the MCP equivalent of `gh aw logs`?"
+- "I'm in Copilot Cloud — how do I compile a workflow?"
+- "Show me all available gh aw commands"
+
+## Instructions
+
+When a user interacts with you:
+
+1. **Identify the task type** from the user's request
+2. **Load the appropriate prompt** from the GitHub repository URLs listed above
+3. **Follow the loaded prompt's instructions** exactly
+4. **If uncertain**, ask clarifying questions to determine the right prompt
+
+## Quick Reference
+
+```bash
+# Initialize repository for agentic workflows
+gh aw init
+
+# Generate the lock file for a workflow
+gh aw compile [workflow-name]
+
+# Trigger a workflow on demand (preferred over gh workflow run)
+gh aw run # interactive input collection
+gh aw run --ref main # run on a specific branch
+
+# Debug workflow runs
+gh aw logs [workflow-name]
+gh aw audit
+
+# Upgrade workflows
+gh aw fix --write
+gh aw compile --validate
+```
+
+## Key Features of gh-aw
+
+- **Natural Language Workflows**: Write workflows in markdown with YAML frontmatter
+- **AI Engine Support**: Copilot, Claude, Codex, or custom engines
+- **MCP Server Integration**: Connect to Model Context Protocol servers for tools
+- **Safe Outputs**: Structured communication between AI and GitHub API
+- **Strict Mode**: Security-first validation and sandboxing
+- **Shared Components**: Reusable workflow building blocks
+- **Repo Memory**: Persistent git-backed storage for agents
+- **Sandboxed Execution**: All workflows run in the Agent Workflow Firewall (AWF) sandbox, enabling full `bash` and `edit` tools by default
+
+## Important Notes
+
+- Always reference the instructions file at https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/github-agentic-workflows.md for complete documentation
+- Use the MCP tool `agentic-workflows` when running in GitHub Copilot Cloud
+- Workflows must be compiled to `.lock.yml` files before running in GitHub Actions
+- **Bash tools are enabled by default** - Don't restrict bash commands unnecessarily since workflows are sandboxed by the AWF
+- Follow security best practices: minimal permissions, explicit network access, no template injection
+- **Network configuration**: Use ecosystem identifiers (`node`, `python`, `go`, etc.) or explicit FQDNs in `network.allowed`. Bare shorthands like `npm` or `pypi` are **not** valid. See https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/network.md for the full list of valid ecosystem identifiers and domain patterns.
+- **Single-file output**: When creating a workflow, produce exactly **one** workflow `.md` file. Do not create separate documentation files (architecture docs, runbooks, usage guides, etc.). If documentation is needed, add a brief `## Usage` section inside the workflow file itself.
+- **Triggering runs**: Always use `gh aw run ` to trigger a workflow on demand — not `gh workflow run .lock.yml`. `gh aw run` handles workflow resolution by short name, input parsing and validation, and correct run-tracking for agentic workflows. Use `--ref ` to run on a specific branch.
+- **CLI commands reference**: For a complete guide on all `gh aw` commands and their MCP tool equivalents (for restricted environments), see https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/cli-commands.md
diff --git a/.github/workflows/code-radiator.lock.yml b/.github/workflows/code-radiator.lock.yml
new file mode 100644
index 000000000000..7c9e915f63c0
--- /dev/null
+++ b/.github/workflows/code-radiator.lock.yml
@@ -0,0 +1,1491 @@
+# gh-aw-metadata: {"schema_version":"v3","frontmatter_hash":"76af0f752f9c80c182f233d9269f96cb4486de4da16d47dd58abdbd52c4ef543","compiler_version":"v0.71.5","strict":true,"agent_id":"copilot","agent_model":"claude-sonnet-4.5"}
+# gh-aw-manifest: {"version":1,"secrets":["COPILOT_GITHUB_TOKEN","GH_AW_CI_TRIGGER_TOKEN","GH_AW_GITHUB_MCP_SERVER_TOKEN","GH_AW_GITHUB_TOKEN","GITHUB_TOKEN"],"actions":[{"repo":"actions/checkout","sha":"de0fac2e4500dabe0009e67214ff5f5447ce83dd","version":"v6.0.2"},{"repo":"actions/download-artifact","sha":"3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c","version":"v8.0.1"},{"repo":"actions/github-script","sha":"3a2844b7e9c422d3c10d287c895573f7108da1b3","version":"v9.0.0"},{"repo":"actions/setup-node","sha":"48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e","version":"v6.4.0"},{"repo":"actions/upload-artifact","sha":"043fb46d1a93c77aae656e7c1c64a875d1fc6a0a","version":"v7.0.1"},{"repo":"github/gh-aw-actions/setup","sha":"b8068426813005612b960b5ab0b8bd2c27142323","version":"v0.71.5"}],"containers":[{"image":"ghcr.io/github/gh-aw-firewall/agent:0.25.40","digest":"sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504","pinned_image":"ghcr.io/github/gh-aw-firewall/agent:0.25.40@sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504"},{"image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40","digest":"sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280","pinned_image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40@sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280"},{"image":"ghcr.io/github/gh-aw-firewall/squid:0.25.40","digest":"sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51","pinned_image":"ghcr.io/github/gh-aw-firewall/squid:0.25.40@sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51"},{"image":"ghcr.io/github/gh-aw-mcpg:v0.3.6","digest":"sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c","pinned_image":"ghcr.io/github/gh-aw-mcpg:v0.3.6@sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c"},{"image":"ghcr.io/github/github-mcp-server:v1.0.3","digest":"sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959","pinned_image":"ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959"},{"image":"node:lts-alpine","digest":"sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f","pinned_image":"node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f"}]}
+# ___ _ _
+# / _ \ | | (_)
+# | |_| | __ _ ___ _ __ | |_ _ ___
+# | _ |/ _` |/ _ \ '_ \| __| |/ __|
+# | | | | (_| | __/ | | | |_| | (__
+# \_| |_/\__, |\___|_| |_|\__|_|\___|
+# __/ |
+# _ _ |___/
+# | | | | / _| |
+# | | | | ___ _ __ _ __| |_| | _____ ____
+# | |/\| |/ _ \ '__| |/ /| _| |/ _ \ \ /\ / / ___|
+# \ /\ / (_) | | | | ( | | | | (_) \ V V /\__ \
+# \/ \/ \___/|_| |_|\_\|_| |_|\___/ \_/\_/ |___/
+#
+# This file was automatically generated by gh-aw (v0.71.5). DO NOT EDIT.
+#
+# To update this file, edit the corresponding .md file and run:
+# gh aw compile
+# Not all edits will cause changes to this file.
+#
+# For more information: https://github.github.com/gh-aw/introduction/overview/
+#
+#
+# Secrets used:
+# - COPILOT_GITHUB_TOKEN
+# - GH_AW_CI_TRIGGER_TOKEN
+# - GH_AW_GITHUB_MCP_SERVER_TOKEN
+# - GH_AW_GITHUB_TOKEN
+# - GITHUB_TOKEN
+#
+# Custom actions used:
+# - actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
+# - actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
+# - actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+# - actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
+# - actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
+# - github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+#
+# Container images used:
+# - ghcr.io/github/gh-aw-firewall/agent:0.25.40@sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504
+# - ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40@sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280
+# - ghcr.io/github/gh-aw-firewall/squid:0.25.40@sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51
+# - ghcr.io/github/gh-aw-mcpg:v0.3.6@sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c
+# - ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959
+# - node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f
+
+name: "Code Radiator"
+"on":
+ # roles: # Roles processed as role check in pre-activation job
+ # - admin # Roles processed as role check in pre-activation job
+ # - maintainer # Roles processed as role check in pre-activation job
+ # - write # Roles processed as role check in pre-activation job
+ schedule:
+ - cron: "0 0 * * *"
+ workflow_dispatch:
+ inputs:
+ aw_context:
+ default: ""
+ description: Agent caller context (used internally by Agentic Workflows).
+ required: false
+ type: string
+
+permissions: {}
+
+concurrency:
+ group: "gh-aw-${{ github.workflow }}"
+
+run-name: "Code Radiator"
+
+jobs:
+ activation:
+ runs-on: ubuntu-slim
+ permissions:
+ actions: read
+ contents: read
+ outputs:
+ comment_id: ""
+ comment_repo: ""
+ engine_id: ${{ steps.generate_aw_info.outputs.engine_id }}
+ lockdown_check_failed: ${{ steps.generate_aw_info.outputs.lockdown_check_failed == 'true' }}
+ model: ${{ steps.generate_aw_info.outputs.model }}
+ secret_verification_result: ${{ steps.validate-secret.outputs.verification_result }}
+ setup-trace-id: ${{ steps.setup.outputs.trace-id }}
+ stale_lock_file_failed: ${{ steps.check-lock-file.outputs.stale_lock_file_failed == 'true' }}
+ steps:
+ - name: Setup Scripts
+ id: setup
+ uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+ with:
+ destination: ${{ runner.temp }}/gh-aw/actions
+ job-name: ${{ github.job }}
+ env:
+ GH_AW_SETUP_WORKFLOW_NAME: "Code Radiator"
+ GH_AW_CURRENT_WORKFLOW_REF: ${{ github.repository }}/.github/workflows/code-radiator.lock.yml@${{ github.ref }}
+ GH_AW_INFO_VERSION: "1.0.40"
+ - name: Generate agentic run info
+ id: generate_aw_info
+ env:
+ GH_AW_INFO_ENGINE_ID: "copilot"
+ GH_AW_INFO_ENGINE_NAME: "GitHub Copilot CLI"
+ GH_AW_INFO_MODEL: "claude-sonnet-4.5"
+ GH_AW_INFO_VERSION: "1.0.40"
+ GH_AW_INFO_AGENT_VERSION: "1.0.40"
+ GH_AW_INFO_CLI_VERSION: "v0.71.5"
+ GH_AW_INFO_WORKFLOW_NAME: "Code Radiator"
+ GH_AW_INFO_EXPERIMENTAL: "false"
+ GH_AW_INFO_SUPPORTS_TOOLS_ALLOWLIST: "true"
+ GH_AW_INFO_STAGED: "false"
+ GH_AW_INFO_ALLOWED_DOMAINS: '["defaults","github"]'
+ GH_AW_INFO_FIREWALL_ENABLED: "true"
+ GH_AW_INFO_AWF_VERSION: "v0.25.40"
+ GH_AW_INFO_AWMG_VERSION: ""
+ GH_AW_INFO_FIREWALL_TYPE: "squid"
+ GH_AW_COMPILED_STRICT: "true"
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ with:
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/generate_aw_info.cjs');
+ await main(core, context);
+ - name: Validate COPILOT_GITHUB_TOKEN secret
+ id: validate-secret
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/validate_multi_secret.sh" COPILOT_GITHUB_TOKEN 'GitHub Copilot CLI' https://github.github.com/gh-aw/reference/engines/#github-copilot-default
+ env:
+ COPILOT_GITHUB_TOKEN: ${{ secrets.COPILOT_GITHUB_TOKEN }}
+ - name: Checkout .github and .agents folders
+ uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
+ with:
+ persist-credentials: false
+ sparse-checkout: |
+ .github
+ .agents
+ .claude
+ .codex
+ .crush
+ .gemini
+ .opencode
+ .pi
+ sparse-checkout-cone-mode: true
+ fetch-depth: 1
+ - name: Save agent config folders for base branch restoration
+ env:
+ GH_AW_AGENT_FOLDERS: ".agents .claude .codex .crush .gemini .github .opencode .pi"
+ GH_AW_AGENT_FILES: ".crush.json AGENTS.md CLAUDE.md GEMINI.md PI.md opencode.jsonc"
+ # poutine:ignore untrusted_checkout_exec
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/save_base_github_folders.sh"
+ - name: Check workflow lock file
+ id: check-lock-file
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ env:
+ GH_AW_WORKFLOW_FILE: "code-radiator.lock.yml"
+ GH_AW_CONTEXT_WORKFLOW_REF: "${{ github.workflow_ref }}"
+ with:
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/check_workflow_timestamp_api.cjs');
+ await main();
+ - name: Check compile-agentic version
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ env:
+ GH_AW_COMPILED_VERSION: "v0.71.5"
+ with:
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/check_version_updates.cjs');
+ await main();
+ - name: Create prompt with built-in context
+ env:
+ GH_AW_PROMPT: /tmp/gh-aw/aw-prompts/prompt.txt
+ GH_AW_SAFE_OUTPUTS: ${{ runner.temp }}/gh-aw/safeoutputs/outputs.jsonl
+ GH_AW_GITHUB_ACTOR: ${{ github.actor }}
+ GH_AW_GITHUB_EVENT_COMMENT_ID: ${{ github.event.comment.id }}
+ GH_AW_GITHUB_EVENT_DISCUSSION_NUMBER: ${{ github.event.discussion.number }}
+ GH_AW_GITHUB_EVENT_ISSUE_NUMBER: ${{ github.event.issue.number }}
+ GH_AW_GITHUB_EVENT_PULL_REQUEST_NUMBER: ${{ github.event.pull_request.number }}
+ GH_AW_GITHUB_REPOSITORY: ${{ github.repository }}
+ GH_AW_GITHUB_RUN_ID: ${{ github.run_id }}
+ GH_AW_GITHUB_WORKSPACE: ${{ github.workspace }}
+ # poutine:ignore untrusted_checkout_exec
+ run: |
+ bash "${RUNNER_TEMP}/gh-aw/actions/create_prompt_first.sh"
+ {
+ cat << 'GH_AW_PROMPT_f18a65bced008989_EOF'
+
+ GH_AW_PROMPT_f18a65bced008989_EOF
+ cat "${RUNNER_TEMP}/gh-aw/prompts/xpia.md"
+ cat "${RUNNER_TEMP}/gh-aw/prompts/temp_folder_prompt.md"
+ cat "${RUNNER_TEMP}/gh-aw/prompts/markdown.md"
+ cat "${RUNNER_TEMP}/gh-aw/prompts/safe_outputs_prompt.md"
+ cat << 'GH_AW_PROMPT_f18a65bced008989_EOF'
+
+ Tools: add_comment(max:10), create_pull_request(max:10), update_pull_request(max:10), add_labels(max:10), push_to_pull_request_branch(max:10), missing_tool, missing_data, noop
+ GH_AW_PROMPT_f18a65bced008989_EOF
+ cat "${RUNNER_TEMP}/gh-aw/prompts/safe_outputs_create_pull_request.md"
+ cat "${RUNNER_TEMP}/gh-aw/prompts/safe_outputs_push_to_pr_branch.md"
+ cat << 'GH_AW_PROMPT_f18a65bced008989_EOF'
+
+ GH_AW_PROMPT_f18a65bced008989_EOF
+ cat "${RUNNER_TEMP}/gh-aw/prompts/mcp_cli_tools_prompt.md"
+ cat << 'GH_AW_PROMPT_f18a65bced008989_EOF'
+
+ The following GitHub context information is available for this workflow:
+ {{#if __GH_AW_GITHUB_ACTOR__ }}
+ - **actor**: __GH_AW_GITHUB_ACTOR__
+ {{/if}}
+ {{#if __GH_AW_GITHUB_REPOSITORY__ }}
+ - **repository**: __GH_AW_GITHUB_REPOSITORY__
+ {{/if}}
+ {{#if __GH_AW_GITHUB_WORKSPACE__ }}
+ - **workspace**: __GH_AW_GITHUB_WORKSPACE__
+ {{/if}}
+ {{#if __GH_AW_GITHUB_EVENT_ISSUE_NUMBER__ }}
+ - **issue-number**: #__GH_AW_GITHUB_EVENT_ISSUE_NUMBER__
+ {{/if}}
+ {{#if __GH_AW_GITHUB_EVENT_DISCUSSION_NUMBER__ }}
+ - **discussion-number**: #__GH_AW_GITHUB_EVENT_DISCUSSION_NUMBER__
+ {{/if}}
+ {{#if __GH_AW_GITHUB_EVENT_PULL_REQUEST_NUMBER__ }}
+ - **pull-request-number**: #__GH_AW_GITHUB_EVENT_PULL_REQUEST_NUMBER__
+ {{/if}}
+ {{#if __GH_AW_GITHUB_EVENT_COMMENT_ID__ }}
+ - **comment-id**: __GH_AW_GITHUB_EVENT_COMMENT_ID__
+ {{/if}}
+ {{#if __GH_AW_GITHUB_RUN_ID__ }}
+ - **workflow-run-id**: __GH_AW_GITHUB_RUN_ID__
+ {{/if}}
+
+
+ GH_AW_PROMPT_f18a65bced008989_EOF
+ cat "${RUNNER_TEMP}/gh-aw/prompts/github_mcp_tools_with_safeoutputs_prompt.md"
+ cat << 'GH_AW_PROMPT_f18a65bced008989_EOF'
+
+ {{#runtime-import .github/workflows/code-radiator.md}}
+ GH_AW_PROMPT_f18a65bced008989_EOF
+ } > "$GH_AW_PROMPT"
+ - name: Interpolate variables and render templates
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ env:
+ GH_AW_PROMPT: /tmp/gh-aw/aw-prompts/prompt.txt
+ GH_AW_ENGINE_ID: "copilot"
+ with:
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/interpolate_prompt.cjs');
+ await main();
+ - name: Substitute placeholders
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ env:
+ GH_AW_PROMPT: /tmp/gh-aw/aw-prompts/prompt.txt
+ GH_AW_GITHUB_ACTOR: ${{ github.actor }}
+ GH_AW_GITHUB_EVENT_COMMENT_ID: ${{ github.event.comment.id }}
+ GH_AW_GITHUB_EVENT_DISCUSSION_NUMBER: ${{ github.event.discussion.number }}
+ GH_AW_GITHUB_EVENT_ISSUE_NUMBER: ${{ github.event.issue.number }}
+ GH_AW_GITHUB_EVENT_PULL_REQUEST_NUMBER: ${{ github.event.pull_request.number }}
+ GH_AW_GITHUB_REPOSITORY: ${{ github.repository }}
+ GH_AW_GITHUB_RUN_ID: ${{ github.run_id }}
+ GH_AW_GITHUB_WORKSPACE: ${{ github.workspace }}
+ GH_AW_MCP_CLI_SERVERS_LIST: '- `safeoutputs` — run `safeoutputs --help` to see available tools'
+ with:
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+
+ const substitutePlaceholders = require('${{ runner.temp }}/gh-aw/actions/substitute_placeholders.cjs');
+
+ // Call the substitution function
+ return await substitutePlaceholders({
+ file: process.env.GH_AW_PROMPT,
+ substitutions: {
+ GH_AW_GITHUB_ACTOR: process.env.GH_AW_GITHUB_ACTOR,
+ GH_AW_GITHUB_EVENT_COMMENT_ID: process.env.GH_AW_GITHUB_EVENT_COMMENT_ID,
+ GH_AW_GITHUB_EVENT_DISCUSSION_NUMBER: process.env.GH_AW_GITHUB_EVENT_DISCUSSION_NUMBER,
+ GH_AW_GITHUB_EVENT_ISSUE_NUMBER: process.env.GH_AW_GITHUB_EVENT_ISSUE_NUMBER,
+ GH_AW_GITHUB_EVENT_PULL_REQUEST_NUMBER: process.env.GH_AW_GITHUB_EVENT_PULL_REQUEST_NUMBER,
+ GH_AW_GITHUB_REPOSITORY: process.env.GH_AW_GITHUB_REPOSITORY,
+ GH_AW_GITHUB_RUN_ID: process.env.GH_AW_GITHUB_RUN_ID,
+ GH_AW_GITHUB_WORKSPACE: process.env.GH_AW_GITHUB_WORKSPACE,
+ GH_AW_MCP_CLI_SERVERS_LIST: process.env.GH_AW_MCP_CLI_SERVERS_LIST
+ }
+ });
+ - name: Validate prompt placeholders
+ env:
+ GH_AW_PROMPT: /tmp/gh-aw/aw-prompts/prompt.txt
+ # poutine:ignore untrusted_checkout_exec
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/validate_prompt_placeholders.sh"
+ - name: Print prompt
+ env:
+ GH_AW_PROMPT: /tmp/gh-aw/aw-prompts/prompt.txt
+ # poutine:ignore untrusted_checkout_exec
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/print_prompt_summary.sh"
+ - name: Upload activation artifact
+ if: success()
+ uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
+ with:
+ name: activation
+ include-hidden-files: true
+ path: |
+ /tmp/gh-aw/aw_info.json
+ /tmp/gh-aw/aw-prompts/prompt.txt
+ /tmp/gh-aw/github_rate_limits.jsonl
+ /tmp/gh-aw/base
+ if-no-files-found: ignore
+ retention-days: 1
+
+ agent:
+ needs: activation
+ runs-on: ubuntu-latest
+ permissions:
+ contents: read
+ pull-requests: read
+ concurrency:
+ group: "gh-aw-copilot-${{ github.workflow }}"
+ env:
+ DEFAULT_BRANCH: ${{ github.event.repository.default_branch }}
+ GH_AW_ASSETS_ALLOWED_EXTS: ""
+ GH_AW_ASSETS_BRANCH: ""
+ GH_AW_ASSETS_MAX_SIZE_KB: 0
+ GH_AW_MCP_LOG_DIR: /tmp/gh-aw/mcp-logs/safeoutputs
+ GH_AW_WORKFLOW_ID_SANITIZED: coderadiator
+ outputs:
+ agentic_engine_timeout: ${{ steps.detect-copilot-errors.outputs.agentic_engine_timeout || 'false' }}
+ checkout_pr_success: ${{ steps.checkout-pr.outputs.checkout_pr_success || 'true' }}
+ effective_tokens: ${{ steps.parse-mcp-gateway.outputs.effective_tokens }}
+ has_patch: ${{ steps.collect_output.outputs.has_patch }}
+ inference_access_error: ${{ steps.detect-copilot-errors.outputs.inference_access_error || 'false' }}
+ mcp_policy_error: ${{ steps.detect-copilot-errors.outputs.mcp_policy_error || 'false' }}
+ model: ${{ needs.activation.outputs.model }}
+ model_not_supported_error: ${{ steps.detect-copilot-errors.outputs.model_not_supported_error || 'false' }}
+ output: ${{ steps.collect_output.outputs.output }}
+ output_types: ${{ steps.collect_output.outputs.output_types }}
+ setup-trace-id: ${{ steps.setup.outputs.trace-id }}
+ steps:
+ - name: Setup Scripts
+ id: setup
+ uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+ with:
+ destination: ${{ runner.temp }}/gh-aw/actions
+ job-name: ${{ github.job }}
+ trace-id: ${{ needs.activation.outputs.setup-trace-id }}
+ env:
+ GH_AW_SETUP_WORKFLOW_NAME: "Code Radiator"
+ GH_AW_CURRENT_WORKFLOW_REF: ${{ github.repository }}/.github/workflows/code-radiator.lock.yml@${{ github.ref }}
+ GH_AW_INFO_VERSION: "1.0.40"
+ - name: Set runtime paths
+ id: set-runtime-paths
+ run: |
+ {
+ echo "GH_AW_SAFE_OUTPUTS=${RUNNER_TEMP}/gh-aw/safeoutputs/outputs.jsonl"
+ echo "GH_AW_SAFE_OUTPUTS_CONFIG_PATH=${RUNNER_TEMP}/gh-aw/safeoutputs/config.json"
+ echo "GH_AW_SAFE_OUTPUTS_TOOLS_PATH=${RUNNER_TEMP}/gh-aw/safeoutputs/tools.json"
+ } >> "$GITHUB_OUTPUT"
+ - name: Checkout repository
+ uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
+ with:
+ persist-credentials: false
+ - name: Create gh-aw temp directory
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/create_gh_aw_tmp_dir.sh"
+ - name: Configure gh CLI for GitHub Enterprise
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/configure_gh_for_ghe.sh"
+ env:
+ GH_TOKEN: ${{ github.token }}
+ - name: Configure Git credentials
+ env:
+ REPO_NAME: ${{ github.repository }}
+ SERVER_URL: ${{ github.server_url }}
+ GITHUB_TOKEN: ${{ github.token }}
+ run: |
+ git config --global user.email "github-actions[bot]@users.noreply.github.com"
+ git config --global user.name "github-actions[bot]"
+ git config --global am.keepcr true
+ # Re-authenticate git with GitHub token
+ SERVER_URL_STRIPPED="${SERVER_URL#https://}"
+ git remote set-url origin "https://x-access-token:${GITHUB_TOKEN}@${SERVER_URL_STRIPPED}/${REPO_NAME}.git"
+ echo "Git configured with standard GitHub Actions identity"
+ - name: Checkout PR branch
+ id: checkout-pr
+ if: |
+ github.event.pull_request || github.event.issue.pull_request
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ env:
+ GH_TOKEN: ${{ secrets.GH_AW_GITHUB_MCP_SERVER_TOKEN || secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
+ with:
+ github-token: ${{ secrets.GH_AW_GITHUB_MCP_SERVER_TOKEN || secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/checkout_pr_branch.cjs');
+ await main();
+ - name: Install GitHub Copilot CLI
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/install_copilot_cli.sh" 1.0.40
+ env:
+ GH_HOST: github.com
+ - name: Install AWF binary
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/install_awf_binary.sh" v0.25.40
+ - name: Parse integrity filter lists
+ id: parse-guard-vars
+ env:
+ GH_AW_BLOCKED_USERS_VAR: ${{ vars.GH_AW_GITHUB_BLOCKED_USERS || '' }}
+ GH_AW_TRUSTED_USERS_VAR: ${{ vars.GH_AW_GITHUB_TRUSTED_USERS || '' }}
+ GH_AW_APPROVAL_LABELS_VAR: ${{ vars.GH_AW_GITHUB_APPROVAL_LABELS || '' }}
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/parse_guard_list.sh"
+ - name: Download activation artifact
+ uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
+ with:
+ name: activation
+ path: /tmp/gh-aw
+ - name: Restore agent config folders from base branch
+ if: steps.checkout-pr.outcome == 'success'
+ env:
+ GH_AW_AGENT_FOLDERS: ".agents .claude .codex .crush .gemini .github .opencode .pi"
+ GH_AW_AGENT_FILES: ".crush.json AGENTS.md CLAUDE.md GEMINI.md PI.md opencode.jsonc"
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/restore_base_github_folders.sh"
+ - name: Download container images
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/download_docker_images.sh" ghcr.io/github/gh-aw-firewall/agent:0.25.40@sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504 ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40@sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280 ghcr.io/github/gh-aw-firewall/squid:0.25.40@sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51 ghcr.io/github/gh-aw-mcpg:v0.3.6@sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959 node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f
+ - name: Generate Safe Outputs Config
+ run: |
+ mkdir -p "${RUNNER_TEMP}/gh-aw/safeoutputs"
+ mkdir -p /tmp/gh-aw/safeoutputs
+ mkdir -p /tmp/gh-aw/mcp-logs/safeoutputs
+ cat > "${RUNNER_TEMP}/gh-aw/safeoutputs/config.json" << 'GH_AW_SAFE_OUTPUTS_CONFIG_67dd340333ff2a92_EOF'
+ {"add_comment":{"max":10},"add_labels":{"max":10},"create_pull_request":{"max":10,"max_patch_files":100,"max_patch_size":1024,"protect_top_level_dot_folders":true,"protected_files":["package.json","bun.lockb","bunfig.toml","deno.json","deno.jsonc","deno.lock","global.json","NuGet.Config","Directory.Packages.props","mix.exs","mix.lock","go.mod","go.sum","stack.yaml","stack.yaml.lock","pom.xml","build.gradle","build.gradle.kts","settings.gradle","settings.gradle.kts","gradle.properties","package-lock.json","yarn.lock","pnpm-lock.yaml","npm-shrinkwrap.json","requirements.txt","Pipfile","Pipfile.lock","pyproject.toml","setup.py","setup.cfg","Gemfile","Gemfile.lock","uv.lock","CODEOWNERS","DESIGN.md","README.md","CONTRIBUTING.md","CHANGELOG.md","SECURITY.md","CODE_OF_CONDUCT.md","AGENTS.md","CLAUDE.md","GEMINI.md"]},"create_report_incomplete_issue":{},"merge_pull_request":{"max":10},"missing_data":{},"missing_tool":{},"noop":{"max":1,"report-as-issue":"true"},"push_to_pull_request_branch":{"if_no_changes":"warn","max":10,"max_patch_size":1024,"protect_top_level_dot_folders":true,"protected_files":["package.json","bun.lockb","bunfig.toml","deno.json","deno.jsonc","deno.lock","global.json","NuGet.Config","Directory.Packages.props","mix.exs","mix.lock","go.mod","go.sum","stack.yaml","stack.yaml.lock","pom.xml","build.gradle","build.gradle.kts","settings.gradle","settings.gradle.kts","gradle.properties","package-lock.json","yarn.lock","pnpm-lock.yaml","npm-shrinkwrap.json","requirements.txt","Pipfile","Pipfile.lock","pyproject.toml","setup.py","setup.cfg","Gemfile","Gemfile.lock","uv.lock","CODEOWNERS","DESIGN.md","README.md","CONTRIBUTING.md","CHANGELOG.md","SECURITY.md","CODE_OF_CONDUCT.md","AGENTS.md","CLAUDE.md","GEMINI.md"]},"report_incomplete":{},"update_pull_request":{"allow_body":true,"allow_title":true,"max":10,"update_branch":false}}
+ GH_AW_SAFE_OUTPUTS_CONFIG_67dd340333ff2a92_EOF
+ - name: Generate Safe Outputs Tools
+ env:
+ GH_AW_TOOLS_META_JSON: |
+ {
+ "description_suffixes": {
+ "add_comment": " CONSTRAINTS: Maximum 10 comment(s) can be added. Supports reply_to_id for discussion threading.",
+ "add_labels": " CONSTRAINTS: Maximum 10 label(s) can be added.",
+ "create_pull_request": " CONSTRAINTS: Maximum 10 pull request(s) can be created.",
+ "push_to_pull_request_branch": " CONSTRAINTS: Maximum 10 push(es) can be made.",
+ "update_pull_request": " CONSTRAINTS: Maximum 10 pull request(s) can be updated."
+ },
+ "repo_params": {},
+ "dynamic_tools": []
+ }
+ GH_AW_VALIDATION_JSON: |
+ {
+ "add_comment": {
+ "defaultMax": 1,
+ "fields": {
+ "body": {
+ "required": true,
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 65000
+ },
+ "item_number": {
+ "issueOrPRNumber": true
+ },
+ "reply_to_id": {
+ "type": "string",
+ "maxLength": 256
+ },
+ "repo": {
+ "type": "string",
+ "maxLength": 256
+ }
+ }
+ },
+ "add_labels": {
+ "defaultMax": 5,
+ "fields": {
+ "item_number": {
+ "issueNumberOrTemporaryId": true
+ },
+ "labels": {
+ "required": true,
+ "type": "array",
+ "itemType": "string",
+ "itemSanitize": true,
+ "itemMaxLength": 128
+ },
+ "repo": {
+ "type": "string",
+ "maxLength": 256
+ }
+ }
+ },
+ "create_pull_request": {
+ "defaultMax": 1,
+ "fields": {
+ "base": {
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 128
+ },
+ "body": {
+ "required": true,
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 65000
+ },
+ "branch": {
+ "required": true,
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 256
+ },
+ "draft": {
+ "type": "boolean"
+ },
+ "labels": {
+ "type": "array",
+ "itemType": "string",
+ "itemSanitize": true,
+ "itemMaxLength": 128
+ },
+ "repo": {
+ "type": "string",
+ "maxLength": 256
+ },
+ "title": {
+ "required": true,
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 128
+ }
+ }
+ },
+ "merge_pull_request": {
+ "defaultMax": 1,
+ "fields": {
+ "commit_message": {
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 65000
+ },
+ "commit_title": {
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 256
+ },
+ "merge_method": {
+ "type": "string",
+ "enum": [
+ "merge",
+ "squash",
+ "rebase"
+ ]
+ },
+ "pull_request_number": {
+ "issueOrPRNumber": true
+ },
+ "repo": {
+ "type": "string",
+ "maxLength": 256
+ }
+ }
+ },
+ "missing_data": {
+ "defaultMax": 20,
+ "fields": {
+ "alternatives": {
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 256
+ },
+ "context": {
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 256
+ },
+ "data_type": {
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 128
+ },
+ "reason": {
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 256
+ }
+ }
+ },
+ "missing_tool": {
+ "defaultMax": 20,
+ "fields": {
+ "alternatives": {
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 512
+ },
+ "reason": {
+ "required": true,
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 256
+ },
+ "tool": {
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 128
+ }
+ }
+ },
+ "noop": {
+ "defaultMax": 1,
+ "fields": {
+ "message": {
+ "required": true,
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 65000
+ }
+ }
+ },
+ "push_to_pull_request_branch": {
+ "defaultMax": 1,
+ "fields": {
+ "branch": {
+ "required": true,
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 256
+ },
+ "message": {
+ "required": true,
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 65000
+ },
+ "pull_request_number": {
+ "issueOrPRNumber": true
+ }
+ }
+ },
+ "report_incomplete": {
+ "defaultMax": 5,
+ "fields": {
+ "details": {
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 65000
+ },
+ "reason": {
+ "required": true,
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 1024
+ }
+ }
+ },
+ "update_pull_request": {
+ "defaultMax": 1,
+ "fields": {
+ "body": {
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 65000
+ },
+ "draft": {
+ "type": "boolean"
+ },
+ "operation": {
+ "type": "string",
+ "enum": [
+ "replace",
+ "append",
+ "prepend"
+ ]
+ },
+ "pull_request_number": {
+ "issueOrPRNumber": true
+ },
+ "repo": {
+ "type": "string",
+ "maxLength": 256
+ },
+ "title": {
+ "type": "string",
+ "sanitize": true,
+ "maxLength": 256
+ },
+ "update_branch": {
+ "type": "boolean"
+ }
+ },
+ "customValidation": "requiresOneOf:title,body,update_branch"
+ }
+ }
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ with:
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/generate_safe_outputs_tools.cjs');
+ await main();
+ - name: Generate Safe Outputs MCP Server Config
+ id: safe-outputs-config
+ run: |
+ # Generate a secure random API key (360 bits of entropy, 40+ chars)
+ # Mask immediately to prevent timing vulnerabilities
+ API_KEY=$(openssl rand -base64 45 | tr -d '/+=')
+ echo "::add-mask::${API_KEY}"
+
+ PORT=3001
+
+ # Set outputs for next steps
+ {
+ echo "safe_outputs_api_key=${API_KEY}"
+ echo "safe_outputs_port=${PORT}"
+ } >> "$GITHUB_OUTPUT"
+
+ echo "Safe Outputs MCP server will run on port ${PORT}"
+
+ - name: Start Safe Outputs MCP HTTP Server
+ id: safe-outputs-start
+ env:
+ DEBUG: '*'
+ GH_AW_SAFE_OUTPUTS: ${{ steps.set-runtime-paths.outputs.GH_AW_SAFE_OUTPUTS }}
+ GH_AW_SAFE_OUTPUTS_PORT: ${{ steps.safe-outputs-config.outputs.safe_outputs_port }}
+ GH_AW_SAFE_OUTPUTS_API_KEY: ${{ steps.safe-outputs-config.outputs.safe_outputs_api_key }}
+ GH_AW_SAFE_OUTPUTS_TOOLS_PATH: ${{ runner.temp }}/gh-aw/safeoutputs/tools.json
+ GH_AW_SAFE_OUTPUTS_CONFIG_PATH: ${{ runner.temp }}/gh-aw/safeoutputs/config.json
+ GH_AW_MCP_LOG_DIR: /tmp/gh-aw/mcp-logs/safeoutputs
+ run: |
+ # Environment variables are set above to prevent template injection
+ export DEBUG
+ export GH_AW_SAFE_OUTPUTS
+ export GH_AW_SAFE_OUTPUTS_PORT
+ export GH_AW_SAFE_OUTPUTS_API_KEY
+ export GH_AW_SAFE_OUTPUTS_TOOLS_PATH
+ export GH_AW_SAFE_OUTPUTS_CONFIG_PATH
+ export GH_AW_MCP_LOG_DIR
+
+ bash "${RUNNER_TEMP}/gh-aw/actions/start_safe_outputs_server.sh"
+
+ - name: Start MCP Gateway
+ id: start-mcp-gateway
+ env:
+ GH_AW_SAFE_OUTPUTS: ${{ steps.set-runtime-paths.outputs.GH_AW_SAFE_OUTPUTS }}
+ GH_AW_SAFE_OUTPUTS_API_KEY: ${{ steps.safe-outputs-start.outputs.api_key }}
+ GH_AW_SAFE_OUTPUTS_PORT: ${{ steps.safe-outputs-start.outputs.port }}
+ GITHUB_MCP_SERVER_TOKEN: ${{ secrets.GH_AW_GITHUB_MCP_SERVER_TOKEN || secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
+ run: |
+ set -eo pipefail
+ mkdir -p "${RUNNER_TEMP}/gh-aw/mcp-config"
+
+ # Export gateway environment variables for MCP config and gateway script
+ export MCP_GATEWAY_PORT="8080"
+ export MCP_GATEWAY_DOMAIN="host.docker.internal"
+ export MCP_GATEWAY_HOST_DOMAIN="localhost"
+ MCP_GATEWAY_API_KEY=$(openssl rand -base64 45 | tr -d '/+=')
+ echo "::add-mask::${MCP_GATEWAY_API_KEY}"
+ export MCP_GATEWAY_API_KEY
+ export MCP_GATEWAY_PAYLOAD_DIR="/tmp/gh-aw/mcp-payloads"
+ mkdir -p "${MCP_GATEWAY_PAYLOAD_DIR}"
+ export MCP_GATEWAY_PAYLOAD_SIZE_THRESHOLD="524288"
+ export DEBUG="*"
+
+ export GH_AW_ENGINE="copilot"
+ MCP_GATEWAY_UID=$(id -u 2>/dev/null || echo '0')
+ MCP_GATEWAY_GID=$(id -g 2>/dev/null || echo '0')
+ DOCKER_SOCK_GID=$(stat -c '%g' /var/run/docker.sock 2>/dev/null || echo '0')
+ export MCP_GATEWAY_DOCKER_COMMAND='docker run -i --rm --network host --add-host host.docker.internal:127.0.0.1 --user '"${MCP_GATEWAY_UID}"':'"${MCP_GATEWAY_GID}"' --group-add '"${DOCKER_SOCK_GID}"' -v /var/run/docker.sock:/var/run/docker.sock -e MCP_GATEWAY_PORT -e MCP_GATEWAY_DOMAIN -e MCP_GATEWAY_API_KEY -e MCP_GATEWAY_PAYLOAD_DIR -e MCP_GATEWAY_PAYLOAD_SIZE_THRESHOLD -e DEBUG -e MCP_GATEWAY_LOG_DIR -e GH_AW_MCP_LOG_DIR -e GH_AW_SAFE_OUTPUTS -e GH_AW_SAFE_OUTPUTS_CONFIG_PATH -e GH_AW_SAFE_OUTPUTS_TOOLS_PATH -e GH_AW_ASSETS_BRANCH -e GH_AW_ASSETS_MAX_SIZE_KB -e GH_AW_ASSETS_ALLOWED_EXTS -e DEFAULT_BRANCH -e GITHUB_MCP_SERVER_TOKEN -e GITHUB_MCP_GUARD_MIN_INTEGRITY -e GITHUB_MCP_GUARD_REPOS -e GITHUB_REPOSITORY -e GITHUB_SERVER_URL -e GITHUB_SHA -e GITHUB_WORKSPACE -e GITHUB_TOKEN -e GITHUB_RUN_ID -e GITHUB_RUN_NUMBER -e GITHUB_RUN_ATTEMPT -e GITHUB_JOB -e GITHUB_ACTION -e GITHUB_EVENT_NAME -e GITHUB_EVENT_PATH -e GITHUB_ACTOR -e GITHUB_ACTOR_ID -e GITHUB_TRIGGERING_ACTOR -e GITHUB_WORKFLOW -e GITHUB_WORKFLOW_REF -e GITHUB_WORKFLOW_SHA -e GITHUB_REF -e GITHUB_REF_NAME -e GITHUB_REF_TYPE -e GITHUB_HEAD_REF -e GITHUB_BASE_REF -e GH_AW_SAFE_OUTPUTS_PORT -e GH_AW_SAFE_OUTPUTS_API_KEY -v /tmp/gh-aw/mcp-payloads:/tmp/gh-aw/mcp-payloads:rw -v /opt:/opt:ro -v /tmp:/tmp:rw -v '"${GITHUB_WORKSPACE}"':'"${GITHUB_WORKSPACE}"':rw ghcr.io/github/gh-aw-mcpg:v0.3.6'
+
+ mkdir -p /home/runner/.copilot
+ GH_AW_NODE=$(which node 2>/dev/null || command -v node 2>/dev/null || echo node)
+ cat << GH_AW_MCP_CONFIG_1fe8f1e7abc04440_EOF | "$GH_AW_NODE" "${RUNNER_TEMP}/gh-aw/actions/start_mcp_gateway.cjs"
+ {
+ "mcpServers": {
+ "github": {
+ "type": "stdio",
+ "container": "ghcr.io/github/github-mcp-server:v1.0.3",
+ "env": {
+ "GITHUB_HOST": "\${GITHUB_SERVER_URL}",
+ "GITHUB_PERSONAL_ACCESS_TOKEN": "\${GITHUB_MCP_SERVER_TOKEN}",
+ "GITHUB_READ_ONLY": "1",
+ "GITHUB_TOOLSETS": "pull_requests,repos"
+ },
+ "guard-policies": {
+ "allow-only": {
+ "approval-labels": ${{ steps.parse-guard-vars.outputs.approval_labels }},
+ "blocked-users": ${{ steps.parse-guard-vars.outputs.blocked_users }},
+ "min-integrity": "none",
+ "repos": "all",
+ "trusted-users": ${{ steps.parse-guard-vars.outputs.trusted_users }}
+ }
+ }
+ },
+ "safeoutputs": {
+ "type": "http",
+ "url": "http://host.docker.internal:$GH_AW_SAFE_OUTPUTS_PORT",
+ "headers": {
+ "Authorization": "\${GH_AW_SAFE_OUTPUTS_API_KEY}"
+ },
+ "guard-policies": {
+ "write-sink": {
+ "accept": [
+ "*"
+ ]
+ }
+ }
+ }
+ },
+ "gateway": {
+ "port": $MCP_GATEWAY_PORT,
+ "domain": "${MCP_GATEWAY_DOMAIN}",
+ "apiKey": "${MCP_GATEWAY_API_KEY}",
+ "payloadDir": "${MCP_GATEWAY_PAYLOAD_DIR}"
+ }
+ }
+ GH_AW_MCP_CONFIG_1fe8f1e7abc04440_EOF
+ - name: Mount MCP servers as CLIs
+ id: mount-mcp-clis
+ continue-on-error: true
+ env:
+ MCP_GATEWAY_API_KEY: ${{ steps.start-mcp-gateway.outputs.gateway-api-key }}
+ MCP_GATEWAY_DOMAIN: ${{ steps.start-mcp-gateway.outputs.gateway-domain }}
+ MCP_GATEWAY_PORT: ${{ steps.start-mcp-gateway.outputs.gateway-port }}
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ with:
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/mount_mcp_as_cli.cjs');
+ await main();
+ - name: Clean credentials
+ continue-on-error: true
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/clean_git_credentials.sh"
+ - name: Audit pre-agent workspace
+ id: pre_agent_audit
+ continue-on-error: true
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/audit_pre_agent_workspace.sh"
+ - name: Execute GitHub Copilot CLI
+ id: agentic_execution
+ # Copilot CLI tool arguments (sorted):
+ timeout-minutes: 20
+ run: |
+ set -o pipefail
+ touch /tmp/gh-aw/agent-step-summary.md
+ GH_AW_NODE_BIN=$(command -v node 2>/dev/null || true)
+ export GH_AW_NODE_BIN
+ (umask 177 && touch /tmp/gh-aw/agent-stdio.log)
+ printf '%s\n' '{"$schema":"https://github.com/github/gh-aw-firewall/releases/download/v0.25.40/awf-config.schema.json","network":{"allowDomains":["*.githubusercontent.com","api.business.githubcopilot.com","api.enterprise.githubcopilot.com","api.github.com","api.githubcopilot.com","api.individual.githubcopilot.com","api.snapcraft.io","archive.ubuntu.com","azure.archive.ubuntu.com","codeload.github.com","crl.geotrust.com","crl.globalsign.com","crl.identrust.com","crl.sectigo.com","crl.thawte.com","crl.usertrust.com","crl.verisign.com","crl3.digicert.com","crl4.digicert.com","crls.ssl.com","docs.github.com","github-cloud.githubusercontent.com","github-cloud.s3.amazonaws.com","github.blog","github.com","github.githubassets.com","host.docker.internal","json-schema.org","json.schemastore.org","keyserver.ubuntu.com","lfs.github.com","objects.githubusercontent.com","ocsp.digicert.com","ocsp.geotrust.com","ocsp.globalsign.com","ocsp.identrust.com","ocsp.sectigo.com","ocsp.ssl.com","ocsp.thawte.com","ocsp.usertrust.com","ocsp.verisign.com","packagecloud.io","packages.cloud.google.com","packages.microsoft.com","ppa.launchpad.net","raw.githubusercontent.com","registry.npmjs.org","s.symcb.com","s.symcd.com","security.ubuntu.com","telemetry.enterprise.githubcopilot.com","ts-crl.ws.symantec.com","ts-ocsp.ws.symantec.com","www.googleapis.com"]},"apiProxy":{"enabled":true,"models":{"auto":["large"],"deep-research":["copilot/deep-research*","google/deep-research*"],"gemini-flash":["copilot/gemini-*flash*","google/gemini-*flash*"],"gemini-pro":["copilot/gemini-*pro*","google/gemini-*pro*"],"gpt-4.1":["copilot/gpt-4.1*","openai/gpt-4.1*"],"gpt-5":["copilot/gpt-5*","openai/gpt-5*"],"gpt-5-codex":["copilot/gpt-5*codex*","openai/gpt-5*codex*"],"gpt-5-mini":["copilot/gpt-5*mini*","openai/gpt-5*mini*"],"gpt-5-nano":["copilot/gpt-5*nano*","openai/gpt-5*nano*"],"gpt-5-pro":["copilot/gpt-5*pro*","openai/gpt-5*pro*"],"haiku":["copilot/*haiku*","anthropic/*haiku*"],"large":["sonnet","gpt-5-pro","gpt-5","gemini-pro"],"mini":["haiku","gpt-5-mini","gpt-5-nano","gemini-flash"],"opus":["copilot/*opus*","anthropic/*opus*"],"reasoning":["copilot/o1*","copilot/o3*","copilot/o4*","openai/o1*","openai/o3*","openai/o4*"],"small":["mini"],"sonnet":["copilot/*sonnet*","anthropic/*sonnet*"]}},"container":{"imageTag":"0.25.40,squid=sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51,agent=sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504,api-proxy=sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280,cli-proxy=sha256:3e7152911d4b4b7b97beef9d3d7d924ff7902227e86001ef3838fb728d5d514c"}}' > "${RUNNER_TEMP}/gh-aw/awf-config.json" && cp "${RUNNER_TEMP}/gh-aw/awf-config.json" /tmp/gh-aw/awf-config.json
+ # shellcheck disable=SC1003
+ sudo -E awf --config "${RUNNER_TEMP}/gh-aw/awf-config.json" --container-workdir "${GITHUB_WORKSPACE}" --mount "${RUNNER_TEMP}/gh-aw:${RUNNER_TEMP}/gh-aw:ro" --mount "${RUNNER_TEMP}/gh-aw:/host${RUNNER_TEMP}/gh-aw:ro" --env-all --exclude-env COPILOT_GITHUB_TOKEN --exclude-env GITHUB_MCP_SERVER_TOKEN --exclude-env MCP_GATEWAY_API_KEY --log-level info --proxy-logs-dir /tmp/gh-aw/sandbox/firewall/logs --audit-dir /tmp/gh-aw/sandbox/firewall/audit --enable-host-access --allow-host-ports 80,443,8080 --skip-pull \
+ -- /bin/bash -c 'export PATH="${RUNNER_TEMP}/gh-aw/mcp-cli/bin:$PATH" && export PATH="$(find /opt/hostedtoolcache /home/runner/work/_tool -maxdepth 4 -type d -name bin 2>/dev/null | tr '\''\n'\'' '\'':'\'')$PATH"; [ -n "$GOROOT" ] && export PATH="$GOROOT/bin:$PATH" || true && GH_AW_NODE_EXEC="${GH_AW_NODE_BIN:-}"; if [ -z "$GH_AW_NODE_EXEC" ] || [ ! -x "$GH_AW_NODE_EXEC" ]; then GH_AW_NODE_EXEC="$(command -v node 2>/dev/null || echo node)"; fi; "$GH_AW_NODE_EXEC" ${RUNNER_TEMP}/gh-aw/actions/copilot_harness.cjs /usr/local/bin/copilot --add-dir /tmp/gh-aw/ --log-level all --log-dir /tmp/gh-aw/sandbox/agent/logs/ --disable-builtin-mcps --no-ask-user --allow-all-tools --allow-all-paths --add-dir "${GITHUB_WORKSPACE}" --prompt-file /tmp/gh-aw/aw-prompts/prompt.txt' 2>&1 | tee -a /tmp/gh-aw/agent-stdio.log
+ env:
+ COPILOT_AGENT_RUNNER_TYPE: STANDALONE
+ COPILOT_API_KEY: dummy-byok-key-for-offline-mode
+ COPILOT_GITHUB_TOKEN: ${{ secrets.COPILOT_GITHUB_TOKEN }}
+ COPILOT_MODEL: claude-sonnet-4.5
+ GH_AW_MCP_CONFIG: /home/runner/.copilot/mcp-config.json
+ GH_AW_PHASE: agent
+ GH_AW_PROMPT: /tmp/gh-aw/aw-prompts/prompt.txt
+ GH_AW_SAFE_OUTPUTS: ${{ steps.set-runtime-paths.outputs.GH_AW_SAFE_OUTPUTS }}
+ GH_AW_VERSION: v0.71.5
+ GITHUB_API_URL: ${{ github.api_url }}
+ GITHUB_AW: true
+ GITHUB_COPILOT_INTEGRATION_ID: agentic-workflows
+ GITHUB_HEAD_REF: ${{ github.head_ref }}
+ GITHUB_MCP_SERVER_TOKEN: ${{ secrets.GH_AW_GITHUB_MCP_SERVER_TOKEN || secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
+ GITHUB_REF_NAME: ${{ github.ref_name }}
+ GITHUB_SERVER_URL: ${{ github.server_url }}
+ GITHUB_STEP_SUMMARY: /tmp/gh-aw/agent-step-summary.md
+ GITHUB_WORKSPACE: ${{ github.workspace }}
+ GIT_AUTHOR_EMAIL: github-actions[bot]@users.noreply.github.com
+ GIT_AUTHOR_NAME: github-actions[bot]
+ GIT_COMMITTER_EMAIL: github-actions[bot]@users.noreply.github.com
+ GIT_COMMITTER_NAME: github-actions[bot]
+ XDG_CONFIG_HOME: /home/runner
+ - name: Detect Copilot errors
+ id: detect-copilot-errors
+ if: always()
+ continue-on-error: true
+ run: node "${RUNNER_TEMP}/gh-aw/actions/detect_copilot_errors.cjs"
+ - name: Configure Git credentials
+ env:
+ REPO_NAME: ${{ github.repository }}
+ SERVER_URL: ${{ github.server_url }}
+ GITHUB_TOKEN: ${{ github.token }}
+ run: |
+ git config --global user.email "github-actions[bot]@users.noreply.github.com"
+ git config --global user.name "github-actions[bot]"
+ git config --global am.keepcr true
+ # Re-authenticate git with GitHub token
+ SERVER_URL_STRIPPED="${SERVER_URL#https://}"
+ git remote set-url origin "https://x-access-token:${GITHUB_TOKEN}@${SERVER_URL_STRIPPED}/${REPO_NAME}.git"
+ echo "Git configured with standard GitHub Actions identity"
+ - name: Copy Copilot session state files to logs
+ if: always()
+ continue-on-error: true
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/copy_copilot_session_state.sh"
+ - name: Stop MCP Gateway
+ if: always()
+ continue-on-error: true
+ env:
+ MCP_GATEWAY_PORT: ${{ steps.start-mcp-gateway.outputs.gateway-port }}
+ MCP_GATEWAY_API_KEY: ${{ steps.start-mcp-gateway.outputs.gateway-api-key }}
+ GATEWAY_PID: ${{ steps.start-mcp-gateway.outputs.gateway-pid }}
+ run: |
+ bash "${RUNNER_TEMP}/gh-aw/actions/stop_mcp_gateway.sh" "$GATEWAY_PID"
+ - name: Redact secrets in logs
+ if: always()
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ with:
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/redact_secrets.cjs');
+ await main();
+ env:
+ GH_AW_SECRET_NAMES: 'COPILOT_GITHUB_TOKEN,GH_AW_GITHUB_MCP_SERVER_TOKEN,GH_AW_GITHUB_TOKEN,GITHUB_TOKEN'
+ SECRET_COPILOT_GITHUB_TOKEN: ${{ secrets.COPILOT_GITHUB_TOKEN }}
+ SECRET_GH_AW_GITHUB_MCP_SERVER_TOKEN: ${{ secrets.GH_AW_GITHUB_MCP_SERVER_TOKEN }}
+ SECRET_GH_AW_GITHUB_TOKEN: ${{ secrets.GH_AW_GITHUB_TOKEN }}
+ SECRET_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+ - name: Append agent step summary
+ if: always()
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/append_agent_step_summary.sh"
+ - name: Copy Safe Outputs
+ if: always()
+ env:
+ GH_AW_SAFE_OUTPUTS: ${{ steps.set-runtime-paths.outputs.GH_AW_SAFE_OUTPUTS }}
+ run: |
+ mkdir -p /tmp/gh-aw
+ cp "$GH_AW_SAFE_OUTPUTS" /tmp/gh-aw/safeoutputs.jsonl 2>/dev/null || true
+ - name: Ingest agent output
+ id: collect_output
+ if: always()
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ env:
+ GH_AW_SAFE_OUTPUTS: ${{ steps.set-runtime-paths.outputs.GH_AW_SAFE_OUTPUTS }}
+ GH_AW_ALLOWED_DOMAINS: "*.githubusercontent.com,api.business.githubcopilot.com,api.enterprise.githubcopilot.com,api.github.com,api.githubcopilot.com,api.individual.githubcopilot.com,api.snapcraft.io,archive.ubuntu.com,azure.archive.ubuntu.com,codeload.github.com,crl.geotrust.com,crl.globalsign.com,crl.identrust.com,crl.sectigo.com,crl.thawte.com,crl.usertrust.com,crl.verisign.com,crl3.digicert.com,crl4.digicert.com,crls.ssl.com,docs.github.com,github-cloud.githubusercontent.com,github-cloud.s3.amazonaws.com,github.blog,github.com,github.githubassets.com,host.docker.internal,json-schema.org,json.schemastore.org,keyserver.ubuntu.com,lfs.github.com,objects.githubusercontent.com,ocsp.digicert.com,ocsp.geotrust.com,ocsp.globalsign.com,ocsp.identrust.com,ocsp.sectigo.com,ocsp.ssl.com,ocsp.thawte.com,ocsp.usertrust.com,ocsp.verisign.com,packagecloud.io,packages.cloud.google.com,packages.microsoft.com,ppa.launchpad.net,raw.githubusercontent.com,registry.npmjs.org,s.symcb.com,s.symcd.com,security.ubuntu.com,telemetry.enterprise.githubcopilot.com,ts-crl.ws.symantec.com,ts-ocsp.ws.symantec.com,www.googleapis.com"
+ GITHUB_SERVER_URL: ${{ github.server_url }}
+ GITHUB_API_URL: ${{ github.api_url }}
+ with:
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/collect_ndjson_output.cjs');
+ await main();
+ - name: Parse agent logs for step summary
+ if: always()
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ env:
+ GH_AW_AGENT_OUTPUT: /tmp/gh-aw/sandbox/agent/logs/
+ with:
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/parse_copilot_log.cjs');
+ await main();
+ - name: Parse MCP Gateway logs for step summary
+ if: always()
+ id: parse-mcp-gateway
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ with:
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/parse_mcp_gateway_log.cjs');
+ await main();
+ - name: Print firewall logs
+ if: always()
+ continue-on-error: true
+ env:
+ AWF_LOGS_DIR: /tmp/gh-aw/sandbox/firewall/logs
+ run: |
+ # Fix permissions on firewall logs/audit dirs so they can be uploaded as artifacts
+ # AWF runs with sudo, creating files owned by root
+ sudo chmod -R a+r /tmp/gh-aw/sandbox/firewall 2>/dev/null || true
+ # Only run awf logs summary if awf command exists (it may not be installed if workflow failed before install step)
+ if command -v awf &> /dev/null; then
+ awf logs summary | tee -a "$GITHUB_STEP_SUMMARY"
+ else
+ echo 'AWF binary not installed, skipping firewall log summary'
+ fi
+ - name: Parse token usage for step summary
+ if: always()
+ continue-on-error: true
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ with:
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/parse_token_usage.cjs');
+ await main();
+ - name: Print AWF reflect summary
+ if: always()
+ continue-on-error: true
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ with:
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/awf_reflect_summary.cjs');
+ await main();
+ - name: Write agent output placeholder if missing
+ if: always()
+ run: |
+ if [ ! -f /tmp/gh-aw/agent_output.json ]; then
+ echo '{"items":[]}' > /tmp/gh-aw/agent_output.json
+ fi
+ - name: Upload agent artifacts
+ if: always()
+ continue-on-error: true
+ uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
+ with:
+ name: agent
+ path: |
+ /tmp/gh-aw/aw-prompts/prompt.txt
+ /tmp/gh-aw/sandbox/agent/logs/
+ /tmp/gh-aw/redacted-urls.log
+ /tmp/gh-aw/mcp-logs/
+ /tmp/gh-aw/proxy-logs/
+ !/tmp/gh-aw/proxy-logs/proxy-tls/
+ /tmp/gh-aw/agent_usage.json
+ /tmp/gh-aw/agent-stdio.log
+ /tmp/gh-aw/pre-agent-audit.txt
+ /tmp/gh-aw/agent/
+ /tmp/gh-aw/github_rate_limits.jsonl
+ /tmp/gh-aw/safeoutputs.jsonl
+ /tmp/gh-aw/agent_output.json
+ /tmp/gh-aw/aw-*.patch
+ /tmp/gh-aw/aw-*.bundle
+ /tmp/gh-aw/awf-config.json
+ /tmp/gh-aw/sandbox/firewall/logs/
+ /tmp/gh-aw/sandbox/firewall/audit/
+ /tmp/gh-aw/sandbox/firewall/awf-reflect.json
+ if-no-files-found: ignore
+
+ conclusion:
+ needs:
+ - activation
+ - agent
+ - detection
+ - safe_outputs
+ if: >
+ always() && (needs.agent.result != 'skipped' || needs.activation.outputs.lockdown_check_failed == 'true' ||
+ needs.activation.outputs.stale_lock_file_failed == 'true')
+ runs-on: ubuntu-slim
+ permissions:
+ contents: write
+ discussions: write
+ issues: write
+ pull-requests: write
+ concurrency:
+ group: "gh-aw-conclusion-code-radiator"
+ cancel-in-progress: false
+ outputs:
+ incomplete_count: ${{ steps.report_incomplete.outputs.incomplete_count }}
+ noop_message: ${{ steps.noop.outputs.noop_message }}
+ tools_reported: ${{ steps.missing_tool.outputs.tools_reported }}
+ total_count: ${{ steps.missing_tool.outputs.total_count }}
+ steps:
+ - name: Setup Scripts
+ id: setup
+ uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+ with:
+ destination: ${{ runner.temp }}/gh-aw/actions
+ job-name: ${{ github.job }}
+ trace-id: ${{ needs.activation.outputs.setup-trace-id }}
+ env:
+ GH_AW_SETUP_WORKFLOW_NAME: "Code Radiator"
+ GH_AW_CURRENT_WORKFLOW_REF: ${{ github.repository }}/.github/workflows/code-radiator.lock.yml@${{ github.ref }}
+ GH_AW_INFO_VERSION: "1.0.40"
+ - name: Download agent output artifact
+ id: download-agent-output
+ continue-on-error: true
+ uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
+ with:
+ name: agent
+ path: /tmp/gh-aw/
+ - name: Setup agent output environment variable
+ id: setup-agent-output-env
+ if: steps.download-agent-output.outcome == 'success'
+ run: |
+ mkdir -p /tmp/gh-aw/
+ find "/tmp/gh-aw/" -type f -print
+ echo "GH_AW_AGENT_OUTPUT=/tmp/gh-aw/agent_output.json" >> "$GITHUB_OUTPUT"
+ - name: Process no-op messages
+ id: noop
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ env:
+ GH_AW_AGENT_OUTPUT: ${{ steps.setup-agent-output-env.outputs.GH_AW_AGENT_OUTPUT }}
+ GH_AW_NOOP_MAX: "1"
+ GH_AW_WORKFLOW_NAME: "Code Radiator"
+ GH_AW_RUN_URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
+ GH_AW_AGENT_CONCLUSION: ${{ needs.agent.result }}
+ GH_AW_NOOP_REPORT_AS_ISSUE: "true"
+ with:
+ github-token: ${{ secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/handle_noop_message.cjs');
+ await main();
+ - name: Log detection run
+ id: detection_runs
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ env:
+ GH_AW_AGENT_OUTPUT: ${{ steps.setup-agent-output-env.outputs.GH_AW_AGENT_OUTPUT }}
+ GH_AW_WORKFLOW_NAME: "Code Radiator"
+ GH_AW_RUN_URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
+ GH_AW_DETECTION_CONCLUSION: ${{ needs.detection.outputs.detection_conclusion }}
+ GH_AW_DETECTION_REASON: ${{ needs.detection.outputs.detection_reason }}
+ with:
+ github-token: ${{ secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/handle_detection_runs.cjs');
+ await main();
+ - name: Record missing tool
+ id: missing_tool
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ env:
+ GH_AW_AGENT_OUTPUT: ${{ steps.setup-agent-output-env.outputs.GH_AW_AGENT_OUTPUT }}
+ GH_AW_MISSING_TOOL_CREATE_ISSUE: "true"
+ GH_AW_WORKFLOW_NAME: "Code Radiator"
+ with:
+ github-token: ${{ secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/missing_tool.cjs');
+ await main();
+ - name: Record incomplete
+ id: report_incomplete
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ env:
+ GH_AW_AGENT_OUTPUT: ${{ steps.setup-agent-output-env.outputs.GH_AW_AGENT_OUTPUT }}
+ GH_AW_REPORT_INCOMPLETE_CREATE_ISSUE: "true"
+ GH_AW_WORKFLOW_NAME: "Code Radiator"
+ with:
+ github-token: ${{ secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/report_incomplete_handler.cjs');
+ await main();
+ - name: Handle agent failure
+ id: handle_agent_failure
+ if: always()
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ env:
+ GH_AW_AGENT_OUTPUT: ${{ steps.setup-agent-output-env.outputs.GH_AW_AGENT_OUTPUT }}
+ GH_AW_WORKFLOW_NAME: "Code Radiator"
+ GH_AW_RUN_URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
+ GH_AW_AGENT_CONCLUSION: ${{ needs.agent.result }}
+ GH_AW_WORKFLOW_ID: "code-radiator"
+ GH_AW_ACTION_FAILURE_ISSUE_EXPIRES_HOURS: "168"
+ GH_AW_ENGINE_ID: "copilot"
+ GH_AW_SECRET_VERIFICATION_RESULT: ${{ needs.activation.outputs.secret_verification_result }}
+ GH_AW_CHECKOUT_PR_SUCCESS: ${{ needs.agent.outputs.checkout_pr_success }}
+ GH_AW_INFERENCE_ACCESS_ERROR: ${{ needs.agent.outputs.inference_access_error }}
+ GH_AW_MCP_POLICY_ERROR: ${{ needs.agent.outputs.mcp_policy_error }}
+ GH_AW_AGENTIC_ENGINE_TIMEOUT: ${{ needs.agent.outputs.agentic_engine_timeout }}
+ GH_AW_MODEL_NOT_SUPPORTED_ERROR: ${{ needs.agent.outputs.model_not_supported_error }}
+ GH_AW_ENGINE_API_HOSTS: "api.enterprise.githubcopilot.com,api.githubcopilot.com,api.business.githubcopilot.com,api.individual.githubcopilot.com"
+ GH_AW_CODE_PUSH_FAILURE_ERRORS: ${{ needs.safe_outputs.outputs.code_push_failure_errors }}
+ GH_AW_CODE_PUSH_FAILURE_COUNT: ${{ needs.safe_outputs.outputs.code_push_failure_count }}
+ GH_AW_LOCKDOWN_CHECK_FAILED: ${{ needs.activation.outputs.lockdown_check_failed }}
+ GH_AW_STALE_LOCK_FILE_FAILED: ${{ needs.activation.outputs.stale_lock_file_failed }}
+ GH_AW_GROUP_REPORTS: "false"
+ GH_AW_FAILURE_REPORT_AS_ISSUE: "true"
+ GH_AW_MISSING_TOOL_REPORT_AS_FAILURE: "true"
+ GH_AW_MISSING_DATA_REPORT_AS_FAILURE: "true"
+ GH_AW_TIMEOUT_MINUTES: "20"
+ with:
+ github-token: ${{ secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/handle_agent_failure.cjs');
+ await main();
+
+ detection:
+ needs:
+ - activation
+ - agent
+ if: >
+ always() && needs.agent.result != 'skipped' && (needs.agent.outputs.output_types != '' || needs.agent.outputs.has_patch == 'true')
+ runs-on: ubuntu-latest
+ permissions:
+ contents: read
+ outputs:
+ detection_conclusion: ${{ steps.detection_conclusion.outputs.conclusion }}
+ detection_reason: ${{ steps.detection_conclusion.outputs.reason }}
+ detection_success: ${{ steps.detection_conclusion.outputs.success }}
+ steps:
+ - name: Setup Scripts
+ id: setup
+ uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+ with:
+ destination: ${{ runner.temp }}/gh-aw/actions
+ job-name: ${{ github.job }}
+ trace-id: ${{ needs.activation.outputs.setup-trace-id }}
+ env:
+ GH_AW_SETUP_WORKFLOW_NAME: "Code Radiator"
+ GH_AW_CURRENT_WORKFLOW_REF: ${{ github.repository }}/.github/workflows/code-radiator.lock.yml@${{ github.ref }}
+ GH_AW_INFO_VERSION: "1.0.40"
+ - name: Download agent output artifact
+ id: download-agent-output
+ continue-on-error: true
+ uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
+ with:
+ name: agent
+ path: /tmp/gh-aw/
+ - name: Setup agent output environment variable
+ id: setup-agent-output-env
+ if: steps.download-agent-output.outcome == 'success'
+ run: |
+ mkdir -p /tmp/gh-aw/
+ find "/tmp/gh-aw/" -type f -print
+ echo "GH_AW_AGENT_OUTPUT=/tmp/gh-aw/agent_output.json" >> "$GITHUB_OUTPUT"
+ - name: Checkout repository for patch context
+ if: needs.agent.outputs.has_patch == 'true'
+ uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
+ with:
+ persist-credentials: false
+ # --- Threat Detection ---
+ - name: Clean stale firewall files from agent artifact
+ run: |
+ rm -rf /tmp/gh-aw/sandbox/firewall/logs
+ rm -rf /tmp/gh-aw/sandbox/firewall/audit
+ - name: Download container images
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/download_docker_images.sh" ghcr.io/github/gh-aw-firewall/agent:0.25.40@sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504 ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40@sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280 ghcr.io/github/gh-aw-firewall/squid:0.25.40@sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51
+ - name: Check if detection needed
+ id: detection_guard
+ if: always()
+ env:
+ OUTPUT_TYPES: ${{ needs.agent.outputs.output_types }}
+ HAS_PATCH: ${{ needs.agent.outputs.has_patch }}
+ run: |
+ if [[ -n "$OUTPUT_TYPES" || "$HAS_PATCH" == "true" ]]; then
+ echo "run_detection=true" >> "$GITHUB_OUTPUT"
+ echo "Detection will run: output_types=$OUTPUT_TYPES, has_patch=$HAS_PATCH"
+ else
+ echo "run_detection=false" >> "$GITHUB_OUTPUT"
+ echo "Detection skipped: no agent outputs or patches to analyze"
+ fi
+ - name: Clear MCP Config for detection
+ if: always() && steps.detection_guard.outputs.run_detection == 'true'
+ run: |
+ rm -f "${RUNNER_TEMP}/gh-aw/mcp-config/mcp-servers.json"
+ rm -f /home/runner/.copilot/mcp-config.json
+ rm -f "$GITHUB_WORKSPACE/.gemini/settings.json"
+ - name: Prepare threat detection files
+ if: always() && steps.detection_guard.outputs.run_detection == 'true'
+ run: |
+ mkdir -p /tmp/gh-aw/threat-detection/aw-prompts
+ cp /tmp/gh-aw/aw-prompts/prompt.txt /tmp/gh-aw/threat-detection/aw-prompts/prompt.txt 2>/dev/null || true
+ cp /tmp/gh-aw/agent_output.json /tmp/gh-aw/threat-detection/agent_output.json 2>/dev/null || true
+ for f in /tmp/gh-aw/aw-*.patch; do
+ [ -f "$f" ] && cp "$f" /tmp/gh-aw/threat-detection/ 2>/dev/null || true
+ done
+ for f in /tmp/gh-aw/aw-*.bundle; do
+ [ -f "$f" ] && cp "$f" /tmp/gh-aw/threat-detection/ 2>/dev/null || true
+ done
+ echo "Prepared threat detection files:"
+ ls -la /tmp/gh-aw/threat-detection/ 2>/dev/null || true
+ - name: Setup threat detection
+ if: always() && steps.detection_guard.outputs.run_detection == 'true'
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ env:
+ WORKFLOW_NAME: "Code Radiator"
+ WORKFLOW_DESCRIPTION: "No description provided"
+ HAS_PATCH: ${{ needs.agent.outputs.has_patch }}
+ with:
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/setup_threat_detection.cjs');
+ await main();
+ - name: Ensure threat-detection directory and log
+ if: always() && steps.detection_guard.outputs.run_detection == 'true'
+ run: |
+ mkdir -p /tmp/gh-aw/threat-detection
+ touch /tmp/gh-aw/threat-detection/detection.log
+ - name: Setup Node.js
+ uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
+ with:
+ node-version: '24'
+ package-manager-cache: false
+ - name: Install GitHub Copilot CLI
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/install_copilot_cli.sh" 1.0.40
+ env:
+ GH_HOST: github.com
+ - name: Install AWF binary
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/install_awf_binary.sh" v0.25.40
+ - name: Execute GitHub Copilot CLI
+ if: always() && steps.detection_guard.outputs.run_detection == 'true'
+ continue-on-error: true
+ id: detection_agentic_execution
+ # Copilot CLI tool arguments (sorted):
+ timeout-minutes: 20
+ run: |
+ set -o pipefail
+ touch /tmp/gh-aw/agent-step-summary.md
+ GH_AW_NODE_BIN=$(command -v node 2>/dev/null || true)
+ export GH_AW_NODE_BIN
+ (umask 177 && touch /tmp/gh-aw/threat-detection/detection.log)
+ printf '%s\n' '{"$schema":"https://github.com/github/gh-aw-firewall/releases/download/v0.25.40/awf-config.schema.json","network":{"allowDomains":["api.business.githubcopilot.com","api.enterprise.githubcopilot.com","api.github.com","api.githubcopilot.com","api.individual.githubcopilot.com","github.com","host.docker.internal","telemetry.enterprise.githubcopilot.com"]},"apiProxy":{"enabled":true},"container":{"imageTag":"0.25.40,squid=sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51,agent=sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504,api-proxy=sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280,cli-proxy=sha256:3e7152911d4b4b7b97beef9d3d7d924ff7902227e86001ef3838fb728d5d514c"}}' > "${RUNNER_TEMP}/gh-aw/awf-config.json" && cp "${RUNNER_TEMP}/gh-aw/awf-config.json" /tmp/gh-aw/awf-config.json
+ # shellcheck disable=SC1003
+ sudo -E awf --config "${RUNNER_TEMP}/gh-aw/awf-config.json" --container-workdir "${GITHUB_WORKSPACE}" --mount "${RUNNER_TEMP}/gh-aw:${RUNNER_TEMP}/gh-aw:ro" --mount "${RUNNER_TEMP}/gh-aw:/host${RUNNER_TEMP}/gh-aw:ro" --env-all --exclude-env COPILOT_GITHUB_TOKEN --log-level info --proxy-logs-dir /tmp/gh-aw/sandbox/firewall/logs --audit-dir /tmp/gh-aw/sandbox/firewall/audit --enable-host-access --allow-host-ports 80,443,8080 --skip-pull \
+ -- /bin/bash -c 'export PATH="$(find /opt/hostedtoolcache /home/runner/work/_tool -maxdepth 4 -type d -name bin 2>/dev/null | tr '\''\n'\'' '\'':'\'')$PATH"; [ -n "$GOROOT" ] && export PATH="$GOROOT/bin:$PATH" || true && GH_AW_NODE_EXEC="${GH_AW_NODE_BIN:-}"; if [ -z "$GH_AW_NODE_EXEC" ] || [ ! -x "$GH_AW_NODE_EXEC" ]; then GH_AW_NODE_EXEC="$(command -v node 2>/dev/null || echo node)"; fi; "$GH_AW_NODE_EXEC" ${RUNNER_TEMP}/gh-aw/actions/copilot_harness.cjs /usr/local/bin/copilot --add-dir /tmp/gh-aw/ --log-level all --log-dir /tmp/gh-aw/sandbox/agent/logs/ --disable-builtin-mcps --no-ask-user --allow-all-tools --add-dir "${GITHUB_WORKSPACE}" --prompt-file /tmp/gh-aw/aw-prompts/prompt.txt' 2>&1 | tee -a /tmp/gh-aw/threat-detection/detection.log
+ env:
+ COPILOT_AGENT_RUNNER_TYPE: STANDALONE
+ COPILOT_API_KEY: dummy-byok-key-for-offline-mode
+ COPILOT_GITHUB_TOKEN: ${{ secrets.COPILOT_GITHUB_TOKEN }}
+ COPILOT_MODEL: claude-sonnet-4.5
+ GH_AW_PHASE: detection
+ GH_AW_PROMPT: /tmp/gh-aw/aw-prompts/prompt.txt
+ GH_AW_VERSION: v0.71.5
+ GITHUB_API_URL: ${{ github.api_url }}
+ GITHUB_AW: true
+ GITHUB_COPILOT_INTEGRATION_ID: agentic-workflows
+ GITHUB_HEAD_REF: ${{ github.head_ref }}
+ GITHUB_REF_NAME: ${{ github.ref_name }}
+ GITHUB_SERVER_URL: ${{ github.server_url }}
+ GITHUB_STEP_SUMMARY: /tmp/gh-aw/agent-step-summary.md
+ GITHUB_WORKSPACE: ${{ github.workspace }}
+ GIT_AUTHOR_EMAIL: github-actions[bot]@users.noreply.github.com
+ GIT_AUTHOR_NAME: github-actions[bot]
+ GIT_COMMITTER_EMAIL: github-actions[bot]@users.noreply.github.com
+ GIT_COMMITTER_NAME: github-actions[bot]
+ XDG_CONFIG_HOME: /home/runner
+ - name: Upload threat detection log
+ if: always() && steps.detection_guard.outputs.run_detection == 'true'
+ uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
+ with:
+ name: detection
+ path: /tmp/gh-aw/threat-detection/detection.log
+ if-no-files-found: ignore
+ - name: Parse and conclude threat detection
+ id: detection_conclusion
+ if: always()
+ continue-on-error: true
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ env:
+ RUN_DETECTION: ${{ steps.detection_guard.outputs.run_detection }}
+ GH_AW_DETECTION_CONTINUE_ON_ERROR: "true"
+ with:
+ script: |
+ try {
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/parse_threat_detection_results.cjs');
+ await main();
+ } catch (loadErr) {
+ const continueOnError = process.env.GH_AW_DETECTION_CONTINUE_ON_ERROR !== 'false';
+ const msg = 'ERR_SYSTEM: \u274C Unexpected error loading threat detection module: ' + (loadErr && loadErr.message ? loadErr.message : String(loadErr));
+ core.error(msg);
+ core.setOutput('reason', 'parse_error');
+ if (continueOnError) {
+ core.warning('\u26A0\uFE0F ' + msg);
+ core.setOutput('conclusion', 'warning');
+ core.setOutput('success', 'false');
+ } else {
+ core.setOutput('conclusion', 'failure');
+ core.setOutput('success', 'false');
+ core.setFailed(msg);
+ }
+ }
+
+ safe_outputs:
+ needs:
+ - activation
+ - agent
+ - detection
+ if: (!cancelled()) && needs.agent.result != 'skipped' && needs.detection.result == 'success'
+ runs-on: ubuntu-slim
+ permissions:
+ contents: write
+ discussions: write
+ issues: write
+ pull-requests: write
+ timeout-minutes: 15
+ env:
+ GH_AW_CALLER_WORKFLOW_ID: "${{ github.repository }}/code-radiator"
+ GH_AW_DETECTION_CONCLUSION: ${{ needs.detection.outputs.detection_conclusion }}
+ GH_AW_DETECTION_REASON: ${{ needs.detection.outputs.detection_reason }}
+ GH_AW_EFFECTIVE_TOKENS: ${{ needs.agent.outputs.effective_tokens }}
+ GH_AW_ENGINE_ID: "copilot"
+ GH_AW_ENGINE_MODEL: "claude-sonnet-4.5"
+ GH_AW_ENGINE_VERSION: "1.0.40"
+ GH_AW_WORKFLOW_ID: "code-radiator"
+ GH_AW_WORKFLOW_NAME: "Code Radiator"
+ outputs:
+ code_push_failure_count: ${{ steps.process_safe_outputs.outputs.code_push_failure_count }}
+ code_push_failure_errors: ${{ steps.process_safe_outputs.outputs.code_push_failure_errors }}
+ comment_id: ${{ steps.process_safe_outputs.outputs.comment_id }}
+ comment_url: ${{ steps.process_safe_outputs.outputs.comment_url }}
+ create_discussion_error_count: ${{ steps.process_safe_outputs.outputs.create_discussion_error_count }}
+ create_discussion_errors: ${{ steps.process_safe_outputs.outputs.create_discussion_errors }}
+ created_pr_number: ${{ steps.process_safe_outputs.outputs.created_pr_number }}
+ created_pr_url: ${{ steps.process_safe_outputs.outputs.created_pr_url }}
+ process_safe_outputs_processed_count: ${{ steps.process_safe_outputs.outputs.processed_count }}
+ process_safe_outputs_temporary_id_map: ${{ steps.process_safe_outputs.outputs.temporary_id_map }}
+ push_commit_sha: ${{ steps.process_safe_outputs.outputs.push_commit_sha }}
+ push_commit_url: ${{ steps.process_safe_outputs.outputs.push_commit_url }}
+ steps:
+ - name: Setup Scripts
+ id: setup
+ uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+ with:
+ destination: ${{ runner.temp }}/gh-aw/actions
+ job-name: ${{ github.job }}
+ trace-id: ${{ needs.activation.outputs.setup-trace-id }}
+ env:
+ GH_AW_SETUP_WORKFLOW_NAME: "Code Radiator"
+ GH_AW_CURRENT_WORKFLOW_REF: ${{ github.repository }}/.github/workflows/code-radiator.lock.yml@${{ github.ref }}
+ GH_AW_INFO_VERSION: "1.0.40"
+ - name: Download agent output artifact
+ id: download-agent-output
+ continue-on-error: true
+ uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
+ with:
+ name: agent
+ path: /tmp/gh-aw/
+ - name: Setup agent output environment variable
+ id: setup-agent-output-env
+ if: steps.download-agent-output.outcome == 'success'
+ run: |
+ mkdir -p /tmp/gh-aw/
+ find "/tmp/gh-aw/" -type f -print
+ echo "GH_AW_AGENT_OUTPUT=/tmp/gh-aw/agent_output.json" >> "$GITHUB_OUTPUT"
+ - name: Download patch artifact
+ continue-on-error: true
+ uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
+ with:
+ name: agent
+ path: /tmp/gh-aw/
+ - name: Checkout repository
+ if: (!cancelled()) && needs.agent.result != 'skipped' && contains(needs.agent.outputs.output_types, 'create_pull_request') || (!cancelled()) && needs.agent.result != 'skipped' && contains(needs.agent.outputs.output_types, 'push_to_pull_request_branch')
+ uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
+ with:
+ ref: ${{ github.base_ref || github.event.pull_request.base.ref || github.ref_name || github.event.repository.default_branch }}
+ token: ${{ secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
+ persist-credentials: false
+ fetch-depth: 1
+ - name: Configure Git credentials
+ if: (!cancelled()) && needs.agent.result != 'skipped' && contains(needs.agent.outputs.output_types, 'create_pull_request') || (!cancelled()) && needs.agent.result != 'skipped' && contains(needs.agent.outputs.output_types, 'push_to_pull_request_branch')
+ env:
+ REPO_NAME: ${{ github.repository }}
+ SERVER_URL: ${{ github.server_url }}
+ GIT_TOKEN: ${{ secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
+ run: |
+ git config --global user.email "github-actions[bot]@users.noreply.github.com"
+ git config --global user.name "github-actions[bot]"
+ git config --global am.keepcr true
+ # Re-authenticate git with GitHub token
+ SERVER_URL_STRIPPED="${SERVER_URL#https://}"
+ git remote set-url origin "https://x-access-token:${GIT_TOKEN}@${SERVER_URL_STRIPPED}/${REPO_NAME}.git"
+ echo "Git configured with standard GitHub Actions identity"
+ - name: Configure GH_HOST for enterprise compatibility
+ id: ghes-host-config
+ shell: bash
+ run: |
+ # Derive GH_HOST from GITHUB_SERVER_URL so the gh CLI targets the correct
+ # GitHub instance (GHES/GHEC). On github.com this is a harmless no-op.
+ GH_HOST="${GITHUB_SERVER_URL#https://}"
+ GH_HOST="${GH_HOST#http://}"
+ echo "GH_HOST=${GH_HOST}" >> "$GITHUB_ENV"
+ - name: Process Safe Outputs
+ id: process_safe_outputs
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
+ env:
+ GH_AW_AGENT_OUTPUT: ${{ steps.setup-agent-output-env.outputs.GH_AW_AGENT_OUTPUT }}
+ GH_AW_ALLOWED_DOMAINS: "*.githubusercontent.com,api.business.githubcopilot.com,api.enterprise.githubcopilot.com,api.github.com,api.githubcopilot.com,api.individual.githubcopilot.com,api.snapcraft.io,archive.ubuntu.com,azure.archive.ubuntu.com,codeload.github.com,crl.geotrust.com,crl.globalsign.com,crl.identrust.com,crl.sectigo.com,crl.thawte.com,crl.usertrust.com,crl.verisign.com,crl3.digicert.com,crl4.digicert.com,crls.ssl.com,docs.github.com,github-cloud.githubusercontent.com,github-cloud.s3.amazonaws.com,github.blog,github.com,github.githubassets.com,host.docker.internal,json-schema.org,json.schemastore.org,keyserver.ubuntu.com,lfs.github.com,objects.githubusercontent.com,ocsp.digicert.com,ocsp.geotrust.com,ocsp.globalsign.com,ocsp.identrust.com,ocsp.sectigo.com,ocsp.ssl.com,ocsp.thawte.com,ocsp.usertrust.com,ocsp.verisign.com,packagecloud.io,packages.cloud.google.com,packages.microsoft.com,ppa.launchpad.net,raw.githubusercontent.com,registry.npmjs.org,s.symcb.com,s.symcd.com,security.ubuntu.com,telemetry.enterprise.githubcopilot.com,ts-crl.ws.symantec.com,ts-ocsp.ws.symantec.com,www.googleapis.com"
+ GITHUB_SERVER_URL: ${{ github.server_url }}
+ GITHUB_API_URL: ${{ github.api_url }}
+ GH_AW_SAFE_OUTPUTS_HANDLER_CONFIG: "{\"add_comment\":{\"max\":10},\"add_labels\":{\"max\":10},\"create_pull_request\":{\"max\":10,\"max_patch_files\":100,\"max_patch_size\":1024,\"protect_top_level_dot_folders\":true,\"protected_files\":[\"package.json\",\"bun.lockb\",\"bunfig.toml\",\"deno.json\",\"deno.jsonc\",\"deno.lock\",\"global.json\",\"NuGet.Config\",\"Directory.Packages.props\",\"mix.exs\",\"mix.lock\",\"go.mod\",\"go.sum\",\"stack.yaml\",\"stack.yaml.lock\",\"pom.xml\",\"build.gradle\",\"build.gradle.kts\",\"settings.gradle\",\"settings.gradle.kts\",\"gradle.properties\",\"package-lock.json\",\"yarn.lock\",\"pnpm-lock.yaml\",\"npm-shrinkwrap.json\",\"requirements.txt\",\"Pipfile\",\"Pipfile.lock\",\"pyproject.toml\",\"setup.py\",\"setup.cfg\",\"Gemfile\",\"Gemfile.lock\",\"uv.lock\",\"CODEOWNERS\",\"DESIGN.md\",\"README.md\",\"CONTRIBUTING.md\",\"CHANGELOG.md\",\"SECURITY.md\",\"CODE_OF_CONDUCT.md\",\"AGENTS.md\",\"CLAUDE.md\",\"GEMINI.md\"]},\"create_report_incomplete_issue\":{},\"merge_pull_request\":{\"max\":10},\"missing_data\":{},\"missing_tool\":{},\"noop\":{\"max\":1,\"report-as-issue\":\"true\"},\"push_to_pull_request_branch\":{\"if_no_changes\":\"warn\",\"max\":10,\"max_patch_size\":1024,\"protect_top_level_dot_folders\":true,\"protected_files\":[\"package.json\",\"bun.lockb\",\"bunfig.toml\",\"deno.json\",\"deno.jsonc\",\"deno.lock\",\"global.json\",\"NuGet.Config\",\"Directory.Packages.props\",\"mix.exs\",\"mix.lock\",\"go.mod\",\"go.sum\",\"stack.yaml\",\"stack.yaml.lock\",\"pom.xml\",\"build.gradle\",\"build.gradle.kts\",\"settings.gradle\",\"settings.gradle.kts\",\"gradle.properties\",\"package-lock.json\",\"yarn.lock\",\"pnpm-lock.yaml\",\"npm-shrinkwrap.json\",\"requirements.txt\",\"Pipfile\",\"Pipfile.lock\",\"pyproject.toml\",\"setup.py\",\"setup.cfg\",\"Gemfile\",\"Gemfile.lock\",\"uv.lock\",\"CODEOWNERS\",\"DESIGN.md\",\"README.md\",\"CONTRIBUTING.md\",\"CHANGELOG.md\",\"SECURITY.md\",\"CODE_OF_CONDUCT.md\",\"AGENTS.md\",\"CLAUDE.md\",\"GEMINI.md\"]},\"report_incomplete\":{},\"update_pull_request\":{\"allow_body\":true,\"allow_title\":true,\"max\":10,\"update_branch\":false}}"
+ GH_AW_CI_TRIGGER_TOKEN: ${{ secrets.GH_AW_CI_TRIGGER_TOKEN }}
+ with:
+ github-token: ${{ secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
+ script: |
+ const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
+ setupGlobals(core, github, context, exec, io, getOctokit);
+ const { main } = require('${{ runner.temp }}/gh-aw/actions/safe_output_handler_manager.cjs');
+ await main();
+ - name: Upload Safe Outputs Items
+ if: always()
+ uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
+ with:
+ name: safe-outputs-items
+ path: |
+ /tmp/gh-aw/safe-output-items.jsonl
+ /tmp/gh-aw/temporary-id-map.json
+ if-no-files-found: ignore
+
diff --git a/.github/workflows/code-radiator.md b/.github/workflows/code-radiator.md
new file mode 100644
index 000000000000..88ef05a185d5
--- /dev/null
+++ b/.github/workflows/code-radiator.md
@@ -0,0 +1,170 @@
+---
+on:
+ schedule: "0 0 * * *"
+ workflow_dispatch:
+ roles: [admin, maintainer, write]
+permissions:
+ contents: read
+ pull-requests: read
+engine:
+ id: copilot
+ model: claude-sonnet-4.5
+network:
+ allowed:
+ - defaults
+ - github
+tools:
+ github:
+ toolsets: [pull_requests, repos]
+ min-integrity: none
+ bash: true
+safe-outputs:
+ create-pull-request:
+ max: 10
+ add-comment:
+ max: 10
+ add-labels:
+ max: 10
+ merge-pull-request:
+ max: 10
+ push-to-pull-request-branch:
+ max: 10
+ update-pull-request:
+ max: 10
+---
+
+# Code Radiator
+
+Merge code from `main` into active target branches, creating pull requests for each.
+
+## Target Branch Patterns
+
+Only consider remote branches matching these patterns:
+- `net[0-9]*.0` (e.g., `net11.0`, `net10.0`)
+- `xcode[0-9]*` (e.g., `xcode26`)
+- `xcode[0-9]*.[0-9]*` (e.g., `xcode26.4`)
+
+Only process branches that have had commits in the last 30 days.
+
+## Workflow
+
+### 1. Identify Target Branches
+
+```bash
+# List remote branches matching target patterns with recent activity
+git fetch origin
+git for-each-ref --sort=-committerdate --format='%(refname:short) %(committerdate:iso8601)' refs/remotes/origin/
+```
+
+Filter to branches matching the patterns above AND having a commit within the last month.
+
+### 2. For Each Target Branch
+
+#### a. Determine the local branch name
+
+The local branch name is: `merge/main-to--` (e.g., `merge/main-to-net11.0-20260506`).
+
+#### b. Check for existing pull requests
+
+Search for an open PR with:
+- Base: the target branch
+- Title matching: `🤖 Merge 'main' => ''`
+
+If a matching PR exists:
+- If it is a **draft**: add a comment saying "⏭️ Skipping merge update: this PR is a draft. Convert to ready when you want automated updates to resume." and **skip** this target.
+- If it is **not a draft**: use its head branch name as the local branch name (to update the existing PR).
+
+#### c. Update from target branch
+
+If updating an existing PR, first merge the target branch into the PR branch to incorporate any new commits from the target:
+
+```bash
+git checkout -B "" "origin/"
+git merge "origin/" --no-edit -m "Merge branch '' into ''"
+```
+
+If creating a new branch, start from the target:
+
+```bash
+git checkout -B "" "origin/"
+```
+
+#### d. Merge main
+
+```bash
+git merge origin/main --no-edit -m "Merge branch 'main' into ''"
+```
+
+#### e. Resolve merge conflicts
+
+If there are merge conflicts:
+
+**For files under `tests/dotnet/UnitTests/expected/`:**
+- Do not include these files in the merge commit at all. Remove them from the index:
+ ```bash
+ git rm --cached
+ ```
+
+**For `eng/Version.Details.props` or `eng/Version.Details.xml`:**
+- Parse both the `origin/main` and `origin/` versions of the file as XML.
+- For each `` element present in both files, keep the one with the **higher** `` value.
+- Use semantic version comparison (split on `.`, `-`, `+` and compare numerically).
+- Write the merged result and `git add` the file.
+
+**For `NuGet.config`:**
+- Include all package source feeds from both the source (main) and target branches.
+- If a feed exists in both with the same key but different URL, keep both (rename the key from main to avoid collision).
+- Write the merged result and `git add` the file.
+
+**For any other conflicting files:**
+- Do your best to resolve them using context and judgment.
+- If you resolved any "other" conflicts (not covered by the rules above), mark the PR for human review:
+ - Do **not** enable automerge (and disable it if already enabled).
+ - Add the `do-not-merge` label.
+ - Add a comment requesting human review of the conflict resolution, listing which files were manually resolved.
+
+#### e. Push and create/update the PR
+
+```bash
+git push origin ""
+```
+
+- If updating an existing PR: the push is sufficient (the PR updates automatically).
+- If creating a new PR:
+ - Title: `🤖 Merge 'main' => ''`
+ - Body: `Automated merge of \`main\` into \`\`.\n\nCreated by the code-radiator workflow.`
+ - Base: the target branch
+ - Head: the local branch
+ - Enable automerge (merge strategy) on the new PR.
+
+### 3. Summary
+
+After processing all branches, report:
+- Which PRs were created (with links)
+- Which PRs were updated
+- Which branches were skipped (draft PRs, no conflicts resolution possible)
+- Which branches had no diff (main already merged)
+
+## Conflict Resolution Details
+
+### Version file merge algorithm
+
+For `eng/Version.Details.props` and `eng/Version.Details.xml`:
+
+1. Parse both XML files.
+2. Build a map of `Dependency[@Name]` → `Version` text from each file.
+3. For each dependency present in either file, select the higher version.
+4. Use the target branch's file as the base structure, updating versions where main has higher values.
+5. Dependencies that exist only in main should be added to the result.
+
+### Version comparison
+
+Split version strings on `.`, `-`, and `+`. Compare each segment numerically. Example:
+- `9.0.0-preview.1.24080.9` vs `9.0.0-preview.2.24101.3` → second is higher.
+
+## Important Notes
+
+- Never force push. Always use regular `git push`.
+- The workflow operates on the current repository checkout.
+- Run `git fetch origin` before starting to ensure up-to-date remote refs.
+- Use `gh` CLI for PR operations (create, comment, list, merge --auto).
diff --git a/.github/workflows/copilot-setup-steps.yml b/.github/workflows/copilot-setup-steps.yml
new file mode 100644
index 000000000000..f5f09b80ef69
--- /dev/null
+++ b/.github/workflows/copilot-setup-steps.yml
@@ -0,0 +1,26 @@
+name: "Copilot Setup Steps"
+
+# This workflow configures the environment for GitHub Copilot Agent with gh-aw MCP server
+on:
+ workflow_dispatch:
+ push:
+ paths:
+ - .github/workflows/copilot-setup-steps.yml
+
+jobs:
+ # The job MUST be called 'copilot-setup-steps' to be recognized by GitHub Copilot Agent
+ copilot-setup-steps:
+ runs-on: ubuntu-latest
+
+ # Set minimal permissions for setup steps
+ # Copilot Agent receives its own token with appropriate permissions
+ permissions:
+ contents: read
+
+ steps:
+ - name: Checkout repository
+ uses: actions/checkout@v6
+ - name: Install gh-aw extension
+ uses: github/gh-aw-actions/setup-cli@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+ with:
+ version: v0.71.5
diff --git a/.github/workflows/inter-branch-merge-flow.yml b/.github/workflows/inter-branch-merge-flow.yml
index 9300b4de0fa0..b6b979ddad46 100644
--- a/.github/workflows/inter-branch-merge-flow.yml
+++ b/.github/workflows/inter-branch-merge-flow.yml
@@ -19,9 +19,10 @@ on:
# allow triggering this action manually
workflow_dispatch:
- # Run every day at 3:00 AM UTC
- schedule:
- - cron: '0 3 * * *'
+# Disable for now, trying out an agentic workflow
+# # Run every day at 3:00 AM UTC
+# schedule:
+# - cron: '0 3 * * *'
permissions:
contents: write
From c4445b1c2aac75ce6146b1fa10af7b13c8d73ddb Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Thu, 7 May 2026 09:08:02 +0200
Subject: [PATCH 026/156] [tests] Fix underlying type for BrowserEngineKit
enums. (#25348)
Also these enums are only available for arm64.
---
tests/monotouch-test/ObjCRuntime/StrongEnumTests.cs | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/tests/monotouch-test/ObjCRuntime/StrongEnumTests.cs b/tests/monotouch-test/ObjCRuntime/StrongEnumTests.cs
index c5b7aefee9df..65e26a101dbd 100644
--- a/tests/monotouch-test/ObjCRuntime/StrongEnumTests.cs
+++ b/tests/monotouch-test/ObjCRuntime/StrongEnumTests.cs
@@ -79,9 +79,9 @@ public void GetConstant ()
};
#if __TVOS__ && !XAMCORE_5_0
- if (Runtime.Arch == Arch.SIMULATOR) {
- rv.AddRange (Enum.GetValues ().Select (v => (typeof (global::BrowserEngineKit.BEAccessibilityTrait), (object) (int) v))); // BrowserEngineKit isn't available in the simulator
- rv.AddRange (Enum.GetValues ().Select (v => (typeof (global::BrowserEngineKit.BEAccessibilityNotification), (object) (int) v))); // BrowserEngineKit isn't available in the simulator
+ if (Runtime.Arch == Arch.SIMULATOR && Runtime.IsARM64CallingConvention) {
+ rv.AddRange (Enum.GetValues ().Select (v => (typeof (global::BrowserEngineKit.BEAccessibilityTrait), (object) (long) v))); // BrowserEngineKit isn't available in the simulator
+ rv.AddRange (Enum.GetValues ().Select (v => (typeof (global::BrowserEngineKit.BEAccessibilityNotification), (object) (long) v))); // BrowserEngineKit isn't available in the simulator
}
#endif // __TVOS__ && !XAMCORE_5_0
From d9c700ce45c09befd392e89f518638835f9e8110 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Thu, 7 May 2026 14:08:14 +0200
Subject: [PATCH 027/156] [tests] Using the strict dlfcn mode only works if
monotouch-test is trimmed. (#25354)
This is not the default in .NET 11 (it is in .NET 10), so make it explicit.
---
tests/xharness/Jenkins/TestVariationsFactory.cs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tests/xharness/Jenkins/TestVariationsFactory.cs b/tests/xharness/Jenkins/TestVariationsFactory.cs
index a095b00616b4..72984f51eeb9 100644
--- a/tests/xharness/Jenkins/TestVariationsFactory.cs
+++ b/tests/xharness/Jenkins/TestVariationsFactory.cs
@@ -114,7 +114,7 @@ IEnumerable GetTestData (RunTestTask test)
yield return new TestData { Variation = "Release (interpreter)", TestVariation = "release|interpreter", Ignored = ignore };
}
yield return new TestData { Variation = $"Release (compat inline dlfcn)", TestVariation = "inline-dlfcn-methods-compat|release", Ignored = ignore };
- yield return new TestData { Variation = $"Release (strict inline dlfcn)", TestVariation = "inline-dlfcn-methods-strict|release", Ignored = ignore };
+ yield return new TestData { Variation = $"Release (strict inline dlfcn, link sdk)", TestVariation = "inline-dlfcn-methods-strict|linksdk|release", Ignored = ignore };
if (mac_supports_arm64)
yield return new TestData { Variation = $"Release (NativeAOT, .NET 11 defaults)", TestVariation = "inline-dlfcn-methods-strict|nativeaot|release", Ignored = ignore, RuntimeIdentifier = arm64_sim_runtime_identifier }; // it's necessary to specify RID, because NativeAOT defaults to building for device
break;
From 6f1dde2b28cf61a61b0238a7c88643fce8a075c4 Mon Sep 17 00:00:00 2001
From: VS MobileTools Engineering Service 2
Date: Thu, 7 May 2026 06:07:14 -0700
Subject: [PATCH 028/156] Localized file check-in by OneLocBuild Task: Build
definition ID 14411: Build ID 14036358 (#25356)
This is the pull request automatically created by the OneLocBuild task in the build process to check-in localized files generated based upon translation source files (.lcl files) handed-back from the downstream localization pipeline. If there are issues in translations, visit https://aka.ms/icxLocBug and log bugs for fixes. The OneLocBuild wiki is https://aka.ms/onelocbuild and the localization process in general is documented at https://aka.ms/AllAboutLoc.
---
.../mtouch/TranslatedAssemblies/Errors.cs.resx | 13 +++++++++++++
.../mtouch/TranslatedAssemblies/Errors.de.resx | 13 +++++++++++++
.../mtouch/TranslatedAssemblies/Errors.es.resx | 13 +++++++++++++
.../mtouch/TranslatedAssemblies/Errors.fr.resx | 13 +++++++++++++
.../mtouch/TranslatedAssemblies/Errors.it.resx | 13 +++++++++++++
.../mtouch/TranslatedAssemblies/Errors.ja.resx | 13 +++++++++++++
.../mtouch/TranslatedAssemblies/Errors.ko.resx | 13 +++++++++++++
.../mtouch/TranslatedAssemblies/Errors.pl.resx | 13 +++++++++++++
.../mtouch/TranslatedAssemblies/Errors.pt-BR.resx | 13 +++++++++++++
.../mtouch/TranslatedAssemblies/Errors.ru.resx | 13 +++++++++++++
.../mtouch/TranslatedAssemblies/Errors.tr.resx | 13 +++++++++++++
.../mtouch/TranslatedAssemblies/Errors.zh-Hans.resx | 13 +++++++++++++
.../mtouch/TranslatedAssemblies/Errors.zh-Hant.resx | 13 +++++++++++++
13 files changed, 169 insertions(+)
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.cs.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.cs.resx
index acaf24817a6d..373de125892d 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.cs.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.cs.resx
@@ -832,6 +832,19 @@
+
+
+ Unsupported primitive field type '{0}' for symbol '{1}' in method '{2}'. Sub-optimal but functional code will be generated. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ The field type '{0}' for symbol '{1}' in method '{2}' is not an NSObject subclass. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.de.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.de.resx
index acaf24817a6d..373de125892d 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.de.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.de.resx
@@ -832,6 +832,19 @@
+
+
+ Unsupported primitive field type '{0}' for symbol '{1}' in method '{2}'. Sub-optimal but functional code will be generated. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ The field type '{0}' for symbol '{1}' in method '{2}' is not an NSObject subclass. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.es.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.es.resx
index acaf24817a6d..373de125892d 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.es.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.es.resx
@@ -832,6 +832,19 @@
+
+
+ Unsupported primitive field type '{0}' for symbol '{1}' in method '{2}'. Sub-optimal but functional code will be generated. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ The field type '{0}' for symbol '{1}' in method '{2}' is not an NSObject subclass. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.fr.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.fr.resx
index acaf24817a6d..373de125892d 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.fr.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.fr.resx
@@ -832,6 +832,19 @@
+
+
+ Unsupported primitive field type '{0}' for symbol '{1}' in method '{2}'. Sub-optimal but functional code will be generated. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ The field type '{0}' for symbol '{1}' in method '{2}' is not an NSObject subclass. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.it.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.it.resx
index acaf24817a6d..373de125892d 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.it.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.it.resx
@@ -832,6 +832,19 @@
+
+
+ Unsupported primitive field type '{0}' for symbol '{1}' in method '{2}'. Sub-optimal but functional code will be generated. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ The field type '{0}' for symbol '{1}' in method '{2}' is not an NSObject subclass. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.ja.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.ja.resx
index acaf24817a6d..373de125892d 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.ja.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.ja.resx
@@ -832,6 +832,19 @@
+
+
+ Unsupported primitive field type '{0}' for symbol '{1}' in method '{2}'. Sub-optimal but functional code will be generated. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ The field type '{0}' for symbol '{1}' in method '{2}' is not an NSObject subclass. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.ko.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.ko.resx
index acaf24817a6d..373de125892d 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.ko.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.ko.resx
@@ -832,6 +832,19 @@
+
+
+ Unsupported primitive field type '{0}' for symbol '{1}' in method '{2}'. Sub-optimal but functional code will be generated. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ The field type '{0}' for symbol '{1}' in method '{2}' is not an NSObject subclass. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.pl.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.pl.resx
index acaf24817a6d..373de125892d 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.pl.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.pl.resx
@@ -832,6 +832,19 @@
+
+
+ Unsupported primitive field type '{0}' for symbol '{1}' in method '{2}'. Sub-optimal but functional code will be generated. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ The field type '{0}' for symbol '{1}' in method '{2}' is not an NSObject subclass. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.pt-BR.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.pt-BR.resx
index acaf24817a6d..373de125892d 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.pt-BR.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.pt-BR.resx
@@ -832,6 +832,19 @@
+
+
+ Unsupported primitive field type '{0}' for symbol '{1}' in method '{2}'. Sub-optimal but functional code will be generated. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ The field type '{0}' for symbol '{1}' in method '{2}' is not an NSObject subclass. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.ru.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.ru.resx
index acaf24817a6d..373de125892d 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.ru.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.ru.resx
@@ -832,6 +832,19 @@
+
+
+ Unsupported primitive field type '{0}' for symbol '{1}' in method '{2}'. Sub-optimal but functional code will be generated. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ The field type '{0}' for symbol '{1}' in method '{2}' is not an NSObject subclass. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.tr.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.tr.resx
index acaf24817a6d..373de125892d 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.tr.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.tr.resx
@@ -832,6 +832,19 @@
+
+
+ Unsupported primitive field type '{0}' for symbol '{1}' in method '{2}'. Sub-optimal but functional code will be generated. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ The field type '{0}' for symbol '{1}' in method '{2}' is not an NSObject subclass. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.zh-Hans.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.zh-Hans.resx
index acaf24817a6d..373de125892d 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.zh-Hans.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.zh-Hans.resx
@@ -832,6 +832,19 @@
+
+
+ Unsupported primitive field type '{0}' for symbol '{1}' in method '{2}'. Sub-optimal but functional code will be generated. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ The field type '{0}' for symbol '{1}' in method '{2}' is not an NSObject subclass. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.zh-Hant.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.zh-Hant.resx
index acaf24817a6d..373de125892d 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.zh-Hant.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.zh-Hant.resx
@@ -832,6 +832,19 @@
+
+
+ Unsupported primitive field type '{0}' for symbol '{1}' in method '{2}'. Sub-optimal but functional code will be generated. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown or unsupported Dlfcn pattern: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ The field type '{0}' for symbol '{1}' in method '{2}' is not an NSObject subclass. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
From 346810ab90b3edcf09dcd49d06976885a7dc3647 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Thu, 7 May 2026 16:58:06 +0200
Subject: [PATCH 029/156] Fix @(XcodeProjet) typo in
docs/native-library-interop.md
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
docs/native-library-interop.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/docs/native-library-interop.md b/docs/native-library-interop.md
index eb70f789d4fe..dec4a772645c 100644
--- a/docs/native-library-interop.md
+++ b/docs/native-library-interop.md
@@ -5,7 +5,7 @@ Native Library Interop (formerly referred to as the "Slim Binding" approach), re
pattern for accessing native SDKs in .NET for iOS, Mac Catalyst, macOS, and tvOS projects.
Starting in .NET 9, the .NET for iOS, Mac Catalyst, macOS, and tvOS SDKs support building
-Xcode framework projects by using the `@(XcodeProjet)` build action. This is declared in
+Xcode framework projects by using the `@(XcodeProject)` build action. This is declared in
an MSBuild ItemGroup in a project file:
```xml
@@ -20,7 +20,7 @@ output will be added as a `@(NativeReference)` to the .NET project so that it ca
API surfaced via an [API definition][0] file.
Please see the [build-items](build-apps/build-items.md) docs for more information about
-the `@(XcodeProjet)` build action.
+the `@(XcodeProject)` build action.
Additional documentation and references can be found below:
From 71b76a871909b221a69cc9b44c2a00e7883f44d5 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Thu, 7 May 2026 21:38:20 +0200
Subject: [PATCH 030/156] Enable nullability and warnings-as-errors globally
(#25292)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
## Summary
Enable nullable reference types, treat-warnings-as-errors, and use the latest C# language version globally across the entire repository via `Directory.Build.props`.
## Changes
### Global settings (`Directory.Build.props`)
* Set `enable` globally.
* Set `true` globally.
* Set `latest` globally (when not already set).
### Cleanup: remove per-project redundant settings
* Remove per-project `enable` from ~100+ `.csproj` files, since it's now set globally.
* Remove per-project `` and `` settings that are now redundant.
* Remove per-project `` settings that are now covered by the global default.
### Fix nullability warnings in test code
* **bindings-test**: Fix nullability issues in `ProtocolTest.cs`, `Registrar.cs`, `RuntimeTest.cs`.
* **dont-link**: Fix nullability issues across multiple test files.
* **link all**: Fix nullability issues in link-all tests.
* **link sdk**: Fix nullability issues in link-sdk tests.
* **BundledResources**: Fix nullability in `ResourcesTest.cs`.
* **F# tests**: Fix nullability issues in F# test code.
* **Other**: Minor nullability fix in `generate-frameworks-constants.cs`.
🤖 Pull request created by Copilot
With this change, nullability is fully enabled everywhere, so:
* Fixes https://github.com/dotnet/macios/issues/17285.
* Fixes https://github.com/dotnet/macios/issues/6154.
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
Directory.Build.props | 7 ++
docs/preparing-your-app-for-testflight.md | 1 -
.../ios/fsharp/SceneDelegate.fs | 38 ++++----
.../Xamarin.Messaging.Build.csproj | 3 -
.../Xamarin.Localization.MSBuild.csproj | 3 -
.../Xamarin.MacDev.Tasks.csproj | 3 -
msbuild/Xamarin.Shared/Xamarin.Shared.props | 9 --
.../Xamarin.iOS.Tasks.Windows.csproj | 3 -
runtime/bindings-generator.csproj | 2 -
scripts/Directory.Build.props | 1 -
.../create-windows-html-report.csproj | 1 -
.../generate-frameworks-constants.cs | 2 +-
src/bgen/bgen.csproj | 2 -
src/dotnet.tmpl.csproj | 1 -
.../Microsoft.Macios.Binding.Common.csproj | 1 -
...oft.Macios.Bindings.Analyzer.Sample.csproj | 2 -
.../Microsoft.Macios.Bindings.Analyzer.csproj | 3 -
...icrosoft.Macios.Bindings.CodeFixers.csproj | 2 -
.../Microsoft.Macios.Generator.Sample.csproj | 2 -
.../Microsoft.Macios.Generator.csproj | 3 -
...rosoft.Macios.Transformer.Generator.csproj | 3 -
.../Microsoft.Macios.Transformer.csproj | 2 -
tests/BundledResources/ResourcesTest.cs | 2 +-
tests/EmbeddedResources/dotnet/shared.csproj | 4 -
tests/bgen/bgen-tests.csproj | 2 -
tests/bindings-test/ProtocolTest.cs | 82 +++++++++--------
tests/bindings-test/Registrar.cs | 6 +-
tests/bindings-test/RuntimeTest.cs | 2 +-
tests/bindings-test/dotnet/shared.csproj | 4 -
tests/cecil-tests/cecil-tests.csproj | 3 -
tests/common/AppDelegate.cs | 11 +--
tests/common/Configuration.cs | 75 +++++++--------
tests/common/ConfigurationNUnit.cs | 2 +-
tests/common/ExecutionHelper.cs | 28 +++---
tests/common/GlobalUsings.cs | 1 +
tests/common/MonoTouch.Dialog/shared.csproj | 3 -
tests/common/PlatformInfo.cs | 23 +++--
.../ComplexAssembly/ComplexAssembly.csproj | 1 -
.../MyActionExtension.csproj | 1 -
.../MyActionExtension.dotnet.csproj | 1 -
.../MyDocumentPickerExtension.csproj | 1 -
.../MyDocumentPickerExtension.dotnet.csproj | 1 -
.../MyIBToolLinkTest/MyIBToolLinkTest.csproj | 1 -
.../MyIBToolLinkTest.dotnet.csproj | 1 -
.../MyKeyboardExtension.csproj | 1 -
.../MyKeyboardExtension.dotnet.csproj | 1 -
.../MyPhotoEditingExtension.csproj | 1 -
.../MyPhotoEditingExtension.dotnet.csproj | 1 -
.../MyShareExtension/MyShareExtension.csproj | 1 -
.../MyShareExtension.dotnet.csproj | 1 -
.../TestProjects/MyTVApp/MyTVApp.csproj | 1 -
.../MyTVApp/MyTVApp.dotnet.csproj | 1 -
.../MyTVServicesExtension.csproj | 1 -
.../MyTVServicesExtension.dotnet.csproj | 1 -
.../MyTodayExtension/MyTodayExtension.csproj | 1 -
.../MyTodayExtension.dotnet.csproj | 1 -
.../Touch.Client/dotnet/shared.csproj | 4 -
tests/common/mac/MacMain.fs | 7 +-
tests/common/shared-dotnet.csproj | 3 -
tests/dotnet/AppWithXCAssets/AppDelegate.cs | 4 +-
.../iOS/ShareViewController.cs | 2 +-
.../macOS/ShareViewController.cs | 6 +-
.../ExtensionProject/tvOS/ServiceProvider.cs | 2 +
.../iOS/ShareViewController.cs | 2 +-
.../macOS/ShareViewController.cs | 6 +-
.../tvOS/ServiceProvider.cs | 2 +
tests/dotnet/MyCatalystApp/AppDelegate.cs | 2 +-
tests/dotnet/MyCatalystApp/Main.cs | 2 +-
tests/dotnet/MyInterpretedApp/AppDelegate.cs | 6 +-
.../dotnet/MyMauiApp/MacCatalyst/App.xaml.cs | 5 +-
tests/dotnet/MyMauiApp/iOS/App.xaml.cs | 5 +-
tests/dotnet/MyMauiApp/shared.csproj | 1 -
.../shared.csproj | 1 +
tests/dotnet/MyRegistrarApp/AppDelegate.cs | 5 +-
tests/dotnet/MySingleView/AppDelegate.cs | 6 +-
tests/dotnet/MyTVApp/AppDelegate.cs | 2 +-
tests/dotnet/SizeTestApp/AppDelegate.cs | 6 +-
tests/dotnet/UnitTests/DotNetUnitTests.csproj | 2 -
tests/dotnet/UnitTests/ExtensionsTest.cs | 2 +-
.../oldnet/MauiForms.iOS/AppDelegate.cs | 2 +-
.../MySingleView/AppDelegate.cs | 6 +-
.../dotnet/shared.csproj | 4 -
tests/introspection/ApiBaseTest.cs | 2 +-
tests/introspection/dotnet/shared.csproj | 6 --
tests/linker/BaseOptimizeGeneratedCodeTest.cs | 16 ++--
tests/linker/CommonLinkAllTest.cs | 8 +-
tests/linker/CommonLinkAnyTest.cs | 6 +-
tests/linker/ILReader.cs | 10 +-
.../dont link/DontLinkRegressionTests.cs | 6 +-
tests/linker/dont link/TableViewSourceTest.cs | 6 +-
tests/linker/dont link/dotnet/shared.csproj | 4 -
tests/linker/link all/AttributeTest.cs | 6 +-
tests/linker/link all/DataContractTest.cs | 2 +-
tests/linker/link all/InterfacesTest.cs | 2 +-
tests/linker/link all/InternalsTest.cs | 4 +-
tests/linker/link all/LinkAllMacTest.cs | 4 +-
tests/linker/link all/LinkAllTest.cs | 42 ++++-----
tests/linker/link all/LinqExpressionTest.cs | 2 +-
tests/linker/link all/PreserveTest.cs | 30 +++---
tests/linker/link all/SealerTest.cs | 14 +--
tests/linker/link all/SerializationTest.cs | 4 +-
tests/linker/link all/XmlSerializationTest.cs | 10 +-
tests/linker/link all/dotnet/shared.csproj | 4 -
tests/linker/link sdk/AotBugs.cs | 23 +++--
tests/linker/link sdk/BitcodeTest.cs | 4 +
tests/linker/link sdk/Bug1820Test.cs | 20 ++--
tests/linker/link sdk/CryptoTest.cs | 8 +-
tests/linker/link sdk/DataContractTest.cs | 2 +-
tests/linker/link sdk/LinkExtraDefsTest.cs | 12 ++-
.../linker/link sdk/LinkSdkRegressionTest.cs | 91 ++++++++++++++-----
tests/linker/link sdk/LocaleTest.cs | 2 +-
.../link sdk/OptimizeGeneratedCodeTest.cs | 2 +-
tests/linker/link sdk/ReflectionTest.cs | 4 +-
tests/linker/link sdk/dotnet/shared.csproj | 4 -
.../linker/trimmode copy/dotnet/shared.csproj | 4 -
.../linker/trimmode link/dotnet/shared.csproj | 4 -
tests/mmptest/mmptest.csproj | 1 -
tests/monotouch-test/dotnet/shared.csproj | 4 -
.../Xamarin.MacDev.Tasks.Tests.csproj | 3 -
.../TestHelpers/TestBase.cs | 2 +-
.../Xamarin.MacDev.Tests.csproj | 3 -
tests/mtouch/mtouchtests.csproj | 1 -
tests/perftest/dotnet/perftest.csproj | 1 -
tests/perftest/legacy/perftest-legacy.csproj | 1 -
...soft.Macios.Bindings.Analyzer.Tests.csproj | 2 -
...ft.Macios.Bindings.CodeFixers.Tests.csproj | 3 -
.../Microsoft.Macios.Generator.Tests.csproj | 2 -
.../Microsoft.Macios.Transformer.Tests.csproj | 9 --
.../Sharpie.Bind.Tests.csproj | 2 -
.../custom-type-assembly.csproj | 1 -
tests/test-libraries/testgenerator.csproj | 2 -
tests/xcframework-test/dotnet/shared.csproj | 5 -
.../dotnet/tvOS/xcframework-test.csproj | 1 -
tests/xharness/xharness.csproj | 3 -
tests/xtro-sharpie/UnitTests/UnitTests.csproj | 3 -
tests/xtro-sharpie/u2ignore/u2ignore.csproj | 1 -
tests/xtro-sharpie/u2todo/u2todo.csproj | 1 -
.../xtro-report/xtro-report.csproj | 4 -
.../xtro-sanity/xtro-sanity.csproj | 4 -
.../xtro-sharpie/xtro-sharpie.csproj | 5 -
.../class-redirector-tests.csproj | 1 -
.../class-redirector/class-redirector.csproj | 1 -
.../create-dotnet-linker-launch-json.csproj | 1 -
tools/dotnet-linker/dotnet-linker.csproj | 2 -
tools/mtouch/mtouch.csproj | 3 -
.../Sharpie.Bind.Tool.csproj | 2 -
.../sharpie/Sharpie.Bind/Sharpie.Bind.csproj | 2 -
147 files changed, 404 insertions(+), 496 deletions(-)
diff --git a/Directory.Build.props b/Directory.Build.props
index 5cfb5c2768de..d4a1086d9d07 100644
--- a/Directory.Build.props
+++ b/Directory.Build.props
@@ -22,6 +22,13 @@
6.1.0
4.7.0
4.4.0
+
+
+ latest
+
+ enable
+
+ true
diff --git a/docs/preparing-your-app-for-testflight.md b/docs/preparing-your-app-for-testflight.md
index 306a2a32102e..70daa109d997 100644
--- a/docs/preparing-your-app-for-testflight.md
+++ b/docs/preparing-your-app-for-testflight.md
@@ -26,7 +26,6 @@ Here's an example within a project file that is correctly configured for publish
net7.0-maccatalyst
maccatalyst-x64;maccatalyst-arm64
Exe
- enable
true
14.2
YourAppName
diff --git a/dotnet/Templates/Microsoft.iOS.Templates/ios/fsharp/SceneDelegate.fs b/dotnet/Templates/Microsoft.iOS.Templates/ios/fsharp/SceneDelegate.fs
index 0599e6877171..2a516579203a 100644
--- a/dotnet/Templates/Microsoft.iOS.Templates/ios/fsharp/SceneDelegate.fs
+++ b/dotnet/Templates/Microsoft.iOS.Templates/ios/fsharp/SceneDelegate.fs
@@ -9,7 +9,7 @@
interface IUIWindowSceneDelegate
[]
- member val Window : UIWindow = null with get, set
+ member val Window : UIWindow | null = null with get, set
[]
member this.WillConnect(scene: UIScene, session: UISceneSession, connectionOptions: UISceneConnectionOptions) =
@@ -20,22 +20,28 @@
| :? UIWindowScene as windowScene ->
if isNull this.Window then
this.Window <- new UIWindow(windowScene)
-
- // create a UIViewController with a single UILabel
- let vc = new UIViewController()
- vc.View.AddSubview(
- new UILabel(
- this.Window.Frame,
- BackgroundColor = UIColor.SystemBackground,
- TextAlignment = UITextAlignment.Center,
- Text = "Hello, iOS!",
- AutoresizingMask = UIViewAutoresizing.All
- )
- )
- this.Window.RootViewController <- vc
- // make the window visible
- this.Window.MakeKeyAndVisible()
+ match this.Window with
+ | null -> ()
+ | window ->
+ // create a UIViewController with a single UILabel
+ let vc = new UIViewController()
+ match vc.View with
+ | null -> ()
+ | view ->
+ view.AddSubview(
+ new UILabel(
+ window.Frame,
+ BackgroundColor = UIColor.SystemBackground,
+ TextAlignment = UITextAlignment.Center,
+ Text = "Hello, iOS!",
+ AutoresizingMask = UIViewAutoresizing.All
+ )
+ )
+ window.RootViewController <- vc
+
+ // make the window visible
+ window.MakeKeyAndVisible()
| _ -> ()
diff --git a/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj b/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj
index a8473bc9047c..36e5dc8eaa00 100644
--- a/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj
+++ b/msbuild/Messaging/Xamarin.Messaging.Build/Xamarin.Messaging.Build.csproj
@@ -9,9 +9,6 @@
$(NoWarn);NU1603
$(NoWarn);MSB3277
true
- enable
- latest
- Nullable
false
LatestMajor
diff --git a/msbuild/Xamarin.Localization.MSBuild/Xamarin.Localization.MSBuild.csproj b/msbuild/Xamarin.Localization.MSBuild/Xamarin.Localization.MSBuild.csproj
index ff948e805810..519494a39001 100644
--- a/msbuild/Xamarin.Localization.MSBuild/Xamarin.Localization.MSBuild.csproj
+++ b/msbuild/Xamarin.Localization.MSBuild/Xamarin.Localization.MSBuild.csproj
@@ -4,9 +4,6 @@
netstandard2.0;net$(BundledNETCoreAppTargetFrameworkVersion)
true
../../product.snk
- enable
- latest
- Nullable
false
diff --git a/msbuild/Xamarin.MacDev.Tasks/Xamarin.MacDev.Tasks.csproj b/msbuild/Xamarin.MacDev.Tasks/Xamarin.MacDev.Tasks.csproj
index 285fb0113a10..8f4555f6dfd4 100644
--- a/msbuild/Xamarin.MacDev.Tasks/Xamarin.MacDev.Tasks.csproj
+++ b/msbuild/Xamarin.MacDev.Tasks/Xamarin.MacDev.Tasks.csproj
@@ -7,15 +7,12 @@
true
../../product.snk
true
- latest
- true
$(DefineConstants);MSBUILD_TASKS
$(NoWarn);NU1603
$(NoWarn);NU1701
$(NoWarn);MSB3277
$(NoWarn);8002
$(NoWarn);CS0618
- enable
true
diff --git a/msbuild/Xamarin.Shared/Xamarin.Shared.props b/msbuild/Xamarin.Shared/Xamarin.Shared.props
index d1cb792970f6..43b3f5fa0091 100644
--- a/msbuild/Xamarin.Shared/Xamarin.Shared.props
+++ b/msbuild/Xamarin.Shared/Xamarin.Shared.props
@@ -233,15 +233,6 @@ Copyright (C) 2020 Microsoft. All rights reserved.
true
-
- latest
-
true
diff --git a/msbuild/Xamarin.iOS.Tasks.Windows/Xamarin.iOS.Tasks.Windows.csproj b/msbuild/Xamarin.iOS.Tasks.Windows/Xamarin.iOS.Tasks.Windows.csproj
index dccb118d4a4e..7db8e29d17b0 100644
--- a/msbuild/Xamarin.iOS.Tasks.Windows/Xamarin.iOS.Tasks.Windows.csproj
+++ b/msbuild/Xamarin.iOS.Tasks.Windows/Xamarin.iOS.Tasks.Windows.csproj
@@ -9,11 +9,8 @@
../../product.snk
$(NoWarn);8002
win
- latest
- Nullable
$(NoWarn);NU1603
$(NoWarn);NU1701
- enable
diff --git a/runtime/bindings-generator.csproj b/runtime/bindings-generator.csproj
index 4348bb7b6941..d2b274015314 100644
--- a/runtime/bindings-generator.csproj
+++ b/runtime/bindings-generator.csproj
@@ -4,8 +4,6 @@
Exe
net$(BundledNETCoreAppTargetFrameworkVersion)
enable
- enable
- latest
false
false
diff --git a/scripts/Directory.Build.props b/scripts/Directory.Build.props
index a68c92a6c121..e27c492ad8e6 100644
--- a/scripts/Directory.Build.props
+++ b/scripts/Directory.Build.props
@@ -3,7 +3,6 @@
Exe
enable
- enable
false
diff --git a/scripts/create-windows-html-report/create-windows-html-report.csproj b/scripts/create-windows-html-report/create-windows-html-report.csproj
index 93254ca37ca7..efde66adac7a 100644
--- a/scripts/create-windows-html-report/create-windows-html-report.csproj
+++ b/scripts/create-windows-html-report/create-windows-html-report.csproj
@@ -3,7 +3,6 @@
Exe
net$(BundledNETCoreAppTargetFrameworkVersion)
enable
- enable
diff --git a/scripts/generate-frameworks-constants/generate-frameworks-constants.cs b/scripts/generate-frameworks-constants/generate-frameworks-constants.cs
index a6489d4b5cca..793a2d12b971 100644
--- a/scripts/generate-frameworks-constants/generate-frameworks-constants.cs
+++ b/scripts/generate-frameworks-constants/generate-frameworks-constants.cs
@@ -32,7 +32,7 @@ static ApplePlatform GetPlatform (string platform)
static int Fix (ApplePlatform platform, string output)
{
- var frameworks = Frameworks.GetFrameworks (platform, false).Values.Where (v => !v.Unavailable);
+ var frameworks = Frameworks.GetFrameworks (platform, false)!.Values.Where (v => !v.Unavailable);
var sb = new StringBuilder ();
sb.AppendLine ("namespace ObjCRuntime {");
diff --git a/src/bgen/bgen.csproj b/src/bgen/bgen.csproj
index e8b0fed1788c..c5f6588ec350 100644
--- a/src/bgen/bgen.csproj
+++ b/src/bgen/bgen.csproj
@@ -7,8 +7,6 @@
DEBUG;BGENERATOR;NET_4_0;NO_AUTHENTICODE;STATIC;NO_SYMBOL_WRITER;NET
$(DefineConstants);XAMMACIOS_DEBUGGER
- Nullable
- enable
APL0003
diff --git a/src/dotnet.tmpl.csproj b/src/dotnet.tmpl.csproj
index cb5a69556c5f..a386a3307f42 100644
--- a/src/dotnet.tmpl.csproj
+++ b/src/dotnet.tmpl.csproj
@@ -9,7 +9,6 @@
Microsoft.%PLATFORM%
true
..\..\..\..\..\product.snk
- latest
MINIMAL
true
BI1234,108,114,219,414,618,660,661,1635,3003,3014,3021,4014
diff --git a/src/rgen/Microsoft.Macios.Binding.Common/Microsoft.Macios.Binding.Common.csproj b/src/rgen/Microsoft.Macios.Binding.Common/Microsoft.Macios.Binding.Common.csproj
index 77e0b430a77a..5d75fb3af4e6 100644
--- a/src/rgen/Microsoft.Macios.Binding.Common/Microsoft.Macios.Binding.Common.csproj
+++ b/src/rgen/Microsoft.Macios.Binding.Common/Microsoft.Macios.Binding.Common.csproj
@@ -3,7 +3,6 @@
net$(BundledNETCoreAppTargetFrameworkVersion)
enable
- enable
diff --git a/src/rgen/Microsoft.Macios.Bindings.Analyzer.Sample/Microsoft.Macios.Bindings.Analyzer.Sample.csproj b/src/rgen/Microsoft.Macios.Bindings.Analyzer.Sample/Microsoft.Macios.Bindings.Analyzer.Sample.csproj
index 946859b5203c..90c90e72f8f7 100644
--- a/src/rgen/Microsoft.Macios.Bindings.Analyzer.Sample/Microsoft.Macios.Bindings.Analyzer.Sample.csproj
+++ b/src/rgen/Microsoft.Macios.Bindings.Analyzer.Sample/Microsoft.Macios.Bindings.Analyzer.Sample.csproj
@@ -2,9 +2,7 @@
net$(BundledNETCoreAppTargetFrameworkVersion)-ios
- enable
APL0003
- true
true
true
diff --git a/src/rgen/Microsoft.Macios.Bindings.Analyzer/Microsoft.Macios.Bindings.Analyzer.csproj b/src/rgen/Microsoft.Macios.Bindings.Analyzer/Microsoft.Macios.Bindings.Analyzer.csproj
index a0e04ed81851..0bc18e3aba25 100644
--- a/src/rgen/Microsoft.Macios.Bindings.Analyzer/Microsoft.Macios.Bindings.Analyzer.csproj
+++ b/src/rgen/Microsoft.Macios.Bindings.Analyzer/Microsoft.Macios.Bindings.Analyzer.csproj
@@ -3,12 +3,9 @@
net$(BundledNETCoreAppTargetFrameworkVersion)
false
- enable
- latest
true
true
- true
Microsoft.Macios.Bindings.Analyzer
Microsoft.Macios.Bindings.Analyzer
diff --git a/src/rgen/Microsoft.Macios.Bindings.CodeFixers/Microsoft.Macios.Bindings.CodeFixers.csproj b/src/rgen/Microsoft.Macios.Bindings.CodeFixers/Microsoft.Macios.Bindings.CodeFixers.csproj
index 083846f42783..67c54c682b96 100644
--- a/src/rgen/Microsoft.Macios.Bindings.CodeFixers/Microsoft.Macios.Bindings.CodeFixers.csproj
+++ b/src/rgen/Microsoft.Macios.Bindings.CodeFixers/Microsoft.Macios.Bindings.CodeFixers.csproj
@@ -3,8 +3,6 @@
net$(BundledNETCoreAppTargetFrameworkVersion)
false
- enable
- latest
true
true
diff --git a/src/rgen/Microsoft.Macios.Generator.Sample/Microsoft.Macios.Generator.Sample.csproj b/src/rgen/Microsoft.Macios.Generator.Sample/Microsoft.Macios.Generator.Sample.csproj
index 22476b3eccbc..fe06ba681d2b 100644
--- a/src/rgen/Microsoft.Macios.Generator.Sample/Microsoft.Macios.Generator.Sample.csproj
+++ b/src/rgen/Microsoft.Macios.Generator.Sample/Microsoft.Macios.Generator.Sample.csproj
@@ -2,10 +2,8 @@
net$(BundledNETCoreAppTargetFrameworkVersion)-ios
- enable
Microsoft.Macios.Generator.Sample
APL0003
- true
true
diff --git a/src/rgen/Microsoft.Macios.Generator/Microsoft.Macios.Generator.csproj b/src/rgen/Microsoft.Macios.Generator/Microsoft.Macios.Generator.csproj
index 4bd305c59e88..f73063d72ce0 100644
--- a/src/rgen/Microsoft.Macios.Generator/Microsoft.Macios.Generator.csproj
+++ b/src/rgen/Microsoft.Macios.Generator/Microsoft.Macios.Generator.csproj
@@ -3,12 +3,9 @@
net$(BundledNETCoreAppTargetFrameworkVersion)
false
- enable
- latest
true
true
- true
Microsoft.Macios.Generator
Microsoft.Macios.Generator
diff --git a/src/rgen/Microsoft.Macios.Transformer.Generator/Microsoft.Macios.Transformer.Generator/Microsoft.Macios.Transformer.Generator.csproj b/src/rgen/Microsoft.Macios.Transformer.Generator/Microsoft.Macios.Transformer.Generator/Microsoft.Macios.Transformer.Generator.csproj
index f5ded35508aa..b608bfb3094f 100644
--- a/src/rgen/Microsoft.Macios.Transformer.Generator/Microsoft.Macios.Transformer.Generator/Microsoft.Macios.Transformer.Generator.csproj
+++ b/src/rgen/Microsoft.Macios.Transformer.Generator/Microsoft.Macios.Transformer.Generator/Microsoft.Macios.Transformer.Generator.csproj
@@ -3,12 +3,9 @@
netstandard2.1
false
- enable
- latest
true
true
- true
Microsoft.Macios.Transformer.Generator
Microsoft.Macios.Transformer.Generator
diff --git a/src/rgen/Microsoft.Macios.Transformer/Microsoft.Macios.Transformer.csproj b/src/rgen/Microsoft.Macios.Transformer/Microsoft.Macios.Transformer.csproj
index d9f51c46fe8b..28395182c78c 100644
--- a/src/rgen/Microsoft.Macios.Transformer/Microsoft.Macios.Transformer.csproj
+++ b/src/rgen/Microsoft.Macios.Transformer/Microsoft.Macios.Transformer.csproj
@@ -4,8 +4,6 @@
Exe
net$(BundledNETCoreAppTargetFrameworkVersion)
enable
- enable
- true
true
diff --git a/tests/BundledResources/ResourcesTest.cs b/tests/BundledResources/ResourcesTest.cs
index 9b1917c7a726..e22cdc7ec85e 100644
--- a/tests/BundledResources/ResourcesTest.cs
+++ b/tests/BundledResources/ResourcesTest.cs
@@ -21,7 +21,7 @@ public void Bundled ()
{
// files are extracted (by MonoDevelop) so we can see them in the file system
// that's true for simulator or devices and whatever the linker settings are
- var dir = NSBundle.MainBundle.ResourcePath;
+ var dir = NSBundle.MainBundle.ResourcePath!;
Assert.True (File.Exists (Path.Combine (dir, "basn3p08.png")), "file-basn3p08.png");
Assert.True (File.Exists (Path.Combine (dir, "basn3p08_with_loc.png")), "file-basn3p08_with_loc.png");
Assert.True (File.Exists (Path.Combine (dir, "xamvideotest.mp4")), "xamvideotest.mp4");
diff --git a/tests/EmbeddedResources/dotnet/shared.csproj b/tests/EmbeddedResources/dotnet/shared.csproj
index bc88c7a465a4..5e93461f732e 100644
--- a/tests/EmbeddedResources/dotnet/shared.csproj
+++ b/tests/EmbeddedResources/dotnet/shared.csproj
@@ -11,10 +11,6 @@
$(NoWarn);CS8981
-
-
- true
- Nullable
diff --git a/tests/bgen/bgen-tests.csproj b/tests/bgen/bgen-tests.csproj
index 0a21be053805..f4f30d3edb79 100644
--- a/tests/bgen/bgen-tests.csproj
+++ b/tests/bgen/bgen-tests.csproj
@@ -5,8 +5,6 @@
bgen_tests
false
- true
- enable
$(DefaultItemExcludesInProjectFolder);tests/**
diff --git a/tests/bindings-test/ProtocolTest.cs b/tests/bindings-test/ProtocolTest.cs
index c85278667de0..5667a8d478a2 100644
--- a/tests/bindings-test/ProtocolTest.cs
+++ b/tests/bindings-test/ProtocolTest.cs
@@ -34,22 +34,22 @@ public void Constructors ()
{
using var dateNow = (NSDate) DateTime.Now;
- using (var obj = IConstructorProtocol.CreateInstance ("Hello world")) {
+ using (var obj = IConstructorProtocol.CreateInstance ("Hello world")!) {
Assert.AreEqual ("Hello world", obj.StringValue, "A StringValue");
Assert.IsNull (obj.DateValue, "A DateValue");
}
- using (var obj = IConstructorProtocol.CreateInstance (dateNow)) {
+ using (var obj = IConstructorProtocol.CreateInstance (dateNow)!) {
Assert.IsNull (obj.StringValue, "B StringValue");
Assert.AreEqual (dateNow, obj.DateValue, "B DateValue");
}
- using (var obj = IConstructorProtocol.CreateInstance ("Hello Subclassed")) {
+ using (var obj = IConstructorProtocol.CreateInstance ("Hello Subclassed")!) {
Assert.AreEqual ("Hello Subclassed", obj.StringValue, "C1 StringValue");
Assert.IsNull (obj.DateValue, "C1 DateValue");
}
- using (var obj = IConstructorProtocol.CreateInstance (dateNow)) {
+ using (var obj = IConstructorProtocol.CreateInstance (dateNow)!) {
Assert.IsNull (obj.StringValue, "C2 StringValue");
Assert.AreEqual (dateNow, obj.DateValue, "C2 DateValue");
}
@@ -59,7 +59,7 @@ public void Constructors ()
IConstructorProtocol.CreateInstance ("Hello Subclassed 2");
}, "D1 Exception");
} else {
- using (var obj = IConstructorProtocol.CreateInstance ("Hello Subclassed 2")) {
+ using (var obj = IConstructorProtocol.CreateInstance ("Hello Subclassed 2")!) {
Assert.AreEqual ("Managed interceptor! Hello Subclassed 2", obj.StringValue, "D1 StringValue");
Assert.IsNull (obj.DateValue, "D1 DateValue");
}
@@ -70,7 +70,7 @@ public void Constructors ()
IConstructorProtocol.CreateInstance (dateNow);
}, "D2 Exception");
} else {
- using (var obj = IConstructorProtocol.CreateInstance (dateNow)) {
+ using (var obj = IConstructorProtocol.CreateInstance (dateNow)!) {
Assert.IsNull (obj.StringValue, "D2 StringValue");
Assert.AreEqual (dateNow.AddSeconds (42), obj.DateValue, "D2 DateValue");
}
@@ -106,7 +106,7 @@ public void OnlyProtocol ()
var bindingAssembly = GetType ().Assembly;
// the interface must be created
- var IP1 = bindingAssembly.GetType ("Bindings.Test.Protocol.IP1");
+ var IP1 = bindingAssembly.GetType ("Bindings.Test.Protocol.IP1")!;
Assert.IsNotNull (IP1, "IP1");
// with a [Protocol] attribute
var IP1Attributes = IP1.GetCustomAttributes (typeof (ProtocolAttribute), false);
@@ -138,7 +138,7 @@ public void ProtocolWithBaseType ()
var bindingAssembly = GetType ().Assembly;
// the interface must be created
- var IP2 = bindingAssembly.GetType ("Bindings.Test.Protocol.IP2");
+ var IP2 = bindingAssembly.GetType ("Bindings.Test.Protocol.IP2")!;
Assert.IsNotNull (IP2, "IP2");
// with a [Protocol] attribute
@@ -161,7 +161,7 @@ public void ProtocolWithBaseType ()
}
// and a model-like class
- var model = bindingAssembly.GetType ("Bindings.Test.Protocol.P2");
+ var model = bindingAssembly.GetType ("Bindings.Test.Protocol.P2")!;
Assert.IsNotNull (model, "P2");
// but without the [Model] attribute
Assert.False (model.IsDefined (typeof (ModelAttribute), false), "model");
@@ -175,7 +175,7 @@ public void ProtocolWithBaseTypeAndModel ()
var bindingAssembly = GetType ().Assembly;
// the interface must be created
- var IP3 = bindingAssembly.GetType ("Bindings.Test.Protocol.IP3");
+ var IP3 = bindingAssembly.GetType ("Bindings.Test.Protocol.IP3")!;
Assert.IsNotNull (IP3, "IP3");
// with a [Protocol] attribute
@@ -198,7 +198,7 @@ public void ProtocolWithBaseTypeAndModel ()
}
// and a model class
- var model = bindingAssembly.GetType ("Bindings.Test.Protocol.P3");
+ var model = bindingAssembly.GetType ("Bindings.Test.Protocol.P3")!;
Assert.IsNotNull (model, "P3");
// with a [Model] attribute
Assert.True (model.IsDefined (typeof (ModelAttribute), false), "model");
@@ -210,12 +210,12 @@ public void RequiredInstanceMethod ()
}
public string RequiredInstanceProperty {
- get { return null; }
+ get { return null!; }
set { }
}
public NSString RequiredReadonlyProperty {
- get { return null; }
+ get { return null!; }
}
}
@@ -381,7 +381,7 @@ static objc_method_description [] protocol_copyMethodDescriptionList (IntPtr pro
var rv = new objc_method_description [count];
for (int i = 0; i < count; i++) {
var sel = new Selector (Marshal.ReadIntPtr (methods + (IntPtr.Size * 2) * i)).Name;
- var types = Marshal.PtrToStringAuto (Marshal.ReadIntPtr (methods + (IntPtr.Size * 2) * i + IntPtr.Size));
+ var types = Marshal.PtrToStringAuto (Marshal.ReadIntPtr (methods + (IntPtr.Size * 2) * i + IntPtr.Size))!;
rv [i] = new objc_method_description (sel, types);
}
return rv;
@@ -406,12 +406,13 @@ static objc_property [] protocol_copyPropertyList (IntPtr protocol)
Trace ($"Protocol {new Protocol (protocol)} has {rv} properties");
try {
for (int i = 0; i < count; i++) {
- var prop = new objc_property ();
IntPtr p = Marshal.ReadIntPtr (list, IntPtr.Size * i);
+ var prop = new objc_property (
+ property_getName (p),
+ property_getAttributes (p),
+ property_copyAttributeList (p)
+ );
rv [i] = prop;
- prop.Name = property_getName (p);
- prop.Attributes = property_getAttributes (p);
- prop.AttributeList = property_copyAttributeList (p);
Trace ($" #{i + 1}: Name={prop.Name} Attributes={prop.Attributes} AttributeList={prop.AttributeList}");
}
return rv;
@@ -429,7 +430,7 @@ static objc_property [] protocol_copyPropertyList (IntPtr protocol)
static string property_getName (IntPtr property)
{
- return Marshal.PtrToStringAuto (_property_getName (property));
+ return Marshal.PtrToStringAuto (_property_getName (property))!;
}
[DllImport ("/usr/lib/libobjc.dylib", EntryPoint = "property_getAttributes")]
@@ -437,7 +438,7 @@ static string property_getName (IntPtr property)
static string property_getAttributes (IntPtr property)
{
- var v = Marshal.PtrToStringAuto (_property_getAttributes (property));
+ var v = Marshal.PtrToStringAuto (_property_getAttributes (property))!;
// Ignore any "?" attributes, apparently it's a new property attribute in Xcode 16, but since there's no documentation about it yet, just ignore it.
var attribs = v.Split (',').Where (v => v != "?").ToArray ();
@@ -454,11 +455,12 @@ static objc_property_attribute [] property_copyAttributeList (IntPtr property)
var rv = new List (count);
try {
for (int i = 0; i < count; i++) {
- var attrib = new objc_property_attribute ();
IntPtr n = Marshal.ReadIntPtr (list, (IntPtr.Size * 2) * i);
IntPtr v = Marshal.ReadIntPtr (list, (IntPtr.Size * 2) * i + IntPtr.Size);
- attrib.Name = Marshal.PtrToStringAuto (n);
- attrib.Value = Marshal.PtrToStringAuto (v);
+ var attrib = new objc_property_attribute (
+ Marshal.PtrToStringAuto (n)!,
+ Marshal.PtrToStringAuto (v)!
+ );
// Ignore any "?" attributes, apparently it's a new property attribute in Xcode 16, but since there's no documentation about it yet, just ignore it.
if (attrib.Name == "?" && string.IsNullOrEmpty (attrib.Value))
continue;
@@ -477,25 +479,23 @@ class objc_property_attribute : IEquatable {
public string Name;
public string Value;
- public objc_property_attribute ()
- {
- }
-
public objc_property_attribute (string name, string value)
{
this.Name = name;
this.Value = value;
}
- bool IEquatable.Equals (objc_property_attribute other)
+ bool IEquatable.Equals (objc_property_attribute? other)
{
+ if (other is null)
+ return false;
+
return Name == other.Name && Value == other.Value;
}
- public override bool Equals (object obj)
+ public override bool Equals (object? obj)
{
- var other = (objc_property_attribute) obj;
- if (other is null)
+ if (obj is not objc_property_attribute other)
return false;
return Name == other.Name && Value == other.Value;
}
@@ -515,11 +515,11 @@ class objc_property : IEquatable {
public string Name;
public string Attributes;
public objc_property_attribute [] AttributeList;
-
- public objc_property ()
- {
- }
-
+ /*
+ public objc_property ()
+ {
+ }
+ */
public objc_property (string name, string attributes, objc_property_attribute [] list)
{
this.Name = name;
@@ -532,8 +532,11 @@ public override string ToString ()
return string.Format ("[{0}; {1}; {2}]", Name, Attributes, string.Join (", ", new List (AttributeList).Select ((v) => string.Format ("{0} = {1}", v.Name, v.Value))));
}
- bool IEquatable.Equals (objc_property other)
+ bool IEquatable.Equals (objc_property? other)
{
+ if (other is null)
+ return false;
+
if (other.Name != Name)
return false;
if (other.Attributes != Attributes)
@@ -562,8 +565,11 @@ public override string ToString ()
return string.Format ("[{0}; {1}]", Name, Types);
}
- bool IEquatable.Equals (objc_method_description other)
+ bool IEquatable.Equals (objc_method_description? other)
{
+ if (other is null)
+ return false;
+
return other.Name == Name && other.Types == Types;
}
}
diff --git a/tests/bindings-test/Registrar.cs b/tests/bindings-test/Registrar.cs
index e9c9a17a876c..2a24d386946f 100644
--- a/tests/bindings-test/Registrar.cs
+++ b/tests/bindings-test/Registrar.cs
@@ -48,7 +48,7 @@ public static bool IsTrimmableStaticRegistrar {
[UnconditionalSuppressMessage ("Trimming", "IL2026", Justification = "This test accesses internals, and this code seems to work fine with the trimmer enabled.")]
public static Registrars CurrentRegistrar {
get {
- var isTrimmableStaticRegistrar = (bool) typeof (Runtime).GetProperty ("IsTrimmableStaticRegistrar", BindingFlags.NonPublic | BindingFlags.Static)!.GetValue (null);
+ var isTrimmableStaticRegistrar = (bool) typeof (Runtime).GetProperty ("IsTrimmableStaticRegistrar", BindingFlags.NonPublic | BindingFlags.Static)!.GetValue (null)!;
if (isTrimmableStaticRegistrar)
return Registrars.TrimmableStatic;
@@ -56,9 +56,9 @@ public static Registrars CurrentRegistrar {
if (__registrar__ is not null)
return Registrars.ManagedStatic;
var types = new Type [] { typeof (NativeHandle), typeof (bool).MakeByRefType () };
- var find_type = typeof (Class).GetMethod ("FindType", BindingFlags.Static | BindingFlags.NonPublic, null, types, null);
+ var find_type = typeof (Class).GetMethod ("FindType", BindingFlags.Static | BindingFlags.NonPublic, null, types, null)!;
var type_to_find = typeof (RegistrationTestClass);
- var type = (Type) find_type.Invoke (null, new object [] { Class.GetHandle (type_to_find), false });
+ var type = (Type) find_type.Invoke (null!, new object? [] { Class.GetHandle (type_to_find), false })!;
var is_static = type_to_find == type;
if (is_static) {
return Registrars.Static;
diff --git a/tests/bindings-test/RuntimeTest.cs b/tests/bindings-test/RuntimeTest.cs
index 4cebd518ae96..aea647585f60 100644
--- a/tests/bindings-test/RuntimeTest.cs
+++ b/tests/bindings-test/RuntimeTest.cs
@@ -107,7 +107,7 @@ public void SwiftTypeEncodings ()
Assert.AreEqual ("42", obj.DoSomething ("42"), "DoSomething");
- string asyncResult = null;
+ string? asyncResult = null;
obj.DoSomethingAsync ("dolphins", (v) => asyncResult = v);
var done = TestRuntime.RunAsync (TimeSpan.FromSeconds (5), () => asyncResult is not null);
Assert.AreEqual ("dolphins", asyncResult, "DoSomethingAsync");
diff --git a/tests/bindings-test/dotnet/shared.csproj b/tests/bindings-test/dotnet/shared.csproj
index 710148d2d1c0..3acadaec8a62 100644
--- a/tests/bindings-test/dotnet/shared.csproj
+++ b/tests/bindings-test/dotnet/shared.csproj
@@ -16,10 +16,6 @@
$(NoWarn);CS8981
-
- true
- Nullable
-
$(DefineConstants);BINDINGS_TEST
diff --git a/tests/cecil-tests/cecil-tests.csproj b/tests/cecil-tests/cecil-tests.csproj
index 51cfe5e183e4..a9d4c1fc8192 100644
--- a/tests/cecil-tests/cecil-tests.csproj
+++ b/tests/cecil-tests/cecil-tests.csproj
@@ -4,9 +4,6 @@
net$(BundledNETCoreAppTargetFrameworkVersion)
ceciltests
cecil-tests
- latest
- enable
- Nullable
diff --git a/tests/common/AppDelegate.cs b/tests/common/AppDelegate.cs
index cb322e2e2b75..cac8bcae5512 100644
--- a/tests/common/AppDelegate.cs
+++ b/tests/common/AppDelegate.cs
@@ -7,18 +7,17 @@
using MonoTouch.NUnit.UI;
using NUnit.Framework.Internal;
-// Disable until we get around to enable + fix any issues.
-#nullable disable
+#nullable enable
[Register ("AppDelegate")]
public partial class AppDelegate : UIApplicationDelegate {
- static internal UIWindow MainWindow;
- public static TouchRunner Runner { get; set; }
+ static internal UIWindow? MainWindow;
+ public static TouchRunner? Runner { get; set; }
partial void PostFinishedLaunching ();
- public override bool FinishedLaunching (UIApplication application, NSDictionary launchOptions)
+ public override bool FinishedLaunching (UIApplication application, NSDictionary? launchOptions)
{
#if __MACCATALYST__ || __MACOS__
TestRuntime.NotifyLaunchCompleted ();
@@ -61,7 +60,7 @@ public override UISceneConfiguration GetConfiguration (UIApplication application
public partial class SceneDelegate : UIResponder, IUIWindowSceneDelegate {
[Export ("window")]
- public UIWindow Window { get; set; }
+ public UIWindow? Window { get; set; }
[Export ("scene:willConnectToSession:options:")]
public void WillConnect (UIScene scene, UISceneSession session, UISceneConnectionOptions connectionOptions)
diff --git a/tests/common/Configuration.cs b/tests/common/Configuration.cs
index e4313eb46264..3e048d52eab1 100644
--- a/tests/common/Configuration.cs
+++ b/tests/common/Configuration.cs
@@ -6,23 +6,23 @@
using System.Threading;
using Xamarin.Utils;
-#nullable disable // until we get around to fixing this file
+#nullable enable
namespace Xamarin.Tests {
static partial class Configuration {
public const string XI_ProductName = "MonoTouch";
public const string XM_ProductName = "Xamarin.Mac";
- public static string DotNetBclDir;
- public static string DotNetCscCommand;
+ public static string DotNetBclDir = "";
+ public static string DotNetCscCommand = "";
public static string DotNetExecutable;
public static string DotNetTfm;
- public static string mt_src_root;
+ public static string? mt_src_root;
public static string sdk_version;
public static string tvos_sdk_version;
public static string macos_sdk_version;
public static string xcode_root;
- public static string XcodeVersionString;
+ public static string? XcodeVersionString;
public static string xcode83_root;
public static string xcode94_root;
#if MONOMAC
@@ -37,12 +37,12 @@ static partial class Configuration {
public static bool XcodeIsStable;
public static string DOTNET_DIR;
- static Version xcode_version;
+ static Version? xcode_version;
public static Version XcodeVersion {
get {
if (xcode_version is null)
- xcode_version = Version.Parse (XcodeVersionString);
+ xcode_version = Version.Parse (XcodeVersionString!);
return xcode_version;
}
}
@@ -101,11 +101,11 @@ public static string XcodeLocation {
}
// This is the location of an Xcode which is older than the recommended one.
- public static string GetOldXcodeRoot (Version min_version = null)
+ public static string? GetOldXcodeRoot (Version? min_version = null)
{
var with_versions = new List> ();
- var max_version = Version.Parse (XcodeVersionString);
+ var max_version = Version.Parse (XcodeVersionString!);
foreach (var xcode in GetAllXcodes ()) {
var path = xcode.Path;
var version = xcode.Version;
@@ -153,8 +153,8 @@ static void ParseConfigFiles ()
if (!test_config.Any () && Environment.OSVersion.Platform != PlatformID.Win32NT) {
// Run 'make test.config' in the tests/ directory
// First find the tests/ directory
- var dir = TestAssemblyDirectory;
- string tests_dir = null;
+ var dir = TestAssemblyDirectory!;
+ string? tests_dir = null;
while (dir.Length > 1) {
var file = Path.Combine (dir, "tests");
if (Directory.Exists (file)) {
@@ -162,7 +162,7 @@ static void ParseConfigFiles ()
break;
}
- dir = Path.GetDirectoryName (dir);
+ dir = Path.GetDirectoryName (dir)!;
}
if (tests_dir is null)
@@ -202,7 +202,8 @@ static void ParseConfigFile (string file)
}
}
- internal static string GetVariable (string variable, string @default)
+ [return: NotNullIfNotNull (nameof (@default))]
+ internal static string? GetVariable (string variable, string? @default)
{
var result = Environment.GetEnvironmentVariable (variable);
if (string.IsNullOrEmpty (result))
@@ -239,7 +240,7 @@ public static string EvaluateVariable (string variable)
return result.Substring (variable.Length + 1);
}
- static string GetXcodeVersion (string xcode_path)
+ static string? GetXcodeVersion (string xcode_path)
{
var version_plist = Path.Combine (xcode_path, "..", "version.plist");
if (!File.Exists (version_plist))
@@ -248,7 +249,7 @@ static string GetXcodeVersion (string xcode_path)
return GetPListStringValue (version_plist, "CFBundleShortVersionString");
}
- public static string GetPListStringValue (string plist, string key)
+ public static string? GetPListStringValue (string plist, string key)
{
var settings = new System.Xml.XmlReaderSettings ();
settings.DtdProcessing = System.Xml.DtdProcessing.Ignore;
@@ -256,15 +257,15 @@ public static string GetPListStringValue (string plist, string key)
using (var fs = new StringReader (ReadPListAsXml (plist))) {
using (var reader = System.Xml.XmlReader.Create (fs, settings)) {
doc.Load (reader);
- return doc.DocumentElement
- .SelectSingleNode ($"//dict/key[text()='{key}']/following-sibling::string[1]/text()").Value;
+ return doc.DocumentElement!
+ .SelectSingleNode ($"//dict/key[text()='{key}']/following-sibling::string[1]/text()")!.Value;
}
}
}
public static string ReadPListAsXml (string path)
{
- string tmpfile = null;
+ string? tmpfile = null;
try {
tmpfile = Path.GetTempFileName ();
File.Copy (path, tmpfile, true);
@@ -295,10 +296,10 @@ static Configuration ()
include_mac = !string.IsNullOrEmpty (GetVariable ("INCLUDE_MAC", ""));
include_tvos = !string.IsNullOrEmpty (GetVariable ("INCLUDE_TVOS", ""));
include_maccatalyst = !string.IsNullOrEmpty (GetVariable ("INCLUDE_MACCATALYST", ""));
- DotNetBclDir = GetVariable ("DOTNET_BCL_DIR", null);
- DotNetCscCommand = GetVariable ("DOTNET_CSC_COMMAND", null)?.Trim ('\'');
- DotNetExecutable = GetVariable ("DOTNET", null);
- DotNetTfm = GetVariable ("DOTNET_TFM", null);
+ DotNetBclDir = GetVariable ("DOTNET_BCL_DIR", "");
+ DotNetCscCommand = GetVariable ("DOTNET_CSC_COMMAND", "").Trim ('\'');
+ DotNetExecutable = GetVariable ("DOTNET", "");
+ DotNetTfm = GetVariable ("DOTNET_TFM", "");
XcodeIsStable = string.Equals (GetVariable ("XCODE_IS_STABLE", ""), "true",
StringComparison.OrdinalIgnoreCase);
DOTNET_DIR = GetVariable ("DOTNET_DIR", "");
@@ -359,7 +360,7 @@ public static string RootPath {
}
}
- public static bool TryGetRootPath (out string rootPath)
+ public static bool TryGetRootPath ([NotNullWhen (true)] out string? rootPath)
{
try {
rootPath = RootPath;
@@ -643,7 +644,7 @@ public static string CloneTestDirectory (string directory)
foreach (var file in files) {
var src = Path.Combine (directory, file);
var tgt = Path.Combine (testsTemporaryDirectory, file);
- var tgtDir = Path.GetDirectoryName (tgt);
+ var tgtDir = Path.GetDirectoryName (tgt)!;
Directory.CreateDirectory (tgtDir);
File.Copy (src, tgt);
if (tgt.EndsWith (".csproj", StringComparison.OrdinalIgnoreCase)) {
@@ -681,19 +682,19 @@ public static void FixupTestFiles (string directory, string mode)
}
}
- public static Dictionary GetBuildEnvironment (ApplePlatform platform)
+ public static Dictionary GetBuildEnvironment (ApplePlatform platform)
{
- var environment = new Dictionary ();
+ var environment = new Dictionary ();
SetBuildVariables (platform, ref environment);
return environment;
}
- public static void SetBuildVariables (ApplePlatform platform, ref Dictionary environment)
+ public static void SetBuildVariables (ApplePlatform platform, [NotNullIfNotNull (nameof (environment))] ref Dictionary? environment)
{
if (environment is null)
- environment = new Dictionary ();
+ environment = new Dictionary ();
- environment ["MD_APPLE_SDK_ROOT"] = Path.GetDirectoryName (Path.GetDirectoryName (xcode_root));
+ environment ["MD_APPLE_SDK_ROOT"] = Path.GetDirectoryName (Path.GetDirectoryName (xcode_root)!)!;
// This is set by `dotnet test` and can cause building legacy projects to fail to build with:
// Microsoft.NET.Build.Extensions.ConflictResolution.targets(30,5):
@@ -713,13 +714,13 @@ public static string GetTestLibraryDirectory (ApplePlatform platform, bool? simu
switch (platform) {
case ApplePlatform.iOS:
- dir = simulator.Value ? "iphonesimulator" : "iphoneos";
+ dir = simulator == true ? "iphonesimulator" : "iphoneos";
break;
case ApplePlatform.MacOSX:
dir = "macos";
break;
case ApplePlatform.TVOS:
- dir = simulator.Value ? "tvsimulator" : "tvos";
+ dir = simulator == true ? "tvsimulator" : "tvos";
break;
case ApplePlatform.MacCatalyst:
dir = "maccatalyst";
@@ -751,7 +752,7 @@ static bool IsAPFS {
} else {
var exit_code = ExecutionHelper.Execute ("/bin/df", new string [] { "-t", "apfs", "/" },
out var output, TimeSpan.FromSeconds (10));
- is_apfs = exit_code == 0 && output.Trim ().Split ('\n').Length >= 2;
+ is_apfs = exit_code == 0 && output?.Trim ()?.Split ('\n')?.Length >= 2;
}
}
@@ -790,7 +791,7 @@ public static bool CanRunArm64 {
[DllImport ("libc")]
static extern int sysctlbyname (string name, ref int value, ref IntPtr size, IntPtr zero, IntPtr zeroAgain);
- public static IEnumerable CallNM (string file, string nmArguments, string arch = null)
+ public static IEnumerable CallNM (string file, string nmArguments, string? arch = null)
{
var arguments = new List (new [] { nmArguments, file });
if (!string.IsNullOrEmpty (arch)) {
@@ -809,12 +810,12 @@ public static IEnumerable CallNM (string file, string nmArguments, strin
});
}
- public static IEnumerable GetNativeSymbols (string file, string arch = null)
+ public static IEnumerable GetNativeSymbols (string file, string? arch = null)
{
return CallNM (file, "-gUjA", arch);
}
- public static IEnumerable GetUndefinedNativeSymbols (string file, string arch = null)
+ public static IEnumerable GetUndefinedNativeSymbols (string file, string? arch = null)
{
return CallNM (file, "-gujA", arch);
}
@@ -829,7 +830,7 @@ public static bool IsStableRelease {
}
public static bool TryGetApiDefinitionRsp (TargetFramework framework,
- [NotNullWhen (true)] out string rspPath)
+ [NotNullWhen (true)] out string? rspPath)
{
rspPath = null;
var platform = framework.Platform switch {
@@ -846,7 +847,7 @@ public static bool TryGetApiDefinitionRsp (TargetFramework framework,
}
public static bool TryGetPlatformPreprocessorSymbolsRsp (TargetFramework framework,
- [NotNullWhen (true)] out string rspPath)
+ [NotNullWhen (true)] out string? rspPath)
{
rspPath = null;
var platform = framework.Platform switch {
diff --git a/tests/common/ConfigurationNUnit.cs b/tests/common/ConfigurationNUnit.cs
index 43a82b38bb15..b351d3b6cf80 100644
--- a/tests/common/ConfigurationNUnit.cs
+++ b/tests/common/ConfigurationNUnit.cs
@@ -6,7 +6,7 @@
using Xamarin.Utils;
-#nullable disable // until we get around to fixing this file
+#nullable enable
namespace Xamarin.Tests {
static partial class Configuration {
diff --git a/tests/common/ExecutionHelper.cs b/tests/common/ExecutionHelper.cs
index 16165517404a..29b260904da7 100644
--- a/tests/common/ExecutionHelper.cs
+++ b/tests/common/ExecutionHelper.cs
@@ -2,7 +2,7 @@
using System.Text;
using Xamarin.Utils;
-#nullable disable // until we get around to fixing this file
+#nullable enable
namespace Xamarin.Tests {
class XBuild {
@@ -12,17 +12,17 @@ public static string ToolPath {
}
}
- public static string BuildXM (string project, string configuration = "Debug", string platform = "x86", string verbosity = null, TimeSpan? timeout = null, string [] arguments = null, string targets = "Clean,Build")
+ public static string BuildXM (string project, string configuration = "Debug", string platform = "x86", string? verbosity = null, TimeSpan? timeout = null, string []? arguments = null, string targets = "Clean,Build")
{
return Build (project, ApplePlatform.MacOSX, configuration, platform, verbosity, timeout, arguments, targets);
}
- public static string BuildXI (string project, string configuration = "Debug", string platform = "iPhoneSimulator", string verbosity = null, TimeSpan? timeout = null, string [] arguments = null, string targets = "Clean,Build")
+ public static string BuildXI (string project, string configuration = "Debug", string platform = "iPhoneSimulator", string? verbosity = null, TimeSpan? timeout = null, string []? arguments = null, string targets = "Clean,Build")
{
return Build (project, ApplePlatform.iOS, configuration, platform, verbosity, timeout, arguments, targets);
}
- static string Build (string project, ApplePlatform applePlatform, string configuration = "Debug", string platform = "iPhoneSimulator", string verbosity = null, TimeSpan? timeout = null, string [] arguments = null, string targets = "Clean,Build")
+ static string Build (string project, ApplePlatform applePlatform, string configuration = "Debug", string platform = "iPhoneSimulator", string? verbosity = null, TimeSpan? timeout = null, string []? arguments = null, string targets = "Clean,Build")
{
return ExecutionHelper.Execute (ToolPath,
new string [] {
@@ -50,7 +50,7 @@ public static int Execute (string fileName, IList arguments, TimeSpan? t
return Execute (fileName, arguments, null, null, null, timeout);
}
- public static int Execute (string fileName, IList arguments, string working_directory = null, Action stdout_callback = null, Action stderr_callback = null, TimeSpan? timeout = null)
+ public static int Execute (string fileName, IList arguments, string? working_directory = null, Action? stdout_callback = null, Action? stderr_callback = null, TimeSpan? timeout = null)
{
return Execute (fileName, arguments, timed_out: out var _, workingDirectory: working_directory, stdout_callback: stdout_callback, stderr_callback: stderr_callback, timeout: timeout);
}
@@ -60,19 +60,19 @@ public static int Execute (string fileName, IList arguments, out StringB
return Execute (fileName, arguments, out output, null, null);
}
- public static int Execute (string fileName, IList arguments, out StringBuilder output, string working_directory, TimeSpan? timeout = null)
+ public static int Execute (string fileName, IList arguments, out StringBuilder output, string? working_directory, TimeSpan? timeout = null)
{
output = new StringBuilder ();
return Execute (fileName, arguments, out var _, workingDirectory: working_directory, stdout: output, stderr: output, timeout: timeout);
}
- public static int Execute (string fileName, IList arguments, out StringBuilder output, string working_directory, Dictionary environment_variables, TimeSpan? timeout = null)
+ public static int Execute (string fileName, IList arguments, out StringBuilder output, string? working_directory, Dictionary? environment_variables, TimeSpan? timeout = null)
{
output = new StringBuilder ();
return Execute (fileName, arguments, out var _, workingDirectory: working_directory, stdout: output, stderr: output, timeout: timeout, environment_variables: environment_variables);
}
- public static int Execute (string fileName, IList arguments, out bool timed_out, string workingDirectory = null, Dictionary environment_variables = null, StringBuilder stdout = null, StringBuilder stderr = null, TimeSpan? timeout = null)
+ public static int Execute (string fileName, IList arguments, out bool timed_out, string? workingDirectory = null, Dictionary? environment_variables = null, StringBuilder? stdout = null, StringBuilder? stderr = null, TimeSpan? timeout = null)
{
var rv = Execution.RunAsync (fileName, arguments, workingDirectory: workingDirectory, environment: environment_variables, timeout: timeout).Result;
if (stdout is not null)
@@ -81,11 +81,11 @@ public static int Execute (string fileName, IList arguments, out bool ti
stderr.Append (rv.Output.StandardError);
timed_out = rv.TimedOut;
if (rv.TimedOut)
- Console.WriteLine ($"Command '{fileName} {StringUtils.FormatArguments (arguments)}' didn't finish in {timeout.Value.TotalMilliseconds} ms, and was killed.", timeout.Value.TotalMinutes);
+ Console.WriteLine ($"Command '{fileName} {StringUtils.FormatArguments (arguments)}' didn't finish in {timeout!.Value.TotalMilliseconds} ms, and was killed.", timeout!.Value.TotalMinutes);
return rv.ExitCode;
}
- public static int Execute (string fileName, IList arguments, out bool timed_out, string workingDirectory = null, Dictionary environment_variables = null, Action stdout_callback = null, Action stderr_callback = null, TimeSpan? timeout = null)
+ public static int Execute (string fileName, IList arguments, out bool timed_out, string? workingDirectory = null, Dictionary? environment_variables = null, Action? stdout_callback = null, Action? stderr_callback = null, TimeSpan? timeout = null)
{
if (stdout_callback is null)
stdout_callback = Console.WriteLine;
@@ -95,11 +95,11 @@ public static int Execute (string fileName, IList arguments, out bool ti
var rv = Execution.RunWithCallbacksAsync (fileName, arguments, workingDirectory: workingDirectory, environment: environment_variables, standardOutput: stdout_callback, standardError: stderr_callback, timeout: timeout).Result;
timed_out = rv.TimedOut;
if (rv.TimedOut)
- Console.WriteLine ($"Command '{fileName} {StringUtils.FormatArguments (arguments)}' didn't finish in {timeout.Value.TotalMilliseconds} ms, and was killed.", timeout.Value.TotalMinutes);
+ Console.WriteLine ($"Command '{fileName} {StringUtils.FormatArguments (arguments)}' didn't finish in {timeout!.Value.TotalMilliseconds} ms, and was killed.", timeout!.Value.TotalMinutes);
return rv.ExitCode;
}
- public static int Execute (string fileName, IList arguments, out string output, TimeSpan? timeout = null)
+ public static int Execute (string fileName, IList arguments, out string? output, TimeSpan? timeout = null)
{
var sb = new StringBuilder ();
var rv = Execute (fileName, arguments, timed_out: out var _, stdout: sb, stderr: sb, timeout: timeout);
@@ -107,12 +107,12 @@ public static int Execute (string fileName, IList arguments, out string
return rv;
}
- public static int Execute (string fileName, IList arguments, Dictionary environmentVariables, StringBuilder stdout, StringBuilder stderr, TimeSpan? timeout = null, string workingDirectory = null)
+ public static int Execute (string fileName, IList arguments, Dictionary? environmentVariables, StringBuilder? stdout, StringBuilder? stderr, TimeSpan? timeout = null, string? workingDirectory = null)
{
return Execute (fileName, arguments, timed_out: out var _, workingDirectory: workingDirectory, environment_variables: environmentVariables, stdout: stdout, stderr: stderr, timeout: timeout);
}
- public static string Execute (string fileName, IList arguments, bool throwOnError = true, Dictionary environmentVariables = null, bool hide_output = false, TimeSpan? timeout = null)
+ public static string Execute (string fileName, IList arguments, bool throwOnError = true, Dictionary? environmentVariables = null, bool hide_output = false, TimeSpan? timeout = null)
{
var rv = Execution.RunAsync (fileName, arguments, environment: environmentVariables, timeout: timeout).Result;
var output = rv.Output.MergedOutput;
diff --git a/tests/common/GlobalUsings.cs b/tests/common/GlobalUsings.cs
index 9f7637a0e6f9..bb2e71447ba4 100644
--- a/tests/common/GlobalUsings.cs
+++ b/tests/common/GlobalUsings.cs
@@ -3,6 +3,7 @@
global using System;
global using System.Collections.Generic;
+global using System.Diagnostics.CodeAnalysis;
global using System.Runtime.InteropServices;
global using CoreFoundation;
diff --git a/tests/common/MonoTouch.Dialog/shared.csproj b/tests/common/MonoTouch.Dialog/shared.csproj
index dbb2c9e2083c..e44199d2ca28 100644
--- a/tests/common/MonoTouch.Dialog/shared.csproj
+++ b/tests/common/MonoTouch.Dialog/shared.csproj
@@ -11,9 +11,6 @@
$(NoWarn);CA1422
-
- enable
- Nullable
diff --git a/tests/common/PlatformInfo.cs b/tests/common/PlatformInfo.cs
index f88e7abd8b46..11f7cacc582a 100644
--- a/tests/common/PlatformInfo.cs
+++ b/tests/common/PlatformInfo.cs
@@ -18,14 +18,13 @@
using Xamarin.Utils;
-// Disable until we get around to enable + fix any issues.
-#nullable disable
+#nullable enable
namespace Xamarin.Tests {
public sealed class PlatformInfo {
static PlatformInfo GetHostPlatformInfo ()
{
- string name;
+ string? name;
string version;
#if __MACCATALYST__
name = "MacCatalyst";
@@ -35,8 +34,8 @@ static PlatformInfo GetHostPlatformInfo ()
version = UIDevice.CurrentDevice.SystemVersion;
#elif MONOMAC || __MACOS__
using (var plist = NSDictionary.FromFile ("/System/Library/CoreServices/SystemVersion.plist")) {
- name = (NSString) plist ["ProductName"];
- version = (NSString) plist ["ProductVersion"];
+ name = (NSString) plist ["ProductName"]!;
+ version = (NSString) plist ["ProductVersion"]!;
}
#else
#error Unknown platform
@@ -58,21 +57,21 @@ static PlatformInfo GetHostPlatformInfo ()
else
throw new FormatException ($"Unknown product name: {name}");
- platformInfo.Version = Version.Parse (version);
+ platformInfo.Version = Version.Parse (version)!;
return platformInfo;
}
#if __MACCATALYST__
- static string _iOSSupportVersion;
+ static string? _iOSSupportVersion;
internal static string iOSSupportVersion {
get {
if (_iOSSupportVersion is null) {
// This is how Apple does it: https://github.com/llvm/llvm-project/blob/62ec4ac90738a5f2d209ed28c822223e58aaaeb7/lldb/source/Host/macosx/objcxx/HostInfoMacOSX.mm#L100-L105
using var dict = NSMutableDictionary.FromFile ("/System/Library/CoreServices/SystemVersion.plist");
using var str = (NSString) "iOSSupportVersion";
- using var obj = dict.ObjectForKey (str);
- _iOSSupportVersion = obj.ToString ();
+ using var obj = dict.ObjectForKey (str)!;
+ _iOSSupportVersion = obj.ToString ()!;
}
return _iOSSupportVersion;
}
@@ -82,7 +81,7 @@ internal static string iOSSupportVersion {
public static readonly PlatformInfo Host = GetHostPlatformInfo ();
public ApplePlatform Name { get; private set; }
- public Version Version { get; private set; }
+ public Version? Version { get; private set; }
public bool IsMac => Name == ApplePlatform.MacOSX;
public bool IsIos => Name == ApplePlatform.iOS;
@@ -117,7 +116,7 @@ public static bool IsAvailableOnHostPlatform (this IEnumerable ParseAttributes (IEnumerable attributes)
+ static IEnumerable<(OSPlatformAttribute Attribute, ApplePlatform Platform, Version? Version)> ParseAttributes (IEnumerable attributes)
{
foreach (var attr in attributes) {
if (!attr.TryParse (out ApplePlatform? platform, out var version))
@@ -153,7 +152,7 @@ public static bool IsAvailable (this IEnumerable attributes
}
[UnconditionalSuppressMessage ("Trimming", "IL2045", Justification = "Some of the attributes this method uses may have been linked away, so things might not work. It actually works though, so unless something changes, we're going to assume it's trimmer-compatible.")]
- public static bool? IsAvailable (IEnumerable<(OSPlatformAttribute Attribute, ApplePlatform Platform, Version Version)> attributes, PlatformInfo targetPlatform, ApplePlatform attributePlatform)
+ public static bool? IsAvailable (IEnumerable<(OSPlatformAttribute Attribute, ApplePlatform Platform, Version? Version)> attributes, PlatformInfo targetPlatform, ApplePlatform attributePlatform)
{
// First we check for any unsupported attributes, and only once we know that there aren't any unsupported
// attributes, we check for supported attributes. Otherwise we might determine that an API is available
diff --git a/tests/common/TestProjects/ComplexAssembly/ComplexAssembly.csproj b/tests/common/TestProjects/ComplexAssembly/ComplexAssembly.csproj
index 7ae6339505aa..278df341f401 100644
--- a/tests/common/TestProjects/ComplexAssembly/ComplexAssembly.csproj
+++ b/tests/common/TestProjects/ComplexAssembly/ComplexAssembly.csproj
@@ -2,7 +2,6 @@
net$(BundledNETCoreAppTargetFrameworkVersion)
- latest
Library
diff --git a/tests/common/TestProjects/MyActionExtension/MyActionExtension.csproj b/tests/common/TestProjects/MyActionExtension/MyActionExtension.csproj
index 2aa268c86be3..c83e49e39d8d 100644
--- a/tests/common/TestProjects/MyActionExtension/MyActionExtension.csproj
+++ b/tests/common/TestProjects/MyActionExtension/MyActionExtension.csproj
@@ -9,7 +9,6 @@
MyActionExtension
Resources
MyActionExtension
- latest
true
diff --git a/tests/common/TestProjects/MyActionExtension/MyActionExtension.dotnet.csproj b/tests/common/TestProjects/MyActionExtension/MyActionExtension.dotnet.csproj
index 32ff962a0897..1ac1c4b5a976 100644
--- a/tests/common/TestProjects/MyActionExtension/MyActionExtension.dotnet.csproj
+++ b/tests/common/TestProjects/MyActionExtension/MyActionExtension.dotnet.csproj
@@ -5,7 +5,6 @@
iossimulator-x64
true
$(CustomBeforeMicrosoftCommonTargets);$(MSBuildThisFileDirectory)../../SupportedOSPlatformVersions.targets
- latest
diff --git a/tests/common/TestProjects/MyDocumentPickerExtension/MyDocumentPickerExtension.csproj b/tests/common/TestProjects/MyDocumentPickerExtension/MyDocumentPickerExtension.csproj
index c7f6c7eb738e..bee7378c9d21 100644
--- a/tests/common/TestProjects/MyDocumentPickerExtension/MyDocumentPickerExtension.csproj
+++ b/tests/common/TestProjects/MyDocumentPickerExtension/MyDocumentPickerExtension.csproj
@@ -9,7 +9,6 @@
MyDocumentPickerExtension
Resources
MyDocumentPickerExtension
- latest
true
diff --git a/tests/common/TestProjects/MyDocumentPickerExtension/MyDocumentPickerExtension.dotnet.csproj b/tests/common/TestProjects/MyDocumentPickerExtension/MyDocumentPickerExtension.dotnet.csproj
index 32ff962a0897..1ac1c4b5a976 100644
--- a/tests/common/TestProjects/MyDocumentPickerExtension/MyDocumentPickerExtension.dotnet.csproj
+++ b/tests/common/TestProjects/MyDocumentPickerExtension/MyDocumentPickerExtension.dotnet.csproj
@@ -5,7 +5,6 @@
iossimulator-x64
true
$(CustomBeforeMicrosoftCommonTargets);$(MSBuildThisFileDirectory)../../SupportedOSPlatformVersions.targets
- latest
diff --git a/tests/common/TestProjects/MyIBToolLinkTest/MyIBToolLinkTest.csproj b/tests/common/TestProjects/MyIBToolLinkTest/MyIBToolLinkTest.csproj
index f89438905d31..4c615e91248c 100644
--- a/tests/common/TestProjects/MyIBToolLinkTest/MyIBToolLinkTest.csproj
+++ b/tests/common/TestProjects/MyIBToolLinkTest/MyIBToolLinkTest.csproj
@@ -9,7 +9,6 @@
MyIBToolLinkTest
MyIBToolLinkTest
Resources
- latest
true
diff --git a/tests/common/TestProjects/MyIBToolLinkTest/MyIBToolLinkTest.dotnet.csproj b/tests/common/TestProjects/MyIBToolLinkTest/MyIBToolLinkTest.dotnet.csproj
index 1c42a286d69d..3388bc17e7dc 100644
--- a/tests/common/TestProjects/MyIBToolLinkTest/MyIBToolLinkTest.dotnet.csproj
+++ b/tests/common/TestProjects/MyIBToolLinkTest/MyIBToolLinkTest.dotnet.csproj
@@ -5,7 +5,6 @@
Exe
iossimulator-x64
$(CustomBeforeMicrosoftCommonTargets);$(MSBuildThisFileDirectory)../../SupportedOSPlatformVersions.targets
- latest
diff --git a/tests/common/TestProjects/MyKeyboardExtension/MyKeyboardExtension.csproj b/tests/common/TestProjects/MyKeyboardExtension/MyKeyboardExtension.csproj
index ee8400c43c3c..5d6826b0ecaf 100644
--- a/tests/common/TestProjects/MyKeyboardExtension/MyKeyboardExtension.csproj
+++ b/tests/common/TestProjects/MyKeyboardExtension/MyKeyboardExtension.csproj
@@ -9,7 +9,6 @@
MyKeyboardExtension
Resources
MyKeyboardExtension
- latest
true
diff --git a/tests/common/TestProjects/MyKeyboardExtension/MyKeyboardExtension.dotnet.csproj b/tests/common/TestProjects/MyKeyboardExtension/MyKeyboardExtension.dotnet.csproj
index 32ff962a0897..1ac1c4b5a976 100644
--- a/tests/common/TestProjects/MyKeyboardExtension/MyKeyboardExtension.dotnet.csproj
+++ b/tests/common/TestProjects/MyKeyboardExtension/MyKeyboardExtension.dotnet.csproj
@@ -5,7 +5,6 @@
iossimulator-x64
true
$(CustomBeforeMicrosoftCommonTargets);$(MSBuildThisFileDirectory)../../SupportedOSPlatformVersions.targets
- latest
diff --git a/tests/common/TestProjects/MyPhotoEditingExtension/MyPhotoEditingExtension.csproj b/tests/common/TestProjects/MyPhotoEditingExtension/MyPhotoEditingExtension.csproj
index c99cd4a6b527..44399686f9a6 100644
--- a/tests/common/TestProjects/MyPhotoEditingExtension/MyPhotoEditingExtension.csproj
+++ b/tests/common/TestProjects/MyPhotoEditingExtension/MyPhotoEditingExtension.csproj
@@ -9,7 +9,6 @@
MyPhotoEditingExtension
Resources
MyPhotoEditingExtension
- latest
true
diff --git a/tests/common/TestProjects/MyPhotoEditingExtension/MyPhotoEditingExtension.dotnet.csproj b/tests/common/TestProjects/MyPhotoEditingExtension/MyPhotoEditingExtension.dotnet.csproj
index 32ff962a0897..1ac1c4b5a976 100644
--- a/tests/common/TestProjects/MyPhotoEditingExtension/MyPhotoEditingExtension.dotnet.csproj
+++ b/tests/common/TestProjects/MyPhotoEditingExtension/MyPhotoEditingExtension.dotnet.csproj
@@ -5,7 +5,6 @@
iossimulator-x64
true
$(CustomBeforeMicrosoftCommonTargets);$(MSBuildThisFileDirectory)../../SupportedOSPlatformVersions.targets
- latest
diff --git a/tests/common/TestProjects/MyShareExtension/MyShareExtension.csproj b/tests/common/TestProjects/MyShareExtension/MyShareExtension.csproj
index 8246218191be..e9f195e1c515 100644
--- a/tests/common/TestProjects/MyShareExtension/MyShareExtension.csproj
+++ b/tests/common/TestProjects/MyShareExtension/MyShareExtension.csproj
@@ -9,7 +9,6 @@
MyShareExtension
Resources
MyShareExtension
- latest
true
diff --git a/tests/common/TestProjects/MyShareExtension/MyShareExtension.dotnet.csproj b/tests/common/TestProjects/MyShareExtension/MyShareExtension.dotnet.csproj
index 32ff962a0897..1ac1c4b5a976 100644
--- a/tests/common/TestProjects/MyShareExtension/MyShareExtension.dotnet.csproj
+++ b/tests/common/TestProjects/MyShareExtension/MyShareExtension.dotnet.csproj
@@ -5,7 +5,6 @@
iossimulator-x64
true
$(CustomBeforeMicrosoftCommonTargets);$(MSBuildThisFileDirectory)../../SupportedOSPlatformVersions.targets
- latest
diff --git a/tests/common/TestProjects/MyTVApp/MyTVApp.csproj b/tests/common/TestProjects/MyTVApp/MyTVApp.csproj
index ffca4a0da55b..f8ff01569afb 100644
--- a/tests/common/TestProjects/MyTVApp/MyTVApp.csproj
+++ b/tests/common/TestProjects/MyTVApp/MyTVApp.csproj
@@ -11,7 +11,6 @@
MyTVApp
Resources
MyTVApp
- latest
true
diff --git a/tests/common/TestProjects/MyTVApp/MyTVApp.dotnet.csproj b/tests/common/TestProjects/MyTVApp/MyTVApp.dotnet.csproj
index 860f20cc1599..9a9145d6101b 100644
--- a/tests/common/TestProjects/MyTVApp/MyTVApp.dotnet.csproj
+++ b/tests/common/TestProjects/MyTVApp/MyTVApp.dotnet.csproj
@@ -5,7 +5,6 @@
tvossimulator-x64
Exe
$(CustomBeforeMicrosoftCommonTargets);$(MSBuildThisFileDirectory)../../SupportedOSPlatformVersions.targets
- latest
diff --git a/tests/common/TestProjects/MyTVServicesExtension/MyTVServicesExtension.csproj b/tests/common/TestProjects/MyTVServicesExtension/MyTVServicesExtension.csproj
index 3344a305abfe..452be8e6258f 100644
--- a/tests/common/TestProjects/MyTVServicesExtension/MyTVServicesExtension.csproj
+++ b/tests/common/TestProjects/MyTVServicesExtension/MyTVServicesExtension.csproj
@@ -11,7 +11,6 @@
Resources
8.0.30703
2.0
- latest
true
diff --git a/tests/common/TestProjects/MyTVServicesExtension/MyTVServicesExtension.dotnet.csproj b/tests/common/TestProjects/MyTVServicesExtension/MyTVServicesExtension.dotnet.csproj
index 4c6a3b015169..78785deda223 100644
--- a/tests/common/TestProjects/MyTVServicesExtension/MyTVServicesExtension.dotnet.csproj
+++ b/tests/common/TestProjects/MyTVServicesExtension/MyTVServicesExtension.dotnet.csproj
@@ -5,7 +5,6 @@
tvossimulator-x64
true
$(CustomBeforeMicrosoftCommonTargets);$(MSBuildThisFileDirectory)../../SupportedOSPlatformVersions.targets
- latest
diff --git a/tests/common/TestProjects/MyTodayExtension/MyTodayExtension.csproj b/tests/common/TestProjects/MyTodayExtension/MyTodayExtension.csproj
index 1e13d1b6f145..aef827c7ab64 100644
--- a/tests/common/TestProjects/MyTodayExtension/MyTodayExtension.csproj
+++ b/tests/common/TestProjects/MyTodayExtension/MyTodayExtension.csproj
@@ -9,7 +9,6 @@
MyTodayExtension
Resources
MyTodayExtension
- latest
true
diff --git a/tests/common/TestProjects/MyTodayExtension/MyTodayExtension.dotnet.csproj b/tests/common/TestProjects/MyTodayExtension/MyTodayExtension.dotnet.csproj
index 32ff962a0897..1ac1c4b5a976 100644
--- a/tests/common/TestProjects/MyTodayExtension/MyTodayExtension.dotnet.csproj
+++ b/tests/common/TestProjects/MyTodayExtension/MyTodayExtension.dotnet.csproj
@@ -5,7 +5,6 @@
iossimulator-x64
true
$(CustomBeforeMicrosoftCommonTargets);$(MSBuildThisFileDirectory)../../SupportedOSPlatformVersions.targets
- latest
diff --git a/tests/common/Touch.Unit/Touch.Client/dotnet/shared.csproj b/tests/common/Touch.Unit/Touch.Client/dotnet/shared.csproj
index d2d40080acff..ada75cd79283 100644
--- a/tests/common/Touch.Unit/Touch.Client/dotnet/shared.csproj
+++ b/tests/common/Touch.Unit/Touch.Client/dotnet/shared.csproj
@@ -1,16 +1,12 @@
NUNITLITE_NUGET
- latest
Touch.Client
$(NoWarn);CA1416
$(NoWarn);CA1422
-
- enable
- Nullable
diff --git a/tests/common/mac/MacMain.fs b/tests/common/mac/MacMain.fs
index 0c1869fb3248..20e2c057169f 100644
--- a/tests/common/mac/MacMain.fs
+++ b/tests/common/mac/MacMain.fs
@@ -11,8 +11,11 @@ module PInvokes =
extern void _exit (int exit_code)
type MainClass =
- static member ThreadMonitor(obj : System.Object) =
- let exit_code = obj :?> int
+ static member ThreadMonitor (state : obj | null) =
+ let exit_code =
+ match state with
+ | :? int as value -> value
+ | _ -> failwith "Expected an exit code."
Thread.Sleep (3000)
Console.WriteLine ($"The process didn't exit within 3s of returning from Main. Assuming something is deadlocked, and will now exit immediately and forcefully (with exit code {exit_code}).")
Console.Out.Flush ()
diff --git a/tests/common/shared-dotnet.csproj b/tests/common/shared-dotnet.csproj
index e3ea873d0c75..06243b83489f 100644
--- a/tests/common/shared-dotnet.csproj
+++ b/tests/common/shared-dotnet.csproj
@@ -54,9 +54,6 @@
true
-
- latest
-
CA1416;$(NoWarn)
diff --git a/tests/dotnet/AppWithXCAssets/AppDelegate.cs b/tests/dotnet/AppWithXCAssets/AppDelegate.cs
index a6edee7af51c..9dd9f6befa6c 100644
--- a/tests/dotnet/AppWithXCAssets/AppDelegate.cs
+++ b/tests/dotnet/AppWithXCAssets/AppDelegate.cs
@@ -19,9 +19,11 @@ public class AppDelegate : UIApplicationDelegate {
UIColor blue = UIColor.FromRGB (31, 174, 206);
UIColor green = UIColor.FromRGB (119, 187, 65);
- public override bool FinishedLaunching (UIApplication app, NSDictionary options)
+ public override bool FinishedLaunching (UIApplication app, NSDictionary? options)
{
+#pragma warning disable CA1422 // Validate platform compatibility
window = new UIWindow (UIScreen.MainScreen.Bounds);
+#pragma warning restore CA1422
var dvc = new UIViewController ();
var bounds = window.Bounds;
diff --git a/tests/dotnet/ExtensionProject/iOS/ShareViewController.cs b/tests/dotnet/ExtensionProject/iOS/ShareViewController.cs
index 08d46e5378c8..f0361286f481 100644
--- a/tests/dotnet/ExtensionProject/iOS/ShareViewController.cs
+++ b/tests/dotnet/ExtensionProject/iOS/ShareViewController.cs
@@ -22,7 +22,7 @@ public override void DidSelectPost ()
// This is called after the user selects Post. Do the upload of contentText and/or NSExtensionContext attachments.
// Inform the host that we're done, so it un-blocks its UI. Note: Alternatively you could call super's -didSelectPost, which will similarly complete the extension context.
- ExtensionContext.CompleteRequest (null, null);
+ ExtensionContext?.CompleteRequest ([], null);
}
public override SLComposeSheetConfigurationItem [] GetConfigurationItems ()
diff --git a/tests/dotnet/ExtensionProject/macOS/ShareViewController.cs b/tests/dotnet/ExtensionProject/macOS/ShareViewController.cs
index 95a23c5e0d77..3d59f883e3b4 100644
--- a/tests/dotnet/ExtensionProject/macOS/ShareViewController.cs
+++ b/tests/dotnet/ExtensionProject/macOS/ShareViewController.cs
@@ -17,7 +17,7 @@ public override void LoadView ()
{
base.LoadView ();
- NSExtensionItem item = ExtensionContext.InputItems.First ();
+ NSExtensionItem item = ExtensionContext?.InputItems.First () ?? new NSExtensionItem ();
Console.WriteLine ("Attachments {0}", item);
}
@@ -25,13 +25,13 @@ partial void Cancel (Foundation.NSObject sender)
{
NSExtensionItem outputItem = new NSExtensionItem ();
var outputItems = new [] { outputItem };
- ExtensionContext.CompleteRequest (outputItems, null);
+ ExtensionContext?.CompleteRequest (outputItems, null);
}
partial void Send (Foundation.NSObject sender)
{
NSError cancelError = NSError.FromDomain (NSError.CocoaErrorDomain, 3072, null);
- ExtensionContext.CancelRequest (cancelError);
+ ExtensionContext?.CancelRequest (cancelError);
}
}
}
diff --git a/tests/dotnet/ExtensionProject/tvOS/ServiceProvider.cs b/tests/dotnet/ExtensionProject/tvOS/ServiceProvider.cs
index c845047d0816..d2fba535f273 100644
--- a/tests/dotnet/ExtensionProject/tvOS/ServiceProvider.cs
+++ b/tests/dotnet/ExtensionProject/tvOS/ServiceProvider.cs
@@ -13,7 +13,9 @@ protected ServiceProvider (IntPtr handle) : base (handle)
public TVContentItem [] TopShelfItems {
[Export ("topShelfItems")]
get {
+#pragma warning disable CA1422
return new TVContentItem [] { new TVContentItem (new TVContentIdentifier ("identifier", null)) { Title = "title" } };
+#pragma warning restore CA1422
}
}
diff --git a/tests/dotnet/ExtensionProjectWithFrameworks/iOS/ShareViewController.cs b/tests/dotnet/ExtensionProjectWithFrameworks/iOS/ShareViewController.cs
index 08d46e5378c8..f0361286f481 100644
--- a/tests/dotnet/ExtensionProjectWithFrameworks/iOS/ShareViewController.cs
+++ b/tests/dotnet/ExtensionProjectWithFrameworks/iOS/ShareViewController.cs
@@ -22,7 +22,7 @@ public override void DidSelectPost ()
// This is called after the user selects Post. Do the upload of contentText and/or NSExtensionContext attachments.
// Inform the host that we're done, so it un-blocks its UI. Note: Alternatively you could call super's -didSelectPost, which will similarly complete the extension context.
- ExtensionContext.CompleteRequest (null, null);
+ ExtensionContext?.CompleteRequest ([], null);
}
public override SLComposeSheetConfigurationItem [] GetConfigurationItems ()
diff --git a/tests/dotnet/ExtensionProjectWithFrameworks/macOS/ShareViewController.cs b/tests/dotnet/ExtensionProjectWithFrameworks/macOS/ShareViewController.cs
index 95a23c5e0d77..3d59f883e3b4 100644
--- a/tests/dotnet/ExtensionProjectWithFrameworks/macOS/ShareViewController.cs
+++ b/tests/dotnet/ExtensionProjectWithFrameworks/macOS/ShareViewController.cs
@@ -17,7 +17,7 @@ public override void LoadView ()
{
base.LoadView ();
- NSExtensionItem item = ExtensionContext.InputItems.First ();
+ NSExtensionItem item = ExtensionContext?.InputItems.First () ?? new NSExtensionItem ();
Console.WriteLine ("Attachments {0}", item);
}
@@ -25,13 +25,13 @@ partial void Cancel (Foundation.NSObject sender)
{
NSExtensionItem outputItem = new NSExtensionItem ();
var outputItems = new [] { outputItem };
- ExtensionContext.CompleteRequest (outputItems, null);
+ ExtensionContext?.CompleteRequest (outputItems, null);
}
partial void Send (Foundation.NSObject sender)
{
NSError cancelError = NSError.FromDomain (NSError.CocoaErrorDomain, 3072, null);
- ExtensionContext.CancelRequest (cancelError);
+ ExtensionContext?.CancelRequest (cancelError);
}
}
}
diff --git a/tests/dotnet/ExtensionProjectWithFrameworks/tvOS/ServiceProvider.cs b/tests/dotnet/ExtensionProjectWithFrameworks/tvOS/ServiceProvider.cs
index c845047d0816..d2fba535f273 100644
--- a/tests/dotnet/ExtensionProjectWithFrameworks/tvOS/ServiceProvider.cs
+++ b/tests/dotnet/ExtensionProjectWithFrameworks/tvOS/ServiceProvider.cs
@@ -13,7 +13,9 @@ protected ServiceProvider (IntPtr handle) : base (handle)
public TVContentItem [] TopShelfItems {
[Export ("topShelfItems")]
get {
+#pragma warning disable CA1422
return new TVContentItem [] { new TVContentItem (new TVContentIdentifier ("identifier", null)) { Title = "title" } };
+#pragma warning restore CA1422
}
}
diff --git a/tests/dotnet/MyCatalystApp/AppDelegate.cs b/tests/dotnet/MyCatalystApp/AppDelegate.cs
index c708592b35a2..1020d28aa4f9 100644
--- a/tests/dotnet/MyCatalystApp/AppDelegate.cs
+++ b/tests/dotnet/MyCatalystApp/AppDelegate.cs
@@ -11,7 +11,7 @@ namespace MySingleView {
[Register ("AppDelegate")]
public partial class AppDelegate : UIApplicationDelegate {
// class-level declarations
- public override UIWindow Window {
+ public override UIWindow? Window {
get;
set;
}
diff --git a/tests/dotnet/MyCatalystApp/Main.cs b/tests/dotnet/MyCatalystApp/Main.cs
index c580453b1ecd..647a8a9cb566 100644
--- a/tests/dotnet/MyCatalystApp/Main.cs
+++ b/tests/dotnet/MyCatalystApp/Main.cs
@@ -11,7 +11,7 @@ static void Main (string [] args)
{
// if you want to use a different Application Delegate class from "AppDelegate"
// you can specify it here.
- UIApplication.Main (args, null, "AppDelegate");
+ UIApplication.Main (args, null, typeof (AppDelegate));
}
}
}
diff --git a/tests/dotnet/MyInterpretedApp/AppDelegate.cs b/tests/dotnet/MyInterpretedApp/AppDelegate.cs
index d650bf83ba7e..b4a9e301991f 100644
--- a/tests/dotnet/MyInterpretedApp/AppDelegate.cs
+++ b/tests/dotnet/MyInterpretedApp/AppDelegate.cs
@@ -5,11 +5,13 @@
namespace MyInterpretedApp {
public partial class AppDelegate : UIApplicationDelegate {
- UIWindow window;
+ UIWindow? window;
- public override bool FinishedLaunching (UIApplication app, NSDictionary options)
+ public override bool FinishedLaunching (UIApplication app, NSDictionary? options)
{
+#pragma warning disable CA1422
window = new UIWindow (UIScreen.MainScreen.Bounds);
+#pragma warning restore CA1422
var dvc = new UIViewController ();
var button = new UIButton (window.Bounds);
diff --git a/tests/dotnet/MyMauiApp/MacCatalyst/App.xaml.cs b/tests/dotnet/MyMauiApp/MacCatalyst/App.xaml.cs
index 525041dbe4ac..f986a7ba7f2b 100644
--- a/tests/dotnet/MyMauiApp/MacCatalyst/App.xaml.cs
+++ b/tests/dotnet/MyMauiApp/MacCatalyst/App.xaml.cs
@@ -4,7 +4,10 @@ public partial class App : Application {
public App ()
{
InitializeComponent ();
+ }
- MainPage = new AppShell ();
+ protected override Window CreateWindow (IActivationState? activationState)
+ {
+ return new Window (new AppShell ());
}
}
diff --git a/tests/dotnet/MyMauiApp/iOS/App.xaml.cs b/tests/dotnet/MyMauiApp/iOS/App.xaml.cs
index 525041dbe4ac..f986a7ba7f2b 100644
--- a/tests/dotnet/MyMauiApp/iOS/App.xaml.cs
+++ b/tests/dotnet/MyMauiApp/iOS/App.xaml.cs
@@ -4,7 +4,10 @@ public partial class App : Application {
public App ()
{
InitializeComponent ();
+ }
- MainPage = new AppShell ();
+ protected override Window CreateWindow (IActivationState? activationState)
+ {
+ return new Window (new AppShell ());
}
}
diff --git a/tests/dotnet/MyMauiApp/shared.csproj b/tests/dotnet/MyMauiApp/shared.csproj
index bcf263936efe..cb7d9a2ec94d 100644
--- a/tests/dotnet/MyMauiApp/shared.csproj
+++ b/tests/dotnet/MyMauiApp/shared.csproj
@@ -5,7 +5,6 @@
true
true
enable
- enable
MyMauiApp
diff --git a/tests/dotnet/MyNativeAotAppWithTrimAnalysisWarning/shared.csproj b/tests/dotnet/MyNativeAotAppWithTrimAnalysisWarning/shared.csproj
index 7e098b544c44..40d5c9df0443 100644
--- a/tests/dotnet/MyNativeAotAppWithTrimAnalysisWarning/shared.csproj
+++ b/tests/dotnet/MyNativeAotAppWithTrimAnalysisWarning/shared.csproj
@@ -8,6 +8,7 @@
3.14
true
+ false
diff --git a/tests/dotnet/MyRegistrarApp/AppDelegate.cs b/tests/dotnet/MyRegistrarApp/AppDelegate.cs
index a6ce71157904..d5a822b67142 100644
--- a/tests/dotnet/MyRegistrarApp/AppDelegate.cs
+++ b/tests/dotnet/MyRegistrarApp/AppDelegate.cs
@@ -26,9 +26,10 @@ static int StaticRegistrarValidationTest ()
Console.WriteLine ($"GCH: {gchandle}");
if (gchandle != IntPtr.Zero) {
var gch = GCHandle.FromIntPtr (gchandle);
- var exc = (Exception) gch.Target;
+ var exc = gch.Target as Exception;
gch.Free ();
- throw exc;
+ if (exc is not null)
+ throw exc;
}
return 1; // We're not supposed to get here
} catch (Exception e) {
diff --git a/tests/dotnet/MySingleView/AppDelegate.cs b/tests/dotnet/MySingleView/AppDelegate.cs
index 6920ca9d8a6b..f3ac5c6cbc1e 100644
--- a/tests/dotnet/MySingleView/AppDelegate.cs
+++ b/tests/dotnet/MySingleView/AppDelegate.cs
@@ -5,11 +5,13 @@
namespace MySingleView {
public partial class AppDelegate : UIApplicationDelegate {
- UIWindow window;
+ UIWindow? window;
- public override bool FinishedLaunching (UIApplication app, NSDictionary options)
+ public override bool FinishedLaunching (UIApplication app, NSDictionary? options)
{
+#pragma warning disable CA1422
window = new UIWindow (UIScreen.MainScreen.Bounds);
+#pragma warning restore CA1422
var dvc = new UIViewController ();
var button = new UIButton (window.Bounds);
diff --git a/tests/dotnet/MyTVApp/AppDelegate.cs b/tests/dotnet/MyTVApp/AppDelegate.cs
index 0b2fcc29d499..f806328b529c 100644
--- a/tests/dotnet/MyTVApp/AppDelegate.cs
+++ b/tests/dotnet/MyTVApp/AppDelegate.cs
@@ -6,7 +6,7 @@
namespace MyTVApp {
public partial class AppDelegate : UIApplicationDelegate {
- public override UIWindow Window {
+ public override UIWindow? Window {
get;
set;
}
diff --git a/tests/dotnet/SizeTestApp/AppDelegate.cs b/tests/dotnet/SizeTestApp/AppDelegate.cs
index 05e173fcd149..a7f46829c690 100644
--- a/tests/dotnet/SizeTestApp/AppDelegate.cs
+++ b/tests/dotnet/SizeTestApp/AppDelegate.cs
@@ -27,11 +27,13 @@ static int Main (string [] args)
#if HAS_UIKIT
public partial class AppDelegate : UIApplicationDelegate {
- UIWindow window;
+ UIWindow? window;
- public override bool FinishedLaunching (UIApplication app, NSDictionary options)
+ public override bool FinishedLaunching (UIApplication app, NSDictionary? options)
{
+#pragma warning disable CA1422
window = new UIWindow (UIScreen.MainScreen.Bounds);
+#pragma warning restore CA1422
var dvc = new UIViewController ();
var button = new UIButton (window.Bounds);
diff --git a/tests/dotnet/UnitTests/DotNetUnitTests.csproj b/tests/dotnet/UnitTests/DotNetUnitTests.csproj
index 82660ce36e45..cacebf7a322e 100644
--- a/tests/dotnet/UnitTests/DotNetUnitTests.csproj
+++ b/tests/dotnet/UnitTests/DotNetUnitTests.csproj
@@ -3,8 +3,6 @@
net$(BundledNETCoreAppTargetFrameworkVersion)
false
$(DefineConstants);NET;TESTS
- enable
- true
diff --git a/tests/dotnet/UnitTests/ExtensionsTest.cs b/tests/dotnet/UnitTests/ExtensionsTest.cs
index cc2e89e0328c..cf50e2098e90 100644
--- a/tests/dotnet/UnitTests/ExtensionsTest.cs
+++ b/tests/dotnet/UnitTests/ExtensionsTest.cs
@@ -27,7 +27,7 @@ public void AdditionalAppExtensionTest (ApplePlatform platform, string runtimeId
"-target", "NativeIntentsExtension",
"-project", Path.Combine (xcodeProjectFolder, "NativeContainer.xcodeproj"),
};
- var env = new Dictionary {
+ var env = new Dictionary {
{ "DEVELOPER_DIR", Configuration.XcodeLocation },
};
foreach (var action in new string [] { "clean", "build" })
diff --git a/tests/dotnet/size-comparison/MauiForms/oldnet/MauiForms.iOS/AppDelegate.cs b/tests/dotnet/size-comparison/MauiForms/oldnet/MauiForms.iOS/AppDelegate.cs
index ccb4afb87ee2..5630f317619e 100644
--- a/tests/dotnet/size-comparison/MauiForms/oldnet/MauiForms.iOS/AppDelegate.cs
+++ b/tests/dotnet/size-comparison/MauiForms/oldnet/MauiForms.iOS/AppDelegate.cs
@@ -18,7 +18,7 @@ public partial class AppDelegate : global::Xamarin.Forms.Platform.iOS.FormsAppli
//
// You have 17 seconds to return from this method, or iOS will terminate your application.
//
- public override bool FinishedLaunching (UIApplication app, NSDictionary options)
+ public override bool FinishedLaunching (UIApplication app, NSDictionary? options)
{
global::Xamarin.Forms.Forms.Init ();
LoadApplication (new App ());
diff --git a/tests/dotnet/size-comparison/MySingleView/AppDelegate.cs b/tests/dotnet/size-comparison/MySingleView/AppDelegate.cs
index 8e84ee355b6a..de6407594ee7 100644
--- a/tests/dotnet/size-comparison/MySingleView/AppDelegate.cs
+++ b/tests/dotnet/size-comparison/MySingleView/AppDelegate.cs
@@ -5,11 +5,13 @@
namespace MyComparableApp {
public partial class AppDelegate : UIApplicationDelegate {
- UIWindow window;
+ UIWindow? window;
- public override bool FinishedLaunching (UIApplication app, NSDictionary options)
+ public override bool FinishedLaunching (UIApplication app, NSDictionary? options)
{
+#pragma warning disable CA1422
window = new UIWindow (UIScreen.MainScreen.Bounds);
+#pragma warning restore CA1422
var dvc = new UIViewController ();
var button = new UIButton (window.Bounds);
diff --git a/tests/interdependent-binding-projects/dotnet/shared.csproj b/tests/interdependent-binding-projects/dotnet/shared.csproj
index 5e4008911365..3e45c81d0def 100644
--- a/tests/interdependent-binding-projects/dotnet/shared.csproj
+++ b/tests/interdependent-binding-projects/dotnet/shared.csproj
@@ -27,10 +27,6 @@
$(NoWarn);CS8002
-
-
- true
- Nullable
diff --git a/tests/introspection/ApiBaseTest.cs b/tests/introspection/ApiBaseTest.cs
index 02cd37df96cd..6e617346107e 100644
--- a/tests/introspection/ApiBaseTest.cs
+++ b/tests/introspection/ApiBaseTest.cs
@@ -101,7 +101,7 @@ protected TextWriter Writer {
#if MONOMAC
get { return Console.Out; }
#else
- get { return AppDelegate.Runner.Writer!; }
+ get { return AppDelegate.Runner!.Writer!; }
#endif
}
diff --git a/tests/introspection/dotnet/shared.csproj b/tests/introspection/dotnet/shared.csproj
index bea97d7308c1..8f70d4b1fea9 100644
--- a/tests/introspection/dotnet/shared.csproj
+++ b/tests/introspection/dotnet/shared.csproj
@@ -16,17 +16,11 @@
$(DefineConstants);DEBUG
- enable
-
$(NoWarn);IL2026;IL2057;IL2059;IL2070;IL2075;IL2096
$(NoWarn);CA1422
-
-
- true
- Nullable
diff --git a/tests/linker/BaseOptimizeGeneratedCodeTest.cs b/tests/linker/BaseOptimizeGeneratedCodeTest.cs
index f4904e104fa4..50d32b49afb0 100644
--- a/tests/linker/BaseOptimizeGeneratedCodeTest.cs
+++ b/tests/linker/BaseOptimizeGeneratedCodeTest.cs
@@ -158,7 +158,7 @@ public void SetupBlockCodeTest ()
unsafe static void BlockCallback (IntPtr block)
{
var descriptor = (BlockLiteral*) block;
- var del = (Action) (descriptor->Target);
+ var del = (Action) (descriptor->Target)!;
del ();
}
@@ -285,17 +285,17 @@ void SetupBlockOptimized_SpecificArgument (
int dummy208 = 0, int dummy218 = 0, int dummy228 = 0, int dummy238 = 0, int dummy248 = 0, int dummy258 = 0, int dummy268 = 0, int dummy278 = 0, int dummy288 = 0, int dummy298 = 0,
int dummy209 = 0, int dummy219 = 0, int dummy229 = 0, int dummy239 = 0, int dummy249 = 0, int dummy259 = 0, int dummy269 = 0, int dummy279 = 0, int dummy289 = 0, int dummy299 = 0,
- Action_IntPtr block_callback = null
+ Action_IntPtr? block_callback = null
)
{
// ldarg
BlockLiteral block = new BlockLiteral ();
- block.SetupBlock (block_callback, callback);
+ block.SetupBlock (block_callback!, callback);
Bindings.Test.CFunctions.x_call_block (ref block);
block.CleanupBlock ();
}
- Action_IntPtr block_callback_instance_field;
+ Action_IntPtr? block_callback_instance_field;
[BindingImpl (BindingImplOptions.Optimizable)]
void SetupBlockOptimized_LoadField (Action callback)
{
@@ -514,17 +514,17 @@ public void IsARM64CallingConvention ()
IEnumerable instructions;
IEnumerable call_instructions;
- method = typeof (BaseOptimizeGeneratedCodeTest).GetMethod (nameof (GetIsARM64CallingConventionOptimized), BindingFlags.NonPublic | BindingFlags.Instance | BindingFlags.Public | BindingFlags.Static);
+ method = typeof (BaseOptimizeGeneratedCodeTest).GetMethod (nameof (GetIsARM64CallingConventionOptimized), BindingFlags.NonPublic | BindingFlags.Instance | BindingFlags.Public | BindingFlags.Static)!;
instructions = new ILReader (method);
call_instructions = instructions.Where ((v) => v.OpCode.Name == "ldsfld");
Assert.AreEqual (0, call_instructions.Count (), "optimized: no ldsfld instruction");
- method = typeof (BaseOptimizeGeneratedCodeTest).GetMethod (nameof (GetIsARM64CallingConventionNotOptimized), BindingFlags.NonPublic | BindingFlags.Instance);
+ method = typeof (BaseOptimizeGeneratedCodeTest).GetMethod (nameof (GetIsARM64CallingConventionNotOptimized), BindingFlags.NonPublic | BindingFlags.Instance)!;
instructions = new ILReader (method);
call_instructions = instructions.Where ((v) => v.OpCode.Name == "ldsfld");
Assert.AreEqual (1, call_instructions.Count (), "not optimized: 1 ldsfld instruction");
-
- method = typeof (Runtime).GetMethod ("GetIsARM64CallingConvention", BindingFlags.Static | BindingFlags.NonPublic);
+
+ method = typeof (Runtime).GetMethod ("GetIsARM64CallingConvention", BindingFlags.Static | BindingFlags.NonPublic)!;
instructions = new ILReader (method);
Assert.AreEqual (2, instructions.Count (), "IL Count");
Assert.That (instructions.Skip (0).First ().OpCode, Is.EqualTo (OpCodes.Ldc_I4_0).Or.EqualTo (OpCodes.Ldc_I4_1), "IL 1");
diff --git a/tests/linker/CommonLinkAllTest.cs b/tests/linker/CommonLinkAllTest.cs
index 45b0a6f8d4ca..3a98d3d7ce96 100644
--- a/tests/linker/CommonLinkAllTest.cs
+++ b/tests/linker/CommonLinkAllTest.cs
@@ -53,7 +53,7 @@ public class CommonLinkAllTest {
public void BindingsAndBeforeInitField ()
{
ObjCRuntime.Trampolines.SDInnerBlock.Invoke (IntPtr.Zero, 0);
- var fields = Type.GetType ("ObjCRuntime.Trampolines+SDInnerBlock" + WorkAroundLinkerHeuristics).GetFields (BindingFlags.NonPublic | BindingFlags.Static);
+ var fields = Type.GetType ("ObjCRuntime.Trampolines+SDInnerBlock" + WorkAroundLinkerHeuristics)!.GetFields (BindingFlags.NonPublic | BindingFlags.Static);
Assert.That (fields.Length, Is.EqualTo (1), "one");
Assert.That (fields [0].Name, Is.EqualTo ("Handler"), "Name");
}
@@ -62,7 +62,7 @@ public void BindingsAndBeforeInitField ()
public void BindingsAndBeforeInitField_2 ()
{
ObjCRuntime.Trampolines.SDInnerBlock_Misnamed.Invoke (IntPtr.Zero, 0);
- var fields = Type.GetType ("ObjCRuntime.Trampolines+SDInnerBlock_Misnamed" + WorkAroundLinkerHeuristics).GetFields (BindingFlags.NonPublic | BindingFlags.Static);
+ var fields = Type.GetType ("ObjCRuntime.Trampolines+SDInnerBlock_Misnamed" + WorkAroundLinkerHeuristics)!.GetFields (BindingFlags.NonPublic | BindingFlags.Static);
Assert.That (fields.Length, Is.EqualTo (0), "zero");
}
@@ -71,7 +71,7 @@ public void TypeConverter_BuiltIn ()
{
Assert.NotNull (TypeDescriptor.GetConverter (new BuiltInConverter ()), "BuiltInConverter");
- string name = (typeof (BuiltInConverter).GetCustomAttributes (false) [0] as TypeConverterAttribute).ConverterTypeName;
+ string? name = (typeof (BuiltInConverter).GetCustomAttributes (false) [0] as TypeConverterAttribute)?.ConverterTypeName;
var typename = $"System.ComponentModel.BooleanConverter, System.ComponentModel.TypeConverter, Version={typeof (int).Assembly.GetName ().Version}, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a";
Assert.That (name, Is.EqualTo (typename), "ConverterTypeName");
}
@@ -81,7 +81,7 @@ public void TypeConverter_Custom ()
{
Assert.NotNull (TypeDescriptor.GetConverter (new TypeDescriptorTest ()), "TypeDescriptorTest");
- string name = (typeof (TypeDescriptorTest).GetCustomAttributes (false) [0] as TypeConverterAttribute).ConverterTypeName;
+ string? name = (typeof (TypeDescriptorTest).GetCustomAttributes (false) [0] as TypeConverterAttribute)?.ConverterTypeName;
var typename = "LinkAll.CustomConverter, link all, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null";
Assert.That (name, Is.EqualTo (typename), "ConverterTypeName");
}
diff --git a/tests/linker/CommonLinkAnyTest.cs b/tests/linker/CommonLinkAnyTest.cs
index 10f3a5ad8390..e873edbcff10 100644
--- a/tests/linker/CommonLinkAnyTest.cs
+++ b/tests/linker/CommonLinkAnyTest.cs
@@ -17,12 +17,12 @@ public class CommonLinkAnyTest {
public void Blocks ()
{
int i = 0;
- string b = null;
+ string? b = null;
NSSet s = new NSSet ("a", "b", "c");
s.Enumerate (delegate (NSObject obj, ref bool stop)
{
stop = i++ == 1;
- b = obj.ToString ();
+ b = obj.ToString ()!;
});
// test behavior (we did not break anything)
Assert.AreEqual ("b", b, "Stop");
@@ -39,7 +39,7 @@ public void CallerFilePath ()
}
// https://bugzilla.xamarin.com/show_bug.cgi?id=7114
- public static void Bug7114 ([CallerFilePath] string filePath = null)
+ public static void Bug7114 ([CallerFilePath] string? filePath = null)
{
Assert.IsNotNull (filePath, "CallerFilePath");
}
diff --git a/tests/linker/ILReader.cs b/tests/linker/ILReader.cs
index dc9913c83dae..0e03255620f9 100644
--- a/tests/linker/ILReader.cs
+++ b/tests/linker/ILReader.cs
@@ -17,9 +17,9 @@ public class ILInstruction {
public MethodBase Method;
public OpCode OpCode;
public int Offset;
- public object Operand;
+ public object? Operand;
- public ILInstruction (MethodBase method, int offset, OpCode opcode, object operand = null)
+ public ILInstruction (MethodBase method, int offset, OpCode opcode, object? operand = null)
{
this.Method = method;
this.OpCode = opcode;
@@ -31,7 +31,7 @@ public override string ToString ()
{
var methodOperand = Operand as MethodBase;
if (methodOperand is not null)
- return $"IL_{Offset:0000} {OpCode} {methodOperand.DeclaringType.FullName}.{methodOperand.Name}";
+ return $"IL_{Offset:0000} {OpCode} {methodOperand.DeclaringType?.FullName}.{methodOperand.Name}";
return $"IL_{Offset:0000} {OpCode} {(Operand is MethodBase ? ((MethodBase) Operand).Name : Operand?.ToString ())}";
}
}
@@ -44,7 +44,7 @@ public class ILReader : IEnumerable {
static ILReader ()
{
foreach (var fi in typeof (OpCodes).GetFields (BindingFlags.Public | BindingFlags.Static)) {
- var opCode = (OpCode) fi.GetValue (null);
+ var opCode = (OpCode) fi.GetValue (null)!;
var value = (ushort) opCode.Value;
if (value < 0x100)
oneByteOpcodes [value] = opCode;
@@ -77,7 +77,7 @@ List Parse (MethodBase method)
if (body is null)
return rv;
- var bytes = body.GetILAsByteArray ();
+ var bytes = body.GetILAsByteArray ()!;
while (position < bytes.Length)
rv.Add (ReadInstruction (method, bytes, ref position));
diff --git a/tests/linker/dont link/DontLinkRegressionTests.cs b/tests/linker/dont link/DontLinkRegressionTests.cs
index 304017d248cf..017cf20ce65b 100644
--- a/tests/linker/dont link/DontLinkRegressionTests.cs
+++ b/tests/linker/dont link/DontLinkRegressionTests.cs
@@ -77,7 +77,7 @@ void AssertThrowsWrappedNotSupportedException (Action action, string message)
} catch (TargetInvocationException tie) {
var nse = tie.InnerException as TargetInvocationException;
if (nse is not null)
- Assert.Fail ("An exception was thrown, but {0} instead of NotSupportedException. " + message, tie.InnerException.GetType ().FullName);
+ Assert.Fail ("An exception was thrown, but {0} instead of NotSupportedException. " + message, nse.GetType ().FullName);
}
}
[Test]
@@ -114,9 +114,9 @@ public void ProcessStart_NotSupported ()
foreach (var notsupported_property in notsupported_properties) {
foreach (var property in all_properties.Where ((v) => v.Name == notsupported_property)) {
if (property.GetGetMethod () is not null)
- AssertThrowsWrappedNotSupportedException (() => property.GetGetMethod ().Invoke (instance, new object [] {}), notsupported_property + " (getter)");
+ AssertThrowsWrappedNotSupportedException (() => property.GetGetMethod ()!.Invoke (instance, new object [] {}), notsupported_property + " (getter)");
if (property.GetSetMethod () is not null)
- AssertThrowsWrappedNotSupportedException (() => property.GetSetMethod ().Invoke (instance, new object [] { null }), notsupported_property + " (setter)");
+ AssertThrowsWrappedNotSupportedException (() => property.GetSetMethod ()!.Invoke (instance, new object? [] { null }), notsupported_property + " (setter)");
}
}
diff --git a/tests/linker/dont link/TableViewSourceTest.cs b/tests/linker/dont link/TableViewSourceTest.cs
index 727df0752a74..a99bb6e8c8da 100644
--- a/tests/linker/dont link/TableViewSourceTest.cs
+++ b/tests/linker/dont link/TableViewSourceTest.cs
@@ -32,13 +32,13 @@ public void ValidateMembers ()
var methods = new List ();
foreach (var mi in typeof (UITableViewDelegate).GetMethods (flags))
- methods.Add (mi.ToString ());
+ methods.Add (mi.ToString ()!);
foreach (var mi in typeof (UITableViewDataSource).GetMethods (flags))
- methods.Add (mi.ToString ());
+ methods.Add (mi.ToString ()!);
var tvsource = new List ();
foreach (var mi in typeof (UITableViewSource).GetMethods (flags))
- tvsource.Add (mi.ToString ());
+ tvsource.Add (mi.ToString ()!);
methods.RemoveAll (delegate (string name)
{
diff --git a/tests/linker/dont link/dotnet/shared.csproj b/tests/linker/dont link/dotnet/shared.csproj
index 3d9e367dfda9..231d01eaa432 100644
--- a/tests/linker/dont link/dotnet/shared.csproj
+++ b/tests/linker/dont link/dotnet/shared.csproj
@@ -11,10 +11,6 @@
$(NoWarn);IL2057
-
-
- true
- Nullable
diff --git a/tests/linker/link all/AttributeTest.cs b/tests/linker/link all/AttributeTest.cs
index 03581f6e7d66..99f69af92667 100644
--- a/tests/linker/link all/AttributeTest.cs
+++ b/tests/linker/link all/AttributeTest.cs
@@ -135,7 +135,7 @@ public void DebugTypeAttributes ()
[Test]
public void DebugConstructorAttributes ()
{
- var ca = typeof (FullyDecorated).GetConstructor (Type.EmptyTypes).GetCustomAttributes (false);
+ var ca = typeof (FullyDecorated).GetConstructor (Type.EmptyTypes)!.GetCustomAttributes (false);
#if DEBUG
Assert.That (ca.Length, Is.EqualTo (2), "Debug attributes in debug mode");
#else
@@ -152,7 +152,7 @@ public void DebugPropertyAttributes ()
c.Property = 1;
bool result = false;
- foreach (object ca in typeof (FullyDecorated).GetProperty ("Property").GetCustomAttributes (false)) {
+ foreach (object ca in typeof (FullyDecorated).GetProperty ("Property")!.GetCustomAttributes (false)) {
if (ca is DebuggerBrowsableAttribute)
result = true;
}
@@ -168,7 +168,7 @@ public void DebuggerTypeProxy_24203 ()
{
var d = new Dictionary () { { "key", 0 } };
Assert.NotNull (d); // just to be 100% sure it won't be linked away (with the attribute we'll be looking for)
- var proxy = Type.GetType ("System.Collections.Generic.IDictionaryDebugView`2, " + mscorlib);
+ var proxy = Type.GetType ("System.Collections.Generic.IDictionaryDebugView`2, " + mscorlib)!;
#if DEBUG
Assert.NotNull (proxy, "proxy");
// having the type is nice, but it must not be empty to be useful
diff --git a/tests/linker/link all/DataContractTest.cs b/tests/linker/link all/DataContractTest.cs
index 118e3303c900..4648807189d6 100644
--- a/tests/linker/link all/DataContractTest.cs
+++ b/tests/linker/link all/DataContractTest.cs
@@ -36,7 +36,7 @@ public static T FromXml (string xml)
{
using (var r = XmlReader.Create (new StringReader (xml))) {
var s = new DataContractSerializer (typeof (T));
- return (T) s.ReadObject (r);
+ return (T) s.ReadObject (r)!;
}
}
diff --git a/tests/linker/link all/InterfacesTest.cs b/tests/linker/link all/InterfacesTest.cs
index b4705258fbad..9b46ca26b4d0 100644
--- a/tests/linker/link all/InterfacesTest.cs
+++ b/tests/linker/link all/InterfacesTest.cs
@@ -30,7 +30,7 @@ class UTF8Marshaler : ICustomMarshaler {
public object MarshalNativeToManaged (IntPtr pNativeData)
{
- return null;
+ return null!;
}
public IntPtr MarshalManagedToNative (object managedObject)
diff --git a/tests/linker/link all/InternalsTest.cs b/tests/linker/link all/InternalsTest.cs
index d0e96ef69b66..31ef3ef2f3b8 100644
--- a/tests/linker/link all/InternalsTest.cs
+++ b/tests/linker/link all/InternalsTest.cs
@@ -46,7 +46,7 @@ public void TimeZone_Names ()
Assert.That (count, Is.GreaterThan (400), "count");
for (int i = 0, offset = 0; i < count; i++, offset += IntPtr.Size) {
IntPtr p = Marshal.ReadIntPtr (array, offset);
- string s = Marshal.PtrToStringAnsi (p);
+ string s = Marshal.PtrToStringAnsi (p)!;
Assert.NotNull (s, i.ToString ());
Marshal.FreeHGlobal (p);
}
@@ -54,7 +54,7 @@ public void TimeZone_Names ()
}
[DllImport ("__Internal")]
- extern static IntPtr xamarin_timezone_get_data (string name, ref uint size);
+ extern static IntPtr xamarin_timezone_get_data (string? name, ref uint size);
[Test]
public void TimeZone_Data ()
diff --git a/tests/linker/link all/LinkAllMacTest.cs b/tests/linker/link all/LinkAllMacTest.cs
index 181df123d073..ba5c7d8ec071 100644
--- a/tests/linker/link all/LinkAllMacTest.cs
+++ b/tests/linker/link all/LinkAllMacTest.cs
@@ -58,8 +58,8 @@ public void XmlSerialization ()
using (var sr = new StringReader (xml))
using (var xr = new XmlTextReader (sr)) {
var xs = new XmlSerializer (typeof (SerializeMe));
- SerializeMe item = xs.Deserialize (xr) as SerializeMe;
- Assert.AreEqual (2, item.SetMe, "SetMe");
+ var item = xs.Deserialize (xr) as SerializeMe;
+ Assert.AreEqual (2, item!.SetMe, "SetMe");
}
}
diff --git a/tests/linker/link all/LinkAllTest.cs b/tests/linker/link all/LinkAllTest.cs
index fb48b13833a3..ec798c25fac5 100644
--- a/tests/linker/link all/LinkAllTest.cs
+++ b/tests/linker/link all/LinkAllTest.cs
@@ -80,7 +80,7 @@ public class LinkAllRegressionTest {
class TypeAttribute : Attribute {
- public TypeAttribute (Type type) { }
+ public TypeAttribute (Type? type) { }
}
[Type (null)]
@@ -98,7 +98,7 @@ public void GetterOnly ()
NotPreserved np = new NotPreserved ();
Assert.That (np.Two, Is.EqualTo (0), "Two==0");
- PropertyInfo pi = not_preserved_type.GetProperty ("Two");
+ PropertyInfo pi = not_preserved_type.GetProperty ("Two")!;
// check the *unused* setter absence from the application
Assert.NotNull (pi.GetGetMethod (), "getter");
Assert.Null (pi.GetSetMethod (), "setter");
@@ -111,7 +111,7 @@ public void SetterOnly ()
NotPreserved np = new NotPreserved ();
np.One = 1;
- PropertyInfo pi = not_preserved_type.GetProperty ("One");
+ PropertyInfo pi = not_preserved_type.GetProperty ("One")!;
// check the *unused* setter absence from the application
Assert.Null (pi.GetGetMethod (), "getter");
Assert.NotNull (pi.GetSetMethod (), "setter");
@@ -122,7 +122,7 @@ public void MEF_3862 ()
{
// note: avoiding using "typeof(DefaultValueAttribute)" in the code
// so the linker does not keep it just because of it
- PropertyInfo pi = not_preserved_type.GetProperty ("Two");
+ PropertyInfo pi = not_preserved_type.GetProperty ("Two")!;
object [] attrs = pi.GetCustomAttributes (false);
bool default_value = false;
foreach (var ca in attrs) {
@@ -213,11 +213,11 @@ public void Assembly_Load ()
string FindAssemblyPath ()
{
var filename = Path.GetFileName (GetType ().Assembly.Location);
- var bundlePath = NSBundle.MainBundle.BundlePath;
+ var bundlePath = NSBundle.MainBundle.BundlePath!;
var isExtension = bundlePath.EndsWith (".appex", StringComparison.Ordinal);
var mainBundlePath = bundlePath;
if (isExtension)
- mainBundlePath = Path.GetDirectoryName (Path.GetDirectoryName (bundlePath));
+ mainBundlePath = Path.GetDirectoryName (Path.GetDirectoryName (bundlePath))!;
foreach (var filepath in Directory.EnumerateFiles (mainBundlePath, filename, SearchOption.AllDirectories)) {
var fname = Path.GetFileName (filepath);
if (filepath.EndsWith ($"{fname}.framework/{fname}", StringComparison.Ordinal)) {
@@ -262,9 +262,9 @@ public void Assembly_ReflectionOnlyLoadFrom ()
[Test]
public void Pasteboard_ImagesTest ()
{
- string file = Path.Combine (NSBundle.MainBundle.ResourcePath, "basn3p08.png");
+ string file = Path.Combine (NSBundle.MainBundle.ResourcePath!, "basn3p08.png");
using (var dp = new CGDataProvider (file)) {
- using (var cgimg = CGImage.FromPNG (dp, null, false, CGColorRenderingIntent.Default)) {
+ using (var cgimg = CGImage.FromPNG (dp, null, false, CGColorRenderingIntent.Default)!) {
using (var img = new UIImage (cgimg)) {
UIPasteboard.General.Images = new UIImage [] { img };
if (TestRuntime.CheckXcodeVersion (8, 0))
@@ -298,7 +298,7 @@ public enum TestEnum {
[Preserve (AllMembers = true)]
public class TestEnumTypeConverter : System.ComponentModel.TypeConverter {
- public override object ConvertTo (ITypeDescriptorContext context, CultureInfo culture, object value, Type destinationType)
+ public override object ConvertTo (ITypeDescriptorContext? context, CultureInfo? culture, object? value, Type destinationType)
{
return "hello";
}
@@ -373,7 +373,7 @@ public void NestedNSObject ()
var p = Helper.GetType ("LinkAll.Parent");
Assert.NotNull (p, "Parent");
// because a nested type is a subclass of NSObject (and not part of monotouch.dll)
- var n = p.GetNestedType ("Derived");
+ var n = p.GetNestedType ("Derived")!;
Assert.NotNull (n, "Derived");
// however other stuff in Parent, like unused methods, will be removed
Assert.Null (p.GetMethod ("UnusedMethod"), "unused method");
@@ -389,7 +389,7 @@ public void Bug20363 ()
Assert.NotNull (cea, "CancelEventArgs");
}
- string GetField (object o, string s)
+ string? GetField (object o, string s)
{
var type = o.GetType ();
var f1 = type.GetField (s, BindingFlags.Instance | BindingFlags.NonPublic);
@@ -409,7 +409,7 @@ string FromPattern (string pattern, object o)
s = GetField (o, "");
if (s is not null)
return s;
- return GetField (o, "");
+ return GetField (o, "")!;
}
[Test]
@@ -429,18 +429,18 @@ public void Events ()
using (var pr = new SKProductsRequest ()) {
Assert.Null (pr.WeakDelegate, "none");
// event on SKProductsRequest itself
- pr.ReceivedResponse += (object sender, SKProductsRequestResponseEventArgs e) => { };
+ pr.ReceivedResponse += (object? sender, SKProductsRequestResponseEventArgs e) => { };
- var t = pr.WeakDelegate.GetType ();
+ var t = pr.WeakDelegate!.GetType ();
Assert.That (t.Name, Is.EqualTo ("_SKProductsRequestDelegate"), "delegate");
- var fi = t.GetField ("receivedResponse", BindingFlags.NonPublic | BindingFlags.Instance);
+ var fi = t.GetField ("receivedResponse", BindingFlags.NonPublic | BindingFlags.Instance)!;
Assert.NotNull (fi, "receivedResponse");
var value = fi.GetValue (pr.WeakDelegate);
Assert.NotNull (value, "value");
// and on the SKRequest defined one
- pr.RequestFailed += (object sender, SKRequestErrorEventArgs e) => { };
+ pr.RequestFailed += (object? sender, SKRequestErrorEventArgs e) => { };
// and the existing (initial field) is still set
fi = t.GetField ("receivedResponse", BindingFlags.NonPublic | BindingFlags.Instance);
Assert.NotNull (fi, "receivedResponse/SKRequest");
@@ -460,7 +460,7 @@ where nic.Id.StartsWith ("en") || nic.Id.StartsWith ("pdp_ip")
public void AppleTls ()
{
// make test work for classic (monotouch) and unified (iOS, tvOS)
- var fqn = typeof (NSObject).AssemblyQualifiedName.Replace ("Foundation.NSObject", "Security.Tls.AppleTlsProvider");
+ var fqn = typeof (NSObject).AssemblyQualifiedName!.Replace ("Foundation.NSObject", "Security.Tls.AppleTlsProvider");
Assert.Null (Helper.GetType (fqn), "Should NOT be included (no SslStream or Socket support)");
}
@@ -469,7 +469,7 @@ public void AppleTls ()
public void WebKit_NSProxy ()
{
// this test works only because "Link all" does not use WebKit
- var fqn = typeof (NSObject).AssemblyQualifiedName.Replace ("Foundation.NSObject", "Foundation.NSProxy");
+ var fqn = typeof (NSObject).AssemblyQualifiedName!.Replace ("Foundation.NSObject", "Foundation.NSProxy");
Assert.Null (Helper.GetType (fqn), fqn);
}
@@ -546,10 +546,10 @@ public void NoFatCorlib ()
public void CGPdfPage ()
{
TestRuntime.AssertXcodeVersion (9, 0);
- var pdfPath = NSBundle.MainBundle.PathForResource ("Tamarin", "pdf");
+ var pdfPath = NSBundle.MainBundle.PathForResource ("Tamarin", "pdf")!;
using var view = new PdfView ();
- view.Document = new PdfDocument (NSUrl.FromFilename (pdfPath));
- using var page = view.CurrentPage;
+ view.Document = new PdfDocument (NSUrl.FromFilename (pdfPath)!);
+ using var page = view.CurrentPage!;
Assert.IsNotNull (page.Page, "Page");
}
#endif
diff --git a/tests/linker/link all/LinqExpressionTest.cs b/tests/linker/link all/LinqExpressionTest.cs
index dbee07a1082b..d6ee2f545335 100644
--- a/tests/linker/link all/LinqExpressionTest.cs
+++ b/tests/linker/link all/LinqExpressionTest.cs
@@ -15,7 +15,7 @@ public class LinqExpressionTest {
[Test]
public void Expression_T_Ctor ()
{
- var ctor = typeof (LinqExpressionTest).GetConstructor (Type.EmptyTypes);
+ var ctor = typeof (LinqExpressionTest).GetConstructor (Type.EmptyTypes)!;
var expr = Expression.New (ctor, new Expression [0]);
Assert.NotNull (Expression.Lambda (typeof (Bug14863Delegate), expr, null), "Lambda");
// note: reflection is used to create an instance of Expression using an internal ctor
diff --git a/tests/linker/link all/PreserveTest.cs b/tests/linker/link all/PreserveTest.cs
index 9792f8ce5e73..19dee363f3ad 100644
--- a/tests/linker/link all/PreserveTest.cs
+++ b/tests/linker/link all/PreserveTest.cs
@@ -24,20 +24,20 @@ namespace LinkAll.Attributes {
// type and members preserved by assembly-level attribute above
class TypeWithMembers {
- public string Present { get; set; }
+ public string Present { get; set; } = "";
}
// type (only, not members) preserved by assembly-level attribute above
class TypeWithoutMembers {
- public string Absent { get; set; }
+ public string Absent { get; set; } = "";
}
class MemberWithCustomAttribute {
// since [Obfuscation] was manually preserved then we'll preserve everything that's decorated with the attribute
[Obfuscation]
- public string Custom { get; set; }
+ public string Custom { get; set; } = "";
}
[TestFixture]
@@ -56,7 +56,7 @@ public class PreserveTest {
[Test]
public void PreserveTypeWithMembers ()
{
- var t = Type.GetType ("LinkAll.Attributes.TypeWithMembers" + WorkAroundLinkerHeuristics);
+ var t = Type.GetType ("LinkAll.Attributes.TypeWithMembers" + WorkAroundLinkerHeuristics)!;
// both type and members are preserved
Assert.NotNull (t, "type");
Assert.NotNull (t.GetProperty ("Present"), "members");
@@ -65,7 +65,7 @@ public void PreserveTypeWithMembers ()
[Test]
public void PreserveTypeWithoutMembers ()
{
- var t = Type.GetType ("LinkAll.Attributes.TypeWithoutMembers" + WorkAroundLinkerHeuristics);
+ var t = Type.GetType ("LinkAll.Attributes.TypeWithoutMembers" + WorkAroundLinkerHeuristics)!;
// type is preserved
Assert.NotNull (t, "type");
// but we did not ask the linker to preserve it's members
@@ -77,7 +77,7 @@ public void Runtime_RegisterEntryAssembly ()
{
TestRuntime.AssertSimulator ("https://github.com/dotnet/macios/issues/10457");
- var klass = Type.GetType ("ObjCRuntime.Runtime, " + AssemblyName);
+ var klass = Type.GetType ("ObjCRuntime.Runtime, " + AssemblyName)!;
Assert.NotNull (klass, "Runtime");
// RegisterEntryAssembly is only needed for the simulator (not on devices) so it's only preserved for sim builds
var method = klass.GetMethod ("RegisterEntryAssembly", BindingFlags.NonPublic | BindingFlags.Static, null, new [] { typeof (Assembly) }, null);
@@ -100,7 +100,7 @@ public void MonoTouchException_Unconditional ()
[Test]
public void Class_Unconditional ()
{
- var klass = Type.GetType ("ObjCRuntime.Class, " + AssemblyName);
+ var klass = Type.GetType ("ObjCRuntime.Class, " + AssemblyName)!;
Assert.NotNull (klass, "Class");
// handle is unconditionally preserved
var field = klass.GetField ("handle", BindingFlags.NonPublic | BindingFlags.Instance);
@@ -110,7 +110,7 @@ public void Class_Unconditional ()
[Test]
public void Runtime_Unconditional ()
{
- var klass = Type.GetType ("ObjCRuntime.Runtime, " + AssemblyName);
+ var klass = Type.GetType ("ObjCRuntime.Runtime, " + AssemblyName)!;
Assert.NotNull (klass, "Runtime");
// Initialize and a few other methods are unconditionally preserved
var method = klass.GetMethod ("Initialize", BindingFlags.NonPublic | BindingFlags.Static);
@@ -122,7 +122,7 @@ public void Runtime_Unconditional ()
[Test]
public void Selector_Unconditional ()
{
- var klass = Type.GetType ("ObjCRuntime.Selector, " + AssemblyName);
+ var klass = Type.GetType ("ObjCRuntime.Selector, " + AssemblyName)!;
Assert.NotNull (klass, "Selector");
// handle and is unconditionally preserved
var field = klass.GetField ("handle", BindingFlags.NonPublic | BindingFlags.Instance);
@@ -134,13 +134,13 @@ public void Selector_Unconditional ()
[Test]
public void SmartEnumTest ()
{
- var consumer = GetType ().Assembly.GetType ("LinkAll.Attributes.SmartConsumer" + WorkAroundLinkerHeuristics);
+ var consumer = GetType ().Assembly.GetType ("LinkAll.Attributes.SmartConsumer" + WorkAroundLinkerHeuristics)!;
Assert.NotNull (consumer, "SmartConsumer");
Assert.NotNull (consumer.GetMethod ("GetSmartEnumValue"), "GetSmartEnumValue");
Assert.NotNull (consumer.GetMethod ("SetSmartEnumValue"), "SetSmartEnumValue");
- var smartEnum = GetType ().Assembly.GetType ("LinkAll.Attributes.SmartEnum");
+ var smartEnum = GetType ().Assembly.GetType ("LinkAll.Attributes.SmartEnum")!;
Assert.NotNull (smartEnum, "SmartEnum");
- var smartExtensions = GetType ().Assembly.GetType ("LinkAll.Attributes.SmartEnumExtensions" + WorkAroundLinkerHeuristics);
+ var smartExtensions = GetType ().Assembly.GetType ("LinkAll.Attributes.SmartEnumExtensions" + WorkAroundLinkerHeuristics)!;
Assert.NotNull (smartExtensions, "SmartEnumExtensions");
Assert.NotNull (smartExtensions.GetMethod ("GetConstant"), "GetConstant");
Assert.NotNull (smartExtensions.GetMethod ("GetValue"), "GetValue");
@@ -166,7 +166,7 @@ public void PreserveAllExcludesNestedTypes ()
[Test]
public void PreserveAllKeepsEnumValues ()
{
- var enumType = GetType ().Assembly.GetType ("LinkAll.Attributes.MyEnum" + WorkAroundLinkerHeuristics);
+ var enumType = GetType ().Assembly.GetType ("LinkAll.Attributes.MyEnum" + WorkAroundLinkerHeuristics)!;
Assert.NotNull (enumType, "MyEnum");
Assert.AreEqual (3, enumType.GetFields (BindingFlags.Public | BindingFlags.Static).Length, "fields");
AssertHasStaticField ("A", 1);
@@ -175,9 +175,9 @@ public void PreserveAllKeepsEnumValues ()
void AssertHasStaticField (string name, int value)
{
- var field = enumType.GetField (name, BindingFlags.Public | BindingFlags.Static);
+ var field = enumType.GetField (name, BindingFlags.Public | BindingFlags.Static)!;
Assert.NotNull (field, name);
- Assert.AreEqual (value, (int) field.GetValue (null), $"{name} == {value}");
+ Assert.AreEqual (value, (int) field.GetValue (null)!, $"{name} == {value}");
}
}
}
diff --git a/tests/linker/link all/SealerTest.cs b/tests/linker/link all/SealerTest.cs
index 578de40d4378..423a88f4be52 100644
--- a/tests/linker/link all/SealerTest.cs
+++ b/tests/linker/link all/SealerTest.cs
@@ -68,9 +68,9 @@ public void Sealed ()
public void Final ()
{
var t = typeof (Sealable);
- var a = t.GetMethod ("A");
- var b = t.GetMethod ("B");
- var c = t.GetMethod ("C");
+ var a = t.GetMethod ("A")!;
+ var b = t.GetMethod ("B")!;
+ var c = t.GetMethod ("C")!;
#if DEBUG || __MACOS__
// this is not a sealed (C#) method (in the source)
Assert.False (a.IsFinal, "A");
@@ -88,9 +88,9 @@ public void Final ()
public void Virtual ()
{
var t = typeof (Sealable);
- var a = t.GetMethod ("A");
- var b = t.GetMethod ("B");
- var c = t.GetMethod ("C");
+ var a = t.GetMethod ("A")!;
+ var b = t.GetMethod ("B")!;
+ var c = t.GetMethod ("C")!;
#if DEBUG || __MACOS__
// both methods are virtual (both in C# and IL)
Assert.True (a.IsVirtual, "A");
@@ -110,7 +110,7 @@ public void Virtual ()
public void Interface ()
{
var t = typeof (Subclass);
- var a = t.GetMethod ("A");
+ var a = t.GetMethod ("A")!;
// A cannot be de-virtualized since Concrete must satisfy Interface thru Base
Assert.True (a.IsVirtual, "A");
}
diff --git a/tests/linker/link all/SerializationTest.cs b/tests/linker/link all/SerializationTest.cs
index 8e1fd97a17b3..45e9dfa9b5f6 100644
--- a/tests/linker/link all/SerializationTest.cs
+++ b/tests/linker/link all/SerializationTest.cs
@@ -13,12 +13,12 @@ namespace LinkAll {
static class Helper {
public static Type GetType (string name)
{
- return Type.GetType (name);
+ return Type.GetType (name)!;
}
public static Type GetType (string typeName, bool throwOnError)
{
- return Type.GetType (typeName, throwOnError);
+ return Type.GetType (typeName, throwOnError)!;
}
}
}
diff --git a/tests/linker/link all/XmlSerializationTest.cs b/tests/linker/link all/XmlSerializationTest.cs
index 5943406fb7ed..9c7acb6f1bb4 100644
--- a/tests/linker/link all/XmlSerializationTest.cs
+++ b/tests/linker/link all/XmlSerializationTest.cs
@@ -15,21 +15,21 @@ namespace LinkAll.Serialization.Xml {
[Serializable]
[XmlRoot ("rsp", IsNullable = false)]
- public class XmlResult {
+ public class XmlResult where T : class {
[XmlAttribute ("stat")]
public int StatusCode { get; set; }
[XmlElement ("photos")]
[XmlElement ("photosets")]
- public T Result { get; set; }
+ public T? Result { get; set; }
}
[Serializable]
[XmlRoot ("rsp")]
- public class XmlField {
+ public class XmlField where T : class {
[XmlElement ("photos")]
[XmlElement ("photosets")]
- public T Result;
+ public T? Result;
}
[Ignore ("https://github.com/dotnet/runtime/issues/41389")]
@@ -52,7 +52,7 @@ public void GenericProperty_Bug5543 ()
r.StatusCode = -1;
ms.Position = 0;
- XmlResult back = (XmlResult) serializer.Deserialize (ms);
+ var back = (XmlResult) serializer.Deserialize (ms)!;
Assert.That (back.Result, Is.EqualTo ("5543"), "Result");
Assert.That (back.StatusCode, Is.EqualTo (10), "StatusCode");
diff --git a/tests/linker/link all/dotnet/shared.csproj b/tests/linker/link all/dotnet/shared.csproj
index a8bad04a8cf9..87a5c90bff5c 100644
--- a/tests/linker/link all/dotnet/shared.csproj
+++ b/tests/linker/link all/dotnet/shared.csproj
@@ -18,10 +18,6 @@
$(NoWarn);CA1422
-
-
- true
- Nullable
diff --git a/tests/linker/link sdk/AotBugs.cs b/tests/linker/link sdk/AotBugs.cs
index c97b6a6d1bd3..ff7e8209013d 100644
--- a/tests/linker/link sdk/AotBugs.cs
+++ b/tests/linker/link sdk/AotBugs.cs
@@ -72,7 +72,7 @@ public void ConcurrentDictionary_3444 ()
}
class SomeObject {
- public event EventHandler Event;
+ public event EventHandler? Event;
public void RaiseEvent ()
{
@@ -82,7 +82,7 @@ public void RaiseEvent ()
}
}
- void OnEvent (object sender, EventArgs e)
+ void OnEvent (object? sender, EventArgs e)
{
}
@@ -103,7 +103,8 @@ public void Workaround_3682 ()
var e = so.GetType ().GetEvent ("Event");
if (e is not null) {
var add = e.GetAddMethod ();
- add.Invoke (so, new object [] { new EventHandler (OnEvent) });
+ if (add is not null)
+ add.Invoke (so, new object [] { new EventHandler (OnEvent) });
}
}
@@ -168,7 +169,7 @@ join personTable in p on wqual.FK_PERSON.ToString () equals personTable.Id.ToStr
public class Foo {
public int Id { get; set; }
- public string Name { get; set; }
+ public string Name { get; set; } = "";
}
[Test]
@@ -368,15 +369,15 @@ public void Override_4114 ()
g.MakeCollectionOfInputs (1.0, 2.0, 3.0);
}
- public sealed class NewDictionary {
+ public sealed class NewDictionary where TKey : notnull {
Dictionary _dictionary = new Dictionary ();
- public NewDictionary (IEnumerable> items)
+ public NewDictionary (IEnumerable>? items)
{
ForEach (items, (item) => _dictionary.Add (item.Key, item.Value));
}
- static void ForEach (IEnumerable collection, Action action)
+ static void ForEach (IEnumerable? collection, Action action)
{
if (collection is not null)
foreach (T item in collection)
@@ -392,8 +393,10 @@ public void ForEachKVP_4114 ()
}
public class Enumbers {
- public IEnumerable> Enumerate (List> alist)
+ public IEnumerable> Enumerate (List>? alist)
{
+ if (alist is null)
+ throw new NullReferenceException ();
return MakeEnumerable (alist.ToArray ());
}
@@ -411,7 +414,7 @@ public void AsEnumerable_4114 ()
Assert.Throws (() => e.Enumerate (null));
}
- static object mInstance = null;
+ static object? mInstance = null;
[MethodImpl (MethodImplOptions.Synchronized)]
public static object getInstance ()
@@ -458,7 +461,7 @@ public void Bug8379_b ()
public static IEnumerable GetStringList () where T : struct, IConvertible
{
- return Enum.GetValues (typeof (T)).Cast ().Select (x => x.ToString ());
+ return Enum.GetValues (typeof (T)).Cast ().Select (x => x.ToString () ?? "");
}
[Test]
diff --git a/tests/linker/link sdk/BitcodeTest.cs b/tests/linker/link sdk/BitcodeTest.cs
index 1e32c93b6e6c..af8a7f520985 100644
--- a/tests/linker/link sdk/BitcodeTest.cs
+++ b/tests/linker/link sdk/BitcodeTest.cs
@@ -63,7 +63,11 @@ public void FaultClauseTest ()
// This is because we only have an indirect way of making csc produce a fault clause
var enumeratorType = GetType ().GetNestedTypes (BindingFlags.NonPublic).First ((v) => v.Name.Contains ($"<{nameof (FaultClause)}>"));
var method = enumeratorType.GetMethod ("MoveNext", BindingFlags.Instance | BindingFlags.Static | BindingFlags.NonPublic | BindingFlags.Public);
+ if (method is null)
+ throw new InvalidOperationException ("MoveNext");
var body = method.GetMethodBody ();
+ if (body is null)
+ throw new InvalidOperationException ("MoveNext body");
Assert.IsTrue (body.ExceptionHandlingClauses.Any ((v) => v.Flags == ExceptionHandlingClauseOptions.Fault), "Any fault clauses");
// Then assert that the method can be called successfully.
diff --git a/tests/linker/link sdk/Bug1820Test.cs b/tests/linker/link sdk/Bug1820Test.cs
index f66a9de7dc26..6f0efd3d572f 100644
--- a/tests/linker/link sdk/Bug1820Test.cs
+++ b/tests/linker/link sdk/Bug1820Test.cs
@@ -15,7 +15,7 @@ public partial class XmlSerializationTest {
[XmlRoot (Namespace = "", IsNullable = false)]
public class Response {
private DataUpdates dataUpdatesField;
- private static XmlSerializer serializer;
+ private static XmlSerializer? serializer;
public Response ()
{
@@ -38,10 +38,10 @@ private static XmlSerializer Serializer {
public static Response Deserialize (string xml)
{
- StringReader stringReader = null;
+ StringReader? stringReader = null;
try {
stringReader = new StringReader (xml);
- return ((Response) (Serializer.Deserialize (XmlReader.Create (stringReader))));
+ return (Response) (Serializer.Deserialize (XmlReader.Create (stringReader)) ?? throw new InvalidOperationException ("Deserialization returned null."));
} finally {
if ((stringReader is not null)) {
stringReader.Dispose ();
@@ -55,7 +55,7 @@ public static Response Deserialize (string xml)
[XmlRoot (Namespace = "", IsNullable = false)]
public class DataUpdates {
private List dataUpdateInfoField;
- private static XmlSerializer serializer;
+ private static XmlSerializer? serializer;
public DataUpdates ()
{
@@ -79,10 +79,10 @@ private static XmlSerializer Serializer {
public static DataUpdates Deserialize (string xml)
{
- StringReader stringReader = null;
+ StringReader? stringReader = null;
try {
stringReader = new StringReader (xml);
- return ((DataUpdates) (Serializer.Deserialize (XmlReader.Create (stringReader))));
+ return (DataUpdates) (Serializer.Deserialize (XmlReader.Create (stringReader)) ?? throw new InvalidOperationException ("Deserialization returned null."));
} finally {
if ((stringReader is not null)) {
stringReader.Dispose ();
@@ -96,9 +96,9 @@ public static DataUpdates Deserialize (string xml)
public class DataUpdatesDataUpdateInfo {
private DateTime dataDateField;
- private string dataTypeField;
+ private string dataTypeField = "";
private DateTime lastUpdatedDateField;
- private static XmlSerializer serializer;
+ private static XmlSerializer? serializer;
public DataUpdatesDataUpdateInfo ()
{
@@ -132,10 +132,10 @@ private static XmlSerializer Serializer {
public static DataUpdatesDataUpdateInfo Deserialize (string xml)
{
- StringReader stringReader = null;
+ StringReader? stringReader = null;
try {
stringReader = new StringReader (xml);
- return ((DataUpdatesDataUpdateInfo) (Serializer.Deserialize (XmlReader.Create (stringReader))));
+ return (DataUpdatesDataUpdateInfo) (Serializer.Deserialize (XmlReader.Create (stringReader)) ?? throw new InvalidOperationException ("Deserialization returned null."));
} finally {
if ((stringReader is not null)) {
stringReader.Dispose ();
diff --git a/tests/linker/link sdk/CryptoTest.cs b/tests/linker/link sdk/CryptoTest.cs
index ebe6064269ab..277b85f21b8c 100644
--- a/tests/linker/link sdk/CryptoTest.cs
+++ b/tests/linker/link sdk/CryptoTest.cs
@@ -41,8 +41,10 @@ public void TrustUsingNewCallback ()
// untrusted, custom ICertificatePolicy and ServerCertificateValidationCallback without
// having caching issues (in S.Net or the SSL handshake cache)
try {
- ServicePointManager.ServerCertificateValidationCallback = delegate (object sender, X509Certificate cert, X509Chain chain, SslPolicyErrors errors)
+ ServicePointManager.ServerCertificateValidationCallback = delegate (object sender, X509Certificate? cert, X509Chain? chain, SslPolicyErrors errors)
{
+ if (cert is null || chain is null)
+ return false;
Assert.That (errors, Is.EqualTo (SslPolicyErrors.None), "certificateProblem");
X509Certificate2 c2 = X509CertificateLoader.LoadCertificate (cert.GetRawCertData ());
Assert.True (chain.Build (c2), "Build");
@@ -93,8 +95,10 @@ public void TLS1_ServerNameExtension ()
var actual = ServicePointManager.SecurityProtocol;
try {
- ServicePointManager.ServerCertificateValidationCallback = delegate (object sender, X509Certificate cert, X509Chain chain, SslPolicyErrors errors)
+ ServicePointManager.ServerCertificateValidationCallback = delegate (object sender, X509Certificate? cert, X509Chain? chain, SslPolicyErrors errors)
{
+ if (cert is null || chain is null)
+ return false;
Assert.That (errors, Is.EqualTo (SslPolicyErrors.None), "certificateProblem");
X509Certificate2 c2 = X509CertificateLoader.LoadCertificate (cert.GetRawCertData ());
Assert.True (chain.Build (c2), "Build");
diff --git a/tests/linker/link sdk/DataContractTest.cs b/tests/linker/link sdk/DataContractTest.cs
index 14f2c52577ca..3156d5f14272 100644
--- a/tests/linker/link sdk/DataContractTest.cs
+++ b/tests/linker/link sdk/DataContractTest.cs
@@ -17,7 +17,7 @@ public class MyClass {
public MyClass () { }
[DataMember]
- List MyList { get; set; }
+ List MyList { get; set; } = [];
}
[TestFixture]
diff --git a/tests/linker/link sdk/LinkExtraDefsTest.cs b/tests/linker/link sdk/LinkExtraDefsTest.cs
index d8329c7abab2..4b30648f3e51 100644
--- a/tests/linker/link sdk/LinkExtraDefsTest.cs
+++ b/tests/linker/link sdk/LinkExtraDefsTest.cs
@@ -26,15 +26,19 @@ public class LinkExtraDefsTest {
[Test]
public void Corlib ()
{
- Type t = Type.GetType ("System.Security.PermissionSet, " + typeof (int).Assembly.GetName ().Name);
+ var t = Type.GetType ("System.Security.PermissionSet, " + typeof (int).Assembly.GetName ().Name);
Assert.NotNull (t, "System.Security.PermissionSet");
+ if (t is null)
+ throw new InvalidOperationException ("System.Security.PermissionSet");
}
[Test]
public void System ()
{
- Type t = Type.GetType ("System.Net.Mime.ContentType, System.Net.Mail");
+ var t = Type.GetType ("System.Net.Mime.ContentType, System.Net.Mail");
Assert.NotNull (t, "System.Net.Mime.ContentType");
+ if (t is null)
+ throw new InvalidOperationException ("System.Net.Mime.ContentType");
// we asked for ParseValue to be preserved
Assert.NotNull (t.GetMethod ("ParseValue", BindingFlags.Instance | BindingFlags.NonPublic), "Parse");
}
@@ -43,8 +47,10 @@ public void System ()
[Test]
public void MonoTouch ()
{
- Type t = Type.GetType ("CoreBluetooth.CBUUID, " + typeof (NSObject).Assembly.ToString ());
+ var t = Type.GetType ("CoreBluetooth.CBUUID, " + typeof (NSObject).Assembly.ToString ());
Assert.NotNull (t, "[MonoTouch.]CoreBluetooth.CBUUID");
+ if (t is null)
+ throw new InvalidOperationException ("CoreBluetooth.CBUUID");
// check (generated) fields since we instructed the linker to keep them
var f = t.GetFields (BindingFlags.NonPublic | BindingFlags.Static);
Assert.That (f.Length, Is.Not.EqualTo (0), "fields were preserved");
diff --git a/tests/linker/link sdk/LinkSdkRegressionTest.cs b/tests/linker/link sdk/LinkSdkRegressionTest.cs
index dd8890e24975..b1bc9b1c2e1b 100644
--- a/tests/linker/link sdk/LinkSdkRegressionTest.cs
+++ b/tests/linker/link sdk/LinkSdkRegressionTest.cs
@@ -68,7 +68,7 @@ public void Bug205_ExposingIEnumerable ()
// http://bugzilla.xamarin.com/show_bug.cgi?id=234
public void Bug234_Interlocked ()
{
- string str = null;
+ string? str = null;
Assert.Null (Interlocked.Exchange (ref str, "one"), "Exchange");
// the above should not crash with System.ExecutionEngineException
Assert.That (str, Is.EqualTo ("one"), "one");
@@ -119,7 +119,9 @@ public void Bug865_CanOpenUrl ()
if (TestRuntime.CheckXcodeVersion (15, 0))
Assert.Ignore ("NSUrl was fixed with Xcode 15.0");
+#pragma warning disable CS8625 // Intentional null test case
Assert.False (UIApplication.SharedApplication.CanOpenUrl (null), "null");
+#pragma warning restore CS8625
// the above should not throw an ArgumentNullException
// and that's important because NSUrl.FromString and NSUrl.ctor(string) differs
const string bad_tel = "tel://1800 023 009";
@@ -284,7 +286,8 @@ public void Bug2000_NSPersistentStoreCoordinator ()
model.Entities = new NSEntityDescription [1] { entity };
model.SetEntities (model.Entities, String.Empty);
- var sqlitePath = Path.Combine (NSFileManager.TemporaryDirectory, $"test-{System.Diagnostics.Process.GetCurrentProcess ().Id}.sqlite");
+ var temporaryDirectory = NSFileManager.TemporaryDirectory ?? Path.GetTempPath ();
+ var sqlitePath = Path.Combine (temporaryDirectory, $"test-{System.Diagnostics.Process.GetCurrentProcess ().Id}.sqlite");
NSUrl url = NSUrl.FromFilename (sqlitePath);
try {
@@ -461,7 +464,7 @@ public void Hardware_SO ()
public class Location { }
- private static Location mInstance = null;
+ private static Location? mInstance = null;
[MethodImpl (MethodImplOptions.Synchronized)]
public static Location getInstance ()
@@ -560,7 +563,7 @@ public void LockRecursionException_5311 ()
class AddedInSilverlight5 : INotifyPropertyChanging {
#pragma warning disable CS0067 // The event 'LinkSdkRegressionTest.AddedInSilverlight5.PropertyChanging' is never used
- public event PropertyChangingEventHandler PropertyChanging;
+ public event PropertyChangingEventHandler? PropertyChanging;
#pragma warning restore CS0067
}
@@ -573,9 +576,17 @@ public void INotifyPropertyChanging_5337 ()
[Test]
public void MonoIOStat_6118 ()
{
- string file = NSBundle.MainBundle.ExecutablePath;
+ var file = NSBundle.MainBundle.ExecutablePath;
+ if (string.IsNullOrEmpty (file))
+ throw new InvalidOperationException ("No executable path.");
DateTime c1 = File.GetCreationTime (file).ToUniversalTime ();
- DateTime c2 = (DateTime) NSFileManager.DefaultManager.GetAttributes (file).CreationDate;
+ var attributes = NSFileManager.DefaultManager.GetAttributes (file);
+ if (attributes is null)
+ throw new InvalidOperationException ("No file attributes.");
+ var creationDate = attributes.CreationDate;
+ if (creationDate is null)
+ throw new InvalidOperationException ("No creation date.");
+ DateTime c2 = (DateTime) creationDate;
Assert.That ((c1 - c2).Seconds, Is.LessThan (30), "MonoIOStat");
}
@@ -584,7 +595,11 @@ public void ObjectHandleCtor ()
{
Type o = typeof (Object);
// this returns a new System.Runtime.Remoting.ObjectHandle which (was) linked away previously
- Assert.NotNull (Activator.CreateInstance (o.Assembly.GetName ().Name, o.FullName), "ObjectHandle");
+ var assemblyName = o.Assembly.GetName ().Name;
+ var typeName = o.FullName;
+ if (string.IsNullOrEmpty (assemblyName) || string.IsNullOrEmpty (typeName))
+ throw new InvalidOperationException ("Unable to create an ObjectHandle.");
+ Assert.NotNull (Activator.CreateInstance (assemblyName, typeName), "ObjectHandle");
}
[Test]
@@ -614,7 +629,7 @@ public void Update (object o)
public void Action_14493 ()
{
var Demo = new Demo_14493 ();
- Action
diff --git a/tests/xtro-sharpie/u2todo/u2todo.csproj b/tests/xtro-sharpie/u2todo/u2todo.csproj
index 8e905ed0a453..6c73ffc392da 100644
--- a/tests/xtro-sharpie/u2todo/u2todo.csproj
+++ b/tests/xtro-sharpie/u2todo/u2todo.csproj
@@ -3,7 +3,6 @@
Exe
net$(BundledNETCoreAppTargetFrameworkVersion)
enable
- enable
false
diff --git a/tests/xtro-sharpie/xtro-report/xtro-report.csproj b/tests/xtro-sharpie/xtro-report/xtro-report.csproj
index 9bcdb596b75e..6c73ffc392da 100644
--- a/tests/xtro-sharpie/xtro-report/xtro-report.csproj
+++ b/tests/xtro-sharpie/xtro-report/xtro-report.csproj
@@ -3,11 +3,7 @@
Exe
net$(BundledNETCoreAppTargetFrameworkVersion)
enable
- enable
false
-
- Nullable
- true
diff --git a/tests/xtro-sharpie/xtro-sanity/xtro-sanity.csproj b/tests/xtro-sharpie/xtro-sanity/xtro-sanity.csproj
index 2a9d8b0f507e..be79a85c1414 100644
--- a/tests/xtro-sharpie/xtro-sanity/xtro-sanity.csproj
+++ b/tests/xtro-sharpie/xtro-sanity/xtro-sanity.csproj
@@ -3,11 +3,7 @@
Exe
net$(BundledNETCoreAppTargetFrameworkVersion)
enable
- enable
false
-
- Nullable
- true
diff --git a/tests/xtro-sharpie/xtro-sharpie/xtro-sharpie.csproj b/tests/xtro-sharpie/xtro-sharpie/xtro-sharpie.csproj
index 46a03e54fe0f..92ce38573813 100644
--- a/tests/xtro-sharpie/xtro-sharpie/xtro-sharpie.csproj
+++ b/tests/xtro-sharpie/xtro-sharpie/xtro-sharpie.csproj
@@ -4,16 +4,11 @@
net$(BundledNETCoreAppTargetFrameworkVersion)
Exe
false
- latest
osx-arm64
false
-
- enable
- Nullable
- true
diff --git a/tools/class-redirector/class-redirector-tests/class-redirector-tests.csproj b/tools/class-redirector/class-redirector-tests/class-redirector-tests.csproj
index acbfba419dfc..fa0748e81827 100644
--- a/tools/class-redirector/class-redirector-tests/class-redirector-tests.csproj
+++ b/tools/class-redirector/class-redirector-tests/class-redirector-tests.csproj
@@ -4,7 +4,6 @@
net7.0
class_redirector_tests
enable
- enable
false
diff --git a/tools/class-redirector/class-redirector/class-redirector.csproj b/tools/class-redirector/class-redirector/class-redirector.csproj
index 93aabb3f2186..7e987df7f028 100644
--- a/tools/class-redirector/class-redirector/class-redirector.csproj
+++ b/tools/class-redirector/class-redirector/class-redirector.csproj
@@ -5,7 +5,6 @@
net7.0
class_redirector
enable
- enable
diff --git a/tools/create-dotnet-linker-launch-json/create-dotnet-linker-launch-json.csproj b/tools/create-dotnet-linker-launch-json/create-dotnet-linker-launch-json.csproj
index 5e249415c463..628dfa2c197c 100644
--- a/tools/create-dotnet-linker-launch-json/create-dotnet-linker-launch-json.csproj
+++ b/tools/create-dotnet-linker-launch-json/create-dotnet-linker-launch-json.csproj
@@ -5,7 +5,6 @@
net$(BundledNETCoreAppTargetFrameworkVersion)
create_dotnet_linker_launch_json
enable
- enable
diff --git a/tools/dotnet-linker/dotnet-linker.csproj b/tools/dotnet-linker/dotnet-linker.csproj
index 5b8b4c66d39e..853bba62528f 100644
--- a/tools/dotnet-linker/dotnet-linker.csproj
+++ b/tools/dotnet-linker/dotnet-linker.csproj
@@ -4,9 +4,7 @@
dotnet_linker
$(DefineConstants);BUNDLER
true
- true
false
- enable
true
$(NoWarn);CS1591
diff --git a/tools/mtouch/mtouch.csproj b/tools/mtouch/mtouch.csproj
index ca0541e4ea60..a11f77fcc353 100644
--- a/tools/mtouch/mtouch.csproj
+++ b/tools/mtouch/mtouch.csproj
@@ -3,8 +3,6 @@
Exe
net$(BundledNETCoreAppTargetFrameworkVersion)
- latest
- enable
false
false
false
@@ -12,7 +10,6 @@
false
LEGACY_TOOLS
true
- true
diff --git a/tools/sharpie/Sharpie.Bind.Tool/Sharpie.Bind.Tool.csproj b/tools/sharpie/Sharpie.Bind.Tool/Sharpie.Bind.Tool.csproj
index c58024873200..27012ed56b62 100644
--- a/tools/sharpie/Sharpie.Bind.Tool/Sharpie.Bind.Tool.csproj
+++ b/tools/sharpie/Sharpie.Bind.Tool/Sharpie.Bind.Tool.csproj
@@ -2,9 +2,7 @@
net$(BundledNETCoreAppTargetFrameworkVersion)
- latest
enable
- enable
Exe
false
diff --git a/tools/sharpie/Sharpie.Bind/Sharpie.Bind.csproj b/tools/sharpie/Sharpie.Bind/Sharpie.Bind.csproj
index d46f1e8c80ce..a6c3b23b957c 100644
--- a/tools/sharpie/Sharpie.Bind/Sharpie.Bind.csproj
+++ b/tools/sharpie/Sharpie.Bind/Sharpie.Bind.csproj
@@ -3,8 +3,6 @@
net$(BundledNETCoreAppTargetFrameworkVersion)
Library
- latest
- enable
$(NETCoreSdkRuntimeIdentifier)
From 8ef0edc851fb3614a1a4fee0b4339a4f0c2ff07c Mon Sep 17 00:00:00 2001
From: VS MobileTools Engineering Service 2
Date: Thu, 7 May 2026 12:42:38 -0700
Subject: [PATCH 031/156] Localized file check-in by OneLocBuild Task: Build
definition ID 14411: Build ID 14038264 (#25361)
This is the pull request automatically created by the OneLocBuild task in the build process to check-in localized files generated based upon translation source files (.lcl files) handed-back from the downstream localization pipeline. If there are issues in translations, visit https://aka.ms/icxLocBug and log bugs for fixes. The OneLocBuild wiki is https://aka.ms/onelocbuild and the localization process in general is documented at https://aka.ms/AllAboutLoc.
From 69aee640a2571bde9ea9485644550d0e9789bb72 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Fri, 8 May 2026 07:22:52 +0200
Subject: [PATCH 032/156] [msbuild] Fix building apps with extensions remotely.
(#23509)
Don't override the GetTargetPath/Build/Rebuild targets for app extensions, because we also override some of these targets when building remotely, and the custom logic for app extensions is overridden.
Instead create new targets that depend on those we previously overrode instead.
Fixes https://github.com/dotnet/macios/issues/23516.
Fixes https://devdiv.visualstudio.com/DevDiv/_workitems/edit/2542958.
---
.../Xamarin.Mac.AppExtension.Common.targets | 11 -----------
msbuild/Xamarin.Shared/Xamarin.Shared.targets | 11 ++++++++---
.../Xamarin.TVOS.AppExtension.Common.targets | 5 -----
.../Xamarin.iOS.AppExtension.Common.targets | 5 -----
msbuild/Xamarin.Shared/Xamarin.iOS.Common.targets | 2 +-
.../Xamarin.Messaging.Apple.targets | 2 +-
tests/dotnet/UnitTests/ProjectTest.cs | 15 ++++++++++++++-
7 files changed, 24 insertions(+), 27 deletions(-)
diff --git a/msbuild/Xamarin.Shared/Xamarin.Mac.AppExtension.Common.targets b/msbuild/Xamarin.Shared/Xamarin.Mac.AppExtension.Common.targets
index 569a2dbac1d9..7e7fb0796862 100644
--- a/msbuild/Xamarin.Shared/Xamarin.Mac.AppExtension.Common.targets
+++ b/msbuild/Xamarin.Shared/Xamarin.Mac.AppExtension.Common.targets
@@ -25,17 +25,6 @@ Copyright (C) 2013-2014 Xamarin. All rights reserved.
-
-
-
-
-
-
-
-
- Entitlements.plist
-
-
diff --git a/msbuild/Xamarin.Shared/Xamarin.Shared.targets b/msbuild/Xamarin.Shared/Xamarin.Shared.targets
index 904b1965ab3b..1c5787205d7e 100644
--- a/msbuild/Xamarin.Shared/Xamarin.Shared.targets
+++ b/msbuild/Xamarin.Shared/Xamarin.Shared.targets
@@ -115,7 +115,7 @@ Copyright (C) 2018 Microsoft. All rights reserved.
- False
+ False
@@ -2676,6 +2676,10 @@ Copyright (C) 2018 Microsoft. All rights reserved.
+
+
+
+
true
-
+
@@ -2736,6 +2740,7 @@ Copyright (C) 2018 Microsoft. All rights reserved.
diff --git a/msbuild/Xamarin.Shared/Xamarin.TVOS.AppExtension.Common.targets b/msbuild/Xamarin.Shared/Xamarin.TVOS.AppExtension.Common.targets
index f2348586feab..78ab53ef731a 100644
--- a/msbuild/Xamarin.Shared/Xamarin.TVOS.AppExtension.Common.targets
+++ b/msbuild/Xamarin.Shared/Xamarin.TVOS.AppExtension.Common.targets
@@ -33,11 +33,6 @@ Copyright (C) 2014-2016 Xamarin. All rights reserved.
-
-
-
-
-
diff --git a/msbuild/Xamarin.Shared/Xamarin.iOS.AppExtension.Common.targets b/msbuild/Xamarin.Shared/Xamarin.iOS.AppExtension.Common.targets
index 2c2584b6b595..67cd4bfe4602 100644
--- a/msbuild/Xamarin.Shared/Xamarin.iOS.AppExtension.Common.targets
+++ b/msbuild/Xamarin.Shared/Xamarin.iOS.AppExtension.Common.targets
@@ -26,11 +26,6 @@ Copyright (C) 2014-2016 Xamarin. All rights reserved.
-
-
-
-
-
diff --git a/msbuild/Xamarin.Shared/Xamarin.iOS.Common.targets b/msbuild/Xamarin.Shared/Xamarin.iOS.Common.targets
index f7686070a0a6..bb7c9955349b 100644
--- a/msbuild/Xamarin.Shared/Xamarin.iOS.Common.targets
+++ b/msbuild/Xamarin.Shared/Xamarin.iOS.Common.targets
@@ -235,7 +235,7 @@ Copyright (C) 2013-2016 Xamarin. All rights reserved.
diff --git a/msbuild/Xamarin.iOS.Tasks.Windows/Xamarin.Messaging.Apple.targets b/msbuild/Xamarin.iOS.Tasks.Windows/Xamarin.Messaging.Apple.targets
index 6e5b721f0aca..38dae88a7f8b 100644
--- a/msbuild/Xamarin.iOS.Tasks.Windows/Xamarin.Messaging.Apple.targets
+++ b/msbuild/Xamarin.iOS.Tasks.Windows/Xamarin.Messaging.Apple.targets
@@ -20,7 +20,7 @@
True
- False
+ False
diff --git a/tests/dotnet/UnitTests/ProjectTest.cs b/tests/dotnet/UnitTests/ProjectTest.cs
index a9ed3fcddbfa..021df8949a06 100644
--- a/tests/dotnet/UnitTests/ProjectTest.cs
+++ b/tests/dotnet/UnitTests/ProjectTest.cs
@@ -1869,6 +1869,19 @@ public void KillEverything ()
[TestCase (ApplePlatform.MacOSX, "osx-x64;osx-arm64", true)]
// [TestCase ("MacCatalyst", "")] - No extension support yet
public void BuildProjectsWithExtensions (ApplePlatform platform, string runtimeIdentifier, bool isNativeAot)
+ {
+ BuildProjectsWithExtensionsImpl (platform, runtimeIdentifier, isNativeAot);
+ }
+
+ [TestCase (ApplePlatform.iOS, "ios-arm64", false)]
+ [Category ("RemoteWindows")]
+ public void BuildProjectsWithExtensionsOnRemoteWindows (ApplePlatform platform, string runtimeIdentifier, bool isNativeAot)
+ {
+ Configuration.IgnoreIfNotOnWindows ();
+ BuildProjectsWithExtensionsImpl (platform, runtimeIdentifier, isNativeAot, AddRemoteProperties ());
+ }
+
+ void BuildProjectsWithExtensionsImpl (ApplePlatform platform, string runtimeIdentifier, bool isNativeAot, Dictionary? properties = null)
{
Configuration.IgnoreIfIgnoredPlatform (platform);
var consumingProjectDir = GetProjectPath ("ExtensionConsumer", runtimeIdentifier, platform, out var appPath);
@@ -1877,7 +1890,7 @@ public void BuildProjectsWithExtensions (ApplePlatform platform, string runtimeI
Clean (extensionProjectDir);
Clean (consumingProjectDir);
- var properties = GetDefaultProperties (runtimeIdentifier);
+ properties = GetDefaultProperties (runtimeIdentifier, extraProperties: properties);
if (isNativeAot) {
properties ["PublishAot"] = "true";
From 0d19b01bcc939557224d5eefc9a8665d52cf50a0 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Mon, 11 May 2026 04:47:30 +0200
Subject: [PATCH 033/156] [github] Fix agentic workflows based on gh-aw guide
(#25364)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
I asked Copilot to review our agentic workflows according to https://github.com/dotnet/vitals/blob/main/.agents/skills/gh-aw-guide/SKILL.md,
and this is what it came up with:
* Fix 'maintainer' → 'maintain' (correct GitHub role name)
* Change min-integrity from 'none' to 'approved' for both workflows (safer default
for public repos, prevents XPIA from untrusted content)
* Add concurrency groups (cancel-in-progress: false for slash_command, true for
schedule/dispatch)
* Add supersede-older-reviews: true on reviewer (auto-dismiss stale REQUEST_CHANGES
reviews)
* Use fuzzy schedule 'daily' instead of fixed cron for code-radiator
* Add target: "*" on add-comment/add-labels for code-radiator (no triggering PR
context on schedule/dispatch)
* Recompile lock files
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
.github/workflows/code-radiator.lock.yml | 48 +++++++++++-----------
.github/workflows/code-radiator.md | 11 +++--
.github/workflows/macios-reviewer.lock.yml | 39 +++++++++---------
.github/workflows/macios-reviewer.md | 8 +++-
4 files changed, 59 insertions(+), 47 deletions(-)
diff --git a/.github/workflows/code-radiator.lock.yml b/.github/workflows/code-radiator.lock.yml
index 7c9e915f63c0..584543578194 100644
--- a/.github/workflows/code-radiator.lock.yml
+++ b/.github/workflows/code-radiator.lock.yml
@@ -1,4 +1,4 @@
-# gh-aw-metadata: {"schema_version":"v3","frontmatter_hash":"76af0f752f9c80c182f233d9269f96cb4486de4da16d47dd58abdbd52c4ef543","compiler_version":"v0.71.5","strict":true,"agent_id":"copilot","agent_model":"claude-sonnet-4.5"}
+# gh-aw-metadata: {"schema_version":"v3","frontmatter_hash":"bf2fb3e7253e90a94c5ce733787030d48f0b569363a045a86099dbafe6742dbf","compiler_version":"v0.71.5","strict":true,"agent_id":"copilot","agent_model":"claude-sonnet-4.5"}
# gh-aw-manifest: {"version":1,"secrets":["COPILOT_GITHUB_TOKEN","GH_AW_CI_TRIGGER_TOKEN","GH_AW_GITHUB_MCP_SERVER_TOKEN","GH_AW_GITHUB_TOKEN","GITHUB_TOKEN"],"actions":[{"repo":"actions/checkout","sha":"de0fac2e4500dabe0009e67214ff5f5447ce83dd","version":"v6.0.2"},{"repo":"actions/download-artifact","sha":"3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c","version":"v8.0.1"},{"repo":"actions/github-script","sha":"3a2844b7e9c422d3c10d287c895573f7108da1b3","version":"v9.0.0"},{"repo":"actions/setup-node","sha":"48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e","version":"v6.4.0"},{"repo":"actions/upload-artifact","sha":"043fb46d1a93c77aae656e7c1c64a875d1fc6a0a","version":"v7.0.1"},{"repo":"github/gh-aw-actions/setup","sha":"b8068426813005612b960b5ab0b8bd2c27142323","version":"v0.71.5"}],"containers":[{"image":"ghcr.io/github/gh-aw-firewall/agent:0.25.40","digest":"sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504","pinned_image":"ghcr.io/github/gh-aw-firewall/agent:0.25.40@sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504"},{"image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40","digest":"sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280","pinned_image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40@sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280"},{"image":"ghcr.io/github/gh-aw-firewall/squid:0.25.40","digest":"sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51","pinned_image":"ghcr.io/github/gh-aw-firewall/squid:0.25.40@sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51"},{"image":"ghcr.io/github/gh-aw-mcpg:v0.3.6","digest":"sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c","pinned_image":"ghcr.io/github/gh-aw-mcpg:v0.3.6@sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c"},{"image":"ghcr.io/github/github-mcp-server:v1.0.3","digest":"sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959","pinned_image":"ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959"},{"image":"node:lts-alpine","digest":"sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f","pinned_image":"node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f"}]}
# ___ _ _
# / _ \ | | (_)
@@ -50,10 +50,11 @@ name: "Code Radiator"
"on":
# roles: # Roles processed as role check in pre-activation job
# - admin # Roles processed as role check in pre-activation job
- # - maintainer # Roles processed as role check in pre-activation job
+ # - maintain # Roles processed as role check in pre-activation job
# - write # Roles processed as role check in pre-activation job
schedule:
- - cron: "0 0 * * *"
+ - cron: "41 19 * * *"
+ # Friendly format: daily (scattered)
workflow_dispatch:
inputs:
aw_context:
@@ -65,7 +66,8 @@ name: "Code Radiator"
permissions: {}
concurrency:
- group: "gh-aw-${{ github.workflow }}"
+ cancel-in-progress: true
+ group: code-radiator-${{ github.ref || github.run_id }}
run-name: "Code Radiator"
@@ -185,24 +187,24 @@ jobs:
run: |
bash "${RUNNER_TEMP}/gh-aw/actions/create_prompt_first.sh"
{
- cat << 'GH_AW_PROMPT_f18a65bced008989_EOF'
+ cat << 'GH_AW_PROMPT_b4389f374632fbe1_EOF'
- GH_AW_PROMPT_f18a65bced008989_EOF
+ GH_AW_PROMPT_b4389f374632fbe1_EOF
cat "${RUNNER_TEMP}/gh-aw/prompts/xpia.md"
cat "${RUNNER_TEMP}/gh-aw/prompts/temp_folder_prompt.md"
cat "${RUNNER_TEMP}/gh-aw/prompts/markdown.md"
cat "${RUNNER_TEMP}/gh-aw/prompts/safe_outputs_prompt.md"
- cat << 'GH_AW_PROMPT_f18a65bced008989_EOF'
+ cat << 'GH_AW_PROMPT_b4389f374632fbe1_EOF'
Tools: add_comment(max:10), create_pull_request(max:10), update_pull_request(max:10), add_labels(max:10), push_to_pull_request_branch(max:10), missing_tool, missing_data, noop
- GH_AW_PROMPT_f18a65bced008989_EOF
+ GH_AW_PROMPT_b4389f374632fbe1_EOF
cat "${RUNNER_TEMP}/gh-aw/prompts/safe_outputs_create_pull_request.md"
cat "${RUNNER_TEMP}/gh-aw/prompts/safe_outputs_push_to_pr_branch.md"
- cat << 'GH_AW_PROMPT_f18a65bced008989_EOF'
+ cat << 'GH_AW_PROMPT_b4389f374632fbe1_EOF'
- GH_AW_PROMPT_f18a65bced008989_EOF
+ GH_AW_PROMPT_b4389f374632fbe1_EOF
cat "${RUNNER_TEMP}/gh-aw/prompts/mcp_cli_tools_prompt.md"
- cat << 'GH_AW_PROMPT_f18a65bced008989_EOF'
+ cat << 'GH_AW_PROMPT_b4389f374632fbe1_EOF'
The following GitHub context information is available for this workflow:
{{#if __GH_AW_GITHUB_ACTOR__ }}
@@ -231,12 +233,12 @@ jobs:
{{/if}}
- GH_AW_PROMPT_f18a65bced008989_EOF
+ GH_AW_PROMPT_b4389f374632fbe1_EOF
cat "${RUNNER_TEMP}/gh-aw/prompts/github_mcp_tools_with_safeoutputs_prompt.md"
- cat << 'GH_AW_PROMPT_f18a65bced008989_EOF'
+ cat << 'GH_AW_PROMPT_b4389f374632fbe1_EOF'
{{#runtime-import .github/workflows/code-radiator.md}}
- GH_AW_PROMPT_f18a65bced008989_EOF
+ GH_AW_PROMPT_b4389f374632fbe1_EOF
} > "$GH_AW_PROMPT"
- name: Interpolate variables and render templates
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
@@ -423,16 +425,16 @@ jobs:
mkdir -p "${RUNNER_TEMP}/gh-aw/safeoutputs"
mkdir -p /tmp/gh-aw/safeoutputs
mkdir -p /tmp/gh-aw/mcp-logs/safeoutputs
- cat > "${RUNNER_TEMP}/gh-aw/safeoutputs/config.json" << 'GH_AW_SAFE_OUTPUTS_CONFIG_67dd340333ff2a92_EOF'
- {"add_comment":{"max":10},"add_labels":{"max":10},"create_pull_request":{"max":10,"max_patch_files":100,"max_patch_size":1024,"protect_top_level_dot_folders":true,"protected_files":["package.json","bun.lockb","bunfig.toml","deno.json","deno.jsonc","deno.lock","global.json","NuGet.Config","Directory.Packages.props","mix.exs","mix.lock","go.mod","go.sum","stack.yaml","stack.yaml.lock","pom.xml","build.gradle","build.gradle.kts","settings.gradle","settings.gradle.kts","gradle.properties","package-lock.json","yarn.lock","pnpm-lock.yaml","npm-shrinkwrap.json","requirements.txt","Pipfile","Pipfile.lock","pyproject.toml","setup.py","setup.cfg","Gemfile","Gemfile.lock","uv.lock","CODEOWNERS","DESIGN.md","README.md","CONTRIBUTING.md","CHANGELOG.md","SECURITY.md","CODE_OF_CONDUCT.md","AGENTS.md","CLAUDE.md","GEMINI.md"]},"create_report_incomplete_issue":{},"merge_pull_request":{"max":10},"missing_data":{},"missing_tool":{},"noop":{"max":1,"report-as-issue":"true"},"push_to_pull_request_branch":{"if_no_changes":"warn","max":10,"max_patch_size":1024,"protect_top_level_dot_folders":true,"protected_files":["package.json","bun.lockb","bunfig.toml","deno.json","deno.jsonc","deno.lock","global.json","NuGet.Config","Directory.Packages.props","mix.exs","mix.lock","go.mod","go.sum","stack.yaml","stack.yaml.lock","pom.xml","build.gradle","build.gradle.kts","settings.gradle","settings.gradle.kts","gradle.properties","package-lock.json","yarn.lock","pnpm-lock.yaml","npm-shrinkwrap.json","requirements.txt","Pipfile","Pipfile.lock","pyproject.toml","setup.py","setup.cfg","Gemfile","Gemfile.lock","uv.lock","CODEOWNERS","DESIGN.md","README.md","CONTRIBUTING.md","CHANGELOG.md","SECURITY.md","CODE_OF_CONDUCT.md","AGENTS.md","CLAUDE.md","GEMINI.md"]},"report_incomplete":{},"update_pull_request":{"allow_body":true,"allow_title":true,"max":10,"update_branch":false}}
- GH_AW_SAFE_OUTPUTS_CONFIG_67dd340333ff2a92_EOF
+ cat > "${RUNNER_TEMP}/gh-aw/safeoutputs/config.json" << 'GH_AW_SAFE_OUTPUTS_CONFIG_cb1262517960b8af_EOF'
+ {"add_comment":{"max":10,"target":"*"},"add_labels":{"max":10,"target":"*"},"create_pull_request":{"max":10,"max_patch_files":100,"max_patch_size":1024,"protect_top_level_dot_folders":true,"protected_files":["package.json","bun.lockb","bunfig.toml","deno.json","deno.jsonc","deno.lock","global.json","NuGet.Config","Directory.Packages.props","mix.exs","mix.lock","go.mod","go.sum","stack.yaml","stack.yaml.lock","pom.xml","build.gradle","build.gradle.kts","settings.gradle","settings.gradle.kts","gradle.properties","package-lock.json","yarn.lock","pnpm-lock.yaml","npm-shrinkwrap.json","requirements.txt","Pipfile","Pipfile.lock","pyproject.toml","setup.py","setup.cfg","Gemfile","Gemfile.lock","uv.lock","CODEOWNERS","DESIGN.md","README.md","CONTRIBUTING.md","CHANGELOG.md","SECURITY.md","CODE_OF_CONDUCT.md","AGENTS.md","CLAUDE.md","GEMINI.md"]},"create_report_incomplete_issue":{},"merge_pull_request":{"max":10},"missing_data":{},"missing_tool":{},"noop":{"max":1,"report-as-issue":"true"},"push_to_pull_request_branch":{"if_no_changes":"warn","max":10,"max_patch_size":1024,"protect_top_level_dot_folders":true,"protected_files":["package.json","bun.lockb","bunfig.toml","deno.json","deno.jsonc","deno.lock","global.json","NuGet.Config","Directory.Packages.props","mix.exs","mix.lock","go.mod","go.sum","stack.yaml","stack.yaml.lock","pom.xml","build.gradle","build.gradle.kts","settings.gradle","settings.gradle.kts","gradle.properties","package-lock.json","yarn.lock","pnpm-lock.yaml","npm-shrinkwrap.json","requirements.txt","Pipfile","Pipfile.lock","pyproject.toml","setup.py","setup.cfg","Gemfile","Gemfile.lock","uv.lock","CODEOWNERS","DESIGN.md","README.md","CONTRIBUTING.md","CHANGELOG.md","SECURITY.md","CODE_OF_CONDUCT.md","AGENTS.md","CLAUDE.md","GEMINI.md"]},"report_incomplete":{},"update_pull_request":{"allow_body":true,"allow_title":true,"max":10,"update_branch":false}}
+ GH_AW_SAFE_OUTPUTS_CONFIG_cb1262517960b8af_EOF
- name: Generate Safe Outputs Tools
env:
GH_AW_TOOLS_META_JSON: |
{
"description_suffixes": {
- "add_comment": " CONSTRAINTS: Maximum 10 comment(s) can be added. Supports reply_to_id for discussion threading.",
- "add_labels": " CONSTRAINTS: Maximum 10 label(s) can be added.",
+ "add_comment": " CONSTRAINTS: Maximum 10 comment(s) can be added. Target: *. Supports reply_to_id for discussion threading.",
+ "add_labels": " CONSTRAINTS: Maximum 10 label(s) can be added. Target: *.",
"create_pull_request": " CONSTRAINTS: Maximum 10 pull request(s) can be created.",
"push_to_pull_request_branch": " CONSTRAINTS: Maximum 10 push(es) can be made.",
"update_pull_request": " CONSTRAINTS: Maximum 10 pull request(s) can be updated."
@@ -763,7 +765,7 @@ jobs:
mkdir -p /home/runner/.copilot
GH_AW_NODE=$(which node 2>/dev/null || command -v node 2>/dev/null || echo node)
- cat << GH_AW_MCP_CONFIG_1fe8f1e7abc04440_EOF | "$GH_AW_NODE" "${RUNNER_TEMP}/gh-aw/actions/start_mcp_gateway.cjs"
+ cat << GH_AW_MCP_CONFIG_30c0410028d42347_EOF | "$GH_AW_NODE" "${RUNNER_TEMP}/gh-aw/actions/start_mcp_gateway.cjs"
{
"mcpServers": {
"github": {
@@ -779,7 +781,7 @@ jobs:
"allow-only": {
"approval-labels": ${{ steps.parse-guard-vars.outputs.approval_labels }},
"blocked-users": ${{ steps.parse-guard-vars.outputs.blocked_users }},
- "min-integrity": "none",
+ "min-integrity": "approved",
"repos": "all",
"trusted-users": ${{ steps.parse-guard-vars.outputs.trusted_users }}
}
@@ -807,7 +809,7 @@ jobs:
"payloadDir": "${MCP_GATEWAY_PAYLOAD_DIR}"
}
}
- GH_AW_MCP_CONFIG_1fe8f1e7abc04440_EOF
+ GH_AW_MCP_CONFIG_30c0410028d42347_EOF
- name: Mount MCP servers as CLIs
id: mount-mcp-clis
continue-on-error: true
@@ -1470,7 +1472,7 @@ jobs:
GH_AW_ALLOWED_DOMAINS: "*.githubusercontent.com,api.business.githubcopilot.com,api.enterprise.githubcopilot.com,api.github.com,api.githubcopilot.com,api.individual.githubcopilot.com,api.snapcraft.io,archive.ubuntu.com,azure.archive.ubuntu.com,codeload.github.com,crl.geotrust.com,crl.globalsign.com,crl.identrust.com,crl.sectigo.com,crl.thawte.com,crl.usertrust.com,crl.verisign.com,crl3.digicert.com,crl4.digicert.com,crls.ssl.com,docs.github.com,github-cloud.githubusercontent.com,github-cloud.s3.amazonaws.com,github.blog,github.com,github.githubassets.com,host.docker.internal,json-schema.org,json.schemastore.org,keyserver.ubuntu.com,lfs.github.com,objects.githubusercontent.com,ocsp.digicert.com,ocsp.geotrust.com,ocsp.globalsign.com,ocsp.identrust.com,ocsp.sectigo.com,ocsp.ssl.com,ocsp.thawte.com,ocsp.usertrust.com,ocsp.verisign.com,packagecloud.io,packages.cloud.google.com,packages.microsoft.com,ppa.launchpad.net,raw.githubusercontent.com,registry.npmjs.org,s.symcb.com,s.symcd.com,security.ubuntu.com,telemetry.enterprise.githubcopilot.com,ts-crl.ws.symantec.com,ts-ocsp.ws.symantec.com,www.googleapis.com"
GITHUB_SERVER_URL: ${{ github.server_url }}
GITHUB_API_URL: ${{ github.api_url }}
- GH_AW_SAFE_OUTPUTS_HANDLER_CONFIG: "{\"add_comment\":{\"max\":10},\"add_labels\":{\"max\":10},\"create_pull_request\":{\"max\":10,\"max_patch_files\":100,\"max_patch_size\":1024,\"protect_top_level_dot_folders\":true,\"protected_files\":[\"package.json\",\"bun.lockb\",\"bunfig.toml\",\"deno.json\",\"deno.jsonc\",\"deno.lock\",\"global.json\",\"NuGet.Config\",\"Directory.Packages.props\",\"mix.exs\",\"mix.lock\",\"go.mod\",\"go.sum\",\"stack.yaml\",\"stack.yaml.lock\",\"pom.xml\",\"build.gradle\",\"build.gradle.kts\",\"settings.gradle\",\"settings.gradle.kts\",\"gradle.properties\",\"package-lock.json\",\"yarn.lock\",\"pnpm-lock.yaml\",\"npm-shrinkwrap.json\",\"requirements.txt\",\"Pipfile\",\"Pipfile.lock\",\"pyproject.toml\",\"setup.py\",\"setup.cfg\",\"Gemfile\",\"Gemfile.lock\",\"uv.lock\",\"CODEOWNERS\",\"DESIGN.md\",\"README.md\",\"CONTRIBUTING.md\",\"CHANGELOG.md\",\"SECURITY.md\",\"CODE_OF_CONDUCT.md\",\"AGENTS.md\",\"CLAUDE.md\",\"GEMINI.md\"]},\"create_report_incomplete_issue\":{},\"merge_pull_request\":{\"max\":10},\"missing_data\":{},\"missing_tool\":{},\"noop\":{\"max\":1,\"report-as-issue\":\"true\"},\"push_to_pull_request_branch\":{\"if_no_changes\":\"warn\",\"max\":10,\"max_patch_size\":1024,\"protect_top_level_dot_folders\":true,\"protected_files\":[\"package.json\",\"bun.lockb\",\"bunfig.toml\",\"deno.json\",\"deno.jsonc\",\"deno.lock\",\"global.json\",\"NuGet.Config\",\"Directory.Packages.props\",\"mix.exs\",\"mix.lock\",\"go.mod\",\"go.sum\",\"stack.yaml\",\"stack.yaml.lock\",\"pom.xml\",\"build.gradle\",\"build.gradle.kts\",\"settings.gradle\",\"settings.gradle.kts\",\"gradle.properties\",\"package-lock.json\",\"yarn.lock\",\"pnpm-lock.yaml\",\"npm-shrinkwrap.json\",\"requirements.txt\",\"Pipfile\",\"Pipfile.lock\",\"pyproject.toml\",\"setup.py\",\"setup.cfg\",\"Gemfile\",\"Gemfile.lock\",\"uv.lock\",\"CODEOWNERS\",\"DESIGN.md\",\"README.md\",\"CONTRIBUTING.md\",\"CHANGELOG.md\",\"SECURITY.md\",\"CODE_OF_CONDUCT.md\",\"AGENTS.md\",\"CLAUDE.md\",\"GEMINI.md\"]},\"report_incomplete\":{},\"update_pull_request\":{\"allow_body\":true,\"allow_title\":true,\"max\":10,\"update_branch\":false}}"
+ GH_AW_SAFE_OUTPUTS_HANDLER_CONFIG: "{\"add_comment\":{\"max\":10,\"target\":\"*\"},\"add_labels\":{\"max\":10,\"target\":\"*\"},\"create_pull_request\":{\"max\":10,\"max_patch_files\":100,\"max_patch_size\":1024,\"protect_top_level_dot_folders\":true,\"protected_files\":[\"package.json\",\"bun.lockb\",\"bunfig.toml\",\"deno.json\",\"deno.jsonc\",\"deno.lock\",\"global.json\",\"NuGet.Config\",\"Directory.Packages.props\",\"mix.exs\",\"mix.lock\",\"go.mod\",\"go.sum\",\"stack.yaml\",\"stack.yaml.lock\",\"pom.xml\",\"build.gradle\",\"build.gradle.kts\",\"settings.gradle\",\"settings.gradle.kts\",\"gradle.properties\",\"package-lock.json\",\"yarn.lock\",\"pnpm-lock.yaml\",\"npm-shrinkwrap.json\",\"requirements.txt\",\"Pipfile\",\"Pipfile.lock\",\"pyproject.toml\",\"setup.py\",\"setup.cfg\",\"Gemfile\",\"Gemfile.lock\",\"uv.lock\",\"CODEOWNERS\",\"DESIGN.md\",\"README.md\",\"CONTRIBUTING.md\",\"CHANGELOG.md\",\"SECURITY.md\",\"CODE_OF_CONDUCT.md\",\"AGENTS.md\",\"CLAUDE.md\",\"GEMINI.md\"]},\"create_report_incomplete_issue\":{},\"merge_pull_request\":{\"max\":10},\"missing_data\":{},\"missing_tool\":{},\"noop\":{\"max\":1,\"report-as-issue\":\"true\"},\"push_to_pull_request_branch\":{\"if_no_changes\":\"warn\",\"max\":10,\"max_patch_size\":1024,\"protect_top_level_dot_folders\":true,\"protected_files\":[\"package.json\",\"bun.lockb\",\"bunfig.toml\",\"deno.json\",\"deno.jsonc\",\"deno.lock\",\"global.json\",\"NuGet.Config\",\"Directory.Packages.props\",\"mix.exs\",\"mix.lock\",\"go.mod\",\"go.sum\",\"stack.yaml\",\"stack.yaml.lock\",\"pom.xml\",\"build.gradle\",\"build.gradle.kts\",\"settings.gradle\",\"settings.gradle.kts\",\"gradle.properties\",\"package-lock.json\",\"yarn.lock\",\"pnpm-lock.yaml\",\"npm-shrinkwrap.json\",\"requirements.txt\",\"Pipfile\",\"Pipfile.lock\",\"pyproject.toml\",\"setup.py\",\"setup.cfg\",\"Gemfile\",\"Gemfile.lock\",\"uv.lock\",\"CODEOWNERS\",\"DESIGN.md\",\"README.md\",\"CONTRIBUTING.md\",\"CHANGELOG.md\",\"SECURITY.md\",\"CODE_OF_CONDUCT.md\",\"AGENTS.md\",\"CLAUDE.md\",\"GEMINI.md\"]},\"report_incomplete\":{},\"update_pull_request\":{\"allow_body\":true,\"allow_title\":true,\"max\":10,\"update_branch\":false}}"
GH_AW_CI_TRIGGER_TOKEN: ${{ secrets.GH_AW_CI_TRIGGER_TOKEN }}
with:
github-token: ${{ secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
diff --git a/.github/workflows/code-radiator.md b/.github/workflows/code-radiator.md
index 88ef05a185d5..64c78bc90562 100644
--- a/.github/workflows/code-radiator.md
+++ b/.github/workflows/code-radiator.md
@@ -1,8 +1,11 @@
---
on:
- schedule: "0 0 * * *"
+ schedule: daily
workflow_dispatch:
- roles: [admin, maintainer, write]
+ roles: [admin, maintain, write]
+concurrency:
+ group: "code-radiator-${{ github.ref || github.run_id }}"
+ cancel-in-progress: true
permissions:
contents: read
pull-requests: read
@@ -16,15 +19,17 @@ network:
tools:
github:
toolsets: [pull_requests, repos]
- min-integrity: none
+ min-integrity: approved
bash: true
safe-outputs:
create-pull-request:
max: 10
add-comment:
max: 10
+ target: "*"
add-labels:
max: 10
+ target: "*"
merge-pull-request:
max: 10
push-to-pull-request-branch:
diff --git a/.github/workflows/macios-reviewer.lock.yml b/.github/workflows/macios-reviewer.lock.yml
index 9f23069944af..716dd4acf735 100644
--- a/.github/workflows/macios-reviewer.lock.yml
+++ b/.github/workflows/macios-reviewer.lock.yml
@@ -1,4 +1,4 @@
-# gh-aw-metadata: {"schema_version":"v3","frontmatter_hash":"a4ffe1d52364aca7fafba9ba975ec40a3f4fc4908801119268fc1812f9b09cbe","compiler_version":"v0.71.5","strict":true,"agent_id":"copilot","agent_model":"claude-sonnet-4.5"}
+# gh-aw-metadata: {"schema_version":"v3","frontmatter_hash":"a0f64139dbc6fe8697f9fd99f5489155b561c37ec0b13d7eaf30bda56d034e7f","compiler_version":"v0.71.5","strict":true,"agent_id":"copilot","agent_model":"claude-sonnet-4.5"}
# gh-aw-manifest: {"version":1,"secrets":["COPILOT_GITHUB_TOKEN","GH_AW_GITHUB_MCP_SERVER_TOKEN","GH_AW_GITHUB_TOKEN","GITHUB_TOKEN"],"actions":[{"repo":"actions/checkout","sha":"de0fac2e4500dabe0009e67214ff5f5447ce83dd","version":"v6.0.2"},{"repo":"actions/download-artifact","sha":"3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c","version":"v8.0.1"},{"repo":"actions/github-script","sha":"3a2844b7e9c422d3c10d287c895573f7108da1b3","version":"v9.0.0"},{"repo":"actions/setup-node","sha":"48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e","version":"v6.4.0"},{"repo":"actions/upload-artifact","sha":"043fb46d1a93c77aae656e7c1c64a875d1fc6a0a","version":"v7.0.1"},{"repo":"github/gh-aw-actions/setup","sha":"b8068426813005612b960b5ab0b8bd2c27142323","version":"v0.71.5"}],"containers":[{"image":"ghcr.io/github/gh-aw-firewall/agent:0.25.40","digest":"sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504","pinned_image":"ghcr.io/github/gh-aw-firewall/agent:0.25.40@sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504"},{"image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40","digest":"sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280","pinned_image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40@sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280"},{"image":"ghcr.io/github/gh-aw-firewall/squid:0.25.40","digest":"sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51","pinned_image":"ghcr.io/github/gh-aw-firewall/squid:0.25.40@sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51"},{"image":"ghcr.io/github/gh-aw-mcpg:v0.3.6","digest":"sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c","pinned_image":"ghcr.io/github/gh-aw-mcpg:v0.3.6@sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c"},{"image":"ghcr.io/github/github-mcp-server:v1.0.3","digest":"sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959","pinned_image":"ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959"},{"image":"node:lts-alpine","digest":"sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f","pinned_image":"node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f"}]}
# ___ _ _
# / _ \ | | (_)
@@ -53,13 +53,14 @@ name: ".NET for Apple Platforms PR Reviewer"
- edited
# roles: # Roles processed as role check in pre-activation job
# - admin # Roles processed as role check in pre-activation job
- # - maintainer # Roles processed as role check in pre-activation job
+ # - maintain # Roles processed as role check in pre-activation job
# - write # Roles processed as role check in pre-activation job
permissions: {}
concurrency:
- group: "gh-aw-${{ github.workflow }}-${{ github.event.issue.number || github.event.pull_request.number || github.run_id }}"
+ cancel-in-progress: false
+ group: macios-reviewer-${{ github.event.issue.number || github.event.pull_request.number || github.run_id }}
run-name: ".NET for Apple Platforms PR Reviewer"
@@ -226,20 +227,20 @@ jobs:
run: |
bash "${RUNNER_TEMP}/gh-aw/actions/create_prompt_first.sh"
{
- cat << 'GH_AW_PROMPT_31522cd090dd3137_EOF'
+ cat << 'GH_AW_PROMPT_33adc77fba6f068a_EOF'
- GH_AW_PROMPT_31522cd090dd3137_EOF
+ GH_AW_PROMPT_33adc77fba6f068a_EOF
cat "${RUNNER_TEMP}/gh-aw/prompts/xpia.md"
cat "${RUNNER_TEMP}/gh-aw/prompts/temp_folder_prompt.md"
cat "${RUNNER_TEMP}/gh-aw/prompts/markdown.md"
cat "${RUNNER_TEMP}/gh-aw/prompts/safe_outputs_prompt.md"
- cat << 'GH_AW_PROMPT_31522cd090dd3137_EOF'
+ cat << 'GH_AW_PROMPT_33adc77fba6f068a_EOF'
Tools: create_pull_request_review_comment(max:50), submit_pull_request_review, missing_tool, missing_data, noop
- GH_AW_PROMPT_31522cd090dd3137_EOF
+ GH_AW_PROMPT_33adc77fba6f068a_EOF
cat "${RUNNER_TEMP}/gh-aw/prompts/mcp_cli_tools_prompt.md"
- cat << 'GH_AW_PROMPT_31522cd090dd3137_EOF'
+ cat << 'GH_AW_PROMPT_33adc77fba6f068a_EOF'
The following GitHub context information is available for this workflow:
{{#if __GH_AW_GITHUB_ACTOR__ }}
@@ -268,15 +269,15 @@ jobs:
{{/if}}
- GH_AW_PROMPT_31522cd090dd3137_EOF
+ GH_AW_PROMPT_33adc77fba6f068a_EOF
cat "${RUNNER_TEMP}/gh-aw/prompts/github_mcp_tools_with_safeoutputs_prompt.md"
if [ "$GITHUB_EVENT_NAME" = "issue_comment" ] && [ -n "$GH_AW_IS_PR_COMMENT" ] || [ "$GITHUB_EVENT_NAME" = "pull_request_review_comment" ] || [ "$GITHUB_EVENT_NAME" = "pull_request_review" ]; then
cat "${RUNNER_TEMP}/gh-aw/prompts/pr_context_prompt.md"
fi
- cat << 'GH_AW_PROMPT_31522cd090dd3137_EOF'
+ cat << 'GH_AW_PROMPT_33adc77fba6f068a_EOF'
{{#runtime-import .github/workflows/macios-reviewer.md}}
- GH_AW_PROMPT_31522cd090dd3137_EOF
+ GH_AW_PROMPT_33adc77fba6f068a_EOF
} > "$GH_AW_PROMPT"
- name: Interpolate variables and render templates
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
@@ -467,9 +468,9 @@ jobs:
mkdir -p "${RUNNER_TEMP}/gh-aw/safeoutputs"
mkdir -p /tmp/gh-aw/safeoutputs
mkdir -p /tmp/gh-aw/mcp-logs/safeoutputs
- cat > "${RUNNER_TEMP}/gh-aw/safeoutputs/config.json" << 'GH_AW_SAFE_OUTPUTS_CONFIG_89a2d4b9522a1c3e_EOF'
- {"create_pull_request_review_comment":{"max":50,"side":"RIGHT"},"create_report_incomplete_issue":{},"missing_data":{},"missing_tool":{},"noop":{"max":1,"report-as-issue":"true"},"report_incomplete":{},"submit_pull_request_review":{"allowed_events":["COMMENT","REQUEST_CHANGES"],"max":1}}
- GH_AW_SAFE_OUTPUTS_CONFIG_89a2d4b9522a1c3e_EOF
+ cat > "${RUNNER_TEMP}/gh-aw/safeoutputs/config.json" << 'GH_AW_SAFE_OUTPUTS_CONFIG_df05992f6de27b87_EOF'
+ {"create_pull_request_review_comment":{"max":50,"side":"RIGHT"},"create_report_incomplete_issue":{},"missing_data":{},"missing_tool":{},"noop":{"max":1,"report-as-issue":"true"},"report_incomplete":{},"submit_pull_request_review":{"allowed_events":["COMMENT","REQUEST_CHANGES"],"max":1,"supersede_older_reviews":true}}
+ GH_AW_SAFE_OUTPUTS_CONFIG_df05992f6de27b87_EOF
- name: Generate Safe Outputs Tools
env:
GH_AW_TOOLS_META_JSON: |
@@ -690,7 +691,7 @@ jobs:
mkdir -p /home/runner/.copilot
GH_AW_NODE=$(which node 2>/dev/null || command -v node 2>/dev/null || echo node)
- cat << GH_AW_MCP_CONFIG_8d4f4bdb31699167_EOF | "$GH_AW_NODE" "${RUNNER_TEMP}/gh-aw/actions/start_mcp_gateway.cjs"
+ cat << GH_AW_MCP_CONFIG_3ee2b0f26b6b2009_EOF | "$GH_AW_NODE" "${RUNNER_TEMP}/gh-aw/actions/start_mcp_gateway.cjs"
{
"mcpServers": {
"github": {
@@ -706,7 +707,7 @@ jobs:
"allow-only": {
"approval-labels": ${{ steps.parse-guard-vars.outputs.approval_labels }},
"blocked-users": ${{ steps.parse-guard-vars.outputs.blocked_users }},
- "min-integrity": "none",
+ "min-integrity": "approved",
"repos": "all",
"trusted-users": ${{ steps.parse-guard-vars.outputs.trusted_users }}
}
@@ -734,7 +735,7 @@ jobs:
"payloadDir": "${MCP_GATEWAY_PAYLOAD_DIR}"
}
}
- GH_AW_MCP_CONFIG_8d4f4bdb31699167_EOF
+ GH_AW_MCP_CONFIG_3ee2b0f26b6b2009_EOF
- name: Mount MCP servers as CLIs
id: mount-mcp-clis
continue-on-error: true
@@ -1328,7 +1329,7 @@ jobs:
id: check_membership
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
- GH_AW_REQUIRED_ROLES: "admin,maintainer,write"
+ GH_AW_REQUIRED_ROLES: "admin,maintain,write"
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
@@ -1419,7 +1420,7 @@ jobs:
GH_AW_ALLOWED_DOMAINS: "*.githubusercontent.com,*.vsblob.vsassets.io,aka.ms,api.business.githubcopilot.com,api.enterprise.githubcopilot.com,api.github.com,api.githubcopilot.com,api.individual.githubcopilot.com,api.nuget.org,api.snapcraft.io,archive.ubuntu.com,azure.archive.ubuntu.com,azuresearch-usnc.nuget.org,azuresearch-ussc.nuget.org,builds.dotnet.microsoft.com,ci.dot.net,codeload.github.com,crl.geotrust.com,crl.globalsign.com,crl.identrust.com,crl.sectigo.com,crl.thawte.com,crl.usertrust.com,crl.verisign.com,crl3.digicert.com,crl4.digicert.com,crls.ssl.com,dc.services.visualstudio.com,dev.azure.com,dist.nuget.org,docs.github.com,dot.net,dotnet.microsoft.com,dotnetcli.blob.core.windows.net,github-cloud.githubusercontent.com,github-cloud.s3.amazonaws.com,github.blog,github.com,github.githubassets.com,host.docker.internal,json-schema.org,json.schemastore.org,keyserver.ubuntu.com,lfs.github.com,microsoft.com,nuget.org,nuget.pkg.github.com,nugetregistryv2prod.blob.core.windows.net,objects.githubusercontent.com,ocsp.digicert.com,ocsp.geotrust.com,ocsp.globalsign.com,ocsp.identrust.com,ocsp.sectigo.com,ocsp.ssl.com,ocsp.thawte.com,ocsp.usertrust.com,ocsp.verisign.com,oneocsp.microsoft.com,packagecloud.io,packages.cloud.google.com,packages.microsoft.com,pkgs.dev.azure.com,ppa.launchpad.net,raw.githubusercontent.com,registry.npmjs.org,s.symcb.com,s.symcd.com,security.ubuntu.com,telemetry.enterprise.githubcopilot.com,ts-crl.ws.symantec.com,ts-ocsp.ws.symantec.com,vsassets.io,www.googleapis.com,www.microsoft.com"
GITHUB_SERVER_URL: ${{ github.server_url }}
GITHUB_API_URL: ${{ github.api_url }}
- GH_AW_SAFE_OUTPUTS_HANDLER_CONFIG: "{\"create_pull_request_review_comment\":{\"max\":50,\"side\":\"RIGHT\"},\"create_report_incomplete_issue\":{},\"missing_data\":{},\"missing_tool\":{},\"noop\":{\"max\":1,\"report-as-issue\":\"true\"},\"report_incomplete\":{},\"submit_pull_request_review\":{\"allowed_events\":[\"COMMENT\",\"REQUEST_CHANGES\"],\"max\":1}}"
+ GH_AW_SAFE_OUTPUTS_HANDLER_CONFIG: "{\"create_pull_request_review_comment\":{\"max\":50,\"side\":\"RIGHT\"},\"create_report_incomplete_issue\":{},\"missing_data\":{},\"missing_tool\":{},\"noop\":{\"max\":1,\"report-as-issue\":\"true\"},\"report_incomplete\":{},\"submit_pull_request_review\":{\"allowed_events\":[\"COMMENT\",\"REQUEST_CHANGES\"],\"max\":1,\"supersede_older_reviews\":true}}"
with:
github-token: ${{ secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
script: |
diff --git a/.github/workflows/macios-reviewer.md b/.github/workflows/macios-reviewer.md
index 10fe33bae503..285343536d0c 100644
--- a/.github/workflows/macios-reviewer.md
+++ b/.github/workflows/macios-reviewer.md
@@ -3,7 +3,10 @@ on:
slash_command:
name: review
events: [pull_request_comment]
- roles: [admin, maintainer, write]
+ roles: [admin, maintain, write]
+concurrency:
+ group: "macios-reviewer-${{ github.event.issue.number || github.event.pull_request.number || github.run_id }}"
+ cancel-in-progress: false
permissions:
contents: read
pull-requests: read
@@ -22,13 +25,14 @@ network:
tools:
github:
toolsets: [pull_requests, repos]
- min-integrity: none
+ min-integrity: approved
safe-outputs:
create-pull-request-review-comment:
max: 50
submit-pull-request-review:
max: 1
allowed-events: [COMMENT, REQUEST_CHANGES]
+ supersede-older-reviews: true
---
# .NET for Apple Platforms PR Reviewer
From 36d0c31171a339f8a0f262a14d2be8c4cc456416 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Mon, 11 May 2026 04:48:22 +0200
Subject: [PATCH 034/156] [docs] Improve docs on updating API docs. (#25366)
---
docs/ReleaseCheckList.md | 5 +++++
docs/update-api-docs.md | 2 +-
2 files changed, 6 insertions(+), 1 deletion(-)
diff --git a/docs/ReleaseCheckList.md b/docs/ReleaseCheckList.md
index 3f0cc42dc66d..84e9a672070f 100644
--- a/docs/ReleaseCheckList.md
+++ b/docs/ReleaseCheckList.md
@@ -65,8 +65,13 @@ This happens after the stable version of Xcode has been released and the `xcodeX
* [ ] Publish NuGets to nuget.org.
* [ ] Publish release notes.
* [ ] Update API diff (the `STABLE_NUGET_VERSION_*` variables in `Make.config`) for the `main` branch. Can only be done after the NuGets have been published to nuget.org.
+ * [ ] Link to PR
* [ ] Update docs by executing `docs/sync-mobile-docs.sh`. Beware if docs were modified in the [docs-mobile](https://github.com/dotnet/docs-mobile) repository by somebody else, any such changes will have to be copied back first.
+ * [ ] Link to dotnet/docs-mobile PR
* [ ] Update API / reference docs. See [update-api-docs.md](https://github.com/dotnet/macios/blob/main/docs/update-api-docs.md) for instructions.
+ * [ ] Create new monikers (add link to dev.azure.com ticket)
+ * [ ] Add reference docs (add link to dotnet/macios-api-docs PR)
+ * [ ] Flip the monikers from prerelease to live (add link to dev.azure.com ticket)
* [ ] Make sure all items in the milestone for the current release have been closed.
* [ ] Close this issue & close the milestone.
* [ ] Wonder about life as you consider the impossibility of actually reaching this point, because you can't close the milestone before all issues have been closed, and you can't close this issue until checking off all items, which you can't do until you've closed the milestone. Decide to schedule yet another viewing of [Life of Brian](https://en.wikipedia.org/wiki/Monty_Python%27s_Life_of_Brian) to ~cope~ celebrate the release 🍾.
diff --git a/docs/update-api-docs.md b/docs/update-api-docs.md
index b6260c476986..58903732193a 100644
--- a/docs/update-api-docs.md
+++ b/docs/update-api-docs.md
@@ -49,7 +49,7 @@ The steps are:
7. Create a pull request in the [binaries](https://apidrop.visualstudio.com/_git/binaries) repository for the `netX.Y-xcodeZ.W` we created with the new assemblies (into the `master` branch).
-8. The final step is to flip the monikers from prerelease to live monikers (another ticket has to be created for this).
+8. The final step is to flip the monikers from prerelease to live monikers (another ticket has to be created for this). Sample ticket: [#540739](https://dev.azure.com/msft-skilling/Content/_workitems/edit/540739).
## How to create new monikers
From 019400005bdeb0e8e969d0ad27e33eb212ed3e78 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Mon, 11 May 2026 08:46:20 +0200
Subject: [PATCH 035/156] [src] Add [Un]SupportedSimulator attributes. (#25347)
Add two attributes to specify whether an API is available in the simulator:
* [UnsupportedSimulator ("")]: API is not available.
* [SupportedSimulator ("[osversion]")]: API is available, optionally
only in the specified OS version or not.
If no attribute is found, then the API is available in the simulator.
Unlike the normal availability attributes, specifying simulator availability for
one platform does not mean anything for any other platforms.
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
src/MLCompute/MLHelpers.cs | 26 +++
src/Metal/MTLEnums.cs | 6 +
src/Metal/MTLIOCompression.cs | 8 +
.../SupportedSimulatorAttribute.cs | 45 ++++
src/TrimAttributes.LinkDescription.xml | 12 ++
src/bgen/AttributeManager.cs | 4 +
src/bgen/Enums.cs | 1 +
src/bgen/Generator.cs | 60 +++++-
src/bgen/bgen.csproj | 1 +
src/frameworks.sources | 1 +
src/metal.cs | 129 +++++++++++
src/metalfx.cs | 4 +
src/videotoolbox.cs | 28 +++
tests/bgen/BGenTests.cs | 67 ++++++
.../simulator-availability-attributes.cs | 30 +++
tests/common/PlatformInfo.cs | 48 +++++
tests/introspection/ApiBaseTest.cs | 1 +
tests/introspection/ApiCtorInitTest.cs | 71 -------
tests/introspection/ApiFieldTest.cs | 8 -
tests/introspection/ApiPInvokeTest.cs | 2 +-
tests/introspection/ApiProtocolTest.cs | 118 +---------
tests/introspection/ApiSelectorTest.cs | 9 -
.../ApiSimulatorAvailabilityTest.cs | 201 ++++++++++++++++++
tests/introspection/ApiTypoTest.cs | 10 -
tests/introspection/dotnet/shared.csproj | 4 +
tests/introspection/iOSApiCtorInitTest.cs | 40 +---
tests/introspection/iOSApiFieldTest.cs | 40 +---
tests/introspection/iOSApiPInvokeTest.cs | 48 -----
.../iOSApiSimulatorAvailabilityTest.cs | 40 ++++
29 files changed, 722 insertions(+), 340 deletions(-)
create mode 100644 src/ObjCRuntime/SupportedSimulatorAttribute.cs
create mode 100644 tests/bgen/tests/simulator-availability-attributes.cs
create mode 100644 tests/introspection/ApiSimulatorAvailabilityTest.cs
create mode 100644 tests/introspection/iOSApiSimulatorAvailabilityTest.cs
diff --git a/src/MLCompute/MLHelpers.cs b/src/MLCompute/MLHelpers.cs
index 8c18ed336c83..4063daf6c391 100644
--- a/src/MLCompute/MLHelpers.cs
+++ b/src/MLCompute/MLHelpers.cs
@@ -10,6 +10,8 @@ namespace MLCompute {
public static class MLCActivationTypeExtensions {
[DllImport (Constants.MLComputeLibrary)]
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
static extern /* NSString */ IntPtr MLCActivationTypeDebugDescription (MLCActivationType activationType);
public static string? GetDebugDescription (this MLCActivationType self)
@@ -25,6 +27,8 @@ public static class MLCActivationTypeExtensions {
public static class MLCArithmeticOperationExtensions {
[DllImport (Constants.MLComputeLibrary)]
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
static extern /* NSString */ IntPtr MLCArithmeticOperationDebugDescription (MLCArithmeticOperation operation);
public static string? GetDebugDescription (this MLCArithmeticOperation self)
@@ -40,6 +44,8 @@ public static class MLCArithmeticOperationExtensions {
public static class MLCPaddingPolicyExtensions {
[DllImport (Constants.MLComputeLibrary)]
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
static extern /* NSString */ IntPtr MLCPaddingPolicyDebugDescription (MLCPaddingPolicy paddingPolicy);
public static string? GetDebugDescription (this MLCPaddingPolicy self)
@@ -55,6 +61,8 @@ public static class MLCPaddingPolicyExtensions {
public static class MLCLossTypeExtensions {
[DllImport (Constants.MLComputeLibrary)]
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
static extern /* NSString */ IntPtr MLCLossTypeDebugDescription (MLCLossType lossType);
public static string? GetDebugDescription (this MLCLossType self)
@@ -70,6 +78,8 @@ public static class MLCLossTypeExtensions {
public static class MLCReductionTypeExtensions {
[DllImport (Constants.MLComputeLibrary)]
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
static extern /* NSString */ IntPtr MLCReductionTypeDebugDescription (MLCReductionType reductionType);
public static string? GetDebugDescription (this MLCReductionType self)
@@ -85,6 +95,8 @@ public static class MLCReductionTypeExtensions {
public static class MLCPaddingTypeExtensions {
[DllImport (Constants.MLComputeLibrary)]
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
static extern /* NSString */ IntPtr MLCPaddingTypeDebugDescription (MLCPaddingType paddingType);
public static string? GetDebugDescription (this MLCPaddingType self)
@@ -100,6 +112,8 @@ public static class MLCPaddingTypeExtensions {
public static class MLCConvolutionTypeExtensions {
[DllImport (Constants.MLComputeLibrary)]
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
static extern /* NSString */ IntPtr MLCConvolutionTypeDebugDescription (MLCConvolutionType convolutionType);
public static string? GetDebugDescription (this MLCConvolutionType self)
@@ -115,6 +129,8 @@ public static class MLCConvolutionTypeExtensions {
public static class MLCPoolingTypeExtensions {
[DllImport (Constants.MLComputeLibrary)]
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
static extern /* NSString */ IntPtr MLCPoolingTypeDebugDescription (MLCPoolingType poolingType);
public static string? GetDebugDescription (this MLCPoolingType self)
@@ -130,6 +146,8 @@ public static class MLCPoolingTypeExtensions {
public static class MLCSoftmaxOperationExtensions {
[DllImport (Constants.MLComputeLibrary)]
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
static extern /* NSString */ IntPtr MLCSoftmaxOperationDebugDescription (MLCSoftmaxOperation operation);
public static string? GetDebugDescription (this MLCSoftmaxOperation self)
@@ -145,6 +163,8 @@ public static class MLCSoftmaxOperationExtensions {
public static class MLCSampleModeExtensions {
[DllImport (Constants.MLComputeLibrary)]
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
static extern /* NSString */ IntPtr MLCSampleModeDebugDescription (MLCSampleMode mode);
public static string? GetDebugDescription (this MLCSampleMode self)
@@ -160,6 +180,8 @@ public static class MLCSampleModeExtensions {
public static class MLCLstmResultModeExtensions {
[DllImport (Constants.MLComputeLibrary)]
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
static extern /* NSString */ IntPtr MLCLSTMResultModeDebugDescription (MLCLstmResultMode mode);
public static string? GetDebugDescription (this MLCLstmResultMode self)
@@ -175,6 +197,8 @@ public static class MLCLstmResultModeExtensions {
public static class MLCComparisonOperationExtensions {
[DllImport (Constants.MLComputeLibrary)]
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
static extern /* NSString */ IntPtr MLCComparisonOperationDebugDescription (MLCComparisonOperation operation);
public static string? GetDebugDescription (this MLCComparisonOperation self)
@@ -190,6 +214,8 @@ public static class MLCComparisonOperationExtensions {
public static class MLCGradientClippingTypeExtensions {
[DllImport (Constants.MLComputeLibrary)]
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
static extern /* NSString */ IntPtr MLCGradientClippingTypeDebugDescription (MLCGradientClippingType gradientClippingType);
public static string? GetDebugDescription (this MLCGradientClippingType self)
diff --git a/src/Metal/MTLEnums.cs b/src/Metal/MTLEnums.cs
index b6f15a43630f..19ea79b3fc6f 100644
--- a/src/Metal/MTLEnums.cs
+++ b/src/Metal/MTLEnums.cs
@@ -2358,6 +2358,8 @@ public enum MTLIOCompressionStatus : long {
[Mac (13, 0), iOS (16, 0), MacCatalyst (16, 0), TV (16, 0)]
[Native]
[ErrorDomain ("MTLIOErrorDomain")]
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
public enum MTLIOError : long {
UrlInvalid = 1,
Internal = 2,
@@ -2466,6 +2468,8 @@ public enum MTL4BlendState : long {
[Mac (26, 0), iOS (26, 0), MacCatalyst (26, 0), TV (26, 0)]
[Native]
[ErrorDomain ("MTL4CommandQueueErrorDomain")]
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
public enum MTL4CommandQueueError : long {
None = 0,
Timeout = 1,
@@ -2599,6 +2603,8 @@ public enum MTLDeviceError : long {
[Mac (26, 0), iOS (26, 0), MacCatalyst (26, 0), TV (26, 0)]
[Native]
[ErrorDomain ("MTLTensorDomain")]
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
public enum MTLTensorError : long {
None = 0,
InternalError = 1,
diff --git a/src/Metal/MTLIOCompression.cs b/src/Metal/MTLIOCompression.cs
index cfe3b53c6663..460f5dc6e484 100644
--- a/src/Metal/MTLIOCompression.cs
+++ b/src/Metal/MTLIOCompression.cs
@@ -15,6 +15,8 @@ public class MTLIOCompressionContext : DisposableObject {
MTLIOCompressionContext (NativeHandle handle, bool owns) : base (handle, owns) { }
[DllImport (Constants.MetalLibrary)]
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
static extern unsafe void MTLIOCompressionContextAppendData (IntPtr context, void* data, nuint size);
unsafe void AppendData (void* data, nuint size)
@@ -47,6 +49,8 @@ public void AppendData (NSData data)
}
[DllImport (Constants.MetalLibrary)]
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
// [return: NullAllowed]
static extern IntPtr MTLIOCreateCompressionContext (IntPtr path, long type, long chunkSize);
@@ -74,6 +78,8 @@ protected override void Dispose (bool disposing)
}
[DllImport (Constants.MetalLibrary)]
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
static extern long MTLIOFlushAndDestroyCompressionContext (IntPtr context);
public MTLIOCompressionStatus FlushAndDestroy ()
@@ -86,6 +92,8 @@ public MTLIOCompressionStatus FlushAndDestroy ()
}
[DllImport (Constants.MetalLibrary)]
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
static extern nint MTLIOCompressionContextDefaultChunkSize ();
public static nint DefaultChunkSize => MTLIOCompressionContextDefaultChunkSize ();
diff --git a/src/ObjCRuntime/SupportedSimulatorAttribute.cs b/src/ObjCRuntime/SupportedSimulatorAttribute.cs
new file mode 100644
index 000000000000..d2f5aa3fa302
--- /dev/null
+++ b/src/ObjCRuntime/SupportedSimulatorAttribute.cs
@@ -0,0 +1,45 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT License.
+
+#nullable enable
+
+namespace ObjCRuntime {
+ /// Indicates that an API is supported for a specified platform. If a version is specified, the API is available starting in the specified OS version. Multiple attributes can be applied to indicate support on multiple operating systems.
+ ///
+ /// Contrary to standard availability attributes (such as attributes), the presence of this attribute for some platforms does not imply any meaning for other platforms.
+ /// If there are no or attributes on an API, the API is assumed to be available in the simulator.
+ /// This attribute will be trimmed away if the app is trimmed.
+ ///
+ [AttributeUsage (AttributeTargets.Class | AttributeTargets.Interface | AttributeTargets.Enum | AttributeTargets.Method | AttributeTargets.Property | AttributeTargets.Constructor | AttributeTargets.Field, AllowMultiple = true)]
+ public sealed class SupportedSimulatorAttribute : Attribute {
+ /// Initializes a new attribute.
+ /// The platform where this API is supported in the simulator.
+ /// Format: platform name (e.g., "ios", "tvos") optionally followed by a version number (e.g., "ios17.0").
+ public SupportedSimulatorAttribute (string platformName)
+ {
+ PlatformName = platformName;
+ }
+
+ /// The name of the platform.
+ public string PlatformName { get; init; }
+ }
+
+ /// Indicates that an API is not supported in the simulator for the specified platform. Multiple attributes can be applied to indicate lack of support on multiple platforms.
+ ///
+ /// Contrary to standard availability attributes (such as attributes), the presence of this attribute for some platforms does not imply any meaning for other platforms.
+ /// If there are no or attributes on an API, the API is assumed to be available in the simulator.
+ /// This attribute will be trimmed away if the app is trimmed.
+ ///
+ [AttributeUsage (AttributeTargets.Class | AttributeTargets.Interface | AttributeTargets.Enum | AttributeTargets.Method | AttributeTargets.Property | AttributeTargets.Constructor | AttributeTargets.Field, AllowMultiple = true)]
+ public sealed class UnsupportedSimulatorAttribute : Attribute {
+ /// Initializes a new attribute.
+ /// The platform where this API is not supported in the simulator.
+ public UnsupportedSimulatorAttribute (string platformName)
+ {
+ PlatformName = platformName;
+ }
+
+ /// The name of the platform.
+ public string PlatformName { get; init; }
+ }
+}
diff --git a/src/TrimAttributes.LinkDescription.xml b/src/TrimAttributes.LinkDescription.xml
index bfe5a67b8964..b38fba735286 100644
--- a/src/TrimAttributes.LinkDescription.xml
+++ b/src/TrimAttributes.LinkDescription.xml
@@ -290,6 +290,18 @@
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/bgen/AttributeManager.cs b/src/bgen/AttributeManager.cs
index d7aadca355f7..3ceccdd0c76e 100644
--- a/src/bgen/AttributeManager.cs
+++ b/src/bgen/AttributeManager.cs
@@ -142,6 +142,10 @@ public AttributeManager (TypeCache typeCache)
return typeof (ObjCRuntime.RequiresSuperAttribute);
case "ObjCRuntime.ObjectiveCFrameworkAttribute":
return typeof (ObjCRuntime.ObjectiveCFrameworkAttribute);
+ case "ObjCRuntime.SupportedSimulatorAttribute":
+ return typeof (ObjCRuntime.SupportedSimulatorAttribute);
+ case "ObjCRuntime.UnsupportedSimulatorAttribute":
+ return typeof (ObjCRuntime.UnsupportedSimulatorAttribute);
case "UnavailableAttribute":
return typeof (UnavailableAttribute);
case "OptionalImplementationAttribute":
diff --git a/src/bgen/Enums.cs b/src/bgen/Enums.cs
index e2aa70af6080..b6c452eb8052 100644
--- a/src/bgen/Enums.cs
+++ b/src/bgen/Enums.cs
@@ -200,6 +200,7 @@ void GenerateEnum (Type type)
}
}
// the *Extensions has the same version requirement as the enum itself
+ PrintSimulatorAvailabilityAttributes (type);
PrintPlatformAttributes (type);
PrintExperimentalAttribute (type);
print_generated_code ();
diff --git a/src/bgen/Generator.cs b/src/bgen/Generator.cs
index 9a2099414299..86ea641986a4 100644
--- a/src/bgen/Generator.cs
+++ b/src/bgen/Generator.cs
@@ -5547,7 +5547,7 @@ public void PrintBindAsAttribute (ICustomAttributeProvider? mi, StringBuilder? s
// Not adding the experimental attribute is bad (it would mean that an API
// we meant to be experimental ended up being released as stable), so it's
// opt-out instead of opt-in.
- public void PrintAttributes (ICustomAttributeProvider? mi, bool platform = false, bool preserve = false, bool advice = false, bool notImplemented = false, bool bindAs = false, bool requiresSuper = false, Type? inlinedType = null, bool experimental = true, bool obsolete = false, bool objectiveCFramework = false)
+ public void PrintAttributes (ICustomAttributeProvider? mi, bool platform = false, bool preserve = false, bool advice = false, bool notImplemented = false, bool bindAs = false, bool requiresSuper = false, Type? inlinedType = null, bool experimental = true, bool obsolete = false, bool objectiveCFramework = false, bool simulatorAvailability = true)
{
if (platform)
PrintPlatformAttributes (mi as MemberInfo, inlinedType);
@@ -5567,6 +5567,8 @@ public void PrintAttributes (ICustomAttributeProvider? mi, bool platform = false
PrintObsoleteAttributes (mi);
if (objectiveCFramework)
PrintObjectiveCFrameworkAttribute (mi);
+ if (simulatorAvailability)
+ PrintSimulatorAvailabilityAttributes (mi);
}
public void PrintExperimentalAttribute (ICustomAttributeProvider? mi)
@@ -5585,6 +5587,62 @@ public void PrintObjectiveCFrameworkAttribute (ICustomAttributeProvider? mi)
print ($"[ObjectiveCFramework (\"{attrib.Framework}\")]");
}
+ public void PrintSimulatorAvailabilityAttributes (ICustomAttributeProvider? provider)
+ {
+ if (!TryGetSimulatorAvailabilityPlatformName (out var platformName))
+ return;
+
+ PrintSupportedSimulatorAttribute (provider, platformName);
+ PrintUnsupportedSimulatorAttribute (provider, platformName);
+ }
+
+ bool TryGetSimulatorAvailabilityPlatformName ([NotNullWhen (true)] out string? platformName)
+ {
+ platformName = null;
+
+ switch (CurrentPlatform) {
+ case PlatformName.MacCatalyst:
+ case PlatformName.MacOSX:
+ return false;
+ case PlatformName.iOS:
+ platformName = "ios";
+ return true;
+ case PlatformName.TvOS:
+ platformName = "tvos";
+ return true;
+ default:
+ throw new BindingException (1047, CurrentPlatform);
+ }
+ }
+
+ void PrintSupportedSimulatorAttribute (ICustomAttributeProvider? provider, string platformName)
+ {
+ var attribs = AttributeManager.GetCustomAttributes (provider);
+ if (attribs?.Any () != true)
+ return;
+
+ // Only print the attribute for the current platform, we don't care about other platforms.
+ foreach (var attrib in attribs) {
+ if (!attrib.PlatformName.StartsWith (platformName, StringComparison.OrdinalIgnoreCase))
+ continue;
+ print ($"[SupportedSimulator (\"{attrib.PlatformName}\")]");
+ }
+ }
+
+ void PrintUnsupportedSimulatorAttribute (ICustomAttributeProvider? provider, string platformName)
+ {
+ var attribs = AttributeManager.GetCustomAttributes (provider);
+ if (attribs?.Any () != true)
+ return;
+
+ // Only print the attribute for the current platform, we don't care about other platforms.
+ foreach (var attrib in attribs) {
+ if (!attrib.PlatformName.StartsWith (platformName, StringComparison.OrdinalIgnoreCase))
+ continue;
+ print ($"[UnsupportedSimulator (\"{attrib.PlatformName}\")]");
+ }
+ }
+
bool WriteDocumentation (MemberInfo info, Func? transformNode = null)
{
return DocumentationManager.WriteDocumentation (sw!, indent, info, transformNode);
diff --git a/src/bgen/bgen.csproj b/src/bgen/bgen.csproj
index c5f6588ec350..8e7a65e7d227 100644
--- a/src/bgen/bgen.csproj
+++ b/src/bgen/bgen.csproj
@@ -57,6 +57,7 @@
+
diff --git a/src/frameworks.sources b/src/frameworks.sources
index 86320fd61d35..49e06425272d 100644
--- a/src/frameworks.sources
+++ b/src/frameworks.sources
@@ -1912,6 +1912,7 @@ SHARED_CORE_SOURCES = \
ObjCRuntime/Registrar.core.cs \
ObjCRuntime/RequiresSuperAttribute.cs \
ObjCRuntime/Selector.cs \
+ ObjCRuntime/SupportedSimulatorAttribute.cs \
ObjCRuntime/SystemVersion.cs \
ObjCRuntime/ThrowHelper.cs \
Simd/MathHelper.cs \
diff --git a/src/metal.cs b/src/metal.cs
index 4e67fa75aeab..b29676ad9f8b 100644
--- a/src/metal.cs
+++ b/src/metal.cs
@@ -5926,6 +5926,8 @@ interface MTLIndirectCommandBuffer : MTLResource {
MTLResourceId GpuResourceID { get; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[iOS (13, 0), TV (13, 0)]
[MacCatalyst (13, 1)]
[BaseType (typeof (NSObject))]
@@ -7804,6 +7806,8 @@ interface IMTLResidencySet { }
interface IMTL4Archive { }
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[Protocol (BackwardsCompatibleCodeGeneration = false)]
interface MTL4Archive {
@@ -7843,6 +7847,9 @@ interface MTL4Archive {
}
interface IMTL4ArgumentTable { }
+
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[Protocol (BackwardsCompatibleCodeGeneration = false)]
interface MTL4ArgumentTable {
@@ -7877,6 +7884,8 @@ interface MTL4ArgumentTable {
interface IMTL4BinaryFunction { }
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[Protocol (BackwardsCompatibleCodeGeneration = false)]
interface MTL4BinaryFunction {
@@ -7891,6 +7900,8 @@ interface MTL4BinaryFunction {
interface IMTL4CommandAllocator { }
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[Protocol (BackwardsCompatibleCodeGeneration = false)]
interface MTL4CommandAllocator {
@@ -7913,6 +7924,8 @@ interface MTL4CommandAllocator {
interface IMTL4CommandBuffer { }
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[Protocol (BackwardsCompatibleCodeGeneration = false)]
interface MTL4CommandBuffer {
@@ -7983,6 +7996,8 @@ interface MTL4CommandBuffer {
interface IMTL4CommandEncoder { }
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[Protocol (BackwardsCompatibleCodeGeneration = false)]
interface MTL4CommandEncoder {
@@ -8033,6 +8048,8 @@ interface MTL4CommandEncoder {
interface IMTL4CommandQueue { }
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[Protocol (BackwardsCompatibleCodeGeneration = false)]
interface MTL4CommandQueue {
@@ -8103,6 +8120,8 @@ interface MTL4CommandQueue {
interface IMTL4CommitFeedback { }
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[Protocol (BackwardsCompatibleCodeGeneration = false)]
interface MTL4CommitFeedback {
@@ -8122,6 +8141,8 @@ interface MTL4CommitFeedback {
interface IMTL4CompilerTask { }
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[Protocol (BackwardsCompatibleCodeGeneration = false)]
interface MTL4CompilerTask {
@@ -8149,6 +8170,8 @@ interface MTL4CompilerTask {
interface IMTL4Compiler { }
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[Protocol (BackwardsCompatibleCodeGeneration = false)]
interface MTL4Compiler {
@@ -8277,6 +8300,8 @@ interface MTL4Compiler {
interface IMTL4ComputeCommandEncoder { }
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[Protocol (BackwardsCompatibleCodeGeneration = false)]
interface MTL4ComputeCommandEncoder : MTL4CommandEncoder {
@@ -8427,6 +8452,8 @@ interface MTL4ComputeCommandEncoder : MTL4CommandEncoder {
interface IMTL4CounterHeap { }
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[Protocol (BackwardsCompatibleCodeGeneration = false)]
interface MTL4CounterHeap {
@@ -8454,6 +8481,8 @@ interface MTL4CounterHeap {
interface IMTL4MachineLearningCommandEncoder { }
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[Protocol (BackwardsCompatibleCodeGeneration = false)]
interface MTL4MachineLearningCommandEncoder : MTL4CommandEncoder {
@@ -8472,6 +8501,8 @@ interface MTL4MachineLearningCommandEncoder : MTL4CommandEncoder {
interface IMTL4MachineLearningPipelineState { }
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[Protocol (BackwardsCompatibleCodeGeneration = false)]
interface MTL4MachineLearningPipelineState : MTLAllocation {
@@ -8494,6 +8525,8 @@ interface MTL4MachineLearningPipelineState : MTLAllocation {
interface IMTL4PipelineDataSetSerializer { }
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[Protocol (BackwardsCompatibleCodeGeneration = false)]
interface MTL4PipelineDataSetSerializer {
@@ -8509,6 +8542,8 @@ interface MTL4PipelineDataSetSerializer {
interface IMTL4RenderCommandEncoder { }
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[Protocol (BackwardsCompatibleCodeGeneration = false)]
interface MTL4RenderCommandEncoder : MTL4CommandEncoder {
@@ -8782,6 +8817,8 @@ interface MTLTextureViewPool : MTLResourceViewPool {
MTLResourceId SetTextureViewFromBuffer (IMTLBuffer buffer, MTLTextureDescriptor descriptor, nuint offset, nuint bytesPerRow, nuint index);
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (MTL4AccelerationStructureGeometryDescriptor))]
interface MTL4AccelerationStructureBoundingBoxGeometryDescriptor {
@@ -8795,6 +8832,8 @@ interface MTL4AccelerationStructureBoundingBoxGeometryDescriptor {
nuint BoundingBoxCount { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (MTL4AccelerationStructureGeometryDescriptor))]
interface MTL4AccelerationStructureCurveGeometryDescriptor {
@@ -8841,11 +8880,15 @@ interface MTL4AccelerationStructureCurveGeometryDescriptor {
MTLCurveEndCaps CurveEndCaps { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (MTLAccelerationStructureDescriptor))]
interface MTL4AccelerationStructureDescriptor {
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4AccelerationStructureGeometryDescriptor : NSCopying {
@@ -8871,6 +8914,8 @@ interface MTL4AccelerationStructureGeometryDescriptor : NSCopying {
nuint PrimitiveDataElementSize { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (MTL4AccelerationStructureGeometryDescriptor))]
interface MTL4AccelerationStructureMotionBoundingBoxGeometryDescriptor {
@@ -8884,6 +8929,8 @@ interface MTL4AccelerationStructureMotionBoundingBoxGeometryDescriptor {
nuint BoundingBoxCount { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (MTL4AccelerationStructureGeometryDescriptor))]
interface MTL4AccelerationStructureMotionCurveGeometryDescriptor {
@@ -8930,6 +8977,8 @@ interface MTL4AccelerationStructureMotionCurveGeometryDescriptor {
MTLCurveEndCaps CurveEndCaps { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (MTL4AccelerationStructureGeometryDescriptor))]
interface MTL4AccelerationStructureMotionTriangleGeometryDescriptor {
@@ -8958,6 +9007,8 @@ interface MTL4AccelerationStructureMotionTriangleGeometryDescriptor {
MTLMatrixLayout TransformationMatrixLayout { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (MTL4AccelerationStructureGeometryDescriptor))]
interface MTL4AccelerationStructureTriangleGeometryDescriptor {
@@ -8986,6 +9037,8 @@ interface MTL4AccelerationStructureTriangleGeometryDescriptor {
MTLMatrixLayout TransformationMatrixLayout { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4ArgumentTableDescriptor : NSCopying {
@@ -9008,6 +9061,8 @@ interface MTL4ArgumentTableDescriptor : NSCopying {
string Label { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4BinaryFunctionDescriptor : NSCopying {
@@ -9021,6 +9076,8 @@ interface MTL4BinaryFunctionDescriptor : NSCopying {
MTL4BinaryFunctionOptions Options { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4CommandAllocatorDescriptor : NSCopying {
@@ -9028,6 +9085,8 @@ interface MTL4CommandAllocatorDescriptor : NSCopying {
string Label { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4CommandBufferOptions : NSCopying {
@@ -9035,6 +9094,8 @@ interface MTL4CommandBufferOptions : NSCopying {
IMTLLogState LogState { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4CommandQueueDescriptor : NSCopying {
@@ -9047,6 +9108,8 @@ interface MTL4CommandQueueDescriptor : NSCopying {
delegate void MTL4CommitFeedbackHandler (IMTL4CommitFeedback commitFeedback);
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4CommitOptions {
@@ -9054,6 +9117,8 @@ interface MTL4CommitOptions {
void AddFeedbackHandler (MTL4CommitFeedbackHandler block);
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4CompilerDescriptor : NSCopying {
@@ -9064,6 +9129,8 @@ interface MTL4CompilerDescriptor : NSCopying {
IMTL4PipelineDataSetSerializer PipelineDataSetSerializer { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4CompilerTaskOptions : NSCopying {
@@ -9071,6 +9138,8 @@ interface MTL4CompilerTaskOptions : NSCopying {
IMTL4Archive [] LookupArchives { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (MTL4PipelineDescriptor))]
interface MTL4ComputePipelineDescriptor {
@@ -9099,6 +9168,8 @@ interface MTL4ComputePipelineDescriptor {
void Reset ();
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4CounterHeapDescriptor : NSCopying {
@@ -9109,11 +9180,15 @@ interface MTL4CounterHeapDescriptor : NSCopying {
nuint Count { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4FunctionDescriptor : NSCopying {
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (MTL4AccelerationStructureDescriptor))]
interface MTL4IndirectInstanceAccelerationStructureDescriptor {
@@ -9151,6 +9226,8 @@ interface MTL4IndirectInstanceAccelerationStructureDescriptor {
nuint MotionTransformStride { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (MTL4AccelerationStructureDescriptor))]
interface MTL4InstanceAccelerationStructureDescriptor {
@@ -9182,6 +9259,8 @@ interface MTL4InstanceAccelerationStructureDescriptor {
nuint MotionTransformStride { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4LibraryDescriptor : NSCopying {
@@ -9195,6 +9274,8 @@ interface MTL4LibraryDescriptor : NSCopying {
string Name { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (MTL4FunctionDescriptor))]
interface MTL4LibraryFunctionDescriptor {
@@ -9205,6 +9286,8 @@ interface MTL4LibraryFunctionDescriptor {
IMTLLibrary Library { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (MTL4PipelineDescriptor))]
interface MTL4MachineLearningPipelineDescriptor {
@@ -9228,6 +9311,8 @@ interface MTL4MachineLearningPipelineDescriptor {
void Reset ();
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4MachineLearningPipelineReflection {
@@ -9235,6 +9320,8 @@ interface MTL4MachineLearningPipelineReflection {
IMTLBinding [] Bindings { get; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (MTL4PipelineDescriptor))]
interface MTL4MeshRenderPipelineDescriptor {
@@ -9317,6 +9404,8 @@ interface MTL4MeshRenderPipelineDescriptor {
void Reset ();
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4PipelineDataSetSerializerDescriptor : NSCopying {
@@ -9324,6 +9413,8 @@ interface MTL4PipelineDataSetSerializerDescriptor : NSCopying {
MTL4PipelineDataSetSerializerConfiguration Configuration { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4PipelineDescriptor : NSCopying {
@@ -9335,6 +9426,8 @@ interface MTL4PipelineDescriptor : NSCopying {
MTL4PipelineOptions Options { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4PipelineOptions : NSCopying {
@@ -9345,6 +9438,8 @@ interface MTL4PipelineOptions : NSCopying {
MTL4ShaderReflection ShaderReflection { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4PipelineStageDynamicLinkingDescriptor : NSCopying {
@@ -9358,6 +9453,8 @@ interface MTL4PipelineStageDynamicLinkingDescriptor : NSCopying {
IMTLDynamicLibrary [] PreloadedLibraries { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (MTL4AccelerationStructureDescriptor))]
interface MTL4PrimitiveAccelerationStructureDescriptor {
@@ -9380,6 +9477,8 @@ interface MTL4PrimitiveAccelerationStructureDescriptor {
nuint MotionKeyframeCount { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4RenderPassDescriptor : NSCopying {
@@ -9435,6 +9534,8 @@ interface MTL4RenderPassDescriptor : NSCopying {
bool SupportColorAttachmentMapping { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4RenderPipelineBinaryFunctionsDescriptor : NSCopying {
@@ -9457,6 +9558,8 @@ interface MTL4RenderPipelineBinaryFunctionsDescriptor : NSCopying {
void Reset ();
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4RenderPipelineColorAttachmentDescriptor : NSCopying {
@@ -9491,6 +9594,8 @@ interface MTL4RenderPipelineColorAttachmentDescriptor : NSCopying {
void Reset ();
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4RenderPipelineColorAttachmentDescriptorArray : NSCopying {
@@ -9504,6 +9609,8 @@ interface MTL4RenderPipelineColorAttachmentDescriptorArray : NSCopying {
void Reset ();
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (MTL4PipelineDescriptor))]
interface MTL4RenderPipelineDescriptor {
@@ -9559,6 +9666,8 @@ interface MTL4RenderPipelineDescriptor {
void Reset ();
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4RenderPipelineDynamicLinkingDescriptor : NSCopying {
@@ -9578,6 +9687,8 @@ interface MTL4RenderPipelineDynamicLinkingDescriptor : NSCopying {
MTL4PipelineStageDynamicLinkingDescriptor MeshLinkingDescriptor { get; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (MTL4FunctionDescriptor))]
interface MTL4SpecializedFunctionDescriptor {
@@ -9591,6 +9702,8 @@ interface MTL4SpecializedFunctionDescriptor {
MTLFunctionConstantValues ConstantValues { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTL4StaticLinkingDescriptor : NSCopying {
@@ -9604,6 +9717,8 @@ interface MTL4StaticLinkingDescriptor : NSCopying {
NSDictionary> Groups { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (MTL4FunctionDescriptor))]
interface MTL4StitchedFunctionDescriptor {
@@ -9614,6 +9729,8 @@ interface MTL4StitchedFunctionDescriptor {
MTL4FunctionDescriptor [] FunctionDescriptors { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (MTL4PipelineDescriptor))]
interface MTL4TileRenderPipelineDescriptor {
@@ -9656,6 +9773,8 @@ interface MTLFunctionReflection {
string UserAnnotation { get; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTLLogicalToPhysicalColorAttachmentMap : NSCopying {
@@ -9669,6 +9788,8 @@ interface MTLLogicalToPhysicalColorAttachmentMap : NSCopying {
void Reset ();
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTLResourceViewPoolDescriptor : NSCopying {
@@ -9679,6 +9800,8 @@ interface MTLResourceViewPoolDescriptor : NSCopying {
string Label { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTLTensorDescriptor : NSCopying {
@@ -9708,6 +9831,8 @@ interface MTLTensorDescriptor : NSCopying {
MTLHazardTrackingMode HazardTrackingMode { get; set; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor] // all properties are readonly, and has a non-default ctor
@@ -9723,6 +9848,8 @@ interface MTLTensorExtents {
nint GetExtent (nuint dimensionIndex);
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (MTLType))]
interface MTLTensorReferenceType {
@@ -9739,6 +9866,8 @@ interface MTLTensorReferenceType {
MTLBindingAccess Access { get; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), TV (26, 0), MacCatalyst (26, 0)]
[BaseType (typeof (NSObject))]
interface MTLTextureViewDescriptor : NSCopying {
diff --git a/src/metalfx.cs b/src/metalfx.cs
index 7e1739db57e1..19515be35435 100644
--- a/src/metalfx.cs
+++ b/src/metalfx.cs
@@ -165,6 +165,8 @@ interface MTLFXTemporalScalerDescriptor : NSCopying {
bool SupportsMetal4FX (IMTLDevice device);
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), MacCatalyst (26, 0), TV (26, 0)]
[BaseType (typeof (NSObject))]
interface MTLFXFrameInterpolatorDescriptor : NSCopying {
@@ -405,6 +407,8 @@ interface MTL4FXFrameInterpolator : MTLFXFrameInterpolatorBase {
void Encode (IMTL4CommandBuffer commandBuffer);
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[Mac (26, 0), iOS (26, 0), MacCatalyst (26, 0), TV (26, 0)]
[BaseType (typeof (NSObject))]
interface MTLFXTemporalDenoisedScalerDescriptor : NSCopying {
diff --git a/src/videotoolbox.cs b/src/videotoolbox.cs
index 85f89d3fadd6..f2342abc5803 100644
--- a/src/videotoolbox.cs
+++ b/src/videotoolbox.cs
@@ -2906,6 +2906,8 @@ public enum VTFrameRateConversionParametersSubmissionMode : long {
SequentialReferencesUnchanged = 3,
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[MacCatalyst (18, 4), NoTV, iOS (26, 0), Mac (15, 4)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor]
@@ -2946,6 +2948,8 @@ interface VTFrameRateConversionConfiguration : VTFrameProcessorConfiguration {
bool Supported { [Bind ("isSupported")] get; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[MacCatalyst (18, 4), NoTV, iOS (26, 0), Mac (15, 4)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor]
@@ -2987,6 +2991,8 @@ public enum VTMotionBlurParametersSubmissionMode : long {
Sequential = 2,
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[MacCatalyst (26, 0), NoTV, iOS (26, 0), Mac (15, 4)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor]
@@ -3027,6 +3033,8 @@ interface VTMotionBlurConfiguration : VTFrameProcessorConfiguration {
bool Supported { [Bind ("isSupported")] get; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[MacCatalyst (26, 0), NoTV, iOS (26, 0), Mac (15, 4)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor]
@@ -3073,6 +3081,8 @@ public enum VTOpticalFlowParametersSubmissionMode : long {
Sequential = 2,
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[MacCatalyst (26, 0), NoTV, iOS (26, 0), Mac (15, 4)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor]
@@ -3110,6 +3120,8 @@ interface VTOpticalFlowConfiguration : VTFrameProcessorConfiguration {
bool Supported { [Bind ("isSupported")] get; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[MacCatalyst (26, 0), NoTV, iOS (26, 0), Mac (15, 4)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor]
@@ -3127,6 +3139,8 @@ interface VTOpticalFlowParameters : VTFrameProcessorParameters {
VTFrameProcessorOpticalFlow DestinationOpticalFlow { get; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[TV (26, 0), MacCatalyst (26, 0), Mac (26, 0), iOS (26, 0)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor]
@@ -3156,6 +3170,8 @@ interface VTLowLatencyFrameInterpolationConfiguration : VTFrameProcessorConfigur
bool Supported { [Bind ("isSupported")] get; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[TV (26, 0), MacCatalyst (26, 0), Mac (26, 0), iOS (26, 0)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor]
@@ -3171,6 +3187,8 @@ interface VTLowLatencyFrameInterpolationParameters : VTFrameProcessorParameters
NSNumber [] InterpolationPhase { get; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[TV (26, 0), MacCatalyst (26, 0), Mac (26, 0), iOS (26, 0)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor]
@@ -3197,6 +3215,8 @@ interface VTLowLatencySuperResolutionScalerConfiguration : VTFrameProcessorConfi
NSNumber [] GetSupportedScaleFactors (nint frameWidth, nint frameHeight);
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[NoTV, MacCatalyst (26, 0), Mac (26, 0), iOS (26, 0)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor]
@@ -3255,6 +3275,8 @@ interface VTSuperResolutionScalerConfiguration : VTFrameProcessorConfiguration {
delegate void VTSuperResolutionScalerConfigurationDownloadConfigurationModelCallback ([NullAllowed] NSError error);
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[MacCatalyst (26, 0), NoTV, Mac (26, 0), iOS (26, 0)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor]
@@ -3275,6 +3297,8 @@ interface VTSuperResolutionScalerParameters : VTFrameProcessorParameters {
VTSuperResolutionScalerParametersSubmissionMode SubmissionMode { get; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[MacCatalyst (26, 0), NoTV, Mac (26, 0), iOS (26, 0)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor]
@@ -3298,6 +3322,8 @@ interface VTTemporalNoiseFilterConfiguration : VTFrameProcessorConfiguration {
bool Supported { [Bind ("isSupported")] get; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[MacCatalyst (26, 0), NoTV, Mac (26, 0), iOS (26, 0)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor]
@@ -3345,6 +3371,8 @@ interface VTMotionEstimationSessionCreationOptionKey {
NSString Label { get; }
}
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
[TV (26, 0), MacCatalyst (26, 0), Mac (26, 0), iOS (26, 0)]
[BaseType (typeof (NSObject))]
[DisableDefaultCtor]
diff --git a/tests/bgen/BGenTests.cs b/tests/bgen/BGenTests.cs
index 7a7ad37fb471..37de37291334 100644
--- a/tests/bgen/BGenTests.cs
+++ b/tests/bgen/BGenTests.cs
@@ -1657,5 +1657,72 @@ public void BothProtectedAndInternal (Profile profile)
var bgen = BuildFile (profile, "both-protected-and-internal.cs");
bgen.AssertNoWarnings ();
}
+
+ [Test]
+ [TestCase (Profile.iOS)]
+ [TestCase (Profile.tvOS)]
+ public void SimulatorAvailabilityAttributes (Profile profile)
+ {
+ Configuration.IgnoreIfIgnoredPlatform (profile.AsPlatform ());
+ var bgen = BuildFile (profile, "simulator-availability-attributes.cs");
+ bgen.AssertNoWarnings ();
+
+ var module = bgen.ApiAssembly.MainModule;
+
+ // Verify [UnsupportedSimulator] is copied for the current platform
+ var unsupportedAll = module.GetType ("NS", "UnsupportedOnAllSimulators");
+ var unsupportedAttrs = unsupportedAll.CustomAttributes
+ .Where (a => a.AttributeType.Name == "UnsupportedSimulatorAttribute")
+ .ToArray ();
+ Assert.That (unsupportedAttrs.Length, Is.EqualTo (1), "UnsupportedOnAllSimulators: one attribute for current platform");
+ var platformName = (string) unsupportedAttrs [0].ConstructorArguments [0].Value;
+ var expectedPlatform = profile == Profile.iOS ? "ios" : "tvos";
+ Assert.That (platformName, Is.EqualTo (expectedPlatform), "UnsupportedOnAllSimulators platform name");
+
+ // Verify only the current platform's attribute is emitted
+ var iosOnly = module.GetType ("NS", "UnsupportedOnIosSimulatorOnly");
+ var iosOnlyAttrs = iosOnly.CustomAttributes
+ .Where (a => a.AttributeType.Name == "UnsupportedSimulatorAttribute")
+ .ToArray ();
+ if (profile == Profile.iOS)
+ Assert.That (iosOnlyAttrs.Length, Is.EqualTo (1), "UnsupportedOnIosSimulatorOnly: present for iOS");
+ else
+ Assert.That (iosOnlyAttrs.Length, Is.EqualTo (0), "UnsupportedOnIosSimulatorOnly: absent for tvOS");
+
+ // Verify [SupportedSimulator] with version is copied
+ var supported = module.GetType ("NS", "SupportedOnSimulatorFromVersion");
+ var supportedAttrs = supported.CustomAttributes
+ .Where (a => a.AttributeType.Name == "SupportedSimulatorAttribute")
+ .ToArray ();
+ Assert.That (supportedAttrs.Length, Is.EqualTo (1), "SupportedOnSimulatorFromVersion: one attribute");
+ var expectedVersion = profile == Profile.iOS ? "ios17.0" : "tvos17.0";
+ Assert.That ((string) supportedAttrs [0].ConstructorArguments [0].Value, Is.EqualTo (expectedVersion), "SupportedOnSimulatorFromVersion platform name");
+
+ // Verify no simulator attributes when none are specified
+ var noAttrs = module.GetType ("NS", "NoSimulatorAttributes");
+ var simulatorAttrs = noAttrs.CustomAttributes
+ .Where (a => a.AttributeType.Name == "UnsupportedSimulatorAttribute" || a.AttributeType.Name == "SupportedSimulatorAttribute")
+ .ToArray ();
+ Assert.That (simulatorAttrs.Length, Is.EqualTo (0), "NoSimulatorAttributes: no simulator attributes");
+ }
+
+ [Test]
+ [TestCase (Profile.macOSMobile)]
+ [TestCase (Profile.MacCatalyst)]
+ public void SimulatorAvailabilityAttributes_NotEmittedForMacPlatforms (Profile profile)
+ {
+ Configuration.IgnoreIfIgnoredPlatform (profile.AsPlatform ());
+ var bgen = BuildFile (profile, "simulator-availability-attributes.cs");
+ bgen.AssertNoWarnings ();
+
+ var module = bgen.ApiAssembly.MainModule;
+ foreach (var typeName in new [] { "UnsupportedOnAllSimulators", "UnsupportedOnIosSimulatorOnly", "SupportedOnSimulatorFromVersion", "NoSimulatorAttributes" }) {
+ var type = module.GetType ("NS", typeName);
+ var simulatorAttrs = type.CustomAttributes
+ .Where (a => a.AttributeType.Name == "UnsupportedSimulatorAttribute" || a.AttributeType.Name == "SupportedSimulatorAttribute")
+ .ToArray ();
+ Assert.That (simulatorAttrs.Length, Is.EqualTo (0), $"{typeName}: no simulator attributes on Mac platforms");
+ }
+ }
}
}
diff --git a/tests/bgen/tests/simulator-availability-attributes.cs b/tests/bgen/tests/simulator-availability-attributes.cs
new file mode 100644
index 000000000000..1cce845e0b80
--- /dev/null
+++ b/tests/bgen/tests/simulator-availability-attributes.cs
@@ -0,0 +1,30 @@
+using System;
+using Foundation;
+using ObjCRuntime;
+
+namespace NS {
+ [UnsupportedSimulator ("ios")]
+ [UnsupportedSimulator ("tvos")]
+ [iOS (16, 0), TV (16, 0), Mac (13, 0), MacCatalyst (16, 0)]
+ [BaseType (typeof (NSObject))]
+ interface UnsupportedOnAllSimulators {
+ }
+
+ [UnsupportedSimulator ("ios")]
+ [iOS (16, 0), TV (16, 0), Mac (13, 0), MacCatalyst (16, 0)]
+ [BaseType (typeof (NSObject))]
+ interface UnsupportedOnIosSimulatorOnly {
+ }
+
+ [SupportedSimulator ("ios17.0")]
+ [SupportedSimulator ("tvos17.0")]
+ [iOS (16, 0), TV (16, 0), Mac (13, 0), MacCatalyst (16, 0)]
+ [BaseType (typeof (NSObject))]
+ interface SupportedOnSimulatorFromVersion {
+ }
+
+ [iOS (16, 0), TV (16, 0), Mac (13, 0), MacCatalyst (16, 0)]
+ [BaseType (typeof (NSObject))]
+ interface NoSimulatorAttributes {
+ }
+}
diff --git a/tests/common/PlatformInfo.cs b/tests/common/PlatformInfo.cs
index 11f7cacc582a..b89dd2810312 100644
--- a/tests/common/PlatformInfo.cs
+++ b/tests/common/PlatformInfo.cs
@@ -97,6 +97,54 @@ public static bool IsAvailableOnHostPlatform (this ICustomAttributeProvider attr
return attributeProvider.IsAvailable (PlatformInfo.Host);
}
+ public static bool IsAvailableInSimulator (this ICustomAttributeProvider attributeProvider)
+ {
+ if (!TestRuntime.IsSimulator)
+ return true;
+
+ var customAttributes = attributeProvider.GetCustomAttributes (true);
+
+ string platformPrefix;
+ switch (PlatformInfo.Host.Name) {
+ case ApplePlatform.iOS:
+ platformPrefix = "ios";
+ break;
+ case ApplePlatform.TVOS:
+ platformPrefix = "tvos";
+ break;
+ default:
+ return true;
+ }
+
+ // Check for [UnsupportedSimulator] attributes
+ foreach (var attr in customAttributes.OfType ()) {
+ if (attr.PlatformName.StartsWith (platformPrefix, StringComparison.OrdinalIgnoreCase))
+ return false;
+ }
+
+ // Check for [SupportedSimulator] attributes
+ var supportedAttrs = customAttributes.OfType ()
+ .Where (a => a.PlatformName.StartsWith (platformPrefix, StringComparison.OrdinalIgnoreCase))
+ .ToArray ();
+
+ // If no SupportedSimulator attributes for the current platform, assume available
+ if (supportedAttrs.Length == 0)
+ return true;
+
+ // There's a SupportedSimulator attribute for the current platform - check version
+ foreach (var attr in supportedAttrs) {
+ var versionString = attr.PlatformName.AsSpan (platformPrefix.Length);
+ if (versionString.IsEmpty)
+ return true; // supported, no version constraint
+ if (!Version.TryParse (versionString, out var version))
+ throw new InvalidOperationException ($"Invalid version string in SupportedSimulator attribute: '{attr.PlatformName}'");
+ if (PlatformInfo.Host.Version >= version)
+ return true;
+ }
+
+ return false;
+ }
+
[UnconditionalSuppressMessage ("Trimming", "IL2045", Justification = "Some of the attributes this method uses may have been linked away, so things might not work. It actually works though, so unless something changes, we're going to assume it's trimmer-compatible.")]
public static bool IsAvailable (this ICustomAttributeProvider attributeProvider, PlatformInfo targetPlatform)
{
diff --git a/tests/introspection/ApiBaseTest.cs b/tests/introspection/ApiBaseTest.cs
index 6e617346107e..66122f4b2326 100644
--- a/tests/introspection/ApiBaseTest.cs
+++ b/tests/introspection/ApiBaseTest.cs
@@ -158,6 +158,7 @@ protected virtual bool SkipDueToAttribute (MemberInfo? member)
return false;
return !member.IsAvailableOnHostPlatform () ||
+ !member.IsAvailableInSimulator () ||
SkipDueToAttribute (member.DeclaringType) ||
SkipDueToAttributeInProperty (member);
}
diff --git a/tests/introspection/ApiCtorInitTest.cs b/tests/introspection/ApiCtorInitTest.cs
index 53a9b0d0ca5c..bbfe6aef1e44 100644
--- a/tests/introspection/ApiCtorInitTest.cs
+++ b/tests/introspection/ApiCtorInitTest.cs
@@ -150,83 +150,12 @@ protected virtual bool Skip (Type type)
case "ASAccountAuthenticationModificationController":
return true; // started failing in Xcode 16.3 beta 1 for unknown reasons (it works in an Xcode project).
#if __TVOS__
- case "MTLAccelerationStructureDescriptor":
- case "MTLAccelerationStructureGeometryDescriptor":
- case "MTLAccelerationStructureMotionBoundingBoxGeometryDescriptor":
- case "MTLAccelerationStructureMotionTriangleGeometryDescriptor":
- case "MTLAccelerationStructurePassDescriptor":
- case "MTLAccelerationStructurePassSampleBufferAttachmentDescriptor":
- case "MTLAccelerationStructurePassSampleBufferAttachmentDescriptorArray":
- case "MTLAccelerationStructureTriangleGeometryDescriptor":
- case "MTLMeshRenderPipelineDescriptor":
- case "MTLMotionKeyframeData":
- case "MTLRasterizationRateLayerArray":
- case "MTLRasterizationRateMapDescriptor":
- case "MTLRasterizationRateSampleArray":
- case "MTLRenderPipelineFunctionsDescriptor":
- case "MTLResourceStatePassSampleBufferAttachmentDescriptor":
- case "MTLResourceStatePassSampleBufferAttachmentDescriptorArray":
- // The initial tvOS 16.0 simulator doesn't have these classes, but the tvOS 16.1 simulator doess
- if (TestRuntime.IsSimulator && !TestRuntime.CheckXcodeVersion (14, 1))
- return true;
- break;
case "CIPersonSegmentation": // removed in Xcode 26?
case "CISaliencyMapFilter": // removed in Xcode 26?
return TestRuntime.CheckXcodeVersion (26, 0);
#endif
case "PhaseConeDirectivityModelParameters":
return !TestRuntime.IsSimulator; // fails on device
- case "MTL4AccelerationStructureBoundingBoxGeometryDescriptor":
- case "MTL4AccelerationStructureCurveGeometryDescriptor":
- case "MTL4AccelerationStructureDescriptor":
- case "MTL4AccelerationStructureGeometryDescriptor":
- case "MTL4AccelerationStructureMotionBoundingBoxGeometryDescriptor":
- case "MTL4AccelerationStructureMotionCurveGeometryDescriptor":
- case "MTL4AccelerationStructureMotionTriangleGeometryDescriptor":
- case "MTL4AccelerationStructureTriangleGeometryDescriptor":
- case "MTL4ArgumentTableDescriptor":
- case "MTL4BinaryFunctionDescriptor":
- case "MTL4CommandAllocatorDescriptor":
- case "MTL4CommandBufferOptions":
- case "MTL4CommandQueueDescriptor":
- case "MTL4CommitOptions":
- case "MTL4CompilerDescriptor":
- case "MTL4CompilerTaskOptions":
- case "MTL4ComputePipelineDescriptor":
- case "MTL4CounterHeapDescriptor":
- case "MTL4FunctionDescriptor":
- case "MTL4IndirectInstanceAccelerationStructureDescriptor":
- case "MTL4InstanceAccelerationStructureDescriptor":
- case "MTL4LibraryDescriptor":
- case "MTL4LibraryFunctionDescriptor":
- case "MTL4MachineLearningPipelineDescriptor":
- case "MTL4MachineLearningPipelineReflection":
- case "MTL4MeshRenderPipelineDescriptor":
- case "MTL4PipelineDataSetSerializerDescriptor":
- case "MTL4PipelineDescriptor":
- case "MTL4PipelineOptions":
- case "MTL4PipelineStageDynamicLinkingDescriptor":
- case "MTL4PrimitiveAccelerationStructureDescriptor":
- case "MTL4RenderPassDescriptor":
- case "MTL4RenderPipelineBinaryFunctionsDescriptor":
- case "MTL4RenderPipelineColorAttachmentDescriptor":
- case "MTL4RenderPipelineColorAttachmentDescriptorArray":
- case "MTL4RenderPipelineDescriptor":
- case "MTL4RenderPipelineDynamicLinkingDescriptor":
- case "MTL4SpecializedFunctionDescriptor":
- case "MTL4StaticLinkingDescriptor":
- case "MTL4StitchedFunctionDescriptor":
- case "MTL4TileRenderPipelineDescriptor":
- case "MTLLogicalToPhysicalColorAttachmentMap":
- case "MTLResourceViewPoolDescriptor":
- case "MTLTensorDescriptor":
- case "MTLTensorReferenceType":
- case "MTLTextureViewDescriptor":
- case "MTLFXFrameInterpolatorDescriptor":
- case "MTLFXTemporalDenoisedScalerDescriptor":
- if (TestRuntime.IsSimulator)
- return true;
- break;
}
switch (type.Namespace) {
diff --git a/tests/introspection/ApiFieldTest.cs b/tests/introspection/ApiFieldTest.cs
index 1cb1b0fb715e..d850e49a0669 100644
--- a/tests/introspection/ApiFieldTest.cs
+++ b/tests/introspection/ApiFieldTest.cs
@@ -75,14 +75,6 @@ protected virtual bool Skip (PropertyInfo property)
default:
return false;
}
- case "CMSampleAttachmentKey": // kCMSampleAttachmentKey_HDR10PlusPerFrameData":
- switch (property.Name) {
- case "Hdr10PlusPerFrameDataKey":
- if (TestRuntime.IsSimulator)
- return !TestRuntime.CheckXcodeVersion (14, 1); // not available in the iOS 16.0 simulator, but it is in the iOS 16.1 simulator
- break;
- }
- break;
}
return SkipDueToAttribute (property);
}
diff --git a/tests/introspection/ApiPInvokeTest.cs b/tests/introspection/ApiPInvokeTest.cs
index 6d1df017699c..9407f80b3fb8 100644
--- a/tests/introspection/ApiPInvokeTest.cs
+++ b/tests/introspection/ApiPInvokeTest.cs
@@ -170,7 +170,7 @@ public void SymbolExists ()
IntPtr lib = Dlfcn.dlopen (path, 0);
if (Dlfcn.GetIndirect (lib, name) == IntPtr.Zero && !failed_api.Contains (name)) {
- ReportError ("Could not find the field '{0}' in {1}", name, path);
+ ReportError ("Could not find the symbol '{0}' in {1}", name, path);
failed_api.Add (name);
}
Dlfcn.dlclose (lib);
diff --git a/tests/introspection/ApiProtocolTest.cs b/tests/introspection/ApiProtocolTest.cs
index f7536f150a34..d8a36e874c40 100644
--- a/tests/introspection/ApiProtocolTest.cs
+++ b/tests/introspection/ApiProtocolTest.cs
@@ -38,10 +38,6 @@ protected virtual bool Skip (Type type)
if (TestRuntime.IsSimulatorOrDesktop)
return true;
break;
- case "SafetyKit":
- if (TestRuntime.IsSimulator)
- return !TestRuntime.CheckXcodeVersion (15, 0); // doesn't seem to be available in the iOS simulator until iOS 17+
- break;
case "SensorKit": // SensorKit doesn't exist on iPads
if (TestRuntime.IsDevice && TestRuntime.IsiPad)
return true;
@@ -67,108 +63,12 @@ protected virtual bool Skip (Type type)
// was removed by apple and is a compat class.
case "HMMatterRequestHandler":
return true;
- case "CIFilterGenerator":
- // only present on device :/
- return TestRuntime.IsSimulatorOrDesktop;
#if !XAMCORE_5_0
case "GKHybridStrategist":
// We removed the bindings for this type.
return true;
#endif
-#if __TVOS__
- case "MTLAccelerationStructureBoundingBoxGeometryDescriptor":
- case "MTLAccelerationStructureDescriptor":
- case "MTLAccelerationStructureGeometryDescriptor":
- case "MTLAccelerationStructureMotionBoundingBoxGeometryDescriptor":
- case "MTLAccelerationStructureMotionTriangleGeometryDescriptor":
- case "MTLAccelerationStructurePassDescriptor":
- case "MTLAccelerationStructurePassSampleBufferAttachmentDescriptor":
- case "MTLAccelerationStructurePassSampleBufferAttachmentDescriptorArray":
- case "MTLAccelerationStructureTriangleGeometryDescriptor":
- case "MTLInstanceAccelerationStructureDescriptor":
- case "MTLIntersectionFunctionDescriptor":
- case "MTLIntersectionFunctionTableDescriptor":
- case "MTLMeshRenderPipelineDescriptor":
- case "MTLMotionKeyframeData":
- case "MTLPrimitiveAccelerationStructureDescriptor":
- case "MTLRasterizationRateLayerArray":
- case "MTLRasterizationRateLayerDescriptor":
- case "MTLRasterizationRateMapDescriptor":
- case "MTLRasterizationRateSampleArray":
- case "MTLRenderPipelineFunctionsDescriptor":
- case "MTLResourceStatePassDescriptor":
- case "MTLResourceStatePassSampleBufferAttachmentDescriptor":
- case "MTLResourceStatePassSampleBufferAttachmentDescriptorArray":
- case "MTLVisibleFunctionTableDescriptor":
- // The initial tvOS 16.0 simulator doesn't have these classes, but the tvOS 16.1 simulator doess
- if (TestRuntime.IsSimulator && !TestRuntime.CheckXcodeVersion (14, 1))
- return true;
- goto default;
-#endif
- case "MTL4AccelerationStructureBoundingBoxGeometryDescriptor":
- case "MTL4AccelerationStructureCurveGeometryDescriptor":
- case "MTL4AccelerationStructureDescriptor":
- case "MTL4AccelerationStructureGeometryDescriptor":
- case "MTL4AccelerationStructureMotionBoundingBoxGeometryDescriptor":
- case "MTL4AccelerationStructureMotionCurveGeometryDescriptor":
- case "MTL4AccelerationStructureMotionTriangleGeometryDescriptor":
- case "MTL4AccelerationStructureTriangleGeometryDescriptor":
- case "MTL4ArgumentTableDescriptor":
- case "MTL4BinaryFunctionDescriptor":
- case "MTL4CommandAllocatorDescriptor":
- case "MTL4CommandBufferOptions":
- case "MTL4CommandQueueDescriptor":
- case "MTL4CommitOptions":
- case "MTL4CompilerDescriptor":
- case "MTL4CompilerTaskOptions":
- case "MTL4ComputePipelineDescriptor":
- case "MTL4CounterHeapDescriptor":
- case "MTL4FunctionDescriptor":
- case "MTL4IndirectInstanceAccelerationStructureDescriptor":
- case "MTL4InstanceAccelerationStructureDescriptor":
- case "MTL4LibraryDescriptor":
- case "MTL4LibraryFunctionDescriptor":
- case "MTL4MachineLearningPipelineDescriptor":
- case "MTL4MachineLearningPipelineReflection":
- case "MTL4MeshRenderPipelineDescriptor":
- case "MTL4PipelineDataSetSerializerDescriptor":
- case "MTL4PipelineDescriptor":
- case "MTL4PipelineOptions":
- case "MTL4PipelineStageDynamicLinkingDescriptor":
- case "MTL4PrimitiveAccelerationStructureDescriptor":
- case "MTL4RenderPassDescriptor":
- case "MTL4RenderPipelineBinaryFunctionsDescriptor":
- case "MTL4RenderPipelineColorAttachmentDescriptor":
- case "MTL4RenderPipelineColorAttachmentDescriptorArray":
- case "MTL4RenderPipelineDescriptor":
- case "MTL4RenderPipelineDynamicLinkingDescriptor":
- case "MTL4SpecializedFunctionDescriptor":
- case "MTL4StaticLinkingDescriptor":
- case "MTL4StitchedFunctionDescriptor":
- case "MTL4TileRenderPipelineDescriptor":
- case "MTLLogicalToPhysicalColorAttachmentMap":
- case "MTLResourceViewPoolDescriptor":
- case "MTLTensorDescriptor":
- case "MTLTensorExtents":
- case "MTLTensorReferenceType":
- case "MTLTextureViewDescriptor":
- case "VTFrameRateConversionConfiguration":
- case "VTFrameRateConversionParameters":
- case "VTLowLatencyFrameInterpolationConfiguration":
- case "VTLowLatencyFrameInterpolationParameters":
- case "VTLowLatencySuperResolutionScalerConfiguration":
- case "VTLowLatencySuperResolutionScalerParameters":
- case "VTMotionBlurConfiguration":
- case "VTMotionBlurParameters":
- case "VTOpticalFlowConfiguration":
- case "VTOpticalFlowParameters":
- case "VTSuperResolutionScalerConfiguration":
- case "VTSuperResolutionScalerParameters":
- case "VTTemporalNoiseFilterConfiguration":
- case "VTTemporalNoiseFilterParameters":
- if (TestRuntime.IsSimulator)
- return true;
- goto default;
+
default:
return SkipDueToAttribute (type);
}
@@ -1016,7 +916,6 @@ public virtual void SupportsSecureCoding ()
// check that +supportsSecureCoding returns YES
if (!supports) {
#if __IOS__ && !__MACCATALYST__
- // broken in xcode 12 beta 1 simulator (only)
if (TestRuntime.IsSimulator) {
switch (type.Name) {
case "ARFaceGeometry":
@@ -1100,21 +999,6 @@ public void GeneralCase ()
switch (t.Name) {
case "AVPlayerInterstitialEventMonitor": // deprecated
continue;
-#if !MONOMAC
- case "MTLCaptureManager":
- case "NEHotspotConfiguration":
- case "NEHotspotConfigurationManager":
- case "NEHotspotEapSettings":
- case "NEHotspotHS20Settings":
- case "SCNGeometryTessellator":
- case "SKRenderer":
- // was not possible in iOS 11.4 (current minimum) simulator
- if (!TestRuntime.CheckXcodeVersion (12, 0)) {
- if (TestRuntime.IsSimulatorOrDesktop)
- continue;
- }
- break;
-#endif
default:
var e = $"[FAIL] Could not load {t.FullName}";
list.Add (e);
diff --git a/tests/introspection/ApiSelectorTest.cs b/tests/introspection/ApiSelectorTest.cs
index 6a453e03f8a6..2f089ffa2ad3 100644
--- a/tests/introspection/ApiSelectorTest.cs
+++ b/tests/introspection/ApiSelectorTest.cs
@@ -46,10 +46,6 @@ protected virtual bool Skip (Type type)
}
switch (type.Namespace) {
- case "SafetyKit":
- if (TestRuntime.IsSimulator)
- return !TestRuntime.CheckXcodeVersion (15, 0); // doesn't seem to be available in the iOS simulator until iOS 17+
- break;
case "SensorKit": // SensorKit doesn't exist on iPads
if (TestRuntime.IsDevice && TestRuntime.IsiPad)
return true;
@@ -210,9 +206,6 @@ protected virtual bool Skip (Type type, string selectorName)
break;
#if !MONOMAC
case "MTLCaptureManager":
- case "NEHotspotEapSettings": // Wireless Accessory Configuration is not supported in the simulator.
- case "NEHotspotConfigurationManager":
- case "NEHotspotHS20Settings":
if (TestRuntime.IsSimulatorOrDesktop)
return true;
break;
@@ -1303,8 +1296,6 @@ protected virtual bool Skip (Type type, string selectorName)
}
break;
}
-
- // old binding mistake
return (selectorName == "initWithCoder:");
}
diff --git a/tests/introspection/ApiSimulatorAvailabilityTest.cs b/tests/introspection/ApiSimulatorAvailabilityTest.cs
new file mode 100644
index 000000000000..9f3fd98c4b1f
--- /dev/null
+++ b/tests/introspection/ApiSimulatorAvailabilityTest.cs
@@ -0,0 +1,201 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT License.
+
+//
+// Verify that [UnsupportedSimulator] / [SupportedSimulator] attributes
+// are consistent with actual symbol availability in the simulator.
+//
+
+using System.IO;
+using System.Linq;
+using System.Reflection;
+using Xamarin.Tests;
+
+#nullable enable
+
+namespace Introspection {
+ [Preserve (AllMembers = true)]
+ public abstract class ApiSimulatorAvailabilityTest : ApiBaseTest {
+
+ protected ApiSimulatorAvailabilityTest ()
+ {
+ ContinueOnFailure = true;
+ LogProgress = false;
+ }
+
+ protected virtual bool Skip (Type type)
+ {
+ return false;
+ }
+
+ protected virtual bool SkipPInvoke (MethodInfo mi)
+ {
+ return false;
+ }
+
+ protected virtual bool SkipField (PropertyInfo pi)
+ {
+ return false;
+ }
+
+ protected virtual bool SkipLibrary (string? libraryName)
+ {
+ return false;
+ }
+
+ ///
+ /// Verifies that P/Invokes marked as unsupported in the simulator are indeed unavailable.
+ /// Also detects P/Invokes not marked as unsupported that are missing from the simulator.
+ ///
+ [Test]
+ public void PInvokeSimulatorAvailability ()
+ {
+ if (!TestRuntime.IsSimulator) {
+ Assert.Ignore ("This test only runs in the simulator.");
+ return;
+ }
+
+ var failed_api = new List ();
+ Errors = 0;
+ int n = 0;
+
+ foreach (var type in Assembly.GetTypes ()) {
+ if (Skip (type))
+ continue;
+
+ if (!type.IsAvailableOnHostPlatform ())
+ continue;
+
+ foreach (var mi in type.GetMethods (BindingFlags.NonPublic | BindingFlags.Public | BindingFlags.Static)) {
+ var dllimport = mi.GetCustomAttribute ();
+ if (dllimport is null)
+ continue;
+
+ if (!mi.IsAvailableOnHostPlatform ())
+ continue;
+
+ if (MemberHasObsolete (mi))
+ continue;
+
+ if (SkipPInvoke (mi))
+ continue;
+
+ var libname = dllimport.Value;
+ switch (libname) {
+ case "__Internal":
+ case "System.Native":
+ case "System.Security.Cryptography.Native.Apple":
+ case "System.Net.Security.Native":
+ continue;
+ }
+
+ if (SkipLibrary (libname))
+ continue;
+
+ string name = dllimport.EntryPoint ?? mi.Name;
+ // skip known missing symbols
+ switch (name) {
+ case "objc_msgSend_stret":
+ case "objc_msgSendSuper_stret":
+ continue;
+ }
+
+ string path = FindLibrary (libname!, requiresFullPath: true);
+ IntPtr lib = Dlfcn.dlopen (path, 0);
+ bool symbolExists = lib != IntPtr.Zero && Dlfcn.GetIndirect (lib, name) != IntPtr.Zero;
+ if (lib != IntPtr.Zero)
+ Dlfcn.dlclose (lib);
+
+ bool markedUnavailable = !mi.IsAvailableInSimulator () || !type.IsAvailableInSimulator ();
+
+ if (markedUnavailable && symbolExists) {
+ var msg = $"P/Invoke '{type.FullName}.{mi.Name}' (symbol '{name}') is marked as unavailable in the simulator, but the symbol exists in '{path}'.";
+ ReportError (msg);
+ failed_api.Add ($"{type.FullName}.{mi.Name}");
+ } else if (!markedUnavailable && !symbolExists && lib != IntPtr.Zero) {
+ // The library exists but the symbol doesn't - might need [UnsupportedSimulator]
+ var msg = $"P/Invoke '{type.FullName}.{mi.Name}' (symbol '{name}') is not marked as unavailable in the simulator, but the symbol was not found in '{path}'. Consider adding [UnsupportedSimulator].";
+ ReportError (msg);
+ failed_api.Add ($"{type.FullName}.{mi.Name}");
+ }
+ n++;
+ }
+ }
+
+ AssertIfErrors ("{0} errors found in {1} P/Invoke simulator availability checks: {2}",
+ Errors, n, string.Join (", ", failed_api));
+ }
+
+ ///
+ /// Verifies that [Field] properties marked as unsupported in the simulator are indeed unavailable.
+ /// Also detects [Field] properties not marked as unsupported that are missing from the simulator.
+ ///
+ [Test]
+ public void FieldSimulatorAvailability ()
+ {
+ if (!TestRuntime.IsSimulator) {
+ Assert.Ignore ("This test only runs in the simulator.");
+ return;
+ }
+
+ var failed_fields = new List ();
+ Errors = 0;
+ int n = 0;
+
+ foreach (var type in Assembly.GetTypes ()) {
+ if (Skip (type))
+ continue;
+
+ if (!type.IsAvailableOnHostPlatform ())
+ continue;
+
+ foreach (var p in type.GetProperties (BindingFlags.Static | BindingFlags.Public | BindingFlags.NonPublic)) {
+ if (p.CanWrite || !p.CanRead)
+ continue;
+
+ var fieldAttr = p.GetCustomAttribute ();
+ if (fieldAttr is null)
+ continue;
+
+ if (!p.IsAvailableOnHostPlatform ())
+ continue;
+
+ if (MemberHasObsolete (p))
+ continue;
+
+ if (SkipField (p))
+ continue;
+
+ string symbolName = fieldAttr.SymbolName;
+ string? libName = fieldAttr.LibraryName;
+
+ if (SkipLibrary (libName))
+ continue;
+
+ string path = FindLibrary (libName!);
+ IntPtr lib = Dlfcn.dlopen (path, 0);
+ bool symbolExists = lib != IntPtr.Zero && Dlfcn.GetIndirect (lib, symbolName) != IntPtr.Zero;
+ if (lib != IntPtr.Zero)
+ Dlfcn.dlclose (lib);
+
+ bool markedUnavailable = !p.IsAvailableInSimulator () || !type.IsAvailableInSimulator ();
+
+ if (markedUnavailable && symbolExists) {
+ var msg = $"Field '{type.FullName}.{p.Name}' (symbol '{symbolName}') is marked as unavailable in the simulator, but the symbol exists in '{path}'.";
+ ReportError (msg);
+ failed_fields.Add ($"{type.FullName}.{p.Name}");
+ } else if (!markedUnavailable && !symbolExists && lib != IntPtr.Zero) {
+ // The library exists but the symbol doesn't - might need [UnsupportedSimulator]
+ var msg = $"Field '{type.FullName}.{p.Name}' (symbol '{symbolName}') is not marked as unavailable in the simulator, but the symbol was not found in '{path}'. Consider adding [UnsupportedSimulator].";
+ ReportError (msg);
+ failed_fields.Add ($"{type.FullName}.{p.Name}");
+ }
+ n++;
+ }
+ }
+
+ AssertIfErrors ("{0} errors found in {1} field simulator availability checks: {2}",
+ Errors, n, string.Join (", ", failed_fields));
+ }
+ }
+}
diff --git a/tests/introspection/ApiTypoTest.cs b/tests/introspection/ApiTypoTest.cs
index 109708a47a15..49a0fc0ec91c 100644
--- a/tests/introspection/ApiTypoTest.cs
+++ b/tests/introspection/ApiTypoTest.cs
@@ -1047,18 +1047,11 @@ public void ConstantsCheck ()
break;
#endif
#if __TVOS__
- case "MetalPerformanceShadersLibrary":
case "MetalPerformanceShadersGraphLibrary":
// not supported in tvOS (12.1) simulator so load fails
if (TestRuntime.IsSimulatorOrDesktop)
break;
goto default;
- case "PhaseLibrary":
- // framework support for tvOS was added in xcode 15
- // but not supported on tvOS simulator so load fails
- if (TestRuntime.IsSimulatorOrDesktop)
- break;
- goto default;
#endif
case "MetalFXLibrary":
if (TestRuntime.IsSimulatorOrDesktop)
@@ -1082,9 +1075,6 @@ public void ConstantsCheck ()
// NFC is currently not available on iPad
if (UIDevice.CurrentDevice.UserInterfaceIdiom == UIUserInterfaceIdiom.Pad)
continue;
- // Phone works unless Xcode 12 on simulator
- if (TestRuntime.IsSimulatorOrDesktop && TestRuntime.CheckXcodeVersion (12, 0))
- continue;
}
#endif
#if __MACOS__
diff --git a/tests/introspection/dotnet/shared.csproj b/tests/introspection/dotnet/shared.csproj
index 8f70d4b1fea9..408680114472 100644
--- a/tests/introspection/dotnet/shared.csproj
+++ b/tests/introspection/dotnet/shared.csproj
@@ -52,6 +52,7 @@
+
@@ -93,6 +94,9 @@
ApiPInvokeTest.cs
+
+ ApiSimulatorAvailabilityTest.cs
+
ApiProtocolTest.cs
diff --git a/tests/introspection/iOSApiCtorInitTest.cs b/tests/introspection/iOSApiCtorInitTest.cs
index 777adbd02c60..58dc7992b39e 100644
--- a/tests/introspection/iOSApiCtorInitTest.cs
+++ b/tests/introspection/iOSApiCtorInitTest.cs
@@ -31,28 +31,12 @@ public iOSApiCtorInitTest ()
protected override bool Skip (Type type)
{
switch (type.Namespace) {
- // all default ctor did not work and were replaced with [Obsolete("",true)] placeholders
- // reflecting on those would create invalid instances (no handle) that crash the app
- case "CoreBluetooth":
- case "MonoTouch.CoreBluetooth":
- return true;
-
- case "CoreAudioKit":
- case "MonoTouch.CoreAudioKit":
- case "Metal":
- case "MonoTouch.Metal":
- // they works with iOS9 beta 4 (but won't work on older simulators)
- if (TestRuntime.IsSimulatorOrDesktop && !TestRuntime.CheckXcodeVersion (7, 0))
- return true;
- break;
case "MetalKit":
- case "MonoTouch.MetalKit":
case "MetalPerformanceShaders":
- case "MonoTouch.MetalPerformanceShaders":
- if (TestRuntime.IsSimulatorOrDesktop)
- return true;
// some devices don't support metal and that crash some API that does not check that, e.g. #33153
- if (!TestRuntime.CheckXcodeVersion (7, 0) || (MTLDevice.SystemDefault is null))
+ if (MTLDevice.SystemDefault is null)
+ return true;
+ if (TestRuntime.IsSimulatorOrDesktop)
return true;
break;
#if __TVOS__
@@ -156,10 +140,6 @@ protected override bool Skip (Type type)
case "NSPersistentStoreCoordinator":
return true;
- // Metal is not available on the (iOS8) simulator
- case "CAMetalLayer":
- return TestRuntime.IsSimulatorOrDesktop && !TestRuntime.CheckXcodeVersion (11, 0);
-
// in 8.2 beta 1 this crash the app (simulator) without giving any details in the logs
case "WKUserNotificationInterfaceController":
return true;
@@ -175,10 +155,6 @@ protected override bool Skip (Type type)
// NSInvalidArgumentException Reason: image must be non-nil
return true;
- // these work only on devices, so we skip the simulator
- case "MTLHeapDescriptor":
- case "MTLSharedEventListener":
- return TestRuntime.IsSimulatorOrDesktop;
// iOS 11 Beta 1
case "UICollectionViewFocusUpdateContext": // [Assert] -init is not a useful initializer for this class. Use one of the designated initializers instead
case "UIFocusUpdateContext": // [Assert] -init is not a useful initializer for this class. Use one of the designated initializers instead
@@ -190,21 +166,11 @@ protected override bool Skip (Type type)
return true;
case "IOSurface": // Only works on device before Xcode 11
return !TestRuntime.CheckXcodeVersion (11, 0);
- case "NEHotspotEapSettings": // Wireless Accessory Configuration is not supported in the simulator.
- case "NEHotspotConfigurationManager":
- case "NEHotspotHS20Settings":
- return TestRuntime.IsSimulatorOrDesktop;
// iOS 12
case "INGetAvailableRestaurantReservationBookingDefaultsIntentResponse": // Objective-C exception thrown. Name: NSInternalInconsistencyException Reason: Unable to initialize 'INGetAvailableRestaurantReservationBookingDefaultsIntentResponse'. Please make sure that your intent definition file is valid.
case "INGetAvailableRestaurantReservationBookingsIntentResponse": // Objective-C exception thrown. Name: NSInternalInconsistencyException Reason: Unable to initialize 'INGetAvailableRestaurantReservationBookingsIntentResponse'. Please make sure that your intent definition file is valid.
case "INGetRestaurantGuestIntentResponse": // Objective-C exception thrown. Name: NSInternalInconsistencyException Reason: Unable to initialize 'INGetRestaurantGuestIntentResponse'. Please make sure that your intent definition file is valid.
return TestRuntime.CheckXcodeVersion (10, 0);
- case "CMMovementDisorderManager": // Not available in simulator, added info to radar://41110708
- return TestRuntime.IsSimulatorOrDesktop;
- case "RPSystemBroadcastPickerView": // Symbol not available in simulator
- return TestRuntime.IsSimulatorOrDesktop;
- case "ICNotificationManagerConfiguration": // This works on device but not on simulator, and docs explicitly says it is user creatable
- return TestRuntime.IsSimulatorOrDesktop;
case "VNDocumentCameraViewController": // Name: NSGenericException Reason: Document camera is not available on simulator
return TestRuntime.IsSimulatorOrDesktop;
case "AVAudioRecorder": // Stopped working with Xcode 11.2 beta 2
diff --git a/tests/introspection/iOSApiFieldTest.cs b/tests/introspection/iOSApiFieldTest.cs
index 11b1157a24f1..638aefa8cc55 100644
--- a/tests/introspection/iOSApiFieldTest.cs
+++ b/tests/introspection/iOSApiFieldTest.cs
@@ -129,51 +129,15 @@ protected override bool Skip (string constantName, string? libraryName)
if (Class.GetHandle ("NFCNDEFReaderSession") == IntPtr.Zero)
return true;
break;
- case "IOSurface":
- return TestRuntime.IsSimulatorOrDesktop && !TestRuntime.CheckXcodeVersion (9, 0);
}
switch (constantName) {
- // grep ImageIO binary shows those symbols are not part of the binary
- // that match older results (nil) when loading them (see above)
- case "kCGImagePropertyAPNGLoopCount":
- case "kCGImagePropertyAPNGDelayTime":
- case "kCGImagePropertyAPNGUnclampedDelayTime":
- case "kCGImagePropertyMakerFujiDictionary":
- case "kCGImagePropertyMakerMinoltaDictionary":
- case "kCGImagePropertyMakerOlympusDictionary":
- case "kCGImagePropertyMakerPentaxDictionary":
- //
- case "kCFHTTPAuthenticationSchemeOAuth1":
- return true;
// Apple does not ship a PushKit for every arch on some devices :(
case "PKPushTypeVoIP":
return TestRuntime.IsDevice;
- // there's only partial support for metal on the simulator (on iOS9 beta 5) but most other frameworks
- // that interop with it are not (yet) supported
- case "kCVMetalTextureCacheMaximumTextureAgeKey":
- case "kCVMetalTextureUsage":
- case "MPSRectNoClip":
- case "MTLCommandBufferErrorDomain":
- case "MTKTextureLoaderErrorDomain":
- case "MTKTextureLoaderErrorKey":
- case "MTKTextureLoaderOptionAllocateMipmaps":
- case "MTKTextureLoaderOptionSRGB":
- case "MTKTextureLoaderOptionTextureUsage":
- case "MTKTextureLoaderOptionTextureCPUCacheMode":
- case "MTKModelErrorDomain":
- case "MTKModelErrorKey":
- return TestRuntime.IsSimulatorOrDesktop;
- // Xcode 12.2 Beta 1 does not ship this but it is available in Xcode 12.0...
- case "HKMetadataKeyBarometricPressure":
- return true;
- case "kCMSampleAttachmentKey_HDR10PlusPerFrameData":
- if (TestRuntime.IsSimulator)
- return !TestRuntime.CheckXcodeVersion (14, 1); // not available in the iOS 16.0 simulator, but it is in the iOS 16.1 simulator
- goto default;
- default:
- return false;
}
+
+ return base.Skip (constantName, libraryName);
}
}
}
diff --git a/tests/introspection/iOSApiPInvokeTest.cs b/tests/introspection/iOSApiPInvokeTest.cs
index e5c240d80d03..d04bbd797a7e 100644
--- a/tests/introspection/iOSApiPInvokeTest.cs
+++ b/tests/introspection/iOSApiPInvokeTest.cs
@@ -18,54 +18,6 @@ namespace Introspection {
// we want the tests to be available because we use the linker
[Preserve (AllMembers = true)]
public class iOSApiPInvokeTest : ApiPInvokeTest {
-
- protected override bool Skip (string symbolName)
- {
- var simulator = TestRuntime.IsSimulatorOrDesktop;
- switch (symbolName) {
- // Metal support inside simulator is only available in recent iOS9 SDK
- case "MTLCreateSystemDefaultDevice":
- return simulator && !UIDevice.CurrentDevice.CheckSystemVersion (9, 0);
- // still most Metal helpers are not available on the simulator (even when the framework is present, it's missing symbols)
- case "MPSSupportsMTLDevice":
- case "MPSGetPreferredDevice":
- // neither are the CoreVideo extensions for Metal
- case "CVMetalTextureGetTexture":
- case "CVMetalTextureIsFlipped":
- case "CVMetalTextureGetCleanTexCoords":
- case "CVMetalTextureCacheCreate":
- case "CVMetalTextureCacheFlush":
- case "CVMetalTextureCacheCreateTextureFromImage":
- case "MTKMetalVertexDescriptorFromModelIO":
- case "MTKModelIOVertexDescriptorFromMetal":
- case "MTKModelIOVertexFormatFromMetal":
- case "MTKMetalVertexFormatFromModelIO":
- case "MTLIOCompressionContextAppendData":
- case "MTLIOCreateCompressionContext":
- case "MTLIOFlushAndDestroyCompressionContext":
- case "MTLIOCompressionContextDefaultChunkSize":
- case "MPSImageBatchIncrementReadCount":
- case "MPSImageBatchSynchronize":
- case "MPSImageBatchResourceSize":
- case "MPSStateBatchIncrementReadCount":
- case "MPSStateBatchSynchronize":
- case "MPSStateBatchResourceSize":
- case "MPSHintTemporaryMemoryHighWaterMark":
- case "MPSSetHeapCacheDuration":
- case "MPSGetImageType":
- return simulator;
- case "CVPixelBufferGetIOSurface":
- case "CVPixelBufferCreateWithIOSurface":
- return simulator && !TestRuntime.CheckXcodeVersion (11, 0);
-
- default:
- // MLCompute not available in simulator as of Xcode 12 beta 3
- if (simulator && symbolName.StartsWith ("MLC", StringComparison.Ordinal))
- return true;
- return base.Skip (symbolName);
- }
- }
-
protected override bool SkipAssembly (Assembly a)
{
if (a == typeof (NSObject).Assembly) {
diff --git a/tests/introspection/iOSApiSimulatorAvailabilityTest.cs b/tests/introspection/iOSApiSimulatorAvailabilityTest.cs
new file mode 100644
index 000000000000..8c46cf563b78
--- /dev/null
+++ b/tests/introspection/iOSApiSimulatorAvailabilityTest.cs
@@ -0,0 +1,40 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT License.
+
+using System.Reflection;
+
+namespace Introspection {
+
+ [TestFixture]
+ [Preserve (AllMembers = true)]
+ public class iOSApiSimulatorAvailabilityTest : ApiSimulatorAvailabilityTest {
+
+ protected override bool SkipPInvoke (MethodInfo mi)
+ {
+ switch (mi.DeclaringType?.Namespace) {
+ case "CoreNFC":
+ if (Class.GetHandle ("NFCNDEFReaderSession") == IntPtr.Zero)
+ return true;
+ break;
+ }
+
+ return base.SkipPInvoke (mi);
+ }
+
+ protected override bool SkipField (PropertyInfo pi)
+ {
+ switch (pi.DeclaringType?.Namespace) {
+ case "CoreNFC":
+ if (Class.GetHandle ("NFCNDEFReaderSession") == IntPtr.Zero)
+ return true;
+ break;
+ case "DeviceCheck":
+ return true;
+ case "Phase":
+ return true;
+ }
+
+ return base.SkipField (pi);
+ }
+ }
+}
From 40269175bb2171fee3b83f5cbb448b14b40040d6 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Mon, 11 May 2026 13:56:11 +0200
Subject: [PATCH 036/156] [tests] Fix introspection TypoTest not being
discovered by NUnit
The overridden TypoTest() methods in iOSApiTypoTest and MacApiTypoTest
were missing the [Test] attribute. NUnit doesn't inherit [Test] from
base class virtual methods to overrides, so these tests were silently
never running.
Add [Test] to the overrides, and add all the newly-discovered 'typo'
words (abbreviations, acronyms, and technical terms) to the allowed
list so the test passes.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
tests/introspection/ApiTypoTest.cs | 193 ++++++++++++++++++++++++++
tests/introspection/MacApiTypoTest.cs | 1 +
tests/introspection/iOSApiTypoTest.cs | 1 +
3 files changed, 195 insertions(+)
diff --git a/tests/introspection/ApiTypoTest.cs b/tests/introspection/ApiTypoTest.cs
index 49a0fc0ec91c..67d093c02180 100644
--- a/tests/introspection/ApiTypoTest.cs
+++ b/tests/introspection/ApiTypoTest.cs
@@ -66,36 +66,53 @@ public virtual bool Skip (MemberInfo methodName, string typo)
HashSet allowed = new HashSet () {
"Aac",
+ "Abgr",
+ "Accurracy",
"Achivements",
"Acos",
"Acosh",
"Acn",
"Actionname",
+ "Activatable",
"Activitiy",
"Addin",
"Addl",
"Addr",
+ "Adessive",
"Adjustmentfor",
"Aes", // Advanced Encryption Standard
+ "Afi",
+ "Ahap",
"Aifc",
"Aiff",
"Agc",
"Aio",
"Alg", // short for Algorithm
+ "Allative",
"Alpn", // Application-Layer Protocol Negotiation RFC7301
"Amete",
"Amr",
+ "Ancs",
+ "Ane",
"Anglet",
+ "Apac",
+ "Apdu",
+ "Apl",
"Apng", // Animated Portable Network Graphics
+ "Apns",
+ "Applei",
"Aps",
"Arraycollation",
"Argb",
"Asin",
"Asinh",
+ "Astc",
"Atan",
"Atanh",
"Atmos", // Dolby Atmos
+ "Atr",
"Ats", // App Transport Security
+ "Atsc",
"Attrib",
"Attributevalue",
"Attrs", // Attributes (used by Apple for keys)
@@ -112,12 +129,16 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Arcball",
"Atm",
"Avg",
+ "Axept",
"Backface",
"Bancaire", // french
"Bancaires", // french
+ "Bancomat",
"Bary",
"Batc",
+ "Ber",
"Bgra", // acrnym for Blue, Green, Red, Alpha
+ "Bgrx",
"Bim",
"Biquad",
"Bitangent",
@@ -125,17 +146,25 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Blit",
"Bokeh",
"Bggr", // acronym for Blue, Green, Green, Red
+ "Brotli",
"Bsln",
"Bssid",
"Btle", // Bluetooth Low Energy
"Bzip",
"Cabac",
"Caf", // acronym: Core Audio Format
+ "Callables",
+ "Callpout",
"Cancellable",
"Cartes", // french
+ "Catmull",
"Cavlc",
+ "Cct",
+ "Ccw",
"Cda", // acronym: Clinical Document Architecture
+ "Cdma",
"Cdrom",
+ "Cea",
"Celu", // Continuously Differentiable Exponential Linear Unit (ML)
"Cfa", // acronym: Color Filter Array
"Celp", // MPEG4ObjectID
@@ -144,38 +173,61 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Cholesky",
"Chacha",
"Chromaticities",
+ "Chw",
"Ciexyz",
"Ciff",
"Cinepak",
+ "Cla",
"Clearcoat",
+ "Clockstamp",
"Cnn", // Convolutional Neural Network
"Cns",
+ "Codabar",
"Colos",
"Commerical",
"Composable",
+ "Conecs",
"Conflictserror",
"Connnect",
+ "Conv",
+ "Cose",
"Counterclock",
"Copyback",
"Craete",
"Crosstraining",
+ "Csr",
+ "Ctor",
"Cubemap",
"Cmaf", // Common Media Application Format (mpeg4)
"Cmy", // acronym: Cyan, magenta, yellow
"Cmyk", // acronym: Cyan, magenta, yellow and key
"Daap",
+ "Dangi",
+ "Dankort",
"Dav",
"Dcip", // acronym: Digital Cinema Implementation Partners
"Deca",
"Decomposables",
"Deinterlace",
+ "Denimonator",
+ "Denoise",
+ "Denoised",
"Depthwise",
+ "Dequantize",
"Descendents",
"Descrete",
+ "Descriptorat",
+ "Descriptorfor",
+ "Dfsi",
"Dhe", // Diffie–Hellman key exchange
+ "Dhs",
+ "Dhwio",
+ "Dicom",
+ "Diconnection",
"Diffable", // that you can diff it.. made up word from apple
"Differental",
"Diffie",
+ "Dirbursement",
"Directionfor",
"Dist",
"dlclose",
@@ -187,6 +239,7 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"dlsym",
"Dng",
"Dns",
+ "Dnssec",
"Dont",
"Dop",
"Dopesheet",
@@ -196,6 +249,9 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Dpad", // Directional pad (D-pad)
"Dpads", // plural of above
"Droste",
+ "Dsf",
+ "Dsfi",
+ "Dstu",
"Dtls",
"Dtmf", // DTMF
"dy",
@@ -205,11 +261,15 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Ecdh", // Elliptic Curve Diffie–Hellman
"Ecdhe", // Elliptic Curve Diffie-Hellman Ephemeral
"Ecdsa", // Elliptic Curve Digital Signature Algorithm
+ "Ecg",
"Ecies", // Elliptic Curve Integrated Encryption Scheme
"Ecn", // Explicit Congestion Notification
"Ect", // ECN Capable Transport
"Editability",
"Edr",
+ "Elative",
+ "Emebedding",
+ "Endc",
"Eof", // acronym End-Of-File
"Elu",
"Emagic",
@@ -221,6 +281,9 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Epub",
"Eftpos", // Electronic funds transfer at point of sale
"Eotf", // DisplayP3_PQ_Eotf
+ "Erf",
+ "Essive",
+ "Evdo",
"Exabits",
"Exbibits",
"Exbibytes",
@@ -228,12 +291,16 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Exp",
"Expr",
"Exr",
+ "Extrinsics",
+ "Feli",
"Felica", // Japanese contactless RFID smart card system
"Femtowatts",
+ "Fft",
"Fhir",
"Flipside",
"Formati",
"Fov",
+ "Fqdns",
"Framebuffer",
"Framesetter",
"Froms", // NSMetadataItemWhereFromsKey
@@ -241,7 +308,11 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Ftps",
"Func",
"Gadu",
+ "Gainmap",
"Gbrg", // acronym for Green-Blue-Reg-Green
+ "Gbtac",
+ "Gbtdc",
+ "Gcm",
"Gelu", // Gaussian Error Linear Unit (ML)
"Geocoder",
"Gigapascals",
@@ -254,6 +325,7 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Gps",
"Gpu", // acronym for Graphics Processing Unit
"Grbg", // acronym for Green-Red-Blue-Green
+ "Groupless",
"Gru",
"Greeking",
"Gtin",
@@ -265,17 +337,26 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Hectopascals",
"Heic", // file type
"Heif", // file type
+ "Hermitean",
"Hevc", // CMVideoCodecType / High Efficiency Video Coding
"Heif", // High Efficiency Image File Format
"Hfp",
+ "Hhr",
+ "Himyan",
+ "Hindlegs",
"Hipass",
+ "Histogrammed",
"Hlg", // Hybrid Log-Gamma
"Hls",
"Hoa",
"Hrtf", // acronym used in AUSpatializationAlgorithm
"Hvxc", // MPEG4ObjectID
+ "Hwc",
+ "Hwio",
+ "Iap",
"Icns",
"Ico",
+ "Iec",
"Ies",
"Icq",
"Ident",
@@ -284,8 +365,12 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Imagefor",
"Imap",
"Imaps",
+ "Imei",
"Img",
"Impl", // BindingImplAttribute
+ "Inessive",
+ "Inot",
+ "Intravaginal",
"Inv",
"Indoorrun",
"Indoorcycle",
@@ -309,18 +394,26 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Iptc",
"Ircs",
"Iso",
+ "Isrc",
"Itf",
+ "Itt",
"Itu",
"Itur", // Itur_2020_Hlg
+ "Jaywan",
"Jcb", // Japanese credit card company
"Jfif",
"Jis",
+ "Jrts",
"Json",
+ "Jws",
+ "Keepalive",
+ "Keycode",
"Keyerror",
"Keyi",
"Keypoint",
"Keypoints",
"Keyspace",
+ "Kickboard",
"ks",
"Kibibits",
"Kibibytes",
@@ -332,6 +425,7 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Langauges",
"Lacunarity",
"Latm", // Low Overhead Audio Transport Multiplex
+ "Lbc",
"Ldaps",
"Lerp",
"Linecap",
@@ -342,9 +436,13 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Lod",
"Lopass",
"Lowlevel",
+ "Lpcm",
"Lstm",
+ "Lte",
+ "Ltr",
"Lun",
"Luma",
+ "Lut",
"Lzfse", // acronym
"Lzma", // acronym
"Mada", // payment system
@@ -353,12 +451,15 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Mcp", // metacarpophalangeal (hand)
"Mebibits",
"Mebibytes",
+ "Mebx",
+ "Meeza",
"Megaampere",
"Megaamperes",
"Megaliters",
"Megameters",
"Megaohms",
"Megapascals",
+ "Mennekes",
"Metacharacters",
"Metalness",
"Metadatas",
@@ -366,14 +467,19 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Microamperes",
"Microohms",
"Microwatts",
+ "Mifare",
"Millimoles",
"Milliohms",
"Mimap",
"Minification",
+ "Mmw",
"Mncs",
"Mgmt",
"Mobike", // acronym
+ "Monoline",
"Morpher",
+ "Msi",
+ "Mtl",
"mtouch",
"Mpe", // acronym
"Mps",
@@ -381,21 +487,39 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Mtu", // acronym
"Mtc", // acronym
"Mtgp",
+ "Muid",
"Mul",
"Mult",
+ "Multiary",
"Multihead",
"Multipath",
"Multipeer",
+ "Multiscript",
+ "Multiselect",
+ "Multivariant",
+ "Multiview",
"Muxed",
+ "Nacs",
"Nai",
+ "Nanaco",
+ "Nand",
"Nanograms",
"Nanowatts",
+ "Ncdhw",
+ "Nchw",
+ "nd",
+ "Ndhwc",
"Nestrov",
"Nesterov",
+ "Nfc",
"nfloat",
"Nfnt",
+ "Nhwc",
"nint",
"Nntps",
+ "Noninteractive",
+ "Noop",
+ "Nsa",
"Ntlm",
"Nsl", // InternetLocationNslNeighborhoodIcon
"Ntsc",
@@ -409,20 +533,29 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Objectfor",
"Objectness",
"Occlussion",
+ "Ocr",
"Ocurrences",
"Ocsp", // Online Certificate Status Protocol
"Octree",
+ "Odia",
+ "Ohwi",
"Oid",
+ "Oidhw",
+ "Oihw",
"Oneup", // TVElementKeyOneupTemplate
+ "Onnx",
+ "Oper",
"Organisation", // kCGImagePropertyIPTCExtRegistryOrganisationID in Xcode9.3-b1
"Orthographyrange",
"Orth",
"Osa", // Open Scripting Architecture
"Otsu", // threshold for image binarization
"ove",
+ "Overline",
"Paeth", // PNG filter
"Palettize",
"Parms", // short for Parameters
+ "Pci",
"Peap",
"Pebibits",
"Pebibytes",
@@ -437,10 +570,13 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Pesented",
"Pfs", // acronym
"Philox",
+ "Photoplethysmogram",
+ "Phq",
"Picometers",
"Picowatts",
"Pkcs",
"Placemark",
+ "Playout",
"Playthrough",
"Pnc", // MIDI
"Pnorm",
@@ -448,22 +584,30 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Polyline",
"Polylines",
"Popularimeter",
+ "Postback",
+ "Ppk",
"Preds", // short for Predicates
+ "Prefilter",
+ "Prereleased",
"Prerolls",
"Preseti",
"Prev",
+ "Prf",
"Privs", // SharingPrivsNotApplicableIcon
"Propogate",
"Psec",
+ "Pskc",
"Psm", // Protocol/Service Multiplexer
"Psk",
"Ptp",
+ "Pvr",
"Pvrtc", // MTLBlitOption - PowerVR Texture Compression
"Qos",
"Quaterniond",
"Quadding",
"Qura",
"Quic",
+ "Qwac",
"Reacquirer",
"Reinvitation",
"Reinvite",
@@ -471,37 +615,50 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Relocalization",
"Relu", // Rectified Linear Unit (ML)
"Relun", // ReLUn - degree n Hermite coefficients
+ "Remmote",
"Reprandial",
"Replayable",
+ "Reprojection",
"Requestwith",
+ "Rgbaf",
+ "Rgbah",
+ "Rgbx",
"Ridesharing",
"Rgb",
"Rgba",
"Rggb", // acronym for Red, Green, Green, Blue
+ "Rint",
+ "Rle",
"Rnn",
"Roi",
"Romm", // acronym: Reference Output Medium Metric
"Rpa",
"Rpn", // acronym
"Rsa", // Rivest, Shamir and Adleman
+ "Rsapss",
"Rsqrt", // reciprocal square root
"Rssi",
"Rtp",
"Rtl",
"Rtsp",
"Saml", // acronym
+ "Scc",
"Sdof",
"Scn",
"Sdk",
+ "Sdr",
"Sdtv", // acronym: Standard Definition Tele Vision
"Sdnn",
"Seekable",
+ "Sel",
"Selu", // Scaled Exponential Linear unit (ML)
+ "Sensel",
"Sgd", // Stochastic Gradient Descent (ML)
"Shadable",
"Sharegroup",
"Sha", // Secure Hash Algorithm
"Siemen",
+ "Signbit",
"simd",
"Sinh",
"Sint", // as in "Signed Integer"
@@ -510,21 +667,29 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Slomo",
"Smpte",
"Snapshotter",
+ "Snn",
"Snorm",
"Sobel",
"Softmax", // get_SoftmaxNormalization
"Spacei",
+ "Spl",
"Sqrt",
"Srgb",
"Ssid",
"Ssids",
+ "Ssml",
+ "st",
"Standarize",
"Stateful",
"Stateright",
+ "Strided",
+ "Subband",
"Subbeat",
"Subcaption",
"Subcardioid",
"Subentities",
+ "Subfilter",
+ "Subfilters",
"Subheadline",
"Sublocality",
"Sublocation",
@@ -538,17 +703,24 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Superentity",
"Supertype",
"Supertypes",
+ "Supression",
+ "Svfg",
"Svg", // Scalable Vector Graphics
+ "Svgf",
+ "Swolf",
"Sym",
"Synchronizable",
"Symbologies",
+ "Sysex",
"Tanh",
+ "Tbgr",
"Tebibits",
"Tebibytes",
"Tensorflow",
"Tessellator",
"Texcoord",
"Texel",
+ "Tga",
"th",
"Threadgroup",
"Threadgroups",
@@ -559,6 +731,9 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Timelapse",
"Timelapses",
"Tls",
+ "Tmoney",
+ "Tonemap",
+ "Tri",
"Ttls",
"Tlv",
"Toc",
@@ -577,16 +752,22 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Undecodable",
"Unemphasized",
"Underrun",
+ "Unfetched",
"Unflagged",
"Unfocusing",
"Uid",
+ "Unioning",
"Unmap",
+ "Unmatch",
"Unorm",
"Unpremultiplied",
"Unpremultiplying",
"Unprepare",
"Unproject",
"Unpublish",
+ "Unsolo",
+ "Usec",
+ "Ussd",
"Uterance",
"Unentitled",
"Untrash",
@@ -598,19 +779,30 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Usdz", // USD zip
"Uti",
"Varispeed",
+ "Vbr",
+ "Vbv",
"Vergence",
+ "Voip",
"Voronoi",
"Vnode",
"Vpn",
+ "Vtt",
+ "Waon",
"Warichu",
+ "Wcdma",
"Wep",
+ "Willl",
+ "Wlan",
"Wpa",
"Warpable",
"Whitespaces",
"Wifes",
"Writeability",
+ "Xbgr",
+ "Xmp",
"Xnor",
"Xpc",
+ "Xrgb",
"xy",
"Xyz",
"Xzy",
@@ -619,6 +811,7 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Yottabits",
"Yxz",
"Yzx",
+ "Zenkaku",
"Zxy",
"Zyx",
"Yuv",
diff --git a/tests/introspection/MacApiTypoTest.cs b/tests/introspection/MacApiTypoTest.cs
index d9fd73e0ab51..daa6f6696ef6 100644
--- a/tests/introspection/MacApiTypoTest.cs
+++ b/tests/introspection/MacApiTypoTest.cs
@@ -7,6 +7,7 @@ namespace Introspection {
public class MacApiTypoTest : ApiTypoTest {
NSSpellChecker? checker;
+ [Test]
public override void TypoTest ()
{
AssertMatchingOSVersionAndSdkVersion ();
diff --git a/tests/introspection/iOSApiTypoTest.cs b/tests/introspection/iOSApiTypoTest.cs
index 42dafda1624d..1ec2b6de0e04 100644
--- a/tests/introspection/iOSApiTypoTest.cs
+++ b/tests/introspection/iOSApiTypoTest.cs
@@ -16,6 +16,7 @@ public override string GetTypo (string txt)
return txt.Substring ((int) typoRange.Location, (int) typoRange.Length);
}
+ [Test]
public override void TypoTest ()
{
// the dictionary used by iOS varies with versions and
From 88ed2ed2897cc80c088a8dc22288973aee762604 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Mon, 11 May 2026 14:13:42 +0200
Subject: [PATCH 037/156] Revert "[tests] Fix introspection TypoTest not being
discovered by NUnit"
This reverts commit 40269175bb2171fee3b83f5cbb448b14b40040d6.
---
tests/introspection/ApiTypoTest.cs | 193 --------------------------
tests/introspection/MacApiTypoTest.cs | 1 -
tests/introspection/iOSApiTypoTest.cs | 1 -
3 files changed, 195 deletions(-)
diff --git a/tests/introspection/ApiTypoTest.cs b/tests/introspection/ApiTypoTest.cs
index 67d093c02180..49a0fc0ec91c 100644
--- a/tests/introspection/ApiTypoTest.cs
+++ b/tests/introspection/ApiTypoTest.cs
@@ -66,53 +66,36 @@ public virtual bool Skip (MemberInfo methodName, string typo)
HashSet allowed = new HashSet () {
"Aac",
- "Abgr",
- "Accurracy",
"Achivements",
"Acos",
"Acosh",
"Acn",
"Actionname",
- "Activatable",
"Activitiy",
"Addin",
"Addl",
"Addr",
- "Adessive",
"Adjustmentfor",
"Aes", // Advanced Encryption Standard
- "Afi",
- "Ahap",
"Aifc",
"Aiff",
"Agc",
"Aio",
"Alg", // short for Algorithm
- "Allative",
"Alpn", // Application-Layer Protocol Negotiation RFC7301
"Amete",
"Amr",
- "Ancs",
- "Ane",
"Anglet",
- "Apac",
- "Apdu",
- "Apl",
"Apng", // Animated Portable Network Graphics
- "Apns",
- "Applei",
"Aps",
"Arraycollation",
"Argb",
"Asin",
"Asinh",
- "Astc",
"Atan",
"Atanh",
"Atmos", // Dolby Atmos
- "Atr",
"Ats", // App Transport Security
- "Atsc",
"Attrib",
"Attributevalue",
"Attrs", // Attributes (used by Apple for keys)
@@ -129,16 +112,12 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Arcball",
"Atm",
"Avg",
- "Axept",
"Backface",
"Bancaire", // french
"Bancaires", // french
- "Bancomat",
"Bary",
"Batc",
- "Ber",
"Bgra", // acrnym for Blue, Green, Red, Alpha
- "Bgrx",
"Bim",
"Biquad",
"Bitangent",
@@ -146,25 +125,17 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Blit",
"Bokeh",
"Bggr", // acronym for Blue, Green, Green, Red
- "Brotli",
"Bsln",
"Bssid",
"Btle", // Bluetooth Low Energy
"Bzip",
"Cabac",
"Caf", // acronym: Core Audio Format
- "Callables",
- "Callpout",
"Cancellable",
"Cartes", // french
- "Catmull",
"Cavlc",
- "Cct",
- "Ccw",
"Cda", // acronym: Clinical Document Architecture
- "Cdma",
"Cdrom",
- "Cea",
"Celu", // Continuously Differentiable Exponential Linear Unit (ML)
"Cfa", // acronym: Color Filter Array
"Celp", // MPEG4ObjectID
@@ -173,61 +144,38 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Cholesky",
"Chacha",
"Chromaticities",
- "Chw",
"Ciexyz",
"Ciff",
"Cinepak",
- "Cla",
"Clearcoat",
- "Clockstamp",
"Cnn", // Convolutional Neural Network
"Cns",
- "Codabar",
"Colos",
"Commerical",
"Composable",
- "Conecs",
"Conflictserror",
"Connnect",
- "Conv",
- "Cose",
"Counterclock",
"Copyback",
"Craete",
"Crosstraining",
- "Csr",
- "Ctor",
"Cubemap",
"Cmaf", // Common Media Application Format (mpeg4)
"Cmy", // acronym: Cyan, magenta, yellow
"Cmyk", // acronym: Cyan, magenta, yellow and key
"Daap",
- "Dangi",
- "Dankort",
"Dav",
"Dcip", // acronym: Digital Cinema Implementation Partners
"Deca",
"Decomposables",
"Deinterlace",
- "Denimonator",
- "Denoise",
- "Denoised",
"Depthwise",
- "Dequantize",
"Descendents",
"Descrete",
- "Descriptorat",
- "Descriptorfor",
- "Dfsi",
"Dhe", // Diffie–Hellman key exchange
- "Dhs",
- "Dhwio",
- "Dicom",
- "Diconnection",
"Diffable", // that you can diff it.. made up word from apple
"Differental",
"Diffie",
- "Dirbursement",
"Directionfor",
"Dist",
"dlclose",
@@ -239,7 +187,6 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"dlsym",
"Dng",
"Dns",
- "Dnssec",
"Dont",
"Dop",
"Dopesheet",
@@ -249,9 +196,6 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Dpad", // Directional pad (D-pad)
"Dpads", // plural of above
"Droste",
- "Dsf",
- "Dsfi",
- "Dstu",
"Dtls",
"Dtmf", // DTMF
"dy",
@@ -261,15 +205,11 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Ecdh", // Elliptic Curve Diffie–Hellman
"Ecdhe", // Elliptic Curve Diffie-Hellman Ephemeral
"Ecdsa", // Elliptic Curve Digital Signature Algorithm
- "Ecg",
"Ecies", // Elliptic Curve Integrated Encryption Scheme
"Ecn", // Explicit Congestion Notification
"Ect", // ECN Capable Transport
"Editability",
"Edr",
- "Elative",
- "Emebedding",
- "Endc",
"Eof", // acronym End-Of-File
"Elu",
"Emagic",
@@ -281,9 +221,6 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Epub",
"Eftpos", // Electronic funds transfer at point of sale
"Eotf", // DisplayP3_PQ_Eotf
- "Erf",
- "Essive",
- "Evdo",
"Exabits",
"Exbibits",
"Exbibytes",
@@ -291,16 +228,12 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Exp",
"Expr",
"Exr",
- "Extrinsics",
- "Feli",
"Felica", // Japanese contactless RFID smart card system
"Femtowatts",
- "Fft",
"Fhir",
"Flipside",
"Formati",
"Fov",
- "Fqdns",
"Framebuffer",
"Framesetter",
"Froms", // NSMetadataItemWhereFromsKey
@@ -308,11 +241,7 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Ftps",
"Func",
"Gadu",
- "Gainmap",
"Gbrg", // acronym for Green-Blue-Reg-Green
- "Gbtac",
- "Gbtdc",
- "Gcm",
"Gelu", // Gaussian Error Linear Unit (ML)
"Geocoder",
"Gigapascals",
@@ -325,7 +254,6 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Gps",
"Gpu", // acronym for Graphics Processing Unit
"Grbg", // acronym for Green-Red-Blue-Green
- "Groupless",
"Gru",
"Greeking",
"Gtin",
@@ -337,26 +265,17 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Hectopascals",
"Heic", // file type
"Heif", // file type
- "Hermitean",
"Hevc", // CMVideoCodecType / High Efficiency Video Coding
"Heif", // High Efficiency Image File Format
"Hfp",
- "Hhr",
- "Himyan",
- "Hindlegs",
"Hipass",
- "Histogrammed",
"Hlg", // Hybrid Log-Gamma
"Hls",
"Hoa",
"Hrtf", // acronym used in AUSpatializationAlgorithm
"Hvxc", // MPEG4ObjectID
- "Hwc",
- "Hwio",
- "Iap",
"Icns",
"Ico",
- "Iec",
"Ies",
"Icq",
"Ident",
@@ -365,12 +284,8 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Imagefor",
"Imap",
"Imaps",
- "Imei",
"Img",
"Impl", // BindingImplAttribute
- "Inessive",
- "Inot",
- "Intravaginal",
"Inv",
"Indoorrun",
"Indoorcycle",
@@ -394,26 +309,18 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Iptc",
"Ircs",
"Iso",
- "Isrc",
"Itf",
- "Itt",
"Itu",
"Itur", // Itur_2020_Hlg
- "Jaywan",
"Jcb", // Japanese credit card company
"Jfif",
"Jis",
- "Jrts",
"Json",
- "Jws",
- "Keepalive",
- "Keycode",
"Keyerror",
"Keyi",
"Keypoint",
"Keypoints",
"Keyspace",
- "Kickboard",
"ks",
"Kibibits",
"Kibibytes",
@@ -425,7 +332,6 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Langauges",
"Lacunarity",
"Latm", // Low Overhead Audio Transport Multiplex
- "Lbc",
"Ldaps",
"Lerp",
"Linecap",
@@ -436,13 +342,9 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Lod",
"Lopass",
"Lowlevel",
- "Lpcm",
"Lstm",
- "Lte",
- "Ltr",
"Lun",
"Luma",
- "Lut",
"Lzfse", // acronym
"Lzma", // acronym
"Mada", // payment system
@@ -451,15 +353,12 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Mcp", // metacarpophalangeal (hand)
"Mebibits",
"Mebibytes",
- "Mebx",
- "Meeza",
"Megaampere",
"Megaamperes",
"Megaliters",
"Megameters",
"Megaohms",
"Megapascals",
- "Mennekes",
"Metacharacters",
"Metalness",
"Metadatas",
@@ -467,19 +366,14 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Microamperes",
"Microohms",
"Microwatts",
- "Mifare",
"Millimoles",
"Milliohms",
"Mimap",
"Minification",
- "Mmw",
"Mncs",
"Mgmt",
"Mobike", // acronym
- "Monoline",
"Morpher",
- "Msi",
- "Mtl",
"mtouch",
"Mpe", // acronym
"Mps",
@@ -487,39 +381,21 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Mtu", // acronym
"Mtc", // acronym
"Mtgp",
- "Muid",
"Mul",
"Mult",
- "Multiary",
"Multihead",
"Multipath",
"Multipeer",
- "Multiscript",
- "Multiselect",
- "Multivariant",
- "Multiview",
"Muxed",
- "Nacs",
"Nai",
- "Nanaco",
- "Nand",
"Nanograms",
"Nanowatts",
- "Ncdhw",
- "Nchw",
- "nd",
- "Ndhwc",
"Nestrov",
"Nesterov",
- "Nfc",
"nfloat",
"Nfnt",
- "Nhwc",
"nint",
"Nntps",
- "Noninteractive",
- "Noop",
- "Nsa",
"Ntlm",
"Nsl", // InternetLocationNslNeighborhoodIcon
"Ntsc",
@@ -533,29 +409,20 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Objectfor",
"Objectness",
"Occlussion",
- "Ocr",
"Ocurrences",
"Ocsp", // Online Certificate Status Protocol
"Octree",
- "Odia",
- "Ohwi",
"Oid",
- "Oidhw",
- "Oihw",
"Oneup", // TVElementKeyOneupTemplate
- "Onnx",
- "Oper",
"Organisation", // kCGImagePropertyIPTCExtRegistryOrganisationID in Xcode9.3-b1
"Orthographyrange",
"Orth",
"Osa", // Open Scripting Architecture
"Otsu", // threshold for image binarization
"ove",
- "Overline",
"Paeth", // PNG filter
"Palettize",
"Parms", // short for Parameters
- "Pci",
"Peap",
"Pebibits",
"Pebibytes",
@@ -570,13 +437,10 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Pesented",
"Pfs", // acronym
"Philox",
- "Photoplethysmogram",
- "Phq",
"Picometers",
"Picowatts",
"Pkcs",
"Placemark",
- "Playout",
"Playthrough",
"Pnc", // MIDI
"Pnorm",
@@ -584,30 +448,22 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Polyline",
"Polylines",
"Popularimeter",
- "Postback",
- "Ppk",
"Preds", // short for Predicates
- "Prefilter",
- "Prereleased",
"Prerolls",
"Preseti",
"Prev",
- "Prf",
"Privs", // SharingPrivsNotApplicableIcon
"Propogate",
"Psec",
- "Pskc",
"Psm", // Protocol/Service Multiplexer
"Psk",
"Ptp",
- "Pvr",
"Pvrtc", // MTLBlitOption - PowerVR Texture Compression
"Qos",
"Quaterniond",
"Quadding",
"Qura",
"Quic",
- "Qwac",
"Reacquirer",
"Reinvitation",
"Reinvite",
@@ -615,50 +471,37 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Relocalization",
"Relu", // Rectified Linear Unit (ML)
"Relun", // ReLUn - degree n Hermite coefficients
- "Remmote",
"Reprandial",
"Replayable",
- "Reprojection",
"Requestwith",
- "Rgbaf",
- "Rgbah",
- "Rgbx",
"Ridesharing",
"Rgb",
"Rgba",
"Rggb", // acronym for Red, Green, Green, Blue
- "Rint",
- "Rle",
"Rnn",
"Roi",
"Romm", // acronym: Reference Output Medium Metric
"Rpa",
"Rpn", // acronym
"Rsa", // Rivest, Shamir and Adleman
- "Rsapss",
"Rsqrt", // reciprocal square root
"Rssi",
"Rtp",
"Rtl",
"Rtsp",
"Saml", // acronym
- "Scc",
"Sdof",
"Scn",
"Sdk",
- "Sdr",
"Sdtv", // acronym: Standard Definition Tele Vision
"Sdnn",
"Seekable",
- "Sel",
"Selu", // Scaled Exponential Linear unit (ML)
- "Sensel",
"Sgd", // Stochastic Gradient Descent (ML)
"Shadable",
"Sharegroup",
"Sha", // Secure Hash Algorithm
"Siemen",
- "Signbit",
"simd",
"Sinh",
"Sint", // as in "Signed Integer"
@@ -667,29 +510,21 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Slomo",
"Smpte",
"Snapshotter",
- "Snn",
"Snorm",
"Sobel",
"Softmax", // get_SoftmaxNormalization
"Spacei",
- "Spl",
"Sqrt",
"Srgb",
"Ssid",
"Ssids",
- "Ssml",
- "st",
"Standarize",
"Stateful",
"Stateright",
- "Strided",
- "Subband",
"Subbeat",
"Subcaption",
"Subcardioid",
"Subentities",
- "Subfilter",
- "Subfilters",
"Subheadline",
"Sublocality",
"Sublocation",
@@ -703,24 +538,17 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Superentity",
"Supertype",
"Supertypes",
- "Supression",
- "Svfg",
"Svg", // Scalable Vector Graphics
- "Svgf",
- "Swolf",
"Sym",
"Synchronizable",
"Symbologies",
- "Sysex",
"Tanh",
- "Tbgr",
"Tebibits",
"Tebibytes",
"Tensorflow",
"Tessellator",
"Texcoord",
"Texel",
- "Tga",
"th",
"Threadgroup",
"Threadgroups",
@@ -731,9 +559,6 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Timelapse",
"Timelapses",
"Tls",
- "Tmoney",
- "Tonemap",
- "Tri",
"Ttls",
"Tlv",
"Toc",
@@ -752,22 +577,16 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Undecodable",
"Unemphasized",
"Underrun",
- "Unfetched",
"Unflagged",
"Unfocusing",
"Uid",
- "Unioning",
"Unmap",
- "Unmatch",
"Unorm",
"Unpremultiplied",
"Unpremultiplying",
"Unprepare",
"Unproject",
"Unpublish",
- "Unsolo",
- "Usec",
- "Ussd",
"Uterance",
"Unentitled",
"Untrash",
@@ -779,30 +598,19 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Usdz", // USD zip
"Uti",
"Varispeed",
- "Vbr",
- "Vbv",
"Vergence",
- "Voip",
"Voronoi",
"Vnode",
"Vpn",
- "Vtt",
- "Waon",
"Warichu",
- "Wcdma",
"Wep",
- "Willl",
- "Wlan",
"Wpa",
"Warpable",
"Whitespaces",
"Wifes",
"Writeability",
- "Xbgr",
- "Xmp",
"Xnor",
"Xpc",
- "Xrgb",
"xy",
"Xyz",
"Xzy",
@@ -811,7 +619,6 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"Yottabits",
"Yxz",
"Yzx",
- "Zenkaku",
"Zxy",
"Zyx",
"Yuv",
diff --git a/tests/introspection/MacApiTypoTest.cs b/tests/introspection/MacApiTypoTest.cs
index daa6f6696ef6..d9fd73e0ab51 100644
--- a/tests/introspection/MacApiTypoTest.cs
+++ b/tests/introspection/MacApiTypoTest.cs
@@ -7,7 +7,6 @@ namespace Introspection {
public class MacApiTypoTest : ApiTypoTest {
NSSpellChecker? checker;
- [Test]
public override void TypoTest ()
{
AssertMatchingOSVersionAndSdkVersion ();
diff --git a/tests/introspection/iOSApiTypoTest.cs b/tests/introspection/iOSApiTypoTest.cs
index 1ec2b6de0e04..42dafda1624d 100644
--- a/tests/introspection/iOSApiTypoTest.cs
+++ b/tests/introspection/iOSApiTypoTest.cs
@@ -16,7 +16,6 @@ public override string GetTypo (string txt)
return txt.Substring ((int) typoRange.Location, (int) typoRange.Length);
}
- [Test]
public override void TypoTest ()
{
// the dictionary used by iOS varies with versions and
From 3921c92259a99333082c31b4a10e3d2f956b56c0 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 12 May 2026 07:44:20 +0200
Subject: [PATCH 038/156] Add git branch safety instructions to
copilot-instructions.md (#25391)
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Rolf Bjarne Kvinge
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
---
.github/copilot-instructions.md | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/.github/copilot-instructions.md b/.github/copilot-instructions.md
index 4cb9965eaa88..4a072d2b8a8d 100644
--- a/.github/copilot-instructions.md
+++ b/.github/copilot-instructions.md
@@ -336,4 +336,9 @@ try {
} catch (Exception e) {
// Code here
}
-```
\ No newline at end of file
+```
+
+## Git Branch Safety
+
+* When creating a branch from `origin/main` (for example `git checkout -b origin/main`), the new branch may be configured to track `origin/main` depending on how it is created and your Git configuration. In that case, a later `git push` or `git push origin` may try to push to `main`.
+* To avoid accidentally pushing to main, use `git push -u origin ` for the first push so Git creates `origin/` and sets the branch's upstream safely. If you want to be completely explicit, use `git push origin :`.
From 081547d5a4ca1c3ed278ca874ed054075b81dd30 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 12 May 2026 07:51:22 +0200
Subject: [PATCH 039/156] [tools] Use the new UnsupportedSimulator attribute to
determine whether a Dlfcn method should be inlined or not. (#25381)
This allows us to remove a few special cases.
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
tests/common/shared-dotnet.mk | 3 +-
tests/common/test-variations.csproj | 7 --
tools/common/DerivedLinkContext.cs | 93 +++++++++++++++++++
.../Steps/InlineDlfcnMethodsStep.cs | 12 +++
tools/mtouch/Errors.designer.cs | 36 +++++++
tools/mtouch/Errors.resx | 16 ++++
6 files changed, 159 insertions(+), 8 deletions(-)
diff --git a/tests/common/shared-dotnet.mk b/tests/common/shared-dotnet.mk
index 717286b7a006..92e7ade41759 100644
--- a/tests/common/shared-dotnet.mk
+++ b/tests/common/shared-dotnet.mk
@@ -178,12 +178,13 @@ reload-and-run:
$(Q) $(MAKE) run
build: prepare
- @echo "Building $(wildcard *.?.csproj)..."
+ @echo "Building $(wildcard *.?sproj)..."
$(Q) $(DOTNET) build "/bl:$(abspath $@-$(BINLOG_TIMESTAMP).binlog)" *.?sproj $(DOTNET_BUILD_VERBOSITY) $(BUILD_ARGUMENTS) $(CONFIG_ARGUMENT) $(UNIVERSAL_ARGUMENT) $(NATIVEAOT_ARGUMENTS) $(TEST_VARIATION_ARGUMENT)
run: export SIMCTL_CHILD_NUNIT_AUTOSTART=true
run: export SIMCTL_CHILD_NUNIT_AUTOEXIT=true
run: prepare
+ @echo "Running $(wildcard *.?sproj)..."
$(Q) $(DOTNET) build "/bl:$(abspath $@-$(BINLOG_TIMESTAMP).binlog)" *.?sproj $(DOTNET_BUILD_VERBOSITY) $(BUILD_ARGUMENTS) $(CONFIG_ARGUMENT) $(UNIVERSAL_ARGUMENT) $(NATIVEAOT_ARGUMENTS) $(TEST_VARIATION_ARGUMENT) -t:Run $(RUN_ARGUMENTS) -tl:off
run-bare:
diff --git a/tests/common/test-variations.csproj b/tests/common/test-variations.csproj
index d5d820a99fad..ea1da526a288 100644
--- a/tests/common/test-variations.csproj
+++ b/tests/common/test-variations.csproj
@@ -161,13 +161,6 @@
$(DefineConstants);STATIC_NATIVE_SYMBOL_LOOKUP
-
-
-
-
-
-
-
<_InvalidTestVariations Include="$(TestVariation.Split('|'))" Exclude="@(TestVariations)" />
diff --git a/tools/common/DerivedLinkContext.cs b/tools/common/DerivedLinkContext.cs
index 8e679a69de81..743b1b768461 100644
--- a/tools/common/DerivedLinkContext.cs
+++ b/tools/common/DerivedLinkContext.cs
@@ -9,6 +9,7 @@
using Mono.Tuner;
using Xamarin.Bundler;
using Xamarin.Linker;
+using Xamarin.Utils;
#if !LEGACY_TOOLS
using LinkContext = Xamarin.Bundler.DotNetLinkContext;
@@ -236,6 +237,98 @@ public void AddLinkedAwayType (TypeDefinition td)
}
#if !LEGACY_TOOLS
+ public bool HasAvailabilityAttributesShowingUnavailableInSimulator (ICustomAttributeProvider provider, MethodDefinition? methodForErrorReporting = null)
+ {
+ if (!App.IsSimulatorBuild) {
+ LinkerConfiguration.Report (LinkerConfiguration.Context, ErrorHelper.CreateError (99, "HasAvailabilityAttributesShowingUnavailableInSimulator should not be called when not building for the simulator. Please file an issue at https://github.com/dotnet/macios/issues."));
+ return false;
+ }
+
+ if (!provider.HasCustomAttributes)
+ return false; // no attributes to say otherwise, so available
+
+ string platformName;
+
+ switch (App.Platform) {
+ case ApplePlatform.iOS:
+ platformName = "ios";
+ break;
+ case ApplePlatform.TVOS:
+ platformName = "tvos";
+ break;
+ default:
+ LinkerConfiguration.Report (LinkerConfiguration.Context, ErrorHelper.CreateWarning (App, 99, methodForErrorReporting, "Unexpected platform '{0}'. Please file an issue at https://github.com/dotnet/macios/issues.", App.Platform));
+ return false;
+ }
+
+ // Pass 1: check for any matching UnsupportedSimulator attribute — if found, it's unavailable.
+ var hasUnsupported = false;
+ foreach (var attrib in provider.CustomAttributes) {
+ if (!attrib.AttributeType.Is ("ObjCRuntime", "UnsupportedSimulatorAttribute"))
+ continue;
+ if (attrib.ConstructorArguments.Count == 1 && attrib.ConstructorArguments [0].Value is string unsupportedPlatform) {
+ if (string.Equals (unsupportedPlatform, platformName, StringComparison.OrdinalIgnoreCase))
+ hasUnsupported = true;
+ } else {
+ LinkerConfiguration.Report (LinkerConfiguration.Context, ErrorHelper.CreateWarning (App, 2258, methodForErrorReporting, Errors.MX2258, provider.AsString (), attrib.RenderAttribute ()));
+ }
+ }
+
+ // Pass 2: check for any matching SupportedSimulator attributes — evaluate as OR across versions.
+ var hasSupported = false;
+ var supportedCount = 0;
+ var isAvailable = false;
+ foreach (var attrib in provider.CustomAttributes) {
+ if (!attrib.AttributeType.Is ("ObjCRuntime", "SupportedSimulatorAttribute"))
+ continue;
+ if (attrib.ConstructorArguments.Count == 1 && attrib.ConstructorArguments [0].Value is string supportedPlatform) {
+ if (!supportedPlatform.StartsWith (platformName, StringComparison.OrdinalIgnoreCase))
+ continue;
+
+ hasSupported = true;
+ supportedCount++;
+ var osVersion = supportedPlatform.Substring (platformName.Length);
+ if (string.IsNullOrEmpty (osVersion)) {
+ // no version constraint: available in the simulator
+ isAvailable = true;
+ } else if (Version.TryParse (osVersion, out var version)) {
+ var simulatorVersion = App.DeploymentTarget;
+ if (simulatorVersion is null) {
+ LinkerConfiguration.Report (LinkerConfiguration.Context, ErrorHelper.CreateWarning (App, 99, methodForErrorReporting, "No deployment target available. Please file an issue at https://github.com/dotnet/macios/issues."));
+ continue;
+ }
+ if (simulatorVersion >= version)
+ isAvailable = true;
+ } else {
+ LinkerConfiguration.Report (LinkerConfiguration.Context, ErrorHelper.CreateWarning (App, 2259, methodForErrorReporting, Errors.MX2259, provider.AsString (), attrib.RenderAttribute ()));
+ }
+ } else {
+ LinkerConfiguration.Report (LinkerConfiguration.Context, ErrorHelper.CreateWarning (App, 2258, methodForErrorReporting, Errors.MX2258, provider.AsString (), attrib.RenderAttribute ()));
+ }
+ }
+
+ // Conflicting attributes: both Supported and Unsupported for the same platform
+ if (hasUnsupported && hasSupported) {
+ LinkerConfiguration.Report (LinkerConfiguration.Context, ErrorHelper.CreateError (App, 2260, methodForErrorReporting, Errors.MX2260, provider.AsString (), platformName));
+ return true; // treat as unavailable
+ }
+
+ // Multiple SupportedSimulator attributes for the same platform
+ if (supportedCount > 1) {
+ LinkerConfiguration.Report (LinkerConfiguration.Context, ErrorHelper.CreateError (App, 2261, methodForErrorReporting, Errors.MX2261, provider.AsString (), platformName));
+ return true; // treat as unavailable
+ }
+
+ if (hasUnsupported)
+ return true;
+
+ if (hasSupported)
+ return !isAvailable;
+
+ // No matching attributes: assume available
+ return false;
+ }
+
class AttributeStorage : ICustomAttribute {
public CustomAttribute Attribute { get; }
public TypeReference AttributeType { get; set; }
diff --git a/tools/dotnet-linker/Steps/InlineDlfcnMethodsStep.cs b/tools/dotnet-linker/Steps/InlineDlfcnMethodsStep.cs
index 0012ca7a456f..5a1be9ed49c9 100644
--- a/tools/dotnet-linker/Steps/InlineDlfcnMethodsStep.cs
+++ b/tools/dotnet-linker/Steps/InlineDlfcnMethodsStep.cs
@@ -539,6 +539,18 @@ protected override bool ProcessMethod (MethodDefinition method)
if (method.DeclaringType.Name == "Dlfcn" && method.DeclaringType.Namespace == "ObjCRuntime")
return modified; // don't process the Dlfcn methods themselves
+ if (DerivedLinkContext.App.IsSimulatorBuild) {
+ // if the method or its declaring type aren't available in the simulator, and we're building for the simulator, then don't inline.
+ if (DerivedLinkContext.HasAvailabilityAttributesShowingUnavailableInSimulator (method, method)) {
+ Driver.Log (3, $"Method {method.FullName} is not available in the simulator. Skipping inlining Dlfcn calls for this method.");
+ return modified;
+ }
+ if (DerivedLinkContext.HasAvailabilityAttributesShowingUnavailableInSimulator (method.DeclaringType, method)) {
+ Driver.Log (3, $"Type {method.DeclaringType.FullName} is not available in the simulator. Skipping inlining Dlfcn calls for this type.");
+ return modified;
+ }
+ }
+
foreach (var instr in method.Body.Instructions) {
if (instr.Operand is not MethodReference mr)
continue;
diff --git a/tools/mtouch/Errors.designer.cs b/tools/mtouch/Errors.designer.cs
index 85e5fd3a6293..ee92d9580d81 100644
--- a/tools/mtouch/Errors.designer.cs
+++ b/tools/mtouch/Errors.designer.cs
@@ -3560,6 +3560,42 @@ public static string MX2257 {
}
}
+ ///
+ /// Looks up a localized string similar to '{0}' is marked with a malformed simulator availability attribute: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new.
+ ///
+ public static string MX2258 {
+ get {
+ return ResourceManager.GetString("MX2258", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to '{0}' is marked with a simulator availability attribute with an invalid version: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new.
+ ///
+ public static string MX2259 {
+ get {
+ return ResourceManager.GetString("MX2259", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to '{0}' has conflicting simulator availability attributes for the '{1}' platform (both SupportedSimulator and UnsupportedSimulator). Please file an issue at https://github.com/dotnet/macios/issues/new.
+ ///
+ public static string MX2260 {
+ get {
+ return ResourceManager.GetString("MX2260", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to '{0}' has multiple SupportedSimulator attributes for the '{1}' platform. Please file an issue at https://github.com/dotnet/macios/issues/new.
+ ///
+ public static string MX2261 {
+ get {
+ return ResourceManager.GetString("MX2261", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Could not {0} the assembly '{1}'.
///
diff --git a/tools/mtouch/Errors.resx b/tools/mtouch/Errors.resx
index f719755a4d48..987d7c75e479 100644
--- a/tools/mtouch/Errors.resx
+++ b/tools/mtouch/Errors.resx
@@ -1115,6 +1115,22 @@
Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+ '{0}' is marked with a malformed simulator availability attribute: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+
+ '{0}' is marked with a simulator availability attribute with an invalid version: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+
+ '{0}' has conflicting simulator availability attributes for the '{1}' platform (both SupportedSimulator and UnsupportedSimulator). Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+
+ '{0}' has multiple SupportedSimulator attributes for the '{1}' platform. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
From 8a133879ec1fbbc5ea5b339541c90c5f00ffa2b0 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 12 May 2026 13:13:19 +0200
Subject: [PATCH 040/156] [apidiff] Fix nullability errors in mono-api-html and
mono-api-info (#25392)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Fix all nullability warnings/errors in the api-tools:
- **mono-api-html**: ~50 fixes across 15 files —
- **mono-api-info**: ~55 fixes across 3 files — nullable XmlWriter override params, nullable return types for `GetBaseType`/`GetMethod`/`GetLayout`, IComparer interface params, late-initialized fields
Both projects now build with 0 errors and 0 warnings.
🤖 Pull request created by Copilot
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
tools/api-tools/mono-api-html/ApiChange.cs | 5 +-
tools/api-tools/mono-api-html/ApiDiff.cs | 36 ++++----
.../mono-api-html/AssemblyComparer.cs | 16 ++--
.../api-tools/mono-api-html/ClassComparer.cs | 30 +++----
tools/api-tools/mono-api-html/Comparer.cs | 4 +-
.../mono-api-html/ConstructorComparer.cs | 8 +-
.../api-tools/mono-api-html/EventComparer.cs | 10 +--
.../api-tools/mono-api-html/FieldComparer.cs | 24 +++---
tools/api-tools/mono-api-html/Formatter.cs | 8 +-
tools/api-tools/mono-api-html/Helpers.cs | 22 ++---
.../mono-api-html/InterfaceComparer.cs | 2 +-
.../api-tools/mono-api-html/MemberComparer.cs | 51 +++++------
.../api-tools/mono-api-html/MethodComparer.cs | 4 +-
.../mono-api-html/NamespaceComparer.cs | 12 +--
.../mono-api-html/PropertyComparer.cs | 44 +++++-----
tools/api-tools/mono-api-info/Util.cs | 10 +--
.../mono-api-info/WellFormedXmlWriter.cs | 28 +++---
.../api-tools/mono-api-info/mono-api-info.cs | 86 +++++++++++--------
18 files changed, 211 insertions(+), 189 deletions(-)
diff --git a/tools/api-tools/mono-api-html/ApiChange.cs b/tools/api-tools/mono-api-html/ApiChange.cs
index a7c0218142fd..3bf895a47b00 100644
--- a/tools/api-tools/mono-api-html/ApiChange.cs
+++ b/tools/api-tools/mono-api-html/ApiChange.cs
@@ -7,7 +7,7 @@
namespace Mono.ApiTools {
class ApiChange {
- public string Header;
+ public string Header = "";
public TextChunk Member = new TextChunk ();
public bool AnyChange;
public string SourceDescription;
@@ -61,8 +61,7 @@ public void Add (XElement source, XElement target, ApiChange change)
if (!change.AnyChange)
return;
- List list;
- if (!TryGetValue (change.Header, out list)) {
+ if (!TryGetValue (change.Header, out List? list)) {
list = new List ();
base.Add (change.Header, list);
}
diff --git a/tools/api-tools/mono-api-html/ApiDiff.cs b/tools/api-tools/mono-api-html/ApiDiff.cs
index 7e28b8e96d3b..421091445367 100644
--- a/tools/api-tools/mono-api-html/ApiDiff.cs
+++ b/tools/api-tools/mono-api-html/ApiDiff.cs
@@ -42,17 +42,17 @@
namespace Mono.ApiTools {
class State {
- public Formatter Formatter { get; set; }
- public Formatter [] Formatters { get; set; }
- public string Assembly { get; set; }
- public string Namespace { get; set; }
- public string Type { get; set; }
- public string BaseType { get; set; }
- public string Parent { get; set; }
+ public Formatter Formatter { get; set; } = null!;
+ public Formatter [] Formatters { get; set; } = [];
+ public string Assembly { get; set; } = "";
+ public string Namespace { get; set; } = "";
+ public string Type { get; set; } = "";
+ public string BaseType { get; set; } = "";
+ public string Parent { get; set; } = "";
public bool Colorize { get; set; } = true;
public int Verbosity { get; set; }
- public string SourceFile;
- public string TargetFile;
+ public string SourceFile = "";
+ public string TargetFile = "";
public void LogDebugMessage (string value)
{
@@ -70,7 +70,7 @@ class Program {
public static int Main (string [] args)
{
var showHelp = false;
- List extra = null;
+ List? extra = null;
var config = new ApiDiffFormattedConfig ();
var options = new Mono.Options.OptionSet {
@@ -130,9 +130,9 @@ public static int Main (string [] args)
#endif
public class ApiDiffFormattedConfig {
- public string HtmlOutput { get; set; }
- public string HtmlHeader { get; set; }
- public string MarkdownOutput { get; set; }
+ public string? HtmlOutput { get; set; }
+ public string? HtmlHeader { get; set; }
+ public string? MarkdownOutput { get; set; }
// public bool IgnoreDuplicateXml { get; set; }
public bool Colorize { get; set; } = true;
@@ -140,7 +140,7 @@ public class ApiDiffFormattedConfig {
}
public static class ApiDiffFormatted {
- public static void Generate (string firstInfo, string secondInfo, ApiDiffFormattedConfig config = null)
+ public static void Generate (string firstInfo, string secondInfo, ApiDiffFormattedConfig? config = null)
{
var state = CreateState (config, firstInfo, secondInfo);
var ac = new AssemblyComparer (state);
@@ -171,14 +171,14 @@ static void Generate (AssemblyComparer ac, State state)
}
}
- static State CreateState (ApiDiffFormattedConfig config, string firstInfo, string secondInfo)
+ static State CreateState (ApiDiffFormattedConfig? config, string firstInfo, string secondInfo)
{
if (config is null)
config = new ApiDiffFormattedConfig ();
var state = new State {
Colorize = config.Colorize,
- Formatter = null,
+ Formatter = null!,
SourceFile = firstInfo,
TargetFile = secondInfo,
@@ -187,9 +187,9 @@ static State CreateState (ApiDiffFormattedConfig config, string firstInfo, strin
var formatters = new List ();
if (!string.IsNullOrWhiteSpace (config.HtmlOutput))
- formatters.Add (new HtmlFormatter (state) { OutputPath = config.HtmlOutput, Header = config.HtmlHeader });
+ formatters.Add (new HtmlFormatter (state) { OutputPath = config.HtmlOutput!, Header = config.HtmlHeader ?? "" });
if (!string.IsNullOrWhiteSpace (config.MarkdownOutput))
- formatters.Add (new MarkdownFormatter (state) { OutputPath = config.MarkdownOutput });
+ formatters.Add (new MarkdownFormatter (state) { OutputPath = config.MarkdownOutput! });
if (formatters.Count > 1) {
state.Formatter = new MultiplexedFormatter (state, formatters.ToArray ());
} else if (formatters.Count == 0) {
diff --git a/tools/api-tools/mono-api-html/AssemblyComparer.cs b/tools/api-tools/mono-api-html/AssemblyComparer.cs
index f1d053142483..6eff7d44e0eb 100644
--- a/tools/api-tools/mono-api-html/AssemblyComparer.cs
+++ b/tools/api-tools/mono-api-html/AssemblyComparer.cs
@@ -58,18 +58,18 @@ public override string ElementName {
get { return "assembly"; }
}
- public string SourceAssembly { get; private set; }
- public string TargetAssembly { get; private set; }
+ public string SourceAssembly { get; private set; } = "";
+ public string TargetAssembly { get; private set; } = "";
public void Compare ()
{
- Compare (source.Element ("assemblies").Elements ("assembly"),
- target.Element ("assemblies").Elements ("assembly"));
+ Compare (source.Element ("assemblies")!.Elements ("assembly"),
+ target.Element ("assemblies")!.Elements ("assembly"));
}
public override void SetContext (XElement current)
{
- State.Assembly = current.GetAttribute ("name");
+ State.Assembly = current.GetAttribute ("name") ?? "";
}
public override void Added (XElement target, bool wasParentAdded)
@@ -79,13 +79,13 @@ public override void Added (XElement target, bool wasParentAdded)
public override void Modified (XElement source, XElement target, ApiChanges diff)
{
- SourceAssembly = source.GetAttribute ("name");
- TargetAssembly = target.GetAttribute ("name");
+ SourceAssembly = source.GetAttribute ("name") ?? "";
+ TargetAssembly = target.GetAttribute ("name") ?? "";
var sb = source.GetAttribute ("version");
var tb = target.GetAttribute ("version");
if (sb != tb) {
- Output.WriteLine ("
Assembly Version Changed: {0} -> {1}
", sb, tb);
+ Output.WriteLine ("Assembly Version Changed: {0} -> {1}
", sb ?? "", tb ?? "");
Output.WriteLine ();
}
diff --git a/tools/api-tools/mono-api-html/ClassComparer.cs b/tools/api-tools/mono-api-html/ClassComparer.cs
index b258ea02aa1d..8afdd03be192 100644
--- a/tools/api-tools/mono-api-html/ClassComparer.cs
+++ b/tools/api-tools/mono-api-html/ClassComparer.cs
@@ -43,7 +43,7 @@ class ClassComparer : Comparer {
PropertyComparer pcomparer;
EventComparer ecomparer;
MethodComparer mcomparer;
- ClassComparer kcomparer;
+ ClassComparer? kcomparer;
public ClassComparer (State state)
: base (state)
@@ -66,8 +66,8 @@ public override string ElementName {
public override void SetContext (XElement current)
{
- State.Type = current.GetAttribute ("name");
- State.BaseType = current.GetAttribute ("base");
+ State.Type = current.GetAttribute ("name") ?? "";
+ State.BaseType = current.GetAttribute ("base") ?? "";
}
public void Compare (XElement source, XElement target)
@@ -76,7 +76,7 @@ public void Compare (XElement source, XElement target)
var t = target.Element ("classes");
if (XNode.DeepEquals (s, t))
return;
- Compare (s.Elements ("class"), t.Elements ("class"));
+ Compare (s!.Elements ("class"), t!.Elements ("class"));
}
public override void Added (XElement target, bool wasParentAdded)
@@ -92,7 +92,7 @@ public void AddedInner (XElement target)
if (target.IsTrue ("serializable"))
Indent ().WriteLine ("[Serializable]");
- var type = target.Attribute ("type").Value;
+ var type = target.Attribute ("type")!.Value;
WriteAttributes (target);
@@ -112,7 +112,7 @@ public void AddedInner (XElement target)
Output.Write (' ');
Output.Write (type);
Output.Write (' ');
- Output.Write (target.GetAttribute ("name"));
+ Output.Write (target.GetAttribute ("name") ?? "");
var baseclass = target.GetAttribute ("base");
if ((type != "enum") && (type != "struct")) {
@@ -206,7 +206,7 @@ static Dictionary CreateClassHierarchyMap (string xml)
foreach (var @assembly in assemblies.Elements ("assembly")) {
foreach (var e in assembly.Elements ("namespaces")) {
foreach (var nsElement in e.Elements ("namespace")) {
- var ns = nsElement.GetAttribute ("name");
+ var ns = nsElement.GetAttribute ("name") ?? "";
foreach (var classesElement in nsElement.Elements ("classes")) {
MapClasses (rv, ns, string.Empty, classesElement);
}
@@ -219,8 +219,8 @@ static Dictionary CreateClassHierarchyMap (string xml)
static void MapClasses (Dictionary dictionary, string @namespace, string declaringType, XElement classes)
{
foreach (var classElement in classes.Elements ("class")) {
- var className = classElement.GetAttribute ("name");
- var baseType = classElement.GetAttribute ("base");
+ var className = classElement.GetAttribute ("name") ?? "";
+ var baseType = classElement.GetAttribute ("base") ?? "";
string fullname;
if (string.IsNullOrEmpty (@namespace)) {
// nested type
@@ -255,7 +255,7 @@ public override void Modified (XElement source, XElement target, ApiChanges diff
State.LogDebugMessage ($"Possible -r value: {rm}");
if (sb != tb) {
Formatter.BeginMemberModification ("Modified base type");
- var apichange = new ApiChange ($"{State.Namespace}.{State.Type}", State).AppendModified (sb, tb);
+ var apichange = new ApiChange ($"{State.Namespace}.{State.Type}", State).AppendModified (sb ?? "", tb ?? "");
Formatter.Diff (apichange);
Formatter.EndMemberModification ();
}
@@ -272,7 +272,7 @@ public override void Modified (XElement source, XElement target, ApiChanges diff
var ti = target.Element ("classes");
kcomparer = new NestedClassComparer (State);
State.Parent = State.Type;
- kcomparer.Compare (si.Elements ("class"), ti is null ? null : ti.Elements ("class"));
+ kcomparer.Compare (si.Elements ("class"), ti?.Elements ("class"));
State.Type = State.Parent;
}
@@ -293,7 +293,7 @@ public override void Removed (XElement source)
Formatter.EndTypeRemoval ();
}
- public virtual string GetTypeName (XElement type)
+ public virtual string? GetTypeName (XElement type)
{
return type.GetAttribute ("name");
}
@@ -308,11 +308,11 @@ public NestedClassComparer (State state)
public override void SetContext (XElement current)
{
- State.Type = State.Parent + "." + current.GetAttribute ("name");
- State.BaseType = current.GetAttribute ("base");
+ State.Type = State.Parent + "." + (current.GetAttribute ("name") ?? "");
+ State.BaseType = current.GetAttribute ("base") ?? "";
}
- public override string GetTypeName (XElement type)
+ public override string? GetTypeName (XElement type)
{
return State.Parent + "." + base.GetTypeName (type);
}
diff --git a/tools/api-tools/mono-api-html/Comparer.cs b/tools/api-tools/mono-api-html/Comparer.cs
index add7414cf948..11517e7da80d 100644
--- a/tools/api-tools/mono-api-html/Comparer.cs
+++ b/tools/api-tools/mono-api-html/Comparer.cs
@@ -156,14 +156,14 @@ public virtual bool Equals (XElement source, XElement target, ApiChanges changes
public abstract void SetContext (XElement current);
- public virtual void Compare (IEnumerable source, IEnumerable target)
+ public virtual void Compare (IEnumerable source, IEnumerable? target)
{
removed.Clear ();
modified.Clear ();
foreach (var s in source) {
SetContext (s);
- string sn = s.GetAttribute ("name");
+ string? sn = s.GetAttribute ("name");
var t = target is null ? null : target.SingleOrDefault (x => x.GetAttribute ("name") == sn);
if (t is null) {
// not in target, it was removed
diff --git a/tools/api-tools/mono-api-html/ConstructorComparer.cs b/tools/api-tools/mono-api-html/ConstructorComparer.cs
index b6adfa6401c3..e541861f2093 100644
--- a/tools/api-tools/mono-api-html/ConstructorComparer.cs
+++ b/tools/api-tools/mono-api-html/ConstructorComparer.cs
@@ -50,7 +50,7 @@ public override string ElementName {
public override bool Find (XElement e)
{
- return (e.Attribute ("name").Value == Source.Attribute ("name").Value);
+ return (e.Attribute ("name")!.Value == Source.Attribute ("name")!.Value);
}
void RenderReturnType (XElement source, XElement target, ApiChange change)
@@ -59,7 +59,7 @@ void RenderReturnType (XElement source, XElement target, ApiChange change)
var tgtType = target.GetTypeName ("returntype", State);
if (srcType != tgtType) {
- change.AppendModified (srcType, tgtType);
+ change.AppendModified (srcType ?? "", tgtType ?? "");
change.Append (" ");
} else if (srcType is not null) {
// ctor don't have a return type
@@ -114,7 +114,7 @@ public override string GetDescription (XElement e)
}
}
- string name = e.GetAttribute ("name");
+ string name = e.GetAttribute ("name") ?? "";
var r = e.GetTypeName ("returntype", State);
if (r is not null) {
@@ -133,7 +133,7 @@ public override string GetDescription (XElement e)
if (genericp is not null) {
var list = new List ();
foreach (var p in genericp.Elements ("generic-parameter")) {
- list.Add (p.GetTypeName ("name", State));
+ list.Add (p.GetTypeName ("name", State) ?? "");
}
sb.Append (Formatter.LesserThan).Append (String.Join (", ", list)).Append (Formatter.GreaterThan);
}
diff --git a/tools/api-tools/mono-api-html/EventComparer.cs b/tools/api-tools/mono-api-html/EventComparer.cs
index 8433e6c52d87..302d483a5008 100644
--- a/tools/api-tools/mono-api-html/EventComparer.cs
+++ b/tools/api-tools/mono-api-html/EventComparer.cs
@@ -55,8 +55,8 @@ public override bool Equals (XElement source, XElement target, ApiChanges change
RenderAttributes (source, target, change);
change.Append ("public event ");
- var srcEventType = source.GetTypeName ("eventtype", State);
- var tgtEventType = target.GetTypeName ("eventtype", State);
+ var srcEventType = source.GetTypeName ("eventtype", State) ?? "";
+ var tgtEventType = target.GetTypeName ("eventtype", State) ?? "";
if (srcEventType != tgtEventType) {
change.AppendModified (srcEventType, tgtEventType);
@@ -64,7 +64,7 @@ public override bool Equals (XElement source, XElement target, ApiChanges change
change.Append (srcEventType);
}
change.Append (" ");
- change.Append (source.GetAttribute ("name")).Append (";");
+ change.Append (source.GetAttribute ("name") ?? "").Append (";");
return false;
}
@@ -73,8 +73,8 @@ public override string GetDescription (XElement e)
var sb = new StringBuilder ();
// TODO: attribs
sb.Append ("public event ");
- sb.Append (e.GetTypeName ("eventtype", State)).Append (' ');
- sb.Append (e.GetAttribute ("name")).Append (';');
+ sb.Append (e.GetTypeName ("eventtype", State) ?? "").Append (' ');
+ sb.Append (e.GetAttribute ("name") ?? "").Append (';');
return sb.ToString ();
}
}
diff --git a/tools/api-tools/mono-api-html/FieldComparer.cs b/tools/api-tools/mono-api-html/FieldComparer.cs
index fb1587c74fa5..ba600ba548c2 100644
--- a/tools/api-tools/mono-api-html/FieldComparer.cs
+++ b/tools/api-tools/mono-api-html/FieldComparer.cs
@@ -106,15 +106,15 @@ void RenderFieldAttributes (FieldAttributes source, FieldAttributes target, ApiC
string GetFullName (XElement element)
{
- var rv = element.GetAttribute ("name");
- element = element.Parent;
+ var rv = element.GetAttribute ("name") ?? "";
+ element = element.Parent!;
while (element is not null) {
if (element.Name.LocalName == "assembly")
break;
var name = element.GetAttribute ("name");
if (!string.IsNullOrEmpty (name))
rv = name + "." + rv;
- element = element.Parent;
+ element = element.Parent!;
}
return rv;
}
@@ -124,7 +124,7 @@ public override bool Equals (XElement source, XElement target, ApiChanges change
if (base.Equals (source, target, changes))
return true;
- var name = source.GetAttribute ("name");
+ var name = source.GetAttribute ("name") ?? "";
var srcValue = source.GetAttribute ("value");
var tgtValue = target.GetAttribute ("value");
var change = new ApiChange (GetDescription (source), State);
@@ -135,15 +135,15 @@ public override bool Equals (XElement source, XElement target, ApiChanges change
if (State.BaseType == "System.Enum") {
change.Append (name).Append (" = ");
if (srcValue != tgtValue) {
- change.AppendModified (srcValue, tgtValue);
+ change.AppendModified (srcValue ?? "", tgtValue ?? "");
} else {
- change.Append (srcValue);
+ change.Append (srcValue ?? "");
}
} else {
RenderFieldAttributes (source.GetFieldAttributes (), target.GetFieldAttributes (), change);
- var srcType = source.GetTypeName ("fieldtype", State);
- var tgtType = target.GetTypeName ("fieldtype", State);
+ var srcType = source.GetTypeName ("fieldtype", State) ?? "";
+ var tgtType = target.GetTypeName ("fieldtype", State) ?? "";
if (srcType != tgtType) {
change.AppendModified (srcType, tgtType);
@@ -183,8 +183,8 @@ public override string GetDescription (XElement e)
{
var sb = new StringBuilder ();
- string name = e.GetAttribute ("name");
- string value = e.GetAttribute ("value");
+ string name = e.GetAttribute ("name") ?? "";
+ string? value = e.GetAttribute ("value");
if (State.BaseType == "System.Enum") {
sb.Append (name).Append (" = ").Append (value).Append (',');
@@ -205,8 +205,8 @@ public override string GetDescription (XElement e)
sb.Append ("const ");
}
- string ftype = e.GetTypeName ("fieldtype", State);
- sb.Append (ftype).Append (' ');
+ string? ftype = e.GetTypeName ("fieldtype", State);
+ sb.Append (ftype ?? "").Append (' ');
sb.Append (name);
if (ftype == "string" && e.Attribute ("value") is not null) {
if (value is null)
diff --git a/tools/api-tools/mono-api-html/Formatter.cs b/tools/api-tools/mono-api-html/Formatter.cs
index 4ca489bfb750..a7be2f256c0b 100644
--- a/tools/api-tools/mono-api-html/Formatter.cs
+++ b/tools/api-tools/mono-api-html/Formatter.cs
@@ -33,11 +33,11 @@
namespace Mono.ApiTools {
abstract class Formatter {
- public string OutputPath { get; set; }
+ public string OutputPath { get; set; } = "";
- Stack<(StringBuilder, TextWriter)> builders;
- public StringBuilder StringBuilder { get; private set; }
- protected TextWriter output;
+ Stack<(StringBuilder, TextWriter)> builders = null!;
+ public StringBuilder StringBuilder { get; private set; } = null!;
+ protected TextWriter output = null!;
protected int IndentLevel { get; set; }
diff --git a/tools/api-tools/mono-api-html/Helpers.cs b/tools/api-tools/mono-api-html/Helpers.cs
index a7d0a3fdb61f..975eefacd838 100644
--- a/tools/api-tools/mono-api-html/Helpers.cs
+++ b/tools/api-tools/mono-api-html/Helpers.cs
@@ -39,7 +39,7 @@ public static bool IsTrue (this XElement self, string name)
return (self.GetAttribute (name) == "true");
}
- public static string GetAttribute (this XElement self, string name)
+ public static string? GetAttribute (this XElement self, string name)
{
var n = self.Attribute (name);
if (n is null)
@@ -47,7 +47,7 @@ public static string GetAttribute (this XElement self, string name)
return n.Value;
}
- public static IEnumerable EnumerateAttributes (this XElement self, string attributeName = null)
+ public static IEnumerable EnumerateAttributes (this XElement self, string? attributeName = null)
{
if (self is null)
yield break;
@@ -63,7 +63,7 @@ public static IEnumerable EnumerateAttributes (this XElement self, str
}
}
- static bool TryGetAttributeProperty (this XElement self, string attributeName, bool recursive, out string firstArgument)
+ static bool TryGetAttributeProperty (this XElement? self, string attributeName, bool recursive, out string? firstArgument)
{
firstArgument = null;
@@ -89,16 +89,16 @@ static bool TryGetAttributeProperty (this XElement self, string attributeName, b
}
// null == no obsolete, String.Empty == no description
- public static string GetObsoleteMessage (this XElement self)
+ public static string? GetObsoleteMessage (this XElement self)
{
- if (TryGetAttributeProperty (self, "System.ObsoleteAttribute", false, out string message))
+ if (TryGetAttributeProperty (self, "System.ObsoleteAttribute", false, out string? message))
return message ?? String.Empty;
return null;
}
- public static IEnumerable Descendants (this XElement self, params string [] names)
+ public static IEnumerable? Descendants (this XElement self, params string [] names)
{
- XElement el = self;
+ XElement? el = self;
if (el is null)
return null;
@@ -110,7 +110,7 @@ public static IEnumerable Descendants (this XElement self, params stri
return el.Elements (names [names.Length - 1]);
}
- public static List DescendantList (this XElement self, params string [] names)
+ public static List? DescendantList (this XElement self, params string [] names)
{
var descendants = self.Descendants (names);
if (descendants is null)
@@ -119,13 +119,13 @@ public static List DescendantList (this XElement self, params string [
}
// make it beautiful (.NET -> C#)
- public static string GetTypeName (this XElement self, string name, State state)
+ public static string? GetTypeName (this XElement self, string name, State state)
{
- string type = self.GetAttribute (name);
+ string? type = self.GetAttribute (name);
if (type is null)
return null;
- StringBuilder sb = null;
+ StringBuilder sb = null!;
bool is_nullable = false;
if (type.StartsWith ("System.Nullable`1[", StringComparison.Ordinal)) {
is_nullable = true;
diff --git a/tools/api-tools/mono-api-html/InterfaceComparer.cs b/tools/api-tools/mono-api-html/InterfaceComparer.cs
index a0eee9de0c48..2ec155a5c1b5 100644
--- a/tools/api-tools/mono-api-html/InterfaceComparer.cs
+++ b/tools/api-tools/mono-api-html/InterfaceComparer.cs
@@ -46,7 +46,7 @@ public override string ElementName {
public override string GetDescription (XElement e)
{
- return e.GetTypeName ("name", State);
+ return e.GetTypeName ("name", State) ?? "";
}
}
}
diff --git a/tools/api-tools/mono-api-html/MemberComparer.cs b/tools/api-tools/mono-api-html/MemberComparer.cs
index 7fa20dbfb49c..d5a0ebfa216c 100644
--- a/tools/api-tools/mono-api-html/MemberComparer.cs
+++ b/tools/api-tools/mono-api-html/MemberComparer.cs
@@ -51,7 +51,7 @@ public void Compare (XElement source, XElement target)
return;
if (s is null) {
- Add (t.Elements (ElementName));
+ Add (t!.Elements (ElementName));
} else if (t is null) {
Remove (s.Elements (ElementName));
} else {
@@ -65,7 +65,7 @@ public override void SetContext (XElement current)
string GetContainingType (XElement el)
{
- return el.Ancestors ("class").First ().Attribute ("type").Value;
+ return el.Ancestors ("class").First ().Attribute ("type")!.Value;
}
bool IsInInterface (XElement el)
@@ -73,19 +73,19 @@ bool IsInInterface (XElement el)
return GetContainingType (el) == "interface";
}
- public XElement Source { get; set; }
+ public XElement Source { get; set; } = null!;
public virtual bool Find (XElement e)
{
return e.GetAttribute ("name") == Source.GetAttribute ("name");
}
- XElement Find (IEnumerable target)
+ XElement? Find (IEnumerable target)
{
return target.SingleOrDefault (Find);
}
- public override void Compare (IEnumerable source, IEnumerable target)
+ public override void Compare (IEnumerable source, IEnumerable? target)
{
removed.Clear ();
modified.Clear ();
@@ -93,7 +93,7 @@ public override void Compare (IEnumerable source, IEnumerable source, IEnumerable elements)
@@ -162,7 +163,7 @@ void Remove (IEnumerable elements)
protected StringBuilder GetObsoleteMessage (XElement e)
{
var sb = new StringBuilder ();
- string o = e.GetObsoleteMessage ();
+ string? o = e.GetObsoleteMessage ();
if (o is not null) {
sb.Append ("[Obsolete");
if (o.Length > 0)
@@ -237,12 +238,12 @@ protected void RenderGenericParameters (XElement source, XElement target, ApiCha
if (i > 0)
change.Append (", ");
if (i >= srcCount) {
- change.AppendAdded (RenderGenericParameter (tgt [i]));
+ change.AppendAdded (RenderGenericParameter (tgt! [i]));
} else if (i >= tgtCount) {
- change.AppendRemoved (RenderGenericParameter (src [i]));
+ change.AppendRemoved (RenderGenericParameter (src! [i]));
} else {
- var srcName = RenderGenericParameter (src [i]);
- var tgtName = RenderGenericParameter (tgt [i]);
+ var srcName = RenderGenericParameter (src! [i]);
+ var tgtName = RenderGenericParameter (tgt! [i]);
if (srcName != tgtName) {
change.AppendModified (srcName, tgtName);
@@ -254,7 +255,7 @@ protected void RenderGenericParameters (XElement source, XElement target, ApiCha
change.Append (Formatter.GreaterThan);
}
- protected string FormatValue (string type, string value)
+ protected string FormatValue (string? type, string? value)
{
if (value is null)
return "null";
@@ -287,8 +288,8 @@ protected void RenderParameters (XElement source, XElement target, ApiChange cha
if (i > 0)
change.Append (", ");
- string mods_tgt = tgt [i].GetAttribute ("direction") ?? "";
- string mods_src = src [i].GetAttribute ("direction") ?? "";
+ string mods_tgt = tgt! [i].GetAttribute ("direction") ?? "";
+ string mods_src = src! [i].GetAttribute ("direction") ?? "";
if (mods_tgt.Length > 0)
mods_tgt = mods_tgt + " ";
@@ -297,12 +298,12 @@ protected void RenderParameters (XElement source, XElement target, ApiChange cha
mods_src = mods_src + " ";
if (i >= srcCount) {
- change.AppendAdded (mods_tgt + tgt [i].GetTypeName ("type", State) + " " + tgt [i].GetAttribute ("name"));
+ change.AppendAdded (mods_tgt + tgt! [i].GetTypeName ("type", State) + " " + tgt [i].GetAttribute ("name"));
} else if (i >= tgtCount) {
- change.AppendRemoved (mods_src + src [i].GetTypeName ("type", State) + " " + src [i].GetAttribute ("name"));
+ change.AppendRemoved (mods_src + src! [i].GetTypeName ("type", State) + " " + src [i].GetAttribute ("name"));
} else {
- var paramSourceType = src [i].GetTypeName ("type", State);
- var paramTargetType = tgt [i].GetTypeName ("type", State);
+ var paramSourceType = src! [i].GetTypeName ("type", State);
+ var paramTargetType = tgt! [i].GetTypeName ("type", State);
var paramSourceName = src [i].GetAttribute ("name");
var paramTargetName = tgt [i].GetAttribute ("name");
@@ -314,15 +315,15 @@ protected void RenderParameters (XElement source, XElement target, ApiChange cha
}
if (paramSourceType != paramTargetType) {
- change.AppendModified (paramSourceType, paramTargetType);
+ change.AppendModified (paramSourceType ?? "", paramTargetType ?? "");
} else {
- change.Append (paramSourceType);
+ change.Append (paramSourceType ?? "");
}
change.Append (" ");
if (paramSourceName != paramTargetName) {
- change.AppendModified (paramSourceName, paramTargetName);
+ change.AppendModified (paramSourceName ?? "", paramTargetName ?? "");
} else {
- change.Append (paramSourceName);
+ change.Append (paramSourceName ?? "");
}
var optSource = src [i].Attribute ("optional");
@@ -467,13 +468,13 @@ protected void RemoveInternalFromProtectedInternal (XElement element)
// Changing between 'protected' and 'protected internal' is not visible in the API, so remove the 'internal' part.
if ((attrib & MethodAttributes.FamORAssem) == MethodAttributes.FamORAssem) {
attrib = (attrib & ~MethodAttributes.MemberAccessMask) | MethodAttributes.Family;
- element.Attribute ("attrib").Value = ((int) attrib).ToString ();
+ element.Attribute ("attrib")!.Value = ((int) attrib).ToString ();
}
}
protected void RenderName (XElement source, XElement target, ApiChange change)
{
- var name = target.GetAttribute ("name");
+ var name = target.GetAttribute ("name") ?? "";
// show the constructor as it would be defined in C#
name = name.Replace (".ctor", State.Type);
diff --git a/tools/api-tools/mono-api-html/MethodComparer.cs b/tools/api-tools/mono-api-html/MethodComparer.cs
index 9d9d58ce7266..677a5136bdf1 100644
--- a/tools/api-tools/mono-api-html/MethodComparer.cs
+++ b/tools/api-tools/mono-api-html/MethodComparer.cs
@@ -63,8 +63,8 @@ public override bool Find (XElement e)
else if (eGP is null ^ sGP is null)
return false;
else {
- var eGPs = eGP.Elements ("generic-parameter");
- var sGPs = sGP.Elements ("generic-parameter");
+ var eGPs = eGP!.Elements ("generic-parameter");
+ var sGPs = sGP!.Elements ("generic-parameter");
return eGPs.Count () == sGPs.Count ();
}
}
diff --git a/tools/api-tools/mono-api-html/NamespaceComparer.cs b/tools/api-tools/mono-api-html/NamespaceComparer.cs
index c2b65bba7463..e0d01e579302 100644
--- a/tools/api-tools/mono-api-html/NamespaceComparer.cs
+++ b/tools/api-tools/mono-api-html/NamespaceComparer.cs
@@ -56,20 +56,20 @@ public void Compare (XElement source, XElement target)
var t = target.Element ("namespaces");
if (XNode.DeepEquals (s, t))
return;
- Compare (s.Elements ("namespace"), t.Elements ("namespace"));
+ Compare (s!.Elements ("namespace"), t!.Elements ("namespace"));
}
public override void SetContext (XElement current)
{
- State.Namespace = current.Attribute ("name").Value;
+ State.Namespace = current.Attribute ("name")!.Value;
}
public override void Added (XElement target, bool wasParentAdded)
{
Formatter.BeginNamespace ("New ");
// list all new types
- foreach (var addedType in target.Element ("classes").Elements ("class")) {
- State.Type = addedType.Attribute ("name").Value;
+ foreach (var addedType in target.Element ("classes")!.Elements ("class")) {
+ State.Type = addedType.Attribute ("name")!.Value;
comparer.Added (addedType, true);
}
Formatter.EndNamespace ();
@@ -96,8 +96,8 @@ public override void Removed (XElement source)
Formatter.BeginNamespace ("Removed ");
Output.WriteLine ();
// list all removed types
- foreach (var removedType in source.Element ("classes").Elements ("class")) {
- State.Type = comparer.GetTypeName (removedType);
+ foreach (var removedType in source.Element ("classes")!.Elements ("class")) {
+ State.Type = comparer.GetTypeName (removedType) ?? "";
comparer.Removed (removedType);
}
Formatter.EndNamespace ();
diff --git a/tools/api-tools/mono-api-html/PropertyComparer.cs b/tools/api-tools/mono-api-html/PropertyComparer.cs
index d0ab5d616114..205600a6a199 100644
--- a/tools/api-tools/mono-api-html/PropertyComparer.cs
+++ b/tools/api-tools/mono-api-html/PropertyComparer.cs
@@ -55,7 +55,7 @@ public override bool Find (XElement e)
return e.GetAttribute ("params") == Source.GetAttribute ("params");
}
- void GetAccessors (XElement element, out XElement getter, out XElement setter)
+ void GetAccessors (XElement element, out XElement? getter, out XElement? setter)
{
var methods = element.Element ("methods");
@@ -66,7 +66,7 @@ void GetAccessors (XElement element, out XElement getter, out XElement setter)
return;
foreach (var m in methods.Elements ("method")) {
- var n = m.GetAttribute ("name");
+ var n = m.GetAttribute ("name") ?? "";
if (n.StartsWith ("get_", StringComparison.Ordinal)) {
getter = m;
} else if (n.StartsWith ("set_", StringComparison.Ordinal)) {
@@ -75,10 +75,10 @@ void GetAccessors (XElement element, out XElement getter, out XElement setter)
}
}
- MethodAttributes GetMethodAttributes (XElement getter, XElement setter)
+ MethodAttributes GetMethodAttributes (XElement? getter, XElement? setter)
{
if (getter is null)
- return setter.GetMethodAttributes ();
+ return setter!.GetMethodAttributes ();
else if (setter is null)
return getter.GetMethodAttributes ();
@@ -97,8 +97,8 @@ MethodAttributes GetMethodAttributes (XElement getter, XElement setter)
void RenderPropertyType (XElement source, XElement target, ApiChange change)
{
- var srcType = source.GetTypeName ("ptype", State);
- var tgtType = target.GetTypeName ("ptype", State);
+ var srcType = source.GetTypeName ("ptype", State) ?? "";
+ var tgtType = target.GetTypeName ("ptype", State) ?? "";
if (srcType == tgtType) {
change.Append (tgtType);
@@ -108,7 +108,7 @@ void RenderPropertyType (XElement source, XElement target, ApiChange change)
change.Append (" ");
}
- void RenderAccessors (XElement srcGetter, XElement tgtGetter, XElement srcSetter, XElement tgtSetter, ApiChange change)
+ void RenderAccessors (XElement? srcGetter, XElement? tgtGetter, XElement? srcSetter, XElement? tgtSetter, ApiChange change)
{
// FIXME: this doesn't render changes in the accessor visibility (a protected setter can become public for instance).
change.Append (" {");
@@ -145,8 +145,8 @@ void RenderIndexers (List srcIndexers, List tgtIndexers, Api
if (i > 0)
change.Append (", ");
- var srcType = source.GetTypeName ("type", State);
- var tgtType = target.GetTypeName ("type", State);
+ var srcType = source.GetTypeName ("type", State) ?? "";
+ var tgtType = target.GetTypeName ("type", State) ?? "";
if (srcType == tgtType) {
change.Append (tgtType);
} else {
@@ -154,8 +154,8 @@ void RenderIndexers (List srcIndexers, List tgtIndexers, Api
}
change.Append (" ");
- var srcName = source.GetAttribute ("name");
- var tgtName = target.GetAttribute ("name");
+ var srcName = source.GetAttribute ("name") ?? "";
+ var tgtName = target.GetAttribute ("name") ?? "";
if (srcName == tgtName) {
change.Append (tgtName);
} else {
@@ -170,17 +170,17 @@ public override bool Equals (XElement source, XElement target, ApiChanges change
if (base.Equals (source, target, changes))
return true;
- XElement srcGetter, srcSetter;
- XElement tgtGetter, tgtSetter;
+ XElement? srcGetter, srcSetter;
+ XElement? tgtGetter, tgtSetter;
GetAccessors (source, out srcGetter, out srcSetter);
GetAccessors (target, out tgtGetter, out tgtSetter);
- List srcIndexers = null;
- List tgtIndexers = null;
+ List? srcIndexers = null;
+ List? tgtIndexers = null;
bool isIndexer = false;
if (srcGetter is not null) {
srcIndexers = srcGetter.DescendantList ("parameters", "parameter");
- tgtIndexers = tgtGetter.DescendantList ("parameters", "parameter");
+ tgtIndexers = tgtGetter?.DescendantList ("parameters", "parameter");
isIndexer = srcIndexers is not null && srcIndexers.Count > 0;
}
@@ -189,8 +189,8 @@ public override bool Equals (XElement source, XElement target, ApiChanges change
RenderAttributes (source, target, change);
RenderMethodAttributes (source, target, GetMethodAttributes (srcGetter, srcSetter), GetMethodAttributes (tgtGetter, tgtSetter), change);
RenderPropertyType (source, target, change);
- if (isIndexer) {
- RenderIndexers (srcIndexers, tgtIndexers, change);
+ if (isIndexer && tgtIndexers is not null) {
+ RenderIndexers (srcIndexers!, tgtIndexers, change);
} else {
RenderName (source, target, change);
}
@@ -211,10 +211,10 @@ void GetProperties (XElement e, out bool @virtual, out bool @override, out bool
foreach (var m in methods.Elements ("method")) {
@virtual |= m.IsTrue ("virtual");
@static |= m.IsTrue ("static");
- var n = m.GetAttribute ("name");
+ var n = m.GetAttribute ("name") ?? "";
getter |= n.StartsWith ("get_", StringComparison.Ordinal);
setter |= n.StartsWith ("set_", StringComparison.Ordinal);
- var attribs = (MethodAttributes) Int32.Parse (m.GetAttribute ("attrib"));
+ var attribs = (MethodAttributes) Int32.Parse (m.GetAttribute ("attrib") ?? "0");
family = ((attribs & MethodAttributes.Public) != MethodAttributes.Public);
@override |= (attribs & MethodAttributes.NewSlot) == 0;
}
@@ -223,8 +223,8 @@ void GetProperties (XElement e, out bool @virtual, out bool @override, out bool
public override string GetDescription (XElement e)
{
- string name = e.Attribute ("name").Value;
- string ptype = e.GetTypeName ("ptype", State);
+ string name = e.Attribute ("name")!.Value;
+ string ptype = e.GetTypeName ("ptype", State) ?? "";
bool virt = false;
bool over = false;
diff --git a/tools/api-tools/mono-api-info/Util.cs b/tools/api-tools/mono-api-info/Util.cs
index bd4f7270700f..43e222825594 100644
--- a/tools/api-tools/mono-api-info/Util.cs
+++ b/tools/api-tools/mono-api-info/Util.cs
@@ -90,7 +90,7 @@ internal IEnumerable GetInterfaces (TypeReference type)
return ifaces.Values;
}
- internal TypeDefinition GetBaseType (TypeDefinition child)
+ internal TypeDefinition? GetBaseType (TypeDefinition child)
{
if (child.BaseType is null)
return null;
@@ -102,7 +102,7 @@ internal TypeDefinition GetBaseType (TypeDefinition child)
}
}
- internal MethodDefinition GetMethod (MethodReference method)
+ internal MethodDefinition? GetMethod (MethodReference method)
{
if (method is null)
throw new ArgumentNullException (nameof (method));
@@ -134,14 +134,14 @@ bool IsOverride (MethodDefinition method)
return method.IsVirtual && !method.IsNewSlot;
}
- public MethodDefinition GetBaseMethodInTypeHierarchy (MethodDefinition method)
+ public MethodDefinition? GetBaseMethodInTypeHierarchy (MethodDefinition method)
{
if (!IsOverride (method))
return method;
var @base = GetBaseType (method.DeclaringType);
while (@base is not null) {
- MethodDefinition base_method = TryMatchMethod (@base.Resolve (), method);
+ MethodDefinition? base_method = TryMatchMethod (@base.Resolve (), method);
if (base_method is not null)
return GetBaseMethodInTypeHierarchy (base_method) ?? base_method;
@@ -151,7 +151,7 @@ public MethodDefinition GetBaseMethodInTypeHierarchy (MethodDefinition method)
return method;
}
- MethodDefinition TryMatchMethod (TypeDefinition type, MethodDefinition method)
+ MethodDefinition? TryMatchMethod (TypeDefinition type, MethodDefinition method)
{
if (!type.HasMethods)
return null;
diff --git a/tools/api-tools/mono-api-info/WellFormedXmlWriter.cs b/tools/api-tools/mono-api-info/WellFormedXmlWriter.cs
index 259176e4347a..754f198a84b1 100644
--- a/tools/api-tools/mono-api-info/WellFormedXmlWriter.cs
+++ b/tools/api-tools/mono-api-info/WellFormedXmlWriter.cs
@@ -77,8 +77,12 @@ public WellFormedXmlWriter (XmlWriter writer) : base (writer)
{
}
- public override void WriteString (string text)
+ public override void WriteString (string? text)
{
+ if (text is null) {
+ Writer.WriteString (text);
+ return;
+ }
int i = IndexOfInvalid (text, true);
if (i >= 0) {
char [] arr = text.ToCharArray ();
@@ -131,7 +135,7 @@ public override void Flush ()
writer.Flush ();
}
- public override string LookupPrefix (string ns)
+ public override string? LookupPrefix (string ns)
{
return writer.LookupPrefix (ns);
}
@@ -146,7 +150,7 @@ public override void WriteBinHex (byte [] buffer, int index, int count)
writer.WriteBinHex (buffer, index, count);
}
- public override void WriteCData (string text)
+ public override void WriteCData (string? text)
{
writer.WriteCData (text);
}
@@ -161,12 +165,12 @@ public override void WriteChars (char [] buffer, int index, int count)
writer.WriteChars (buffer, index, count);
}
- public override void WriteComment (string text)
+ public override void WriteComment (string? text)
{
writer.WriteComment (text);
}
- public override void WriteDocType (string name, string pubid, string sysid, string subset)
+ public override void WriteDocType (string name, string? pubid, string? sysid, string? subset)
{
writer.WriteDocType (name, pubid, sysid, subset);
}
@@ -211,12 +215,12 @@ public override void WriteNode (XmlReader reader, bool defattr)
writer.WriteNode (reader, defattr);
}
- public override void WriteProcessingInstruction (string name, string text)
+ public override void WriteProcessingInstruction (string name, string? text)
{
writer.WriteProcessingInstruction (name, text);
}
- public override void WriteQualifiedName (string localName, string ns)
+ public override void WriteQualifiedName (string localName, string? ns)
{
writer.WriteQualifiedName (localName, ns);
}
@@ -231,7 +235,7 @@ public override void WriteRaw (char [] buffer, int index, int count)
writer.WriteRaw (buffer, index, count);
}
- public override void WriteStartAttribute (string prefix, string localName, string ns)
+ public override void WriteStartAttribute (string? prefix, string localName, string? ns)
{
writer.WriteStartAttribute (prefix, localName, ns);
}
@@ -246,12 +250,12 @@ public override void WriteStartDocument ()
writer.WriteStartDocument ();
}
- public override void WriteStartElement (string prefix, string localName, string ns)
+ public override void WriteStartElement (string? prefix, string localName, string? ns)
{
writer.WriteStartElement (prefix, localName, ns);
}
- public override void WriteString (string text)
+ public override void WriteString (string? text)
{
writer.WriteString (text);
}
@@ -261,7 +265,7 @@ public override void WriteSurrogateCharEntity (char lowChar, char highChar)
writer.WriteSurrogateCharEntity (lowChar, highChar);
}
- public override void WriteWhitespace (string ws)
+ public override void WriteWhitespace (string? ws)
{
writer.WriteWhitespace (ws);
}
@@ -272,7 +276,7 @@ public override WriteState WriteState {
}
}
- public override string XmlLang {
+ public override string? XmlLang {
get {
return writer.XmlLang;
}
diff --git a/tools/api-tools/mono-api-info/mono-api-info.cs b/tools/api-tools/mono-api-info/mono-api-info.cs
index 07d6c3791c3b..b0c8a4d9d542 100644
--- a/tools/api-tools/mono-api-info/mono-api-info.cs
+++ b/tools/api-tools/mono-api-info/mono-api-info.cs
@@ -29,8 +29,8 @@ class Driver {
public static int Main (string [] args)
{
bool showHelp = false;
- string output = null;
- List asms = null;
+ string? output = null;
+ List? asms = null;
ApiInfoConfig config = new ApiInfoConfig ();
var options = new Mono.Options.OptionSet {
@@ -82,7 +82,7 @@ public static int Main (string [] args)
return showHelp ? 0 : 1;
}
- TextWriter outputStream = null;
+ TextWriter? outputStream = null;
try {
if (!string.IsNullOrEmpty (output))
outputStream = new StreamWriter (output);
@@ -116,7 +116,7 @@ class State {
public List ResolveStreams { get; } = new List ();
- public TypeHelper TypeHelper { get; private set; }
+ public TypeHelper TypeHelper { get; private set; } = null!;
public void ResolveTypes ()
{
@@ -156,7 +156,7 @@ public class ApiInfoConfig {
}
public static class ApiInfo {
- public static void Generate (string assemblyPath, TextWriter outStream, ApiInfoConfig config = null)
+ public static void Generate (string assemblyPath, TextWriter outStream, ApiInfoConfig? config = null)
{
if (assemblyPath is null)
throw new ArgumentNullException (nameof (assemblyPath));
@@ -164,7 +164,7 @@ public static void Generate (string assemblyPath, TextWriter outStream, ApiInfoC
Generate (new [] { assemblyPath }, null, outStream, config);
}
- public static void Generate (Stream assemblyStream, TextWriter outStream, ApiInfoConfig config = null)
+ public static void Generate (Stream assemblyStream, TextWriter outStream, ApiInfoConfig? config = null)
{
if (assemblyStream is null)
throw new ArgumentNullException (nameof (assemblyStream));
@@ -172,17 +172,17 @@ public static void Generate (Stream assemblyStream, TextWriter outStream, ApiInf
Generate (null, new [] { assemblyStream }, outStream, config);
}
- public static void Generate (IEnumerable assemblyPaths, TextWriter outStream, ApiInfoConfig config = null)
+ public static void Generate (IEnumerable assemblyPaths, TextWriter outStream, ApiInfoConfig? config = null)
{
Generate (assemblyPaths, null, outStream, config);
}
- public static void Generate (IEnumerable assemblyStreams, TextWriter outStream, ApiInfoConfig config = null)
+ public static void Generate (IEnumerable assemblyStreams, TextWriter outStream, ApiInfoConfig? config = null)
{
Generate (null, assemblyStreams, outStream, config);
}
- public static void Generate (IEnumerable assemblyPaths, IEnumerable assemblyStreams, TextWriter outStream, ApiInfoConfig config = null)
+ public static void Generate (IEnumerable? assemblyPaths, IEnumerable? assemblyStreams, TextWriter outStream, ApiInfoConfig? config = null)
{
if (outStream is null)
throw new ArgumentNullException (nameof (outStream));
@@ -204,7 +204,7 @@ public static void Generate (IEnumerable assemblyPaths, IEnumerable assemblyFiles, IEnumerable assemblyStreams, TextWriter outStream, State state = null)
+ internal static void Generate (IEnumerable? assemblyFiles, IEnumerable? assemblyStreams, TextWriter outStream, State? state = null)
{
if (outStream is null)
throw new ArgumentNullException (nameof (outStream));
@@ -295,7 +295,7 @@ public static string CleanupTypeName (string t)
}
class AssemblyCollection {
- XmlWriter writer;
+ XmlWriter writer = null!;
List assemblies = new List ();
State state;
@@ -384,7 +384,7 @@ public override void DoOutput ()
continue;
writer.WriteStartElement ("attribute");
- AddAttribute ("name", typeof (TypeForwardedToAttribute).FullName);
+ AddAttribute ("name", typeof (TypeForwardedToAttribute).FullName!);
writer.WriteStartElement ("properties");
writer.WriteStartElement ("property");
AddAttribute ("name", "Destination");
@@ -497,7 +497,7 @@ public MemberData (XmlWriter writer, MemberReference [] members, State state)
this.members = members;
}
- protected virtual ICustomAttributeProvider GetAdditionalCustomAttributeProvider (MemberReference member)
+ protected virtual ICustomAttributeProvider? GetAdditionalCustomAttributeProvider (MemberReference member)
{
return null;
}
@@ -510,10 +510,14 @@ public override void DoOutput ()
writer.WriteStartElement (Tag);
AddAttribute ("name", GetName (member));
if (!NoMemberAttributes)
- AddAttribute ("attrib", GetMemberAttributes (member));
+ AddAttribute ("attrib", GetMemberAttributes (member) ?? "");
AddExtraAttributes (member);
- AttributeData.OutputAttributes (writer, state, (ICustomAttributeProvider) member, GetAdditionalCustomAttributeProvider (member));
+ var additionalProvider = GetAdditionalCustomAttributeProvider (member);
+ if (additionalProvider is not null)
+ AttributeData.OutputAttributes (writer, state, (ICustomAttributeProvider) member, additionalProvider);
+ else
+ AttributeData.OutputAttributes (writer, state, (ICustomAttributeProvider) member);
AddExtraData (member);
writer.WriteEndElement (); // Tag
@@ -535,7 +539,7 @@ protected virtual string GetName (MemberReference memberDefenition)
return "NoNAME";
}
- protected virtual string GetMemberAttributes (MemberReference memberDefenition)
+ protected virtual string? GetMemberAttributes (MemberReference memberDefenition)
{
return null;
}
@@ -596,7 +600,7 @@ class TypeData : MemberData {
TypeDefinition type;
public TypeData (XmlWriter writer, TypeDefinition type, State state)
- : base (writer, null, state)
+ : base (writer, [], state)
{
this.type = type;
}
@@ -625,7 +629,7 @@ public override void DoOutput ()
string charSet = GetCharSet (type);
AddAttribute ("charset", charSet);
- string layout = GetLayout (type);
+ string? layout = GetLayout (type);
if (layout is not null)
AddAttribute ("layout", layout);
@@ -732,7 +736,7 @@ public override void DoOutput ()
writer.WriteEndElement (); // class
}
- static FieldReference GetEnumValueField (TypeDefinition type)
+ static FieldReference? GetEnumValueField (TypeDefinition type)
{
foreach (FieldDefinition field in type.Fields)
if (field.IsSpecialName && field.Name == "value__")
@@ -793,7 +797,7 @@ static string GetCharSet (TypeDefinition type)
return CharSet.None.ToString ();
}
- static string GetLayout (TypeDefinition type)
+ static string? GetLayout (TypeDefinition type)
{
TypeAttributes maskedLayout = type.Attributes & TypeAttributes.LayoutMask;
if (maskedLayout == TypeAttributes.AutoLayout)
@@ -926,8 +930,10 @@ private MethodDefinition [] GetMethods (TypeDefinition type, bool fullAPI)
}
sealed class ParameterComparer : IEqualityComparer {
- public bool Equals (ParameterDefinition x, ParameterDefinition y)
+ public bool Equals (ParameterDefinition? x, ParameterDefinition? y)
{
+ if (x is null || y is null)
+ return x is null && y is null;
return x.ParameterType.Name == y.ParameterType.Name;
}
@@ -1012,7 +1018,7 @@ protected override void AddExtraAttributes (MemberReference memberDefinition)
if (field.IsLiteral) {
object value = field.Constant;//object value = field.GetValue (null);
- string stringValue = null;
+ string? stringValue = null;
//if (value is Enum) {
// // FIXME: when Mono bug #60090 has been
// // fixed, we should just be able to use
@@ -1049,21 +1055,21 @@ protected override string GetName (MemberReference memberDefenition)
return prop.Name;
}
- MethodDefinition [] GetMethods (PropertyDefinition prop, out bool haveParameters)
+ MethodDefinition []? GetMethods (PropertyDefinition prop, out bool haveParameters)
{
MethodDefinition _get = prop.GetMethod;
MethodDefinition _set = prop.SetMethod;
bool haveGet = (_get is not null && TypeData.MustDocumentMethod (_get));
bool haveSet = (_set is not null && TypeData.MustDocumentMethod (_set));
- haveParameters = haveGet || (haveSet && _set.Parameters.Count > 1);
+ haveParameters = haveGet || (haveSet && _set!.Parameters.Count > 1);
MethodDefinition [] methods;
if (haveGet && haveSet) {
- methods = new MethodDefinition [] { _get, _set };
+ methods = new MethodDefinition [] { _get!, _set! };
} else if (haveGet) {
- methods = new MethodDefinition [] { _get };
+ methods = new MethodDefinition [] { _get! };
} else if (haveSet) {
- methods = new MethodDefinition [] { _set };
+ methods = new MethodDefinition [] { _set! };
} else {
//odd
return null;
@@ -1080,7 +1086,7 @@ protected override void AddExtraAttributes (MemberReference memberDefinition)
AddAttribute ("ptype", Utils.CleanupTypeName (prop.PropertyType));
bool haveParameters;
- MethodDefinition [] methods = GetMethods ((PropertyDefinition) memberDefinition, out haveParameters);
+ MethodDefinition []? methods = GetMethods ((PropertyDefinition) memberDefinition, out haveParameters);
if (methods is not null && haveParameters) {
string parms = Parameters.GetSignature (methods [0].Parameters);
@@ -1095,7 +1101,7 @@ protected override void AddExtraData (MemberReference memberDefenition)
base.AddExtraData (memberDefenition);
bool haveParameters;
- MethodDefinition [] methods = GetMethods ((PropertyDefinition) memberDefenition, out haveParameters);
+ MethodDefinition []? methods = GetMethods ((PropertyDefinition) memberDefenition, out haveParameters);
if (methods is null)
return;
@@ -1301,7 +1307,7 @@ public override void DoOutput ()
if (parameter.IsOptional) {
AddAttribute ("optional", "true");
if (parameter.HasConstant)
- AddAttribute ("defaultValue", parameter.Constant is null ? "NULL" : parameter.Constant.ToString ());
+ AddAttribute ("defaultValue", parameter.Constant is null ? "NULL" : parameter.Constant.ToString () ?? "");
}
if (direction != "in")
@@ -1453,8 +1459,11 @@ public static string GetSignature (IList infos)
class TypeReferenceComparer : IComparer {
public static TypeReferenceComparer Default = new TypeReferenceComparer ();
- public int Compare (TypeReference a, TypeReference b)
+ public int Compare (TypeReference? a, TypeReference? b)
{
+ if (a is null && b is null) return 0;
+ if (a is null) return -1;
+ if (b is null) return 1;
int result = String.Compare (a.Namespace, b.Namespace, StringComparison.Ordinal);
if (result != 0)
return result;
@@ -1466,8 +1475,11 @@ public int Compare (TypeReference a, TypeReference b)
class MemberReferenceComparer : IComparer {
public static MemberReferenceComparer Default = new MemberReferenceComparer ();
- public int Compare (object a, object b)
+ public int Compare (object? a, object? b)
{
+ if (a is null && b is null) return 0;
+ if (a is null) return -1;
+ if (b is null) return 1;
MemberReference ma = (MemberReference) a;
MemberReference mb = (MemberReference) b;
return String.Compare (ma.Name, mb.Name, StringComparison.Ordinal);
@@ -1477,8 +1489,11 @@ public int Compare (object a, object b)
class PropertyDefinitionComparer : IComparer {
public static PropertyDefinitionComparer Default = new PropertyDefinitionComparer ();
- public int Compare (PropertyDefinition ma, PropertyDefinition mb)
+ public int Compare (PropertyDefinition? ma, PropertyDefinition? mb)
{
+ if (ma is null && mb is null) return 0;
+ if (ma is null) return -1;
+ if (mb is null) return 1;
int res = String.Compare (ma.Name, mb.Name, StringComparison.Ordinal);
if (res != 0)
return res;
@@ -1499,8 +1514,11 @@ public int Compare (PropertyDefinition ma, PropertyDefinition mb)
class MethodDefinitionComparer : IComparer {
public static MethodDefinitionComparer Default = new MethodDefinitionComparer ();
- public int Compare (object a, object b)
+ public int Compare (object? a, object? b)
{
+ if (a is null && b is null) return 0;
+ if (a is null) return -1;
+ if (b is null) return 1;
MethodDefinition ma = (MethodDefinition) a;
MethodDefinition mb = (MethodDefinition) b;
int res = String.Compare (ma.Name, mb.Name, StringComparison.Ordinal);
From 6181392f5ae422b6e969d24979d70b79c38aed1e Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 12 May 2026 20:01:57 +0200
Subject: [PATCH 041/156] [tests] Fix introspection TypoTest and improve
allowed word management (#25393)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
## Summary
Fix the introspection TypoTest that was silently not being discovered by NUnit, merge platform-specific subclasses into the base class, and improve the allowed word list management.
## Changes
1. **Fix TypoTest not being discovered by NUnit** — NUnit 3 doesn't discover overridden virtual `[Test]` methods in derived classes unless `[Test]` is re-added. Added `[Test]` to the overrides and fixed the resulting test failures (193+ new words needed in the allowed list).
2. **Merge iOSApiTypoTest and MacApiTypoTest into ApiTypoTest** — Made the base class concrete with `#if` conditions for platform differences, deleted the now-unnecessary subclass files.
3. **Verify allowed words are still needed** — Enabled the unused-word verification (previously disabled with `#if false`) to ensure stale entries are caught.
4. **Platform-specific allowed word lists** — Categorized all 740 allowed words by which platforms need them, using data from all 4 platforms (macOS, Mac Catalyst, iOS, tvOS).
5. **Use Dictionary instead of #if guards** — Replaced complex `#if` conditional compilation with a `Dictionary` mapping each word to its platform flags. Much easier to maintain.
## Testing
Verified all 4 platforms pass:
- macOS: 34/34 ✅
- Mac Catalyst: 41/41 ✅
- iOS: 44/44 ✅
- tvOS: 43/43 ✅
🤖 Pull request created by Copilot
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Rolf Bjarne Kvinge
---
tests/introspection/ApiTypoTest.cs | 1464 ++++++++++++----------
tests/introspection/MacApiTypoTest.cs | 28 -
tests/introspection/dotnet/shared.csproj | 2 -
tests/introspection/iOSApiTypoTest.cs | 34 -
4 files changed, 786 insertions(+), 742 deletions(-)
delete mode 100644 tests/introspection/MacApiTypoTest.cs
delete mode 100644 tests/introspection/iOSApiTypoTest.cs
diff --git a/tests/introspection/ApiTypoTest.cs b/tests/introspection/ApiTypoTest.cs
index 49a0fc0ec91c..a42f62aa4141 100644
--- a/tests/introspection/ApiTypoTest.cs
+++ b/tests/introspection/ApiTypoTest.cs
@@ -27,8 +27,10 @@
using System.Text.RegularExpressions;
#if MONOMAC
using AppKit;
+using SpellChecker = AppKit.NSSpellChecker;
#else
using UIKit;
+using SpellChecker = UIKit.UITextChecker;
#endif
using Xamarin.Tests;
using Xamarin.Utils;
@@ -36,8 +38,11 @@
#nullable enable
namespace Introspection {
- public abstract class ApiTypoTest : ApiBaseTest {
- protected ApiTypoTest ()
+ [TestFixture]
+ public class ApiTypoTest : ApiBaseTest {
+ const ApplePlatform All = ApplePlatform.MacOSX | ApplePlatform.iOS | ApplePlatform.TVOS | ApplePlatform.MacCatalyst;
+
+ public ApiTypoTest ()
{
ContinueOnFailure = true;
}
@@ -64,675 +69,755 @@ public virtual bool Skip (MemberInfo methodName, string typo)
"MacAttribute",
};
- HashSet allowed = new HashSet () {
- "Aac",
- "Achivements",
- "Acos",
- "Acosh",
- "Acn",
- "Actionname",
- "Activitiy",
- "Addin",
- "Addl",
- "Addr",
- "Adjustmentfor",
- "Aes", // Advanced Encryption Standard
- "Aifc",
- "Aiff",
- "Agc",
- "Aio",
- "Alg", // short for Algorithm
- "Alpn", // Application-Layer Protocol Negotiation RFC7301
- "Amete",
- "Amr",
- "Anglet",
- "Apng", // Animated Portable Network Graphics
- "Aps",
- "Arraycollation",
- "Argb",
- "Asin",
- "Asinh",
- "Atan",
- "Atanh",
- "Atmos", // Dolby Atmos
- "Ats", // App Transport Security
- "Attrib",
- "Attributevalue",
- "Attrs", // Attributes (used by Apple for keys)
- "Audiofile",
- "Automapping",
- "Automatch",
- "Automounted",
- "Autoredirect",
- "Autospace",
- "Autostarts",
- "Avci", // file type
- "Avb", // acronym: Audio Video Bridging
- "Aliasable",
- "Arcball",
- "Atm",
- "Avg",
- "Backface",
- "Bancaire", // french
- "Bancaires", // french
- "Bary",
- "Batc",
- "Bgra", // acrnym for Blue, Green, Red, Alpha
- "Bim",
- "Biquad",
- "Bitangent",
- "Blinn",
- "Blit",
- "Bokeh",
- "Bggr", // acronym for Blue, Green, Green, Red
- "Bsln",
- "Bssid",
- "Btle", // Bluetooth Low Energy
- "Bzip",
- "Cabac",
- "Caf", // acronym: Core Audio Format
- "Cancellable",
- "Cartes", // french
- "Cavlc",
- "Cda", // acronym: Clinical Document Architecture
- "Cdrom",
- "Celu", // Continuously Differentiable Exponential Linear Unit (ML)
- "Cfa", // acronym: Color Filter Array
- "Celp", // MPEG4ObjectID
- "Characterteristic",
- "Chapv",
- "Cholesky",
- "Chacha",
- "Chromaticities",
- "Ciexyz",
- "Ciff",
- "Cinepak",
- "Clearcoat",
- "Cnn", // Convolutional Neural Network
- "Cns",
- "Colos",
- "Commerical",
- "Composable",
- "Conflictserror",
- "Connnect",
- "Counterclock",
- "Copyback",
- "Craete",
- "Crosstraining",
- "Cubemap",
- "Cmaf", // Common Media Application Format (mpeg4)
- "Cmy", // acronym: Cyan, magenta, yellow
- "Cmyk", // acronym: Cyan, magenta, yellow and key
- "Daap",
- "Dav",
- "Dcip", // acronym: Digital Cinema Implementation Partners
- "Deca",
- "Decomposables",
- "Deinterlace",
- "Depthwise",
- "Descendents",
- "Descrete",
- "Dhe", // Diffie–Hellman key exchange
- "Diffable", // that you can diff it.. made up word from apple
- "Differental",
- "Diffie",
- "Directionfor",
- "Dist",
- "dlclose",
- "dlerror",
- "Dlfcn",
- "dlopen",
- "Dls",
- "Dlsym",
- "dlsym",
- "Dng",
- "Dns",
- "Dont",
- "Dop",
- "Dopesheet",
- "Downsample",
- "Downmix", // Sound terminology that means making a stereo mix from a 5.1 surround mix.
- "Dpa",
- "Dpad", // Directional pad (D-pad)
- "Dpads", // plural of above
- "Droste",
- "Dtls",
- "Dtmf", // DTMF
- "dy",
- "Eap",
- "Ebu",
- "Ecc", // Elliptic Curve Cryptography
- "Ecdh", // Elliptic Curve Diffie–Hellman
- "Ecdhe", // Elliptic Curve Diffie-Hellman Ephemeral
- "Ecdsa", // Elliptic Curve Digital Signature Algorithm
- "Ecies", // Elliptic Curve Integrated Encryption Scheme
- "Ecn", // Explicit Congestion Notification
- "Ect", // ECN Capable Transport
- "Editability",
- "Edr",
- "Eof", // acronym End-Of-File
- "Elu",
- "Emagic",
- "Emaili",
- "Embd",
- "Emsg", // 4cc
- "Enc",
- "Eppc",
- "Epub",
- "Eftpos", // Electronic funds transfer at point of sale
- "Eotf", // DisplayP3_PQ_Eotf
- "Exabits",
- "Exbibits",
- "Exbibytes",
- "Exhange",
- "Exp",
- "Expr",
- "Exr",
- "Felica", // Japanese contactless RFID smart card system
- "Femtowatts",
- "Fhir",
- "Flipside",
- "Formati",
- "Fov",
- "Framebuffer",
- "Framesetter",
- "Froms", // NSMetadataItemWhereFromsKey
- "Freq",
- "Ftps",
- "Func",
- "Gadu",
- "Gbrg", // acronym for Green-Blue-Reg-Green
- "Gelu", // Gaussian Error Linear Unit (ML)
- "Geocoder",
- "Gigapascals",
- "Gibibits",
- "Gibibytes",
- "Girocard",
- "Glorot", // NN
- "Gop", // acronym for Group Of Pictures
- "Gpp",
- "Gps",
- "Gpu", // acronym for Graphics Processing Unit
- "Grbg", // acronym for Green-Red-Blue-Green
- "Gru",
- "Greeking",
- "Gtin",
- "Gui",
- "Hardlink",
- "Heics", // High Efficiency Image File Format (Sequence)
- "Hdmi",
- "Hdr",
- "Hectopascals",
- "Heic", // file type
- "Heif", // file type
- "Hevc", // CMVideoCodecType / High Efficiency Video Coding
- "Heif", // High Efficiency Image File Format
- "Hfp",
- "Hipass",
- "Hlg", // Hybrid Log-Gamma
- "Hls",
- "Hoa",
- "Hrtf", // acronym used in AUSpatializationAlgorithm
- "Hvxc", // MPEG4ObjectID
- "Icns",
- "Ico",
- "Ies",
- "Icq",
- "Ident",
- "Identd",
- "Imageblock",
- "Imagefor",
- "Imap",
- "Imaps",
- "Img",
- "Impl", // BindingImplAttribute
- "Inv",
- "Indoorrun",
- "Indoorcycle",
- "Inklist",
- "Indeterm",
- "Indoorwalk",
- "Inode",
- "Inser",
- "Instamatic",
- "Interac",
- "Interframe",
- "Interitem",
- "Intermenstrual",
- "Intersector",
- "Intoi",
- "Invitable",
- "Ios",
- "Iou",
- "Ipa",
- "Ipp",
- "Iptc",
- "Ircs",
- "Iso",
- "Itf",
- "Itu",
- "Itur", // Itur_2020_Hlg
- "Jcb", // Japanese credit card company
- "Jfif",
- "Jis",
- "Json",
- "Keyerror",
- "Keyi",
- "Keypoint",
- "Keypoints",
- "Keyspace",
- "ks",
- "Kibibits",
- "Kibibytes",
- "Kiloampere",
- "Kiloamperes",
- "Kiloohms",
- "Kilopascals",
- "Kullback", // Kullback-Leibler Divergence
- "Langauges",
- "Lacunarity",
- "Latm", // Low Overhead Audio Transport Multiplex
- "Ldaps",
- "Lerp",
- "Linecap",
- "Lingustic",
- "libcompression",
- "libdispatch",
- "Loas", // Low Overhead Audio Stream
- "Lod",
- "Lopass",
- "Lowlevel",
- "Lstm",
- "Lun",
- "Luma",
- "Lzfse", // acronym
- "Lzma", // acronym
- "Mada", // payment system
- "Mapbuffer",
- "Matchingcoalesce",
- "Mcp", // metacarpophalangeal (hand)
- "Mebibits",
- "Mebibytes",
- "Megaampere",
- "Megaamperes",
- "Megaliters",
- "Megameters",
- "Megaohms",
- "Megapascals",
- "Metacharacters",
- "Metalness",
- "Metadatas",
- "Microampere",
- "Microamperes",
- "Microohms",
- "Microwatts",
- "Millimoles",
- "Milliohms",
- "Mimap",
- "Minification",
- "Mncs",
- "Mgmt",
- "Mobike", // acronym
- "Morpher",
- "mtouch",
- "Mpe", // acronym
- "Mps",
- "Msaa", // multisample anti-aliasing
- "Mtu", // acronym
- "Mtc", // acronym
- "Mtgp",
- "Mul",
- "Mult",
- "Multihead",
- "Multipath",
- "Multipeer",
- "Muxed",
- "Nai",
- "Nanograms",
- "Nanowatts",
- "Nestrov",
- "Nesterov",
- "nfloat",
- "Nfnt",
- "nint",
- "Nntps",
- "Ntlm",
- "Nsl", // InternetLocationNslNeighborhoodIcon
- "Ntsc",
- "nuint",
- "Ndef",
- "Noi", // From NoiOSAttribute
- "Nop",
- "Numbernumber",
- "Nyquist",
- "Oaep", // Optimal asymmetric encryption padding
- "Objectfor",
- "Objectness",
- "Occlussion",
- "Ocurrences",
- "Ocsp", // Online Certificate Status Protocol
- "Octree",
- "Oid",
- "Oneup", // TVElementKeyOneupTemplate
- "Organisation", // kCGImagePropertyIPTCExtRegistryOrganisationID in Xcode9.3-b1
- "Orthographyrange",
- "Orth",
- "Osa", // Open Scripting Architecture
- "Otsu", // threshold for image binarization
- "ove",
- "Paeth", // PNG filter
- "Palettize",
- "Parms", // short for Parameters
- "Peap",
- "Pebibits",
- "Pebibytes",
- "Petabits",
- "Perlin",
- "Persistable",
- "Pausable",
- "Pcl",
- "Pcm",
- "Pdu",
- "Persistance",
- "Pesented",
- "Pfs", // acronym
- "Philox",
- "Picometers",
- "Picowatts",
- "Pkcs",
- "Placemark",
- "Playthrough",
- "Pnc", // MIDI
- "Pnorm",
- "Pointillize",
- "Polyline",
- "Polylines",
- "Popularimeter",
- "Preds", // short for Predicates
- "Prerolls",
- "Preseti",
- "Prev",
- "Privs", // SharingPrivsNotApplicableIcon
- "Propogate",
- "Psec",
- "Psm", // Protocol/Service Multiplexer
- "Psk",
- "Ptp",
- "Pvrtc", // MTLBlitOption - PowerVR Texture Compression
- "Qos",
- "Quaterniond",
- "Quadding",
- "Qura",
- "Quic",
- "Reacquirer",
- "Reinvitation",
- "Reinvite",
- "Rel",
- "Relocalization",
- "Relu", // Rectified Linear Unit (ML)
- "Relun", // ReLUn - degree n Hermite coefficients
- "Reprandial",
- "Replayable",
- "Requestwith",
- "Ridesharing",
- "Rgb",
- "Rgba",
- "Rggb", // acronym for Red, Green, Green, Blue
- "Rnn",
- "Roi",
- "Romm", // acronym: Reference Output Medium Metric
- "Rpa",
- "Rpn", // acronym
- "Rsa", // Rivest, Shamir and Adleman
- "Rsqrt", // reciprocal square root
- "Rssi",
- "Rtp",
- "Rtl",
- "Rtsp",
- "Saml", // acronym
- "Sdof",
- "Scn",
- "Sdk",
- "Sdtv", // acronym: Standard Definition Tele Vision
- "Sdnn",
- "Seekable",
- "Selu", // Scaled Exponential Linear unit (ML)
- "Sgd", // Stochastic Gradient Descent (ML)
- "Shadable",
- "Sharegroup",
- "Sha", // Secure Hash Algorithm
- "Siemen",
- "simd",
- "Sinh",
- "Sint", // as in "Signed Integer"
- "Simd",
- "Slerp",
- "Slomo",
- "Smpte",
- "Snapshotter",
- "Snorm",
- "Sobel",
- "Softmax", // get_SoftmaxNormalization
- "Spacei",
- "Sqrt",
- "Srgb",
- "Ssid",
- "Ssids",
- "Standarize",
- "Stateful",
- "Stateright",
- "Subbeat",
- "Subcaption",
- "Subcardioid",
- "Subentities",
- "Subheadline",
- "Sublocality",
- "Sublocation",
- "Submesh",
- "Submeshes",
- "Subpixel",
- "Subresource",
- "Subresources",
- "Subsec",
- "Suica", // Japanese contactless smart card type
- "Superentity",
- "Supertype",
- "Supertypes",
- "Svg", // Scalable Vector Graphics
- "Sym",
- "Synchronizable",
- "Symbologies",
- "Tanh",
- "Tebibits",
- "Tebibytes",
- "Tensorflow",
- "Tessellator",
- "Texcoord",
- "Texel",
- "th",
- "Threadgroup",
- "Threadgroups",
- "Thumbnailing",
- "Thumbstick",
- "Thumbsticks",
- "Timecodes",
- "Timelapse",
- "Timelapses",
- "Tls",
- "Ttls",
- "Tlv",
- "Toc",
- "Toci",
- "Toi",
- "Transceive",
- "Trc",
- "Truncantion",
- "Tweening",
- "Twips",
- "tx",
- "ty",
- "Udi",
- "Udp",
- "Unconfigured",
- "Undecodable",
- "Unemphasized",
- "Underrun",
- "Unflagged",
- "Unfocusing",
- "Uid",
- "Unmap",
- "Unorm",
- "Unpremultiplied",
- "Unpremultiplying",
- "Unprepare",
- "Unproject",
- "Unpublish",
- "Uterance",
- "Unentitled",
- "Untrash",
- "Utf",
- "Upce",
- "Uri",
- "Usac", // Unified Speech and Audio Coding
- "Usd", // Universal Scene Description
- "Usdz", // USD zip
- "Uti",
- "Varispeed",
- "Vergence",
- "Voronoi",
- "Vnode",
- "Vpn",
- "Warichu",
- "Wep",
- "Wpa",
- "Warpable",
- "Whitespaces",
- "Wifes",
- "Writeability",
- "Xnor",
- "Xpc",
- "xy",
- "Xyz",
- "Xzy",
- "Yobibits",
- "Yobibytes",
- "Yottabits",
- "Yxz",
- "Yzx",
- "Zxy",
- "Zyx",
- "Yuv",
- "Yuvk",
- "yuvs",
- "yx",
- "yy",
- "Yyy",
- "Zebibits",
- "Zebibytes",
- "Zettabits",
- "Zlib",
-#if MONOMAC
- "Abbr",
- "Accum",
- "Ack", // TcpSetDisableAckStretching
- "Addin",
- "Addons",
- "Appactive",
- "Approx",
- "Arae",
- "Attr",
- "Attributesfor",
- "Autoresizin",
- "Avc",
- "Callpout",
- "Ccitt",
- "Commited",
- "Constrainted",
- "Ctm",
- "Cymk",
- "Cymka",
- "Cmyka",
- "Compat",
- "Credendtials",
- "Descriptorat",
- "Descriptorfor",
- "Dimensionsfor",
- "Dissapearing",
- "Distinguised", // ITLibPlaylistPropertyDistinguisedKind
- "Dirs",
- "Drm", // MediaItemProperty.IsDrmProtected
- "Editability",
- "Eisu",
- "Entryat",
- "Equiv",
- "Fourty",
- "Grammarl",
- "Greeking",
- "Hsb",
- "Hsba",
- "Ibss",
- "Iconfor",
- "Incrementor",
- "Indexeffective",
- "Indexestable",
- "Itemto",
- "Lowsrc",
- "Lpcm",
- "Lzw",
- "Mihret",
- "Mps",
- "Nonenumerated",
- "Nsevent",
- "Numberof",
- "Orginal",
- "Parms",
- "Pbm",
- "Pde",
- "Performwith",
- "Phy",
- "Pmgt",
- "Preceeding",
- "Preds",
- "Previewable",
- "Qtvr",
- "Rangewith",
- "Rangeswith",
- "Reassociation",
- "Rectfrom",
- "Registeration",
- "Segmentnew",
- "Semitransient",
- "Sixtyfour",
- "Sourcei",
- "Steppable",
- "Stringto",
- "Succesfully",
- "Supression",
- "Targetand",
- "Tkip",
- "Tsn",
- "Tunesi",
- "Twentyfour",
- "Uneditable",
- "Unfocus",
- "Unpublish",
- "Usec",
- "Usedby",
- "Viewwrite",
- "Wep",
- "Wlan",
- "Wme",
- "Writeln",
- "Xattr",
-#endif
+ Dictionary allowed = new Dictionary () {
+ { "Aac", All },
+ { "Abgr", All },
+ { "Accurracy", All },
+ { "Achivements", All },
+ { "Acos", All },
+ { "Acosh", All },
+ { "Activatable", All },
+ { "Addin", All },
+ { "Addl", All },
+ { "Addons", ApplePlatform.MacOSX },
+ { "Addr", All },
+ { "Adessive", All },
+ { "Adjustmentfor", All & ~ApplePlatform.MacOSX },
+ { "Afi", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Agc", All },
+ { "Ahap", ApplePlatform.MacOSX | ApplePlatform.MacCatalyst },
+ { "Aifc", All },
+ { "Aiff", All },
+ { "Aime", ApplePlatform.MacOSX },
+ { "Aio", ApplePlatform.MacOSX },
+ { "Alg", All }, // short for Algorithm
+ { "Aliasable", All },
+ { "Allative", All },
+ { "Amete", All },
+ { "Amr", All },
+ { "Ancs", All & ~ApplePlatform.MacOSX },
+ { "Ane", All },
+ { "Anglet", All },
+ { "Apac", All },
+ { "Apdu", All },
+ { "Apl", All & ~ApplePlatform.TVOS },
+ { "Apng", All }, // Animated Portable Network Graphics
+ { "Apns", All & ~ApplePlatform.TVOS },
+ { "Appactive", ApplePlatform.MacOSX },
+ { "Applei", All },
+ { "Aps", ApplePlatform.MacOSX },
+ { "Apv", ApplePlatform.MacOSX },
+ { "Arae", ApplePlatform.MacOSX },
+ { "Arcball", All },
+ { "Argb", All },
+ { "Arraycollation", All & ~ApplePlatform.MacOSX },
+ { "Asin", All },
+ { "Asinh", All },
+ { "Astc", All },
+ { "Aswas", ApplePlatform.MacOSX },
+ { "Atan", All },
+ { "Atanh", All },
+ { "Atm", All },
+ { "Atmos", All }, // Dolby Atmos
+ { "Atr", All },
+ { "Ats", All }, // App Transport Security
+ { "Atsc", All },
+ { "Attr", ApplePlatform.MacOSX },
+ { "Attrib", All },
+ { "Attributesfor", ApplePlatform.MacOSX },
+ { "Attributevalue", All },
+ { "Attrs", All }, // Attributes (used by Apple for keys)
+ { "Audiofile", All },
+ { "Audiograph", ApplePlatform.MacOSX },
+ { "Authenticatable", ApplePlatform.MacOSX },
+ { "Automapping", All },
+ { "Automatch", All },
+ { "Automounted", All },
+ { "Autoredirect", ApplePlatform.MacCatalyst | ApplePlatform.TVOS },
+ { "Autospace", ApplePlatform.MacOSX },
+ { "Autostarts", ApplePlatform.MacOSX },
+ { "Avb", All }, // acronym: Audio Video Bridging
+ { "Avci", All }, // file type
+ { "Avg", All },
+ { "Axept", All & ~ApplePlatform.TVOS },
+ { "Bancomat", All & ~ApplePlatform.TVOS },
+ { "Bary", All },
+ { "Ber", All },
+ { "Bggr", All }, // acronym for Blue, Green, Green, Red
+ { "Bgra", All }, // acrnym for Blue, Green, Red, Alpha
+ { "Bgrx", All },
+ { "Bim", All },
+ { "Bitangent", All },
+ { "Blinn", All },
+ { "Blit", All },
+ { "Blockmap", ApplePlatform.MacOSX },
+ { "Blockquote", ApplePlatform.MacOSX },
+ { "Brotli", All },
+ { "Bsd", ApplePlatform.MacOSX },
+ { "Bsln", All },
+ { "Bssid", All & ~ApplePlatform.TVOS },
+ { "Btle", ApplePlatform.MacOSX }, // Bluetooth Low Energy
+ { "Cabac", All },
+ { "Caf", All }, // acronym: Core Audio Format
+ { "Callables", All },
+ { "Callpout", ApplePlatform.MacOSX | ApplePlatform.MacCatalyst },
+ { "Cartes", All & ~ApplePlatform.TVOS }, // french
+ { "Catmull", All },
+ { "Cavlc", All },
+ { "Ccitt", ApplePlatform.MacOSX },
+ { "Cct", All },
+ { "Ccw", All },
+ { "Cda", All & ~ApplePlatform.TVOS }, // acronym: Clinical Document Architecture
+ { "Cdma", All },
+ { "Cdrom", ApplePlatform.MacOSX | ApplePlatform.MacCatalyst },
+ { "Cea", All },
+ { "Celp", All }, // MPEG4ObjectID
+ { "Celu", All }, // Continuously Differentiable Exponential Linear Unit (ML)
+ { "Cfa", All }, // acronym: Color Filter Array
+ { "Chacha", All },
+ { "Chapv", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Characterteristic", All },
+ { "Cholesky", All },
+ { "Chromaticities", All },
+ { "Chw", All },
+ { "Ciexyz", ApplePlatform.MacOSX },
+ { "Ciff", All },
+ { "Cinemagraph", ApplePlatform.TVOS },
+ { "Cinepak", All },
+ { "Cla", All },
+ { "Clearcoat", All },
+ { "Clockstamp", All },
+ { "Cmaf", All }, // Common Media Application Format (mpeg4)
+ { "Cmy", ApplePlatform.MacOSX }, // acronym: Cyan, magenta, yellow
+ { "Cmyk", All }, // acronym: Cyan, magenta, yellow and key
+ { "Cmyka", ApplePlatform.MacOSX },
+ { "Cnn", All }, // Convolutional Neural Network
+ { "Cns", ApplePlatform.MacOSX },
+ { "Codabar", All },
+ { "Commited", ApplePlatform.MacOSX },
+ { "Conecs", All & ~ApplePlatform.TVOS },
+ { "Constrainted", ApplePlatform.MacOSX },
+ { "Conv", All },
+ { "Copyback", All },
+ { "Cose", All & ~ApplePlatform.TVOS },
+ { "Crosstraining", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Csr", All },
+ { "Ctm", ApplePlatform.MacOSX },
+ { "Ctor", All },
+ { "Cubemap", All },
+ { "Cymk", ApplePlatform.MacOSX },
+ { "Cymka", ApplePlatform.MacOSX },
+ { "Daap", All },
+ { "Dangi", All },
+ { "Dankort", All & ~ApplePlatform.TVOS },
+ { "Dav", All & ~ApplePlatform.TVOS },
+ { "Dcip", All }, // acronym: Digital Cinema Implementation Partners
+ { "Deca", All & ~ApplePlatform.TVOS },
+ { "Decomposables", All },
+ { "Deinterlace", All },
+ { "Denimonator", All },
+ { "Denoise", All },
+ { "Denoised", All },
+ { "Depthwise", All },
+ { "Dequantize", All },
+ { "Descendents", All },
+ { "Descriptorat", ApplePlatform.MacOSX | ApplePlatform.MacCatalyst },
+ { "Descriptorfor", ApplePlatform.MacOSX | ApplePlatform.MacCatalyst },
+ { "Dfsi", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Dhe", All }, // Diffie–Hellman key exchange
+ { "Dhs", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Dhwio", All },
+ { "Dicom", All },
+ { "Diconnection", All },
+ { "Diffable", All }, // that you can diff it.. made up word from apple
+ { "Differental", All },
+ { "Diffie", All },
+ { "Dirbursement", All & ~ApplePlatform.TVOS },
+ { "Directionfor", All & ~ApplePlatform.MacOSX },
+ { "Dirs", ApplePlatform.MacOSX },
+ { "Dismissable", ApplePlatform.MacOSX },
+ { "Dissapearing", ApplePlatform.MacOSX },
+ { "Dist", All },
+ { "Distinguised", ApplePlatform.MacOSX }, // ITLibPlaylistPropertyDistinguisedKind
+ { "dlclose", All },
+ { "dlerror", All },
+ { "Dlfcn", All },
+ { "Dls", ApplePlatform.MacOSX },
+ { "Dng", All },
+ { "Dnssec", All },
+ { "Dont", All },
+ { "Dop", ApplePlatform.iOS },
+ { "Dopesheet", All },
+ { "Downmix", All }, // Sound terminology that means making a stereo mix from a 5.1 surround mix.
+ { "Dpa", All },
+ { "Dpad", All }, // Directional pad (D-pad)
+ { "Dpads", All }, // plural of above
+ { "Drm", ApplePlatform.MacOSX }, // MediaItemProperty.IsDrmProtected
+ { "Droste", All },
+ { "Dsf", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Dsfi", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Dstu", All & ~ApplePlatform.TVOS },
+ { "Dtls", All },
+ { "Dtmf", ApplePlatform.iOS | ApplePlatform.MacCatalyst }, // DTMF
+ { "Dtss", ApplePlatform.MacOSX },
+ { "dy", All },
+ { "Eap", All },
+ { "Ebu", All },
+ { "Ecc", All }, // Elliptic Curve Cryptography
+ { "Ecdh", All }, // Elliptic Curve Diffie–Hellman
+ { "Ecdhe", All }, // Elliptic Curve Diffie-Hellman Ephemeral
+ { "Ecdsa", All }, // Elliptic Curve Digital Signature Algorithm
+ { "Ecg", All & ~ApplePlatform.TVOS },
+ { "Ecies", All }, // Elliptic Curve Integrated Encryption Scheme
+ { "Ecn", All }, // Explicit Congestion Notification
+ { "Ect", All }, // ECN Capable Transport
+ { "Editability", All & ~ApplePlatform.MacOSX },
+ { "Edr", All },
+ { "Eftpos", All & ~ApplePlatform.TVOS }, // Electronic funds transfer at point of sale
+ { "Eisu", ApplePlatform.MacOSX },
+ { "Elative", All },
+ { "Elu", All },
+ { "Emagic", All },
+ { "Emaili", All & ~ApplePlatform.TVOS },
+ { "Embd", All },
+ { "Emebedding", All },
+ { "Emsg", ApplePlatform.MacOSX | ApplePlatform.MacCatalyst }, // 4cc
+ { "Enc", All },
+ { "Endc", All },
+ { "Eof", All }, // acronym End-Of-File
+ { "Eppc", All },
+ { "Epub", All },
+ { "Erf", All },
+ { "Essive", All },
+ { "Evdo", All },
+ { "Evictable", ApplePlatform.MacOSX | ApplePlatform.iOS },
+ { "Exabits", All },
+ { "Exbibits", All },
+ { "Exhange", All },
+ { "Expr", All },
+ { "Exr", All },
+ { "Extrinsics", All },
+ { "Feli", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Felica", All & ~ApplePlatform.TVOS }, // Japanese contactless RFID smart card system
+ { "Femtowatts", All },
+ { "Fft", All },
+ { "Fhir", All & ~ApplePlatform.TVOS },
+ { "Fieldset", All & ~ApplePlatform.MacCatalyst },
+ { "Flipside", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Formati", All },
+ { "Fourty", ApplePlatform.MacOSX },
+ { "Fov", All },
+ { "Fqdns", All },
+ { "Framebuffer", All },
+ { "Framesetter", All },
+ { "Freq", All },
+ { "Froms", ApplePlatform.MacOSX }, // NSMetadataItemWhereFromsKey
+ { "Ftps", All },
+ { "Gadu", All & ~ApplePlatform.TVOS },
+ { "Gainmap", All },
+ { "Gbrg", All }, // acronym for Green-Blue-Reg-Green
+ { "Gbtac", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Gbtdc", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Gcm", All },
+ { "Gelu", All }, // Gaussian Error Linear Unit (ML)
+ { "Gibibits", All },
+ { "Gid", ApplePlatform.MacOSX },
+ { "Gigapascals", All },
+ { "Girocard", All & ~ApplePlatform.TVOS },
+ { "Gles", ApplePlatform.iOS | ApplePlatform.TVOS },
+ { "Glorot", All }, // NN
+ { "Gop", All }, // acronym for Group Of Pictures
+ { "Gpp", All },
+ { "Gps", ApplePlatform.MacOSX | ApplePlatform.MacCatalyst },
+ { "Grammarl", ApplePlatform.MacOSX },
+ { "Grbg", All }, // acronym for Green-Red-Blue-Green
+ { "Greeking", ApplePlatform.MacOSX },
+ { "Groupless", All & ~ApplePlatform.TVOS },
+ { "Gru", All },
+ { "Gtin", All },
+ { "Gui", All },
+ { "Hardlink", ApplePlatform.MacOSX },
+ { "Hdmi", All & ~ApplePlatform.MacOSX },
+ { "Hdr", All },
+ { "Heic", All }, // file type
+ { "Heics", All }, // High Efficiency Image File Format (Sequence)
+ { "Heif", All }, // High Efficiency Image File Format
+ { "Hermitean", All },
+ { "Hevc", All }, // CMVideoCodecType / High Efficiency Video Coding
+ { "Hfp", All & ~ApplePlatform.MacOSX },
+ { "Hhr", All },
+ { "Himyan", All & ~ApplePlatform.TVOS },
+ { "Hindlegs", All },
+ { "Hipass", All },
+ { "Histogrammed", All & ~ApplePlatform.TVOS },
+ { "Hlg", All }, // Hybrid Log-Gamma
+ { "Hls", All },
+ { "Hoa", All },
+ { "Hpke", ApplePlatform.MacOSX },
+ { "Hrtf", All }, // acronym used in AUSpatializationAlgorithm
+ { "Hsb", ApplePlatform.MacOSX },
+ { "Hsba", ApplePlatform.MacOSX },
+ { "Hvxc", All }, // MPEG4ObjectID
+ { "Hwc", All },
+ { "Hwio", All },
+ { "Iap", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Ibss", ApplePlatform.MacOSX },
+ { "Icns", All },
+ { "Ico", All },
+ { "Iconfor", ApplePlatform.MacOSX },
+ { "Icq", All & ~ApplePlatform.TVOS },
+ { "Identd", All },
+ { "Iec", All },
+ { "Ies", All },
+ { "Imageblock", All },
+ { "Imagefor", All & ~ApplePlatform.MacOSX },
+ { "Imap", All },
+ { "Imaps", All },
+ { "Imei", All & ~ApplePlatform.MacOSX },
+ { "Img", All },
+ { "Impl", All }, // BindingImplAttribute
+ { "Incrementor", ApplePlatform.MacOSX },
+ { "Indoorcycle", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Indoorrun", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Indoorwalk", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Inessive", All },
+ { "Inklist", All },
+ { "Inode", ApplePlatform.MacOSX },
+ { "Inot", All },
+ { "Inser", All },
+ { "Instamatic", ApplePlatform.MacOSX },
+ { "Interac", All & ~ApplePlatform.TVOS },
+ { "Interactable", ApplePlatform.MacOSX },
+ { "Interframe", All },
+ { "Interitem", All },
+ { "Intermenstrual", All & ~ApplePlatform.TVOS },
+ { "Intoi", All & ~ApplePlatform.MacOSX },
+ { "Intravaginal", All & ~ApplePlatform.TVOS },
+ { "Inv", All },
+ { "Invitable", All },
+ { "Iou", All },
+ { "Ipa", All },
+ { "Ipp", All },
+ { "Iptc", All },
+ { "Ircs", All },
+ { "Isrc", All },
+ { "Itemto", ApplePlatform.MacOSX },
+ { "Itf", All },
+ { "Itt", All & ~ApplePlatform.TVOS },
+ { "Itu", All },
+ { "Itur", All }, // Itur_2020_Hlg
+ { "Jaywan", All & ~ApplePlatform.TVOS },
+ { "Jcb", All & ~ApplePlatform.TVOS }, // Japanese credit card company
+ { "Jfif", All },
+ { "Jis", ApplePlatform.MacOSX },
+ { "Jrts", All & ~ApplePlatform.TVOS },
+ { "Jwks", ApplePlatform.MacOSX },
+ { "Jws", All & ~ApplePlatform.TVOS },
+ { "Jwt", ApplePlatform.MacOSX },
+ { "Keepalive", All },
+ { "Keycode", ApplePlatform.MacOSX | ApplePlatform.MacCatalyst },
+ { "Keyerror", All },
+ { "Keyi", All },
+ { "Keypath", ApplePlatform.MacOSX },
+ { "Keypoint", All },
+ { "Keypoints", All },
+ { "Kibibits", All },
+ { "Kickboard", All & ~ApplePlatform.TVOS },
+ { "Kiloampere", All },
+ { "Kiloamperes", All },
+ { "Kiloohms", All },
+ { "Kilopascals", All },
+ { "ks", All },
+ { "Kullback", All }, // Kullback-Leibler Divergence
+ { "Lacunarity", All },
+ { "Langauges", All & ~ApplePlatform.MacOSX },
+ { "Latm", All }, // Low Overhead Audio Transport Multiplex
+ { "Lbc", All },
+ { "Ldaps", All },
+ { "Lerp", All },
+ { "libcompression", All },
+ { "libdispatch", All },
+ { "Lingustic", All },
+ { "Lod", All },
+ { "Lopass", All },
+ { "Lowlevel", All },
+ { "Lpcm", All },
+ { "Lstm", All },
+ { "Lte", All },
+ { "Ltr", All },
+ { "Lun", All },
+ { "Lut", All },
+ { "Lzfse", All }, // acronym
+ { "Lzma", All }, // acronym
+ { "Lzw", ApplePlatform.MacOSX },
+ { "Mada", All & ~ApplePlatform.TVOS }, // payment system
+ { "Matchingcoalesce", All },
+ { "Mcp", All }, // metacarpophalangeal (hand)
+ { "Mebibits", All },
+ { "Mebx", All },
+ { "Meeza", All & ~ApplePlatform.TVOS },
+ { "Megaampere", All },
+ { "Megaamperes", All },
+ { "Megaliters", All },
+ { "Megameters", All },
+ { "Megaohms", All },
+ { "Megapascals", All },
+ { "Mennekes", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Metacharacters", All },
+ { "Metadatas", All },
+ { "Metalness", All },
+ { "Mgmt", All },
+ { "Microampere", All },
+ { "Microamperes", All },
+ { "Microohms", All },
+ { "Microwatts", All },
+ { "Mifare", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Millimoles", All },
+ { "Milliohms", All },
+ { "Minification", All },
+ { "Mmw", All },
+ { "Mncs", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Mobike", All }, // acronym
+ { "Monoline", All & ~ApplePlatform.TVOS },
+ { "Morpher", All },
+ { "Mpe", All }, // acronym
+ { "Mps", All },
+ { "Msaa", All }, // multisample anti-aliasing
+ { "Msi", All },
+ { "Mtc", All }, // acronym
+ { "Mtgp", All },
+ { "Mtl", All },
+ { "Mtu", All }, // acronym
+ { "Muid", All & ~ApplePlatform.TVOS },
+ { "Mul", All },
+ { "Mult", All },
+ { "Multiary", All },
+ { "Multipath", All },
+ { "Multipeer", All },
+ { "Multiscript", All },
+ { "Multiselect", All & ~ApplePlatform.MacOSX },
+ { "Multivariant", All },
+ { "Multiview", All },
+ { "Muxed", All },
+ { "Nacs", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Nai", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Nanaco", All & ~ApplePlatform.TVOS },
+ { "Nand", All },
+ { "Nanograms", All },
+ { "Nanowatts", All },
+ { "Ncdhw", All },
+ { "Nchw", All },
+ { "nd", All },
+ { "Ndef", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Ndhwc", All },
+ { "Nesterov", All },
+ { "Nestrov", All },
+ { "Nfc", ApplePlatform.MacOSX | ApplePlatform.MacCatalyst },
+ { "Nfnt", All },
+ { "Nhwc", All },
+ { "Nntps", All },
+ { "Nonenumerated", ApplePlatform.MacOSX },
+ { "Noninteractive", All & ~ApplePlatform.TVOS },
+ { "Noop", All },
+ { "Nop", ApplePlatform.MacOSX },
+ { "Nsa", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Nsevent", ApplePlatform.MacOSX },
+ { "Nsl", ApplePlatform.MacOSX | ApplePlatform.MacCatalyst }, // InternetLocationNslNeighborhoodIcon
+ { "Ntlm", All },
+ { "Ntsc", All },
+ { "Numberof", ApplePlatform.MacOSX },
+ { "Nyquist", All & ~ApplePlatform.MacOSX },
+ { "Objectness", All },
+ { "Occlussion", All },
+ { "Ocr", All },
+ { "Ocsp", All }, // Online Certificate Status Protocol
+ { "Octree", All },
+ { "Ocurrences", All },
+ { "Odia", All },
+ { "Ohwi", All },
+ { "Oid", All },
+ { "Oidhw", All },
+ { "Oihw", All },
+ { "Onnx", All },
+ { "Oper", All & ~ApplePlatform.MacOSX },
+ { "Organisation", All }, // kCGImagePropertyIPTCExtRegistryOrganisationID in Xcode9.3-b1
+ { "Orth", All },
+ { "Osa", All }, // Open Scripting Architecture
+ { "Otsu", All }, // threshold for image binarization
+ { "ove", All },
+ { "Overline", All & ~ApplePlatform.TVOS },
+ { "Paeth", All }, // PNG filter
+ { "Palettize", All },
+ { "Parms", All },
+ { "Pausable", All },
+ { "Pbm", ApplePlatform.MacOSX },
+ { "Pci", All & ~ApplePlatform.MacOSX },
+ { "Pcl", All },
+ { "Pcm", All },
+ { "Pde", ApplePlatform.MacOSX },
+ { "Pdu", All },
+ { "Peap", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Pebibits", All },
+ { "Performwith", ApplePlatform.MacOSX },
+ { "Perlin", All },
+ { "Persistable", All },
+ { "Persistance", All },
+ { "Petabits", All },
+ { "Pfs", All }, // acronym
+ { "Philox", All },
+ { "Photoplethysmogram", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Phq", All & ~ApplePlatform.TVOS },
+ { "Phy", ApplePlatform.MacOSX },
+ { "Picometers", All },
+ { "Picowatts", All },
+ { "Pkcs", All },
+ { "Placemark", All },
+ { "Playout", All },
+ { "Pnc", All }, // MIDI
+ { "Pnorm", All },
+ { "Polyline", All },
+ { "Polylines", All },
+ { "Popularimeter", All },
+ { "Postback", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Ppk", All },
+ { "Preauthentication", ApplePlatform.MacOSX },
+ { "Preds", All },
+ { "Prefilter", All },
+ { "Prereleased", All },
+ { "Prerolls", All },
+ { "Preseti", All },
+ { "Previewable", ApplePlatform.MacOSX },
+ { "Prf", All & ~ApplePlatform.TVOS },
+ { "Propogate", All },
+ { "Psec", All },
+ { "Psk", All },
+ { "Pskc", All & ~ApplePlatform.TVOS },
+ { "Psm", All }, // Protocol/Service Multiplexer
+ { "Ptp", ApplePlatform.MacOSX },
+ { "Pvr", All },
+ { "Pvrtc", All }, // MTLBlitOption - PowerVR Texture Compression
+ { "Qos", All },
+ { "Quadding", All },
+ { "Quaterniond", All },
+ { "Quic", All },
+ { "Qura", All },
+ { "Qwac", All },
+ { "Raycast", ApplePlatform.iOS },
+ { "Raycasts", ApplePlatform.iOS },
+ { "Reacquirer", All },
+ { "Reassociation", ApplePlatform.MacOSX },
+ { "Reauthentication", ApplePlatform.MacOSX },
+ { "Rectfrom", ApplePlatform.MacOSX },
+ { "Registeration", ApplePlatform.MacOSX },
+ { "Reinvitation", All },
+ { "Reinvite", All },
+ { "Rel", All },
+ { "Relocalization", ApplePlatform.iOS },
+ { "Relu", All }, // Rectified Linear Unit (ML)
+ { "Remmote", All },
+ { "Replayable", All },
+ { "Reprojection", All },
+ { "Rgb", All },
+ { "Rgba", All },
+ { "Rgbaf", All },
+ { "Rgbah", All },
+ { "Rgbx", All },
+ { "Rggb", All }, // acronym for Red, Green, Green, Blue
+ { "Rint", All },
+ { "Rle", All },
+ { "Rnn", All },
+ { "Roi", All },
+ { "Romm", All }, // acronym: Reference Output Medium Metric
+ { "Rpa", All },
+ { "Rpn", All }, // acronym
+ { "Rsa", All }, // Rivest, Shamir and Adleman
+ { "Rsapss", All },
+ { "Rsqrt", All }, // reciprocal square root
+ { "Rssi", All },
+ { "Rtl", All },
+ { "Rtp", All & ~ApplePlatform.MacOSX },
+ { "Rtsp", All },
+ { "Saml", All & ~ApplePlatform.MacCatalyst }, // acronym
+ { "Scc", All },
+ { "Scn", All },
+ { "Sdh", ApplePlatform.TVOS },
+ { "Sdk", ApplePlatform.MacOSX | ApplePlatform.MacCatalyst },
+ { "Sdnn", All & ~ApplePlatform.TVOS },
+ { "Sdof", ApplePlatform.MacOSX },
+ { "Sdr", All },
+ { "Sdtv", ApplePlatform.TVOS }, // acronym: Standard Definition Tele Vision
+ { "Securit", ApplePlatform.iOS },
+ { "Seekable", All },
+ { "Sel", All & ~ApplePlatform.MacOSX },
+ { "Selu", All }, // Scaled Exponential Linear unit (ML)
+ { "Semitransient", ApplePlatform.MacOSX },
+ { "Sensel", All },
+ { "Shadable", All },
+ { "Siemen", All & ~ApplePlatform.TVOS },
+ { "Signbit", All },
+ { "Sint", All }, // as in "Signed Integer"
+ { "Sixtyfour", ApplePlatform.MacOSX },
+ { "Slerp", All },
+ { "Slomo", All },
+ { "Smpte", All },
+ { "Snapshotter", All },
+ { "Snn", All },
+ { "Snorm", All },
+ { "Sobel", All },
+ { "Softmax", All }, // get_SoftmaxNormalization
+ { "Sopen", ApplePlatform.MacOSX },
+ { "Spacei", All },
+ { "Spl", All },
+ { "Sqrt", All },
+ { "Srgb", All },
+ { "Ssid", All },
+ { "Ssids", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Ssml", All },
+ { "Sso", ApplePlatform.MacOSX },
+ { "st", All },
+ { "Sta", ApplePlatform.MacOSX },
+ { "Standarize", All },
+ { "Strided", All },
+ { "Subband", All & ~ApplePlatform.TVOS },
+ { "Subbeat", All },
+ { "Subcaption", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Subcardioid", All & ~ApplePlatform.MacOSX },
+ { "Subentities", All },
+ { "Subfilter", All & ~ApplePlatform.TVOS },
+ { "Subfilters", All & ~ApplePlatform.TVOS },
+ { "Subheadline", All },
+ { "Sublocality", All },
+ { "Sublocation", All },
+ { "Submesh", All },
+ { "Submeshes", All },
+ { "Subpixel", All },
+ { "Subresources", All },
+ { "Subsec", All },
+ { "Suica", All & ~ApplePlatform.TVOS }, // Japanese contactless smart card type
+ { "Superentity", All },
+ { "Supertype", All },
+ { "Supertypes", All },
+ { "Supression", ApplePlatform.MacOSX | ApplePlatform.MacCatalyst },
+ { "Svfg", All },
+ { "Svg", All }, // Scalable Vector Graphics
+ { "Svgf", All },
+ { "Swolf", All & ~ApplePlatform.TVOS },
+ { "Sysex", All },
+ { "Targetand", ApplePlatform.MacOSX },
+ { "Tbgr", All },
+ { "Tdoa", ApplePlatform.iOS },
+ { "Tebibits", All },
+ { "Tensorflow", All },
+ { "Tessellator", All },
+ { "Texcoord", All },
+ { "Texel", All },
+ { "Tga", All },
+ { "th", All },
+ { "Threadgroup", All },
+ { "Threadgroups", All },
+ { "Thumbnailing", All & ~ApplePlatform.TVOS },
+ { "Thumbstick", All },
+ { "Thumbsticks", ApplePlatform.iOS },
+ { "Timecodes", All & ~ApplePlatform.TVOS },
+ { "Tls", All },
+ { "Tlv", All },
+ { "Tmoney", All & ~ApplePlatform.TVOS },
+ { "Toc", All },
+ { "Toci", All },
+ { "Tonemap", All },
+ { "Transceive", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Trc", All },
+ { "Tri", All },
+ { "Ttls", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Tweening", All },
+ { "Twentyfour", ApplePlatform.MacOSX },
+ { "Twips", ApplePlatform.MacOSX },
+ { "tx", All },
+ { "ty", All },
+ { "Udi", All & ~ApplePlatform.TVOS },
+ { "Udp", All },
+ { "Uid", All & ~ApplePlatform.TVOS },
+ { "Unconfigured", All & ~ApplePlatform.MacOSX },
+ { "Undecodable", All },
+ { "Underrun", All },
+ { "Unemphasized", ApplePlatform.MacOSX },
+ { "Unentitled", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Unfetched", All },
+ { "Unioning", All },
+ { "Unmap", All },
+ { "Unmatch", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Unorm", All },
+ { "Unpremultiplied", All },
+ { "Unpremultiplying", All },
+ { "Unprepare", All },
+ { "Unproject", All },
+ { "Unpublish", All },
+ { "Unsolo", All },
+ { "Unsynced", ApplePlatform.MacOSX | ApplePlatform.iOS },
+ { "Untrash", ApplePlatform.iOS },
+ { "Upce", All },
+ { "Upi", ApplePlatform.iOS },
+ { "Uri", ApplePlatform.MacOSX | ApplePlatform.MacCatalyst },
+ { "Usac", All }, // Unified Speech and Audio Coding
+ { "Usd", All }, // Universal Scene Description
+ { "Usdz", All }, // USD zip
+ { "Usec", ApplePlatform.MacOSX | ApplePlatform.MacCatalyst },
+ { "Ussd", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Uterance", All },
+ { "Utf", All },
+ { "Uti", All & ~ApplePlatform.TVOS },
+ { "Varispeed", All },
+ { "Vbr", All },
+ { "Vbv", All },
+ { "Vergence", All },
+ { "Vnode", All },
+ { "Voip", ApplePlatform.MacCatalyst },
+ { "Voronoi", All },
+ { "Vpn", All },
+ { "Vtt", All },
+ { "Waon", All & ~ApplePlatform.TVOS },
+ { "Warichu", All },
+ { "Warpable", All },
+ { "Wcdma", All },
+ { "Wep", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Wifes", All & ~ApplePlatform.TVOS },
+ { "Willl", All & ~ApplePlatform.TVOS },
+ { "Wlan", ApplePlatform.MacOSX | ApplePlatform.MacCatalyst },
+ { "Wpa", All & ~ApplePlatform.TVOS },
+ { "Writeability", All },
+ { "Xattr", ApplePlatform.MacOSX },
+ { "Xattrs", ApplePlatform.MacOSX },
+ { "Xbgr", All },
+ { "Xmp", All },
+ { "Xnor", All },
+ { "Xrgb", All },
+ { "xy", All },
+ { "Xyz", All },
+ { "Xzy", All },
+ { "Yobibits", All },
+ { "Yottabits", All },
+ { "Yuv", ApplePlatform.MacOSX },
+ { "Yuvk", ApplePlatform.MacOSX },
+ { "yuvs", All },
+ { "yx", All },
+ { "Yxz", All },
+ { "yy", All },
+ { "Yyy", All },
+ { "Yzx", All },
+ { "Zebibits", All },
+ { "Zenkaku", All & ~ApplePlatform.MacOSX },
+ { "Zettabits", All },
+ { "Zlib", All },
+ { "Zxy", All },
+ { "Zyx", All },
};
- // ease maintenance of the list
+ // tracks which allowed words were actually seen during TypoTest
HashSet used = new HashSet ();
bool SkipAllowed (string? typeName, string? methodName, string typo)
{
- if (allowed.Contains (typo)) {
+ if (allowed.TryGetValue (typo, out var platforms) && platforms.HasFlag (TestRuntime.CurrentPlatform)) {
used.Add (typo);
return true;
}
@@ -785,6 +870,14 @@ void AttributeTypo (Type t, ref int totalErrors)
[Test]
public virtual void TypoTest ()
{
+ AssertMatchingOSVersionAndSdkVersion ();
+
+ // that's slow and there's no value to run it on devices as the API names
+ // being verified won't change from the simulator
+ TestRuntime.AssertSimulatorOrDesktop ("Typos only detected on simulator/desktop");
+
+ using var checker = new SpellChecker ();
+
var types = Assembly.GetTypes ();
int totalErrors = 0;
foreach (Type t in types) {
@@ -793,7 +886,7 @@ public virtual void TypoTest ()
continue;
string txt = NameCleaner (t.Name);
- var typo = GetCachedTypo (txt);
+ var typo = GetCachedTypo (checker, txt);
if (typo.Length > 0) {
if (!Skip (t, typo)) {
ReportError ("Typo in TYPE: {0} - {1} ", t.Name, typo);
@@ -810,7 +903,7 @@ public virtual void TypoTest ()
continue;
txt = NameCleaner (f.Name);
- typo = GetCachedTypo (txt);
+ typo = GetCachedTypo (checker, txt);
if (typo.Length > 0) {
if (!Skip (f, typo)) {
ReportError ("Typo in FIELD name: {0} - {1}, Type: {2}", f.Name, typo, t.Name);
@@ -828,7 +921,7 @@ public virtual void TypoTest ()
continue;
txt = NameCleaner (m.Name);
- typo = GetCachedTypo (txt);
+ typo = GetCachedTypo (checker, txt);
if (typo.Length > 0) {
if (!Skip (m, typo)) {
ReportError ("Typo in METHOD name: {0} - {1}, Type: {2}", m.Name, typo, t.Name);
@@ -839,7 +932,7 @@ public virtual void TypoTest ()
var parameters = m.GetParameters ();
foreach (ParameterInfo p in parameters) {
txt = NameCleaner (p.Name);
- typo = GetCachedTypo (txt);
+ typo = GetCachedTypo (checker, txt);
if (typo.Length > 0) {
ReportError ("Typo in PARAMETER Name: {0} - {1}, Method: {2}, Type: {3}", p.Name, typo, m.Name, t.Name);
totalErrors++;
@@ -849,12 +942,15 @@ public virtual void TypoTest ()
}
}
}
-#if false
- // ease removal of unrequired values (but needs to be checked for every profile)
- var unused = allowed.Except (used);
- foreach (var typo in unused)
- Console.WriteLine ("Unused entry \"{0}\"", typo);
-#endif
+ // verify that all allowed words for the current platform are still needed
+ var currentPlatform = TestRuntime.CurrentPlatform;
+ var unused = allowed.Keys
+ .Where (w => allowed [w].HasFlag (currentPlatform))
+ .Except (used);
+ foreach (var typo in unused) {
+ ReportError ($"Unnecessary allowed typo \"{typo}\" is not present in any API name");
+ totalErrors++;
+ }
Assert.AreEqual (0, totalErrors, "Typos!");
}
@@ -926,13 +1022,25 @@ void AttributesMessageTypoRules (MemberInfo mi, string typeName, ref int totalEr
}
Dictionary cached_typoes = new Dictionary ();
- string GetCachedTypo (string txt)
+ string GetCachedTypo (SpellChecker checker, string txt)
{
if (!cached_typoes.TryGetValue (txt, out var rv))
- cached_typoes [txt] = rv = GetTypo (txt);
+ cached_typoes [txt] = rv = GetTypo (checker, txt);
return rv;
}
- public abstract string GetTypo (string txt);
+
+ string GetTypo (SpellChecker checker, string txt)
+ {
+ var checkRange = new NSRange (0, txt.Length);
+#if MONOMAC
+ var typoRange = checker.CheckSpelling (txt, 0, "en_US", false, 0, out var _);
+#else
+ var typoRange = checker.RangeOfMisspelledWordInString (txt, checkRange, checkRange.Location, false, "en_US");
+#endif
+ if (typoRange.Length == 0)
+ return String.Empty;
+ return txt.Substring ((int) typoRange.Location, (int) typoRange.Length);
+ }
static StringBuilder clean = new StringBuilder ();
diff --git a/tests/introspection/MacApiTypoTest.cs b/tests/introspection/MacApiTypoTest.cs
deleted file mode 100644
index d9fd73e0ab51..000000000000
--- a/tests/introspection/MacApiTypoTest.cs
+++ /dev/null
@@ -1,28 +0,0 @@
-
-using AppKit;
-
-namespace Introspection {
-
- [TestFixture]
- public class MacApiTypoTest : ApiTypoTest {
- NSSpellChecker? checker;
-
- public override void TypoTest ()
- {
- AssertMatchingOSVersionAndSdkVersion ();
- checker = new NSSpellChecker ();
-
- base.TypoTest ();
- }
-
- public override string GetTypo (string txt)
- {
- var checkRange = new NSRange (0, txt.Length);
- nint wordCount;
- var typoRange = checker!.CheckSpelling (txt, 0, "en_US", false, 0, out wordCount);
- if (typoRange.Length == 0)
- return String.Empty;
- return txt.Substring ((int) typoRange.Location, (int) typoRange.Length);
- }
- }
-}
diff --git a/tests/introspection/dotnet/shared.csproj b/tests/introspection/dotnet/shared.csproj
index 408680114472..b8310c48cbc6 100644
--- a/tests/introspection/dotnet/shared.csproj
+++ b/tests/introspection/dotnet/shared.csproj
@@ -34,7 +34,6 @@
-
MacMain.cs
@@ -54,7 +53,6 @@
-
diff --git a/tests/introspection/iOSApiTypoTest.cs b/tests/introspection/iOSApiTypoTest.cs
deleted file mode 100644
index 42dafda1624d..000000000000
--- a/tests/introspection/iOSApiTypoTest.cs
+++ /dev/null
@@ -1,34 +0,0 @@
-
-using UIKit;
-
-namespace Introspection {
-
- [TestFixture]
- public class iOSApiTypoTest : ApiTypoTest {
- UITextChecker checker = new UITextChecker ();
-
- public override string GetTypo (string txt)
- {
- var checkRange = new NSRange (0, txt.Length);
- var typoRange = checker.RangeOfMisspelledWordInString (txt, checkRange, checkRange.Location, false, "en_US");
- if (typoRange.Length == 0)
- return String.Empty;
- return txt.Substring ((int) typoRange.Location, (int) typoRange.Length);
- }
-
- public override void TypoTest ()
- {
- // the dictionary used by iOS varies with versions and
- // we don't want to maintain special cases for each version
- var sdk = new Version (Constants.SdkVersion);
- if (!UIDevice.CurrentDevice.CheckSystemVersion (sdk.Major, sdk.Minor))
- Assert.Ignore ("Typos only verified using the latest SDK");
-
- // that's slow and there's no value to run it on devices as the API names
- // being verified won't change from the simulator
- TestRuntime.AssertSimulatorOrDesktop ("Typos only detected on simulator");
-
- base.TypoTest ();
- }
- }
-}
From 34f8250d35b23ac43159722c4d5c7681a3f2b5eb Mon Sep 17 00:00:00 2001
From: "dotnet-maestro[bot]"
<42748379+dotnet-maestro[bot]@users.noreply.github.com>
Date: Tue, 12 May 2026 18:44:26 +0000
Subject: [PATCH 042/156] [main] Update dependencies from dotnet/macios
(#25370)
This pull request updates the following dependencies
## From https://github.com/dotnet/macios
- **Subscription**: [c0371266-dd6f-4959-822b-decc72d2d668](https://maestro.dot.net/subscriptions?search=c0371266-dd6f-4959-822b-decc72d2d668)
- **Build**: [20260507.6](https://dev.azure.com/devdiv/DevDiv/_build/results?buildId=14036531) ([313422](https://maestro.dot.net/channel/3884/github:dotnet:macios/build/313422))
- **Date Produced**: May 7, 2026 9:05:16 AM UTC
- **Commit**: [fde62395708fce0a6f65ec9df9656c4c6e1f9d2b](https://github.com/dotnet/macios/commit/fde62395708fce0a6f65ec9df9656c4c6e1f9d2b)
- **Branch**: [release/9.0.1xx](https://github.com/dotnet/macios/tree/release/9.0.1xx)
- **Dependency Updates**:
- From [26.4.9016 to 26.4.9017][1]
- Microsoft.iOS.Sdk.net9.0_26.4
- Microsoft.MacCatalyst.Sdk.net9.0_26.4
- Microsoft.macOS.Sdk.net9.0_26.4
- Microsoft.tvOS.Sdk.net9.0_26.4
[1]: https://github.com/dotnet/macios/compare/ceb40a14f5...fde6239570
---
NuGet.config | 2 +-
eng/Version.Details.props | 8 ++++----
eng/Version.Details.xml | 16 ++++++++--------
3 files changed, 13 insertions(+), 13 deletions(-)
diff --git a/NuGet.config b/NuGet.config
index e528f7299264..2a29638a04d1 100644
--- a/NuGet.config
+++ b/NuGet.config
@@ -12,7 +12,7 @@
-
+
diff --git a/eng/Version.Details.props b/eng/Version.Details.props
index 9db3ac6e2428..33ea6a861727 100644
--- a/eng/Version.Details.props
+++ b/eng/Version.Details.props
@@ -19,16 +19,16 @@ This file should be imported by eng/Versions.props
26.0.11017
18.5.9227
- 26.4.9016
+ 26.4.9017
26.0.11017
18.5.9227
- 26.4.9016
+ 26.4.9017
26.0.11017
15.5.9227
- 26.4.9016
+ 26.4.9017
26.0.11017
18.5.9227
- 26.4.9016
+ 26.4.9017
11.0.0-prerelease.26230.4
diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml
index 72646c0712a2..5eb61a033c7d 100644
--- a/eng/Version.Details.xml
+++ b/eng/Version.Details.xml
@@ -60,21 +60,21 @@
797d30720e5e629d23eb146935da94cb1b61047e
-
+
https://github.com/dotnet/macios
- ceb40a14f584bcd835da2051360df596f77d9dae
+ fde62395708fce0a6f65ec9df9656c4c6e1f9d2b
-
+
https://github.com/dotnet/macios
- ceb40a14f584bcd835da2051360df596f77d9dae
+ fde62395708fce0a6f65ec9df9656c4c6e1f9d2b
-
+
https://github.com/dotnet/macios
- ceb40a14f584bcd835da2051360df596f77d9dae
+ fde62395708fce0a6f65ec9df9656c4c6e1f9d2b
-
+
https://github.com/dotnet/macios
- ceb40a14f584bcd835da2051360df596f77d9dae
+ fde62395708fce0a6f65ec9df9656c4c6e1f9d2b
From b3e1f3c08fddeae400d8e2dc83ec21e0d068e038 Mon Sep 17 00:00:00 2001
From: "CSIGS@microsoft.com"
Date: Tue, 12 May 2026 15:29:07 -0700
Subject: [PATCH 043/156] LEGO: Pull request from
lego/hb_5df43909-4a19-4f55-bc3f-9ea8fccf3c82_20260509054811778 to main
(#25380)
LEGO: Pull request from lego/hb_5df43909-4a19-4f55-bc3f-9ea8fccf3c82_20260509054811778 to main with localized lcls
---
.../cs/macios/tools/mtouch/Errors.resx.lcl | 36 +++++++++++++++++++
.../ko/macios/tools/mtouch/Errors.resx.lcl | 36 +++++++++++++++++++
.../pl/macios/tools/mtouch/Errors.resx.lcl | 36 +++++++++++++++++++
.../tr/macios/tools/mtouch/Errors.resx.lcl | 36 +++++++++++++++++++
4 files changed, 144 insertions(+)
diff --git a/macios/Localize/loc/cs/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/cs/macios/tools/mtouch/Errors.resx.lcl
index 81e85ff7b213..93308563ebb8 100644
--- a/macios/Localize/loc/cs/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/cs/macios/tools/mtouch/Errors.resx.lcl
@@ -4501,6 +4501,42 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/ko/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/ko/macios/tools/mtouch/Errors.resx.lcl
index 88ca649db7d8..e1f509268f52 100644
--- a/macios/Localize/loc/ko/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/ko/macios/tools/mtouch/Errors.resx.lcl
@@ -4501,6 +4501,42 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/pl/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/pl/macios/tools/mtouch/Errors.resx.lcl
index ce7aec51d493..85a0c823e2ea 100644
--- a/macios/Localize/loc/pl/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/pl/macios/tools/mtouch/Errors.resx.lcl
@@ -4501,6 +4501,42 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/tr/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/tr/macios/tools/mtouch/Errors.resx.lcl
index 2aeda18d004b..a0735f829e81 100644
--- a/macios/Localize/loc/tr/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/tr/macios/tools/mtouch/Errors.resx.lcl
@@ -4501,6 +4501,42 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
From 0d303817c2ac4b06db031717cb96f15e39ee8db0 Mon Sep 17 00:00:00 2001
From: Alex Soto
Date: Tue, 12 May 2026 23:42:48 -0400
Subject: [PATCH 044/156] [macios-devtools] Bump devtools (#25402)
---
external/Xamarin.MacDev | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/external/Xamarin.MacDev b/external/Xamarin.MacDev
index 11fad7fe464a..95ec821da377 160000
--- a/external/Xamarin.MacDev
+++ b/external/Xamarin.MacDev
@@ -1 +1 @@
-Subproject commit 11fad7fe464a7de7dd809542e4bb352310236052
+Subproject commit 95ec821da377c2dda841eed4578250cf9469b4ad
From 6915c8c062e5678a8cf86e626636ed75063f26f8 Mon Sep 17 00:00:00 2001
From: VS MobileTools Engineering Service 2
Date: Wed, 13 May 2026 00:35:49 -0700
Subject: [PATCH 045/156] Localized file check-in by OneLocBuild Task: Build
definition ID 14411: Build ID 14077114 (#25406)
This is the pull request automatically created by the OneLocBuild task in the build process to check-in localized files generated based upon translation source files (.lcl files) handed-back from the downstream localization pipeline. If there are issues in translations, visit https://aka.ms/icxLocBug and log bugs for fixes. The OneLocBuild wiki is https://aka.ms/onelocbuild and the localization process in general is documented at https://aka.ms/AllAboutLoc.
---
.../tools/mtouch/TranslatedAssemblies/Errors.cs.resx | 12 ++++++++++++
.../tools/mtouch/TranslatedAssemblies/Errors.de.resx | 12 ++++++++++++
.../tools/mtouch/TranslatedAssemblies/Errors.es.resx | 12 ++++++++++++
.../tools/mtouch/TranslatedAssemblies/Errors.fr.resx | 12 ++++++++++++
.../tools/mtouch/TranslatedAssemblies/Errors.it.resx | 12 ++++++++++++
.../tools/mtouch/TranslatedAssemblies/Errors.ja.resx | 12 ++++++++++++
.../tools/mtouch/TranslatedAssemblies/Errors.ko.resx | 12 ++++++++++++
.../tools/mtouch/TranslatedAssemblies/Errors.pl.resx | 12 ++++++++++++
.../mtouch/TranslatedAssemblies/Errors.pt-BR.resx | 12 ++++++++++++
.../tools/mtouch/TranslatedAssemblies/Errors.ru.resx | 12 ++++++++++++
.../tools/mtouch/TranslatedAssemblies/Errors.tr.resx | 12 ++++++++++++
.../mtouch/TranslatedAssemblies/Errors.zh-Hans.resx | 12 ++++++++++++
.../mtouch/TranslatedAssemblies/Errors.zh-Hant.resx | 12 ++++++++++++
13 files changed, 156 insertions(+)
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.cs.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.cs.resx
index 373de125892d..3cbbaf109f2a 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.cs.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.cs.resx
@@ -845,6 +845,18 @@
Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+ '{0}' is marked with a malformed simulator availability attribute: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' is marked with a simulator availability attribute with an invalid version: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has conflicting simulator availability attributes for the '{1}' platform (both SupportedSimulator and UnsupportedSimulator). Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has multiple SupportedSimulator attributes for the '{1}' platform. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.de.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.de.resx
index 373de125892d..3cbbaf109f2a 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.de.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.de.resx
@@ -845,6 +845,18 @@
Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+ '{0}' is marked with a malformed simulator availability attribute: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' is marked with a simulator availability attribute with an invalid version: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has conflicting simulator availability attributes for the '{1}' platform (both SupportedSimulator and UnsupportedSimulator). Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has multiple SupportedSimulator attributes for the '{1}' platform. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.es.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.es.resx
index 373de125892d..3cbbaf109f2a 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.es.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.es.resx
@@ -845,6 +845,18 @@
Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+ '{0}' is marked with a malformed simulator availability attribute: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' is marked with a simulator availability attribute with an invalid version: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has conflicting simulator availability attributes for the '{1}' platform (both SupportedSimulator and UnsupportedSimulator). Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has multiple SupportedSimulator attributes for the '{1}' platform. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.fr.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.fr.resx
index 373de125892d..3cbbaf109f2a 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.fr.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.fr.resx
@@ -845,6 +845,18 @@
Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+ '{0}' is marked with a malformed simulator availability attribute: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' is marked with a simulator availability attribute with an invalid version: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has conflicting simulator availability attributes for the '{1}' platform (both SupportedSimulator and UnsupportedSimulator). Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has multiple SupportedSimulator attributes for the '{1}' platform. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.it.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.it.resx
index 373de125892d..3cbbaf109f2a 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.it.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.it.resx
@@ -845,6 +845,18 @@
Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+ '{0}' is marked with a malformed simulator availability attribute: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' is marked with a simulator availability attribute with an invalid version: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has conflicting simulator availability attributes for the '{1}' platform (both SupportedSimulator and UnsupportedSimulator). Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has multiple SupportedSimulator attributes for the '{1}' platform. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.ja.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.ja.resx
index 373de125892d..3cbbaf109f2a 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.ja.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.ja.resx
@@ -845,6 +845,18 @@
Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+ '{0}' is marked with a malformed simulator availability attribute: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' is marked with a simulator availability attribute with an invalid version: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has conflicting simulator availability attributes for the '{1}' platform (both SupportedSimulator and UnsupportedSimulator). Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has multiple SupportedSimulator attributes for the '{1}' platform. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.ko.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.ko.resx
index 373de125892d..3cbbaf109f2a 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.ko.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.ko.resx
@@ -845,6 +845,18 @@
Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+ '{0}' is marked with a malformed simulator availability attribute: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' is marked with a simulator availability attribute with an invalid version: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has conflicting simulator availability attributes for the '{1}' platform (both SupportedSimulator and UnsupportedSimulator). Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has multiple SupportedSimulator attributes for the '{1}' platform. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.pl.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.pl.resx
index 373de125892d..3cbbaf109f2a 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.pl.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.pl.resx
@@ -845,6 +845,18 @@
Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+ '{0}' is marked with a malformed simulator availability attribute: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' is marked with a simulator availability attribute with an invalid version: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has conflicting simulator availability attributes for the '{1}' platform (both SupportedSimulator and UnsupportedSimulator). Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has multiple SupportedSimulator attributes for the '{1}' platform. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.pt-BR.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.pt-BR.resx
index 373de125892d..3cbbaf109f2a 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.pt-BR.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.pt-BR.resx
@@ -845,6 +845,18 @@
Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+ '{0}' is marked with a malformed simulator availability attribute: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' is marked with a simulator availability attribute with an invalid version: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has conflicting simulator availability attributes for the '{1}' platform (both SupportedSimulator and UnsupportedSimulator). Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has multiple SupportedSimulator attributes for the '{1}' platform. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.ru.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.ru.resx
index 373de125892d..3cbbaf109f2a 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.ru.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.ru.resx
@@ -845,6 +845,18 @@
Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+ '{0}' is marked with a malformed simulator availability attribute: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' is marked with a simulator availability attribute with an invalid version: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has conflicting simulator availability attributes for the '{1}' platform (both SupportedSimulator and UnsupportedSimulator). Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has multiple SupportedSimulator attributes for the '{1}' platform. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.tr.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.tr.resx
index 373de125892d..3cbbaf109f2a 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.tr.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.tr.resx
@@ -845,6 +845,18 @@
Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+ '{0}' is marked with a malformed simulator availability attribute: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' is marked with a simulator availability attribute with an invalid version: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has conflicting simulator availability attributes for the '{1}' platform (both SupportedSimulator and UnsupportedSimulator). Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has multiple SupportedSimulator attributes for the '{1}' platform. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.zh-Hans.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.zh-Hans.resx
index 373de125892d..3cbbaf109f2a 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.zh-Hans.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.zh-Hans.resx
@@ -845,6 +845,18 @@
Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+ '{0}' is marked with a malformed simulator availability attribute: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' is marked with a simulator availability attribute with an invalid version: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has conflicting simulator availability attributes for the '{1}' platform (both SupportedSimulator and UnsupportedSimulator). Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has multiple SupportedSimulator attributes for the '{1}' platform. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
diff --git a/macios/tools/mtouch/TranslatedAssemblies/Errors.zh-Hant.resx b/macios/tools/mtouch/TranslatedAssemblies/Errors.zh-Hant.resx
index 373de125892d..3cbbaf109f2a 100644
--- a/macios/tools/mtouch/TranslatedAssemblies/Errors.zh-Hant.resx
+++ b/macios/tools/mtouch/TranslatedAssemblies/Errors.zh-Hant.resx
@@ -845,6 +845,18 @@
Unknown IL sequence for method with call to Dlfcn.CachePointer: '{0}' in method '{1}'. The call will not be inlined. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+ '{0}' is marked with a malformed simulator availability attribute: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' is marked with a simulator availability attribute with an invalid version: {1}. Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has conflicting simulator availability attributes for the '{1}' platform (both SupportedSimulator and UnsupportedSimulator). Please file an issue at https://github.com/dotnet/macios/issues/new
+
+
+ '{0}' has multiple SupportedSimulator attributes for the '{1}' platform. Please file an issue at https://github.com/dotnet/macios/issues/new
+
The linker step '{0}' failed during processing: {1}
From 55b19c2bb6cb9968353c9b415f9f304b171c8682 Mon Sep 17 00:00:00 2001
From: Copilot <198982749+Copilot@users.noreply.github.com>
Date: Wed, 13 May 2026 08:19:19 -0400
Subject: [PATCH 046/156] [aw] Harden Code Radiator safe-outputs for scheduled
runs (#25371)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Code Radiator failed on `main` scheduled execution because safe outputs
assumed PR-trigger context and rejected dynamic base overrides. This updates
workflow constraints so scheduled runs can safely update existing merge PRs
and create new ones across target branches.
- **Safe output policy updates**
- Enabled per-run PR base override for expected branch families:
- `safe-outputs.create-pull-request.allowed-base-branches: ["net*.0", "xcode*"]`
- Switched PR-branch push targeting from implicit triggering PR to explicit any-PR mode:
- `safe-outputs.push-to-pull-request-branch.target: "*"`
- Added push guardrail to restrict eligible PRs:
- `safe-outputs.push-to-pull-request-branch.title-prefix: "🤖 Merge 'main' => '"`
- **Checkout behavior aligned to safe-output targeting**
- Added wildcard ref fetch config required for `target: "*"` PR-branch pushes:
- `checkout.fetch: ["*"]`
- `checkout.fetch-depth: 0`
- **Compiled workflow artifact refresh**
- Regenerated `.github/workflows/code-radiator.lock.yml` from updated source workflow frontmatter.
```yaml
checkout:
fetch: ["*"]
fetch-depth: 0
safe-outputs:
create-pull-request:
max: 10
allowed-base-branches:
- "net*.0"
- "xcode*"
push-to-pull-request-branch:
max: 10
target: "*"
title-prefix: "🤖 Merge 'main' => '"
```
---------
Co-authored-by: Rolf Bjarne Kvinge
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
.github/agents/agentic-workflows.agent.md | 26 ++---
.github/aw/actions-lock.json | 41 ++++++-
.github/workflows/code-radiator.lock.yml | 127 ++++++++++++++-------
.github/workflows/code-radiator.md | 8 ++
.github/workflows/copilot-setup-steps.yml | 4 +-
.github/workflows/macios-reviewer.lock.yml | 61 ++++++----
6 files changed, 182 insertions(+), 85 deletions(-)
diff --git a/.github/agents/agentic-workflows.agent.md b/.github/agents/agentic-workflows.agent.md
index b6e648cbda58..cd376c5b1b30 100644
--- a/.github/agents/agentic-workflows.agent.md
+++ b/.github/agents/agentic-workflows.agent.md
@@ -31,7 +31,7 @@ Workflows may optionally include:
- Workflow files: `.github/workflows/*.md` and `.github/workflows/**/*.md`
- Workflow lock files: `.github/workflows/*.lock.yml`
- Shared components: `.github/workflows/shared/*.md`
-- Configuration: https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/github-agentic-workflows.md
+- Configuration: https://github.com/github/gh-aw/blob/v0.72.1/.github/aw/github-agentic-workflows.md
## Problems This Solves
@@ -53,7 +53,7 @@ When you interact with this agent, it will:
### Create New Workflow
**Load when**: User wants to create a new workflow from scratch, add automation, or design a workflow that doesn't exist yet
-**Prompt file**: https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/create-agentic-workflow.md
+**Prompt file**: https://github.com/github/gh-aw/blob/v0.72.1/.github/aw/create-agentic-workflow.md
**Use cases**:
- "Create a workflow that triages issues"
@@ -63,7 +63,7 @@ When you interact with this agent, it will:
### Update Existing Workflow
**Load when**: User wants to modify, improve, or refactor an existing workflow
-**Prompt file**: https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/update-agentic-workflow.md
+**Prompt file**: https://github.com/github/gh-aw/blob/v0.72.1/.github/aw/update-agentic-workflow.md
**Use cases**:
- "Add web-fetch tool to the issue-classifier workflow"
@@ -73,7 +73,7 @@ When you interact with this agent, it will:
### Debug Workflow
**Load when**: User needs to investigate, audit, debug, or understand a workflow, troubleshoot issues, analyze logs, or fix errors
-**Prompt file**: https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/debug-agentic-workflow.md
+**Prompt file**: https://github.com/github/gh-aw/blob/v0.72.1/.github/aw/debug-agentic-workflow.md
**Use cases**:
- "Why is this workflow failing?"
@@ -83,7 +83,7 @@ When you interact with this agent, it will:
### Upgrade Agentic Workflows
**Load when**: User wants to upgrade workflows to a new gh-aw version or fix deprecations
-**Prompt file**: https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/upgrade-agentic-workflows.md
+**Prompt file**: https://github.com/github/gh-aw/blob/v0.72.1/.github/aw/upgrade-agentic-workflows.md
**Use cases**:
- "Upgrade all workflows to the latest version"
@@ -93,7 +93,7 @@ When you interact with this agent, it will:
### Create a Report-Generating Workflow
**Load when**: The workflow being created or updated produces reports — recurring status updates, audit summaries, analyses, or any structured output posted as a GitHub issue, discussion, or comment
-**Prompt file**: https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/report.md
+**Prompt file**: https://github.com/github/gh-aw/blob/v0.72.1/.github/aw/report.md
**Use cases**:
- "Create a weekly CI health report"
@@ -103,7 +103,7 @@ When you interact with this agent, it will:
### Create Shared Agentic Workflow
**Load when**: User wants to create a reusable workflow component or wrap an MCP server
-**Prompt file**: https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/create-shared-agentic-workflow.md
+**Prompt file**: https://github.com/github/gh-aw/blob/v0.72.1/.github/aw/create-shared-agentic-workflow.md
**Use cases**:
- "Create a shared component for Notion integration"
@@ -113,7 +113,7 @@ When you interact with this agent, it will:
### Fix Dependabot PRs
**Load when**: User needs to close or fix open Dependabot PRs that update dependencies in generated manifest files (`.github/workflows/package.json`, `.github/workflows/requirements.txt`, `.github/workflows/go.mod`)
-**Prompt file**: https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/dependabot.md
+**Prompt file**: https://github.com/github/gh-aw/blob/v0.72.1/.github/aw/dependabot.md
**Use cases**:
- "Fix the open Dependabot PRs for npm dependencies"
@@ -123,7 +123,7 @@ When you interact with this agent, it will:
### Analyze Test Coverage
**Load when**: The workflow reads, analyzes, or reports test coverage — whether triggered by a PR, a schedule, or a slash command. Always consult this prompt before designing the coverage data strategy.
-**Prompt file**: https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/test-coverage.md
+**Prompt file**: https://github.com/github/gh-aw/blob/v0.72.1/.github/aw/test-coverage.md
**Use cases**:
- "Create a workflow that comments coverage on PRs"
@@ -133,7 +133,7 @@ When you interact with this agent, it will:
### CLI Commands Reference
**Load when**: The user asks how to run, compile, debug, or manage workflows from the command line; needs the MCP tool equivalent of a `gh aw` command; or is in a restricted environment (e.g., Copilot Cloud) without direct CLI access.
-**Reference file**: https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/cli-commands.md
+**Reference file**: https://github.com/github/gh-aw/blob/v0.72.1/.github/aw/cli-commands.md
**Use cases**:
- "How do I trigger workflow X on the main branch?"
@@ -185,12 +185,12 @@ gh aw compile --validate
## Important Notes
-- Always reference the instructions file at https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/github-agentic-workflows.md for complete documentation
+- Always reference the instructions file at https://github.com/github/gh-aw/blob/v0.72.1/.github/aw/github-agentic-workflows.md for complete documentation
- Use the MCP tool `agentic-workflows` when running in GitHub Copilot Cloud
- Workflows must be compiled to `.lock.yml` files before running in GitHub Actions
- **Bash tools are enabled by default** - Don't restrict bash commands unnecessarily since workflows are sandboxed by the AWF
- Follow security best practices: minimal permissions, explicit network access, no template injection
-- **Network configuration**: Use ecosystem identifiers (`node`, `python`, `go`, etc.) or explicit FQDNs in `network.allowed`. Bare shorthands like `npm` or `pypi` are **not** valid. See https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/network.md for the full list of valid ecosystem identifiers and domain patterns.
+- **Network configuration**: Use ecosystem identifiers (`node`, `python`, `go`, etc.) or explicit FQDNs in `network.allowed`. Bare shorthands like `npm` or `pypi` are **not** valid. See https://github.com/github/gh-aw/blob/v0.72.1/.github/aw/network.md for the full list of valid ecosystem identifiers and domain patterns.
- **Single-file output**: When creating a workflow, produce exactly **one** workflow `.md` file. Do not create separate documentation files (architecture docs, runbooks, usage guides, etc.). If documentation is needed, add a brief `## Usage` section inside the workflow file itself.
- **Triggering runs**: Always use `gh aw run ` to trigger a workflow on demand — not `gh workflow run .lock.yml`. `gh aw run` handles workflow resolution by short name, input parsing and validation, and correct run-tracking for agentic workflows. Use `--ref ` to run on a specific branch.
-- **CLI commands reference**: For a complete guide on all `gh aw` commands and their MCP tool equivalents (for restricted environments), see https://github.com/github/gh-aw/blob/v0.71.5/.github/aw/cli-commands.md
+- **CLI commands reference**: For a complete guide on all `gh aw` commands and their MCP tool equivalents (for restricted environments), see https://github.com/github/gh-aw/blob/v0.72.1/.github/aw/cli-commands.md
diff --git a/.github/aw/actions-lock.json b/.github/aw/actions-lock.json
index 79c34c44d3d7..4b30f2d3389b 100644
--- a/.github/aw/actions-lock.json
+++ b/.github/aw/actions-lock.json
@@ -1,17 +1,52 @@
{
"entries": {
+ "actions/checkout@v6.0.2": {
+ "repo": "actions/checkout",
+ "version": "v6.0.2",
+ "sha": "de0fac2e4500dabe0009e67214ff5f5447ce83dd"
+ },
+ "actions/download-artifact@v8.0.1": {
+ "repo": "actions/download-artifact",
+ "version": "v8.0.1",
+ "sha": "3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c"
+ },
"actions/github-script@v9.0.0": {
"repo": "actions/github-script",
"version": "v9.0.0",
"sha": "3a2844b7e9c422d3c10d287c895573f7108da1b3"
},
- "github/gh-aw-actions/setup@v0.71.5": {
+ "actions/setup-node@v6.4.0": {
+ "repo": "actions/setup-node",
+ "version": "v6.4.0",
+ "sha": "48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e"
+ },
+ "actions/upload-artifact@v7.0.1": {
+ "repo": "actions/upload-artifact",
+ "version": "v7.0.1",
+ "sha": "043fb46d1a93c77aae656e7c1c64a875d1fc6a0a"
+ },
+ "github/gh-aw-actions/setup@v0.72.1": {
"repo": "github/gh-aw-actions/setup",
- "version": "v0.71.5",
- "sha": "b8068426813005612b960b5ab0b8bd2c27142323"
+ "version": "v0.72.1",
+ "sha": "bc56a0cad2f450c562810785ef38649c04db812a"
}
},
"containers": {
+ "ghcr.io/github/gh-aw-firewall/agent:0.25.41": {
+ "image": "ghcr.io/github/gh-aw-firewall/agent:0.25.41",
+ "digest": "sha256:cb2b565d070116d4b67e355775340528b5a2c3cb18b2c9049638bcc2df681770",
+ "pinned_image": "ghcr.io/github/gh-aw-firewall/agent:0.25.41@sha256:cb2b565d070116d4b67e355775340528b5a2c3cb18b2c9049638bcc2df681770"
+ },
+ "ghcr.io/github/gh-aw-firewall/api-proxy:0.25.41": {
+ "image": "ghcr.io/github/gh-aw-firewall/api-proxy:0.25.41",
+ "digest": "sha256:fadd0de387209f69a9a7a1b8722bb5e7fdfb80ba9749a5c60f0e4cd7582a74d0",
+ "pinned_image": "ghcr.io/github/gh-aw-firewall/api-proxy:0.25.41@sha256:fadd0de387209f69a9a7a1b8722bb5e7fdfb80ba9749a5c60f0e4cd7582a74d0"
+ },
+ "ghcr.io/github/gh-aw-firewall/squid:0.25.41": {
+ "image": "ghcr.io/github/gh-aw-firewall/squid:0.25.41",
+ "digest": "sha256:1260445d25968dbf3ae70143964177a0e5914cf2ce07a6117f7d3caec6c3e3c4",
+ "pinned_image": "ghcr.io/github/gh-aw-firewall/squid:0.25.41@sha256:1260445d25968dbf3ae70143964177a0e5914cf2ce07a6117f7d3caec6c3e3c4"
+ },
"ghcr.io/github/gh-aw-mcpg:v0.3.0": {
"image": "ghcr.io/github/gh-aw-mcpg:v0.3.0",
"digest": "sha256:9c2228324fb1f26f39dc9471612e530ae3efc3156dac05efb2e8d212878d454d",
diff --git a/.github/workflows/code-radiator.lock.yml b/.github/workflows/code-radiator.lock.yml
index 584543578194..a9fbf6808f54 100644
--- a/.github/workflows/code-radiator.lock.yml
+++ b/.github/workflows/code-radiator.lock.yml
@@ -1,5 +1,5 @@
-# gh-aw-metadata: {"schema_version":"v3","frontmatter_hash":"bf2fb3e7253e90a94c5ce733787030d48f0b569363a045a86099dbafe6742dbf","compiler_version":"v0.71.5","strict":true,"agent_id":"copilot","agent_model":"claude-sonnet-4.5"}
-# gh-aw-manifest: {"version":1,"secrets":["COPILOT_GITHUB_TOKEN","GH_AW_CI_TRIGGER_TOKEN","GH_AW_GITHUB_MCP_SERVER_TOKEN","GH_AW_GITHUB_TOKEN","GITHUB_TOKEN"],"actions":[{"repo":"actions/checkout","sha":"de0fac2e4500dabe0009e67214ff5f5447ce83dd","version":"v6.0.2"},{"repo":"actions/download-artifact","sha":"3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c","version":"v8.0.1"},{"repo":"actions/github-script","sha":"3a2844b7e9c422d3c10d287c895573f7108da1b3","version":"v9.0.0"},{"repo":"actions/setup-node","sha":"48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e","version":"v6.4.0"},{"repo":"actions/upload-artifact","sha":"043fb46d1a93c77aae656e7c1c64a875d1fc6a0a","version":"v7.0.1"},{"repo":"github/gh-aw-actions/setup","sha":"b8068426813005612b960b5ab0b8bd2c27142323","version":"v0.71.5"}],"containers":[{"image":"ghcr.io/github/gh-aw-firewall/agent:0.25.40","digest":"sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504","pinned_image":"ghcr.io/github/gh-aw-firewall/agent:0.25.40@sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504"},{"image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40","digest":"sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280","pinned_image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40@sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280"},{"image":"ghcr.io/github/gh-aw-firewall/squid:0.25.40","digest":"sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51","pinned_image":"ghcr.io/github/gh-aw-firewall/squid:0.25.40@sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51"},{"image":"ghcr.io/github/gh-aw-mcpg:v0.3.6","digest":"sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c","pinned_image":"ghcr.io/github/gh-aw-mcpg:v0.3.6@sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c"},{"image":"ghcr.io/github/github-mcp-server:v1.0.3","digest":"sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959","pinned_image":"ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959"},{"image":"node:lts-alpine","digest":"sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f","pinned_image":"node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f"}]}
+# gh-aw-metadata: {"schema_version":"v3","frontmatter_hash":"d2239141a1fb75dd529ab1ac4919d3b325cce94b8ab3bb1f7f2dcb291481fd7d","compiler_version":"v0.72.1","strict":true,"agent_id":"copilot","agent_model":"claude-sonnet-4.5"}
+# gh-aw-manifest: {"version":1,"secrets":["COPILOT_GITHUB_TOKEN","GH_AW_CI_TRIGGER_TOKEN","GH_AW_GITHUB_MCP_SERVER_TOKEN","GH_AW_GITHUB_TOKEN","GITHUB_TOKEN"],"actions":[{"repo":"actions/checkout","sha":"de0fac2e4500dabe0009e67214ff5f5447ce83dd","version":"v6.0.2"},{"repo":"actions/download-artifact","sha":"3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c","version":"v8.0.1"},{"repo":"actions/github-script","sha":"3a2844b7e9c422d3c10d287c895573f7108da1b3","version":"v9.0.0"},{"repo":"actions/setup-node","sha":"48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e","version":"v6.4.0"},{"repo":"actions/upload-artifact","sha":"043fb46d1a93c77aae656e7c1c64a875d1fc6a0a","version":"v7.0.1"},{"repo":"github/gh-aw-actions/setup","sha":"bc56a0cad2f450c562810785ef38649c04db812a","version":"v0.72.1"}],"containers":[{"image":"ghcr.io/github/gh-aw-firewall/agent:0.25.41","digest":"sha256:cb2b565d070116d4b67e355775340528b5a2c3cb18b2c9049638bcc2df681770","pinned_image":"ghcr.io/github/gh-aw-firewall/agent:0.25.41@sha256:cb2b565d070116d4b67e355775340528b5a2c3cb18b2c9049638bcc2df681770"},{"image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.41","digest":"sha256:fadd0de387209f69a9a7a1b8722bb5e7fdfb80ba9749a5c60f0e4cd7582a74d0","pinned_image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.41@sha256:fadd0de387209f69a9a7a1b8722bb5e7fdfb80ba9749a5c60f0e4cd7582a74d0"},{"image":"ghcr.io/github/gh-aw-firewall/squid:0.25.41","digest":"sha256:1260445d25968dbf3ae70143964177a0e5914cf2ce07a6117f7d3caec6c3e3c4","pinned_image":"ghcr.io/github/gh-aw-firewall/squid:0.25.41@sha256:1260445d25968dbf3ae70143964177a0e5914cf2ce07a6117f7d3caec6c3e3c4"},{"image":"ghcr.io/github/gh-aw-mcpg:v0.3.6","digest":"sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c","pinned_image":"ghcr.io/github/gh-aw-mcpg:v0.3.6@sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c"},{"image":"ghcr.io/github/github-mcp-server:v1.0.3","digest":"sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959","pinned_image":"ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959"},{"image":"node:lts-alpine","digest":"sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f","pinned_image":"node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f"}]}
# ___ _ _
# / _ \ | | (_)
# | |_| | __ _ ___ _ __ | |_ _ ___
@@ -14,7 +14,7 @@
# \ /\ / (_) | | | | ( | | | | (_) \ V V /\__ \
# \/ \/ \___/|_| |_|\_\|_| |_|\___/ \_/\_/ |___/
#
-# This file was automatically generated by gh-aw (v0.71.5). DO NOT EDIT.
+# This file was automatically generated by gh-aw (v0.72.1). DO NOT EDIT.
#
# To update this file, edit the corresponding .md file and run:
# gh aw compile
@@ -36,12 +36,12 @@
# - actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
# - actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
# - actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
-# - github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+# - github/gh-aw-actions/setup@bc56a0cad2f450c562810785ef38649c04db812a # v0.72.1
#
# Container images used:
-# - ghcr.io/github/gh-aw-firewall/agent:0.25.40@sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504
-# - ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40@sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280
-# - ghcr.io/github/gh-aw-firewall/squid:0.25.40@sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51
+# - ghcr.io/github/gh-aw-firewall/agent:0.25.41@sha256:cb2b565d070116d4b67e355775340528b5a2c3cb18b2c9049638bcc2df681770
+# - ghcr.io/github/gh-aw-firewall/api-proxy:0.25.41@sha256:fadd0de387209f69a9a7a1b8722bb5e7fdfb80ba9749a5c60f0e4cd7582a74d0
+# - ghcr.io/github/gh-aw-firewall/squid:0.25.41@sha256:1260445d25968dbf3ae70143964177a0e5914cf2ce07a6117f7d3caec6c3e3c4
# - ghcr.io/github/gh-aw-mcpg:v0.3.6@sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c
# - ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959
# - node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f
@@ -89,7 +89,7 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+ uses: github/gh-aw-actions/setup@bc56a0cad2f450c562810785ef38649c04db812a # v0.72.1
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
@@ -105,14 +105,14 @@ jobs:
GH_AW_INFO_MODEL: "claude-sonnet-4.5"
GH_AW_INFO_VERSION: "1.0.40"
GH_AW_INFO_AGENT_VERSION: "1.0.40"
- GH_AW_INFO_CLI_VERSION: "v0.71.5"
+ GH_AW_INFO_CLI_VERSION: "v0.72.1"
GH_AW_INFO_WORKFLOW_NAME: "Code Radiator"
GH_AW_INFO_EXPERIMENTAL: "false"
GH_AW_INFO_SUPPORTS_TOOLS_ALLOWLIST: "true"
GH_AW_INFO_STAGED: "false"
GH_AW_INFO_ALLOWED_DOMAINS: '["defaults","github"]'
GH_AW_INFO_FIREWALL_ENABLED: "true"
- GH_AW_INFO_AWF_VERSION: "v0.25.40"
+ GH_AW_INFO_AWF_VERSION: "v0.25.41"
GH_AW_INFO_AWMG_VERSION: ""
GH_AW_INFO_FIREWALL_TYPE: "squid"
GH_AW_COMPILED_STRICT: "true"
@@ -164,7 +164,7 @@ jobs:
- name: Check compile-agentic version
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
- GH_AW_COMPILED_VERSION: "v0.71.5"
+ GH_AW_COMPILED_VERSION: "v0.72.1"
with:
script: |
const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
@@ -187,24 +187,24 @@ jobs:
run: |
bash "${RUNNER_TEMP}/gh-aw/actions/create_prompt_first.sh"
{
- cat << 'GH_AW_PROMPT_b4389f374632fbe1_EOF'
+ cat << 'GH_AW_PROMPT_3513a5223ca2e9d0_EOF'
- GH_AW_PROMPT_b4389f374632fbe1_EOF
+ GH_AW_PROMPT_3513a5223ca2e9d0_EOF
cat "${RUNNER_TEMP}/gh-aw/prompts/xpia.md"
cat "${RUNNER_TEMP}/gh-aw/prompts/temp_folder_prompt.md"
cat "${RUNNER_TEMP}/gh-aw/prompts/markdown.md"
cat "${RUNNER_TEMP}/gh-aw/prompts/safe_outputs_prompt.md"
- cat << 'GH_AW_PROMPT_b4389f374632fbe1_EOF'
+ cat << 'GH_AW_PROMPT_3513a5223ca2e9d0_EOF'
Tools: add_comment(max:10), create_pull_request(max:10), update_pull_request(max:10), add_labels(max:10), push_to_pull_request_branch(max:10), missing_tool, missing_data, noop
- GH_AW_PROMPT_b4389f374632fbe1_EOF
+ GH_AW_PROMPT_3513a5223ca2e9d0_EOF
cat "${RUNNER_TEMP}/gh-aw/prompts/safe_outputs_create_pull_request.md"
cat "${RUNNER_TEMP}/gh-aw/prompts/safe_outputs_push_to_pr_branch.md"
- cat << 'GH_AW_PROMPT_b4389f374632fbe1_EOF'
+ cat << 'GH_AW_PROMPT_3513a5223ca2e9d0_EOF'
- GH_AW_PROMPT_b4389f374632fbe1_EOF
+ GH_AW_PROMPT_3513a5223ca2e9d0_EOF
cat "${RUNNER_TEMP}/gh-aw/prompts/mcp_cli_tools_prompt.md"
- cat << 'GH_AW_PROMPT_b4389f374632fbe1_EOF'
+ cat << 'GH_AW_PROMPT_3513a5223ca2e9d0_EOF'
The following GitHub context information is available for this workflow:
{{#if __GH_AW_GITHUB_ACTOR__ }}
@@ -231,14 +231,17 @@ jobs:
{{#if __GH_AW_GITHUB_RUN_ID__ }}
- **workflow-run-id**: __GH_AW_GITHUB_RUN_ID__
{{/if}}
+ - **checkouts**: The following repositories have been checked out and are available in the workspace:
+ - `$GITHUB_WORKSPACE` → `__GH_AW_GITHUB_REPOSITORY__` (cwd) [full history, all branches available as remote-tracking refs] [additional refs fetched: *]
+ - **Note**: If a branch you need is not in the list above and is not listed as an additional fetched ref, it has NOT been checked out. For private repositories you cannot fetch it without proper authentication. If the branch is required and not available, exit with an error and ask the user to add it to the `fetch:` option of the `checkout:` configuration (e.g., `fetch: ["refs/pulls/open/*"]` for all open PR refs, or `fetch: ["main", "feature/my-branch"]` for specific branches).
- GH_AW_PROMPT_b4389f374632fbe1_EOF
+ GH_AW_PROMPT_3513a5223ca2e9d0_EOF
cat "${RUNNER_TEMP}/gh-aw/prompts/github_mcp_tools_with_safeoutputs_prompt.md"
- cat << 'GH_AW_PROMPT_b4389f374632fbe1_EOF'
+ cat << 'GH_AW_PROMPT_3513a5223ca2e9d0_EOF'
{{#runtime-import .github/workflows/code-radiator.md}}
- GH_AW_PROMPT_b4389f374632fbe1_EOF
+ GH_AW_PROMPT_3513a5223ca2e9d0_EOF
} > "$GH_AW_PROMPT"
- name: Interpolate variables and render templates
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
@@ -305,8 +308,11 @@ jobs:
path: |
/tmp/gh-aw/aw_info.json
/tmp/gh-aw/aw-prompts/prompt.txt
+ /tmp/gh-aw/aw-prompts/prompt-template.txt
+ /tmp/gh-aw/aw-prompts/prompt-import-tree.json
/tmp/gh-aw/github_rate_limits.jsonl
/tmp/gh-aw/base
+ /tmp/gh-aw/.github/agents
if-no-files-found: ignore
retention-days: 1
@@ -340,7 +346,7 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+ uses: github/gh-aw-actions/setup@bc56a0cad2f450c562810785ef38649c04db812a # v0.72.1
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
@@ -361,6 +367,13 @@ jobs:
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
+ fetch-depth: 0
+ - name: Fetch additional refs
+ env:
+ GH_AW_FETCH_TOKEN: ${{ secrets.GH_AW_GITHUB_MCP_SERVER_TOKEN || secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
+ run: |
+ header=$(printf "x-access-token:%s" "${GH_AW_FETCH_TOKEN}" | base64 -w 0)
+ git -c "http.extraheader=Authorization: Basic ${header}" fetch origin '+refs/heads/*:refs/remotes/origin/*'
- name: Create gh-aw temp directory
run: bash "${RUNNER_TEMP}/gh-aw/actions/create_gh_aw_tmp_dir.sh"
- name: Configure gh CLI for GitHub Enterprise
@@ -399,7 +412,7 @@ jobs:
env:
GH_HOST: github.com
- name: Install AWF binary
- run: bash "${RUNNER_TEMP}/gh-aw/actions/install_awf_binary.sh" v0.25.40
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/install_awf_binary.sh" v0.25.41
- name: Parse integrity filter lists
id: parse-guard-vars
env:
@@ -418,16 +431,21 @@ jobs:
GH_AW_AGENT_FOLDERS: ".agents .claude .codex .crush .gemini .github .opencode .pi"
GH_AW_AGENT_FILES: ".crush.json AGENTS.md CLAUDE.md GEMINI.md PI.md opencode.jsonc"
run: bash "${RUNNER_TEMP}/gh-aw/actions/restore_base_github_folders.sh"
+ - name: Restore inline sub-agents from activation artifact
+ env:
+ GH_AW_SUB_AGENT_DIR: ".github/agents"
+ GH_AW_SUB_AGENT_EXT: ".agent.md"
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/restore_inline_sub_agents.sh"
- name: Download container images
- run: bash "${RUNNER_TEMP}/gh-aw/actions/download_docker_images.sh" ghcr.io/github/gh-aw-firewall/agent:0.25.40@sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504 ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40@sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280 ghcr.io/github/gh-aw-firewall/squid:0.25.40@sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51 ghcr.io/github/gh-aw-mcpg:v0.3.6@sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959 node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/download_docker_images.sh" ghcr.io/github/gh-aw-firewall/agent:0.25.41@sha256:cb2b565d070116d4b67e355775340528b5a2c3cb18b2c9049638bcc2df681770 ghcr.io/github/gh-aw-firewall/api-proxy:0.25.41@sha256:fadd0de387209f69a9a7a1b8722bb5e7fdfb80ba9749a5c60f0e4cd7582a74d0 ghcr.io/github/gh-aw-firewall/squid:0.25.41@sha256:1260445d25968dbf3ae70143964177a0e5914cf2ce07a6117f7d3caec6c3e3c4 ghcr.io/github/gh-aw-mcpg:v0.3.6@sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959 node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f
- name: Generate Safe Outputs Config
run: |
mkdir -p "${RUNNER_TEMP}/gh-aw/safeoutputs"
mkdir -p /tmp/gh-aw/safeoutputs
mkdir -p /tmp/gh-aw/mcp-logs/safeoutputs
- cat > "${RUNNER_TEMP}/gh-aw/safeoutputs/config.json" << 'GH_AW_SAFE_OUTPUTS_CONFIG_cb1262517960b8af_EOF'
- {"add_comment":{"max":10,"target":"*"},"add_labels":{"max":10,"target":"*"},"create_pull_request":{"max":10,"max_patch_files":100,"max_patch_size":1024,"protect_top_level_dot_folders":true,"protected_files":["package.json","bun.lockb","bunfig.toml","deno.json","deno.jsonc","deno.lock","global.json","NuGet.Config","Directory.Packages.props","mix.exs","mix.lock","go.mod","go.sum","stack.yaml","stack.yaml.lock","pom.xml","build.gradle","build.gradle.kts","settings.gradle","settings.gradle.kts","gradle.properties","package-lock.json","yarn.lock","pnpm-lock.yaml","npm-shrinkwrap.json","requirements.txt","Pipfile","Pipfile.lock","pyproject.toml","setup.py","setup.cfg","Gemfile","Gemfile.lock","uv.lock","CODEOWNERS","DESIGN.md","README.md","CONTRIBUTING.md","CHANGELOG.md","SECURITY.md","CODE_OF_CONDUCT.md","AGENTS.md","CLAUDE.md","GEMINI.md"]},"create_report_incomplete_issue":{},"merge_pull_request":{"max":10},"missing_data":{},"missing_tool":{},"noop":{"max":1,"report-as-issue":"true"},"push_to_pull_request_branch":{"if_no_changes":"warn","max":10,"max_patch_size":1024,"protect_top_level_dot_folders":true,"protected_files":["package.json","bun.lockb","bunfig.toml","deno.json","deno.jsonc","deno.lock","global.json","NuGet.Config","Directory.Packages.props","mix.exs","mix.lock","go.mod","go.sum","stack.yaml","stack.yaml.lock","pom.xml","build.gradle","build.gradle.kts","settings.gradle","settings.gradle.kts","gradle.properties","package-lock.json","yarn.lock","pnpm-lock.yaml","npm-shrinkwrap.json","requirements.txt","Pipfile","Pipfile.lock","pyproject.toml","setup.py","setup.cfg","Gemfile","Gemfile.lock","uv.lock","CODEOWNERS","DESIGN.md","README.md","CONTRIBUTING.md","CHANGELOG.md","SECURITY.md","CODE_OF_CONDUCT.md","AGENTS.md","CLAUDE.md","GEMINI.md"]},"report_incomplete":{},"update_pull_request":{"allow_body":true,"allow_title":true,"max":10,"update_branch":false}}
- GH_AW_SAFE_OUTPUTS_CONFIG_cb1262517960b8af_EOF
+ cat > "${RUNNER_TEMP}/gh-aw/safeoutputs/config.json" << 'GH_AW_SAFE_OUTPUTS_CONFIG_2d619531306fbf49_EOF'
+ {"add_comment":{"max":10,"target":"*"},"add_labels":{"max":10,"target":"*"},"create_pull_request":{"allowed_base_branches":["net[0-9]*.0","xcode[0-9]*"],"max":10,"max_patch_files":100,"max_patch_size":1024,"protect_top_level_dot_folders":true,"protected_files":["package.json","bun.lockb","bunfig.toml","deno.json","deno.jsonc","deno.lock","global.json","NuGet.Config","Directory.Packages.props","mix.exs","mix.lock","go.mod","go.sum","stack.yaml","stack.yaml.lock","pom.xml","build.gradle","build.gradle.kts","settings.gradle","settings.gradle.kts","gradle.properties","package-lock.json","yarn.lock","pnpm-lock.yaml","npm-shrinkwrap.json","requirements.txt","Pipfile","Pipfile.lock","pyproject.toml","setup.py","setup.cfg","Gemfile","Gemfile.lock","uv.lock","CODEOWNERS","DESIGN.md","README.md","CONTRIBUTING.md","CHANGELOG.md","SECURITY.md","CODE_OF_CONDUCT.md","AGENTS.md","CLAUDE.md","GEMINI.md"]},"create_report_incomplete_issue":{},"merge_pull_request":{"max":10},"missing_data":{},"missing_tool":{},"noop":{"max":1,"report-as-issue":"true"},"push_to_pull_request_branch":{"if_no_changes":"warn","max":10,"max_patch_size":1024,"protect_top_level_dot_folders":true,"protected_files":["package.json","bun.lockb","bunfig.toml","deno.json","deno.jsonc","deno.lock","global.json","NuGet.Config","Directory.Packages.props","mix.exs","mix.lock","go.mod","go.sum","stack.yaml","stack.yaml.lock","pom.xml","build.gradle","build.gradle.kts","settings.gradle","settings.gradle.kts","gradle.properties","package-lock.json","yarn.lock","pnpm-lock.yaml","npm-shrinkwrap.json","requirements.txt","Pipfile","Pipfile.lock","pyproject.toml","setup.py","setup.cfg","Gemfile","Gemfile.lock","uv.lock","CODEOWNERS","DESIGN.md","README.md","CONTRIBUTING.md","CHANGELOG.md","SECURITY.md","CODE_OF_CONDUCT.md","AGENTS.md","CLAUDE.md","GEMINI.md"],"target":"*","title_prefix":"🤖 Merge 'main' =\u003e '"},"report_incomplete":{},"update_pull_request":{"allow_body":true,"allow_title":true,"max":10,"update_branch":false}}
+ GH_AW_SAFE_OUTPUTS_CONFIG_2d619531306fbf49_EOF
- name: Generate Safe Outputs Tools
env:
GH_AW_TOOLS_META_JSON: |
@@ -436,7 +454,7 @@ jobs:
"add_comment": " CONSTRAINTS: Maximum 10 comment(s) can be added. Target: *. Supports reply_to_id for discussion threading.",
"add_labels": " CONSTRAINTS: Maximum 10 label(s) can be added. Target: *.",
"create_pull_request": " CONSTRAINTS: Maximum 10 pull request(s) can be created.",
- "push_to_pull_request_branch": " CONSTRAINTS: Maximum 10 push(es) can be made.",
+ "push_to_pull_request_branch": " CONSTRAINTS: Maximum 10 push(es) can be made. The target pull request title must start with \"🤖 Merge 'main' =\u003e '\".",
"update_pull_request": " CONSTRAINTS: Maximum 10 pull request(s) can be updated."
},
"repo_params": {},
@@ -765,7 +783,7 @@ jobs:
mkdir -p /home/runner/.copilot
GH_AW_NODE=$(which node 2>/dev/null || command -v node 2>/dev/null || echo node)
- cat << GH_AW_MCP_CONFIG_30c0410028d42347_EOF | "$GH_AW_NODE" "${RUNNER_TEMP}/gh-aw/actions/start_mcp_gateway.cjs"
+ cat << GH_AW_MCP_CONFIG_2faa3bb664926a36_EOF | "$GH_AW_NODE" "${RUNNER_TEMP}/gh-aw/actions/start_mcp_gateway.cjs"
{
"mcpServers": {
"github": {
@@ -809,7 +827,7 @@ jobs:
"payloadDir": "${MCP_GATEWAY_PAYLOAD_DIR}"
}
}
- GH_AW_MCP_CONFIG_30c0410028d42347_EOF
+ GH_AW_MCP_CONFIG_2faa3bb664926a36_EOF
- name: Mount MCP servers as CLIs
id: mount-mcp-clis
continue-on-error: true
@@ -841,11 +859,12 @@ jobs:
GH_AW_NODE_BIN=$(command -v node 2>/dev/null || true)
export GH_AW_NODE_BIN
(umask 177 && touch /tmp/gh-aw/agent-stdio.log)
- printf '%s\n' '{"$schema":"https://github.com/github/gh-aw-firewall/releases/download/v0.25.40/awf-config.schema.json","network":{"allowDomains":["*.githubusercontent.com","api.business.githubcopilot.com","api.enterprise.githubcopilot.com","api.github.com","api.githubcopilot.com","api.individual.githubcopilot.com","api.snapcraft.io","archive.ubuntu.com","azure.archive.ubuntu.com","codeload.github.com","crl.geotrust.com","crl.globalsign.com","crl.identrust.com","crl.sectigo.com","crl.thawte.com","crl.usertrust.com","crl.verisign.com","crl3.digicert.com","crl4.digicert.com","crls.ssl.com","docs.github.com","github-cloud.githubusercontent.com","github-cloud.s3.amazonaws.com","github.blog","github.com","github.githubassets.com","host.docker.internal","json-schema.org","json.schemastore.org","keyserver.ubuntu.com","lfs.github.com","objects.githubusercontent.com","ocsp.digicert.com","ocsp.geotrust.com","ocsp.globalsign.com","ocsp.identrust.com","ocsp.sectigo.com","ocsp.ssl.com","ocsp.thawte.com","ocsp.usertrust.com","ocsp.verisign.com","packagecloud.io","packages.cloud.google.com","packages.microsoft.com","ppa.launchpad.net","raw.githubusercontent.com","registry.npmjs.org","s.symcb.com","s.symcd.com","security.ubuntu.com","telemetry.enterprise.githubcopilot.com","ts-crl.ws.symantec.com","ts-ocsp.ws.symantec.com","www.googleapis.com"]},"apiProxy":{"enabled":true,"models":{"auto":["large"],"deep-research":["copilot/deep-research*","google/deep-research*"],"gemini-flash":["copilot/gemini-*flash*","google/gemini-*flash*"],"gemini-pro":["copilot/gemini-*pro*","google/gemini-*pro*"],"gpt-4.1":["copilot/gpt-4.1*","openai/gpt-4.1*"],"gpt-5":["copilot/gpt-5*","openai/gpt-5*"],"gpt-5-codex":["copilot/gpt-5*codex*","openai/gpt-5*codex*"],"gpt-5-mini":["copilot/gpt-5*mini*","openai/gpt-5*mini*"],"gpt-5-nano":["copilot/gpt-5*nano*","openai/gpt-5*nano*"],"gpt-5-pro":["copilot/gpt-5*pro*","openai/gpt-5*pro*"],"haiku":["copilot/*haiku*","anthropic/*haiku*"],"large":["sonnet","gpt-5-pro","gpt-5","gemini-pro"],"mini":["haiku","gpt-5-mini","gpt-5-nano","gemini-flash"],"opus":["copilot/*opus*","anthropic/*opus*"],"reasoning":["copilot/o1*","copilot/o3*","copilot/o4*","openai/o1*","openai/o3*","openai/o4*"],"small":["mini"],"sonnet":["copilot/*sonnet*","anthropic/*sonnet*"]}},"container":{"imageTag":"0.25.40,squid=sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51,agent=sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504,api-proxy=sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280,cli-proxy=sha256:3e7152911d4b4b7b97beef9d3d7d924ff7902227e86001ef3838fb728d5d514c"}}' > "${RUNNER_TEMP}/gh-aw/awf-config.json" && cp "${RUNNER_TEMP}/gh-aw/awf-config.json" /tmp/gh-aw/awf-config.json
+ printf '%s\n' '{"$schema":"https://github.com/github/gh-aw-firewall/releases/download/v0.25.41/awf-config.schema.json","network":{"allowDomains":["*.githubusercontent.com","api.business.githubcopilot.com","api.enterprise.githubcopilot.com","api.github.com","api.githubcopilot.com","api.individual.githubcopilot.com","api.snapcraft.io","archive.ubuntu.com","azure.archive.ubuntu.com","codeload.github.com","crl.geotrust.com","crl.globalsign.com","crl.identrust.com","crl.sectigo.com","crl.thawte.com","crl.usertrust.com","crl.verisign.com","crl3.digicert.com","crl4.digicert.com","crls.ssl.com","docs.github.com","github-cloud.githubusercontent.com","github-cloud.s3.amazonaws.com","github.blog","github.com","github.githubassets.com","host.docker.internal","json-schema.org","json.schemastore.org","keyserver.ubuntu.com","lfs.github.com","objects.githubusercontent.com","ocsp.digicert.com","ocsp.geotrust.com","ocsp.globalsign.com","ocsp.identrust.com","ocsp.sectigo.com","ocsp.ssl.com","ocsp.thawte.com","ocsp.usertrust.com","ocsp.verisign.com","packagecloud.io","packages.cloud.google.com","packages.microsoft.com","ppa.launchpad.net","raw.githubusercontent.com","registry.npmjs.org","s.symcb.com","s.symcd.com","security.ubuntu.com","telemetry.enterprise.githubcopilot.com","ts-crl.ws.symantec.com","ts-ocsp.ws.symantec.com","www.googleapis.com"]},"apiProxy":{"enabled":true,"models":{"auto":["large"],"deep-research":["copilot/deep-research*","copilot/o3-deep-research*","copilot/o4-mini-deep-research*","google/deep-research*","openai/o3-deep-research*","openai/o4-mini-deep-research*"],"gemini-flash":["copilot/gemini-*flash*","google/gemini-*flash*"],"gemini-pro":["copilot/gemini-*pro*","google/gemini-*pro*"],"gpt-4.1":["copilot/gpt-4.1*","openai/gpt-4.1*"],"gpt-5":["copilot/gpt-5*","openai/gpt-5*"],"gpt-5-codex":["copilot/gpt-5*codex*","openai/gpt-5*codex*"],"gpt-5-mini":["copilot/gpt-5*mini*","openai/gpt-5*mini*"],"gpt-5-nano":["copilot/gpt-5*nano*","openai/gpt-5*nano*"],"gpt-5-pro":["copilot/gpt-5*pro*","openai/gpt-5*pro*"],"haiku":["copilot/*haiku*","anthropic/*haiku*"],"large":["sonnet","gpt-5-pro","gpt-5","gemini-pro"],"mini":["haiku","gpt-5-mini","gpt-5-nano","gemini-flash"],"opus":["copilot/*opus*","anthropic/*opus*"],"reasoning":["copilot/o1*","copilot/o3*","copilot/o4*","openai/o1*","openai/o3*","openai/o4*"],"small":["mini"],"sonnet":["copilot/*sonnet*","anthropic/*sonnet*"]}},"container":{"imageTag":"0.25.41,squid=sha256:1260445d25968dbf3ae70143964177a0e5914cf2ce07a6117f7d3caec6c3e3c4,agent=sha256:cb2b565d070116d4b67e355775340528b5a2c3cb18b2c9049638bcc2df681770,api-proxy=sha256:fadd0de387209f69a9a7a1b8722bb5e7fdfb80ba9749a5c60f0e4cd7582a74d0"}}' > "${RUNNER_TEMP}/gh-aw/awf-config.json" && cp "${RUNNER_TEMP}/gh-aw/awf-config.json" /tmp/gh-aw/awf-config.json
# shellcheck disable=SC1003
sudo -E awf --config "${RUNNER_TEMP}/gh-aw/awf-config.json" --container-workdir "${GITHUB_WORKSPACE}" --mount "${RUNNER_TEMP}/gh-aw:${RUNNER_TEMP}/gh-aw:ro" --mount "${RUNNER_TEMP}/gh-aw:/host${RUNNER_TEMP}/gh-aw:ro" --env-all --exclude-env COPILOT_GITHUB_TOKEN --exclude-env GITHUB_MCP_SERVER_TOKEN --exclude-env MCP_GATEWAY_API_KEY --log-level info --proxy-logs-dir /tmp/gh-aw/sandbox/firewall/logs --audit-dir /tmp/gh-aw/sandbox/firewall/audit --enable-host-access --allow-host-ports 80,443,8080 --skip-pull \
-- /bin/bash -c 'export PATH="${RUNNER_TEMP}/gh-aw/mcp-cli/bin:$PATH" && export PATH="$(find /opt/hostedtoolcache /home/runner/work/_tool -maxdepth 4 -type d -name bin 2>/dev/null | tr '\''\n'\'' '\'':'\'')$PATH"; [ -n "$GOROOT" ] && export PATH="$GOROOT/bin:$PATH" || true && GH_AW_NODE_EXEC="${GH_AW_NODE_BIN:-}"; if [ -z "$GH_AW_NODE_EXEC" ] || [ ! -x "$GH_AW_NODE_EXEC" ]; then GH_AW_NODE_EXEC="$(command -v node 2>/dev/null || echo node)"; fi; "$GH_AW_NODE_EXEC" ${RUNNER_TEMP}/gh-aw/actions/copilot_harness.cjs /usr/local/bin/copilot --add-dir /tmp/gh-aw/ --log-level all --log-dir /tmp/gh-aw/sandbox/agent/logs/ --disable-builtin-mcps --no-ask-user --allow-all-tools --allow-all-paths --add-dir "${GITHUB_WORKSPACE}" --prompt-file /tmp/gh-aw/aw-prompts/prompt.txt' 2>&1 | tee -a /tmp/gh-aw/agent-stdio.log
env:
+ AWF_REFLECT_ENABLED: 1
COPILOT_AGENT_RUNNER_TYPE: STANDALONE
COPILOT_API_KEY: dummy-byok-key-for-offline-mode
COPILOT_GITHUB_TOKEN: ${{ secrets.COPILOT_GITHUB_TOKEN }}
@@ -854,7 +873,7 @@ jobs:
GH_AW_PHASE: agent
GH_AW_PROMPT: /tmp/gh-aw/aw-prompts/prompt.txt
GH_AW_SAFE_OUTPUTS: ${{ steps.set-runtime-paths.outputs.GH_AW_SAFE_OUTPUTS }}
- GH_AW_VERSION: v0.71.5
+ GH_AW_VERSION: v0.72.1
GITHUB_API_URL: ${{ github.api_url }}
GITHUB_AW: true
GITHUB_COPILOT_INTEGRATION_ID: agentic-workflows
@@ -969,7 +988,7 @@ jobs:
run: |
# Fix permissions on firewall logs/audit dirs so they can be uploaded as artifacts
# AWF runs with sudo, creating files owned by root
- sudo chmod -R a+r /tmp/gh-aw/sandbox/firewall 2>/dev/null || true
+ sudo chmod -R a+rX /tmp/gh-aw/sandbox/firewall 2>/dev/null || true
# Only run awf logs summary if awf command exists (it may not be installed if workflow failed before install step)
if command -v awf &> /dev/null; then
awf logs summary | tee -a "$GITHUB_STEP_SUMMARY"
@@ -1056,7 +1075,7 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+ uses: github/gh-aw-actions/setup@bc56a0cad2f450c562810785ef38649c04db812a # v0.72.1
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
@@ -1192,7 +1211,7 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+ uses: github/gh-aw-actions/setup@bc56a0cad2f450c562810785ef38649c04db812a # v0.72.1
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
@@ -1226,7 +1245,7 @@ jobs:
rm -rf /tmp/gh-aw/sandbox/firewall/logs
rm -rf /tmp/gh-aw/sandbox/firewall/audit
- name: Download container images
- run: bash "${RUNNER_TEMP}/gh-aw/actions/download_docker_images.sh" ghcr.io/github/gh-aw-firewall/agent:0.25.40@sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504 ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40@sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280 ghcr.io/github/gh-aw-firewall/squid:0.25.40@sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/download_docker_images.sh" ghcr.io/github/gh-aw-firewall/agent:0.25.41@sha256:cb2b565d070116d4b67e355775340528b5a2c3cb18b2c9049638bcc2df681770 ghcr.io/github/gh-aw-firewall/api-proxy:0.25.41@sha256:fadd0de387209f69a9a7a1b8722bb5e7fdfb80ba9749a5c60f0e4cd7582a74d0 ghcr.io/github/gh-aw-firewall/squid:0.25.41@sha256:1260445d25968dbf3ae70143964177a0e5914cf2ce07a6117f7d3caec6c3e3c4
- name: Check if detection needed
id: detection_guard
if: always()
@@ -1289,7 +1308,7 @@ jobs:
env:
GH_HOST: github.com
- name: Install AWF binary
- run: bash "${RUNNER_TEMP}/gh-aw/actions/install_awf_binary.sh" v0.25.40
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/install_awf_binary.sh" v0.25.41
- name: Execute GitHub Copilot CLI
if: always() && steps.detection_guard.outputs.run_detection == 'true'
continue-on-error: true
@@ -1302,18 +1321,19 @@ jobs:
GH_AW_NODE_BIN=$(command -v node 2>/dev/null || true)
export GH_AW_NODE_BIN
(umask 177 && touch /tmp/gh-aw/threat-detection/detection.log)
- printf '%s\n' '{"$schema":"https://github.com/github/gh-aw-firewall/releases/download/v0.25.40/awf-config.schema.json","network":{"allowDomains":["api.business.githubcopilot.com","api.enterprise.githubcopilot.com","api.github.com","api.githubcopilot.com","api.individual.githubcopilot.com","github.com","host.docker.internal","telemetry.enterprise.githubcopilot.com"]},"apiProxy":{"enabled":true},"container":{"imageTag":"0.25.40,squid=sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51,agent=sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504,api-proxy=sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280,cli-proxy=sha256:3e7152911d4b4b7b97beef9d3d7d924ff7902227e86001ef3838fb728d5d514c"}}' > "${RUNNER_TEMP}/gh-aw/awf-config.json" && cp "${RUNNER_TEMP}/gh-aw/awf-config.json" /tmp/gh-aw/awf-config.json
+ printf '%s\n' '{"$schema":"https://github.com/github/gh-aw-firewall/releases/download/v0.25.41/awf-config.schema.json","network":{"allowDomains":["api.business.githubcopilot.com","api.enterprise.githubcopilot.com","api.github.com","api.githubcopilot.com","api.individual.githubcopilot.com","github.com","host.docker.internal","telemetry.enterprise.githubcopilot.com"]},"apiProxy":{"enabled":true},"container":{"imageTag":"0.25.41"}}' > "${RUNNER_TEMP}/gh-aw/awf-config.json" && cp "${RUNNER_TEMP}/gh-aw/awf-config.json" /tmp/gh-aw/awf-config.json
# shellcheck disable=SC1003
sudo -E awf --config "${RUNNER_TEMP}/gh-aw/awf-config.json" --container-workdir "${GITHUB_WORKSPACE}" --mount "${RUNNER_TEMP}/gh-aw:${RUNNER_TEMP}/gh-aw:ro" --mount "${RUNNER_TEMP}/gh-aw:/host${RUNNER_TEMP}/gh-aw:ro" --env-all --exclude-env COPILOT_GITHUB_TOKEN --log-level info --proxy-logs-dir /tmp/gh-aw/sandbox/firewall/logs --audit-dir /tmp/gh-aw/sandbox/firewall/audit --enable-host-access --allow-host-ports 80,443,8080 --skip-pull \
-- /bin/bash -c 'export PATH="$(find /opt/hostedtoolcache /home/runner/work/_tool -maxdepth 4 -type d -name bin 2>/dev/null | tr '\''\n'\'' '\'':'\'')$PATH"; [ -n "$GOROOT" ] && export PATH="$GOROOT/bin:$PATH" || true && GH_AW_NODE_EXEC="${GH_AW_NODE_BIN:-}"; if [ -z "$GH_AW_NODE_EXEC" ] || [ ! -x "$GH_AW_NODE_EXEC" ]; then GH_AW_NODE_EXEC="$(command -v node 2>/dev/null || echo node)"; fi; "$GH_AW_NODE_EXEC" ${RUNNER_TEMP}/gh-aw/actions/copilot_harness.cjs /usr/local/bin/copilot --add-dir /tmp/gh-aw/ --log-level all --log-dir /tmp/gh-aw/sandbox/agent/logs/ --disable-builtin-mcps --no-ask-user --allow-all-tools --add-dir "${GITHUB_WORKSPACE}" --prompt-file /tmp/gh-aw/aw-prompts/prompt.txt' 2>&1 | tee -a /tmp/gh-aw/threat-detection/detection.log
env:
+ AWF_REFLECT_ENABLED: 1
COPILOT_AGENT_RUNNER_TYPE: STANDALONE
COPILOT_API_KEY: dummy-byok-key-for-offline-mode
COPILOT_GITHUB_TOKEN: ${{ secrets.COPILOT_GITHUB_TOKEN }}
COPILOT_MODEL: claude-sonnet-4.5
GH_AW_PHASE: detection
GH_AW_PROMPT: /tmp/gh-aw/aw-prompts/prompt.txt
- GH_AW_VERSION: v0.71.5
+ GH_AW_VERSION: v0.72.1
GITHUB_API_URL: ${{ github.api_url }}
GITHUB_AW: true
GITHUB_COPILOT_INTEGRATION_ID: agentic-workflows
@@ -1404,7 +1424,7 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+ uses: github/gh-aw-actions/setup@bc56a0cad2f450c562810785ef38649c04db812a # v0.72.1
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
@@ -1433,11 +1453,34 @@ jobs:
with:
name: agent
path: /tmp/gh-aw/
+ - name: Extract base branch from agent output
+ id: extract-base-branch
+ if: steps.download-agent-output.outcome == 'success'
+ shell: bash
+ run: |
+ if [ -f "/tmp/gh-aw/agent_output.json" ]; then
+ GH_AW_NODE=$(which node 2>/dev/null || command -v node 2>/dev/null || echo node)
+ BASE_BRANCH=$("$GH_AW_NODE" -e "
+ try {
+ const data = JSON.parse(require('fs').readFileSync('/tmp/gh-aw/agent_output.json', 'utf8'));
+ const item = (data.items || []).find(i =>
+ (i.type === 'create_pull_request' || i.type === 'push_to_pull_request_branch') &&
+ i.base_branch
+ );
+ if (item) process.stdout.write(item.base_branch);
+ } catch(e) {}
+ " 2>/dev/null || true)
+ # Validate: only allow safe git branch name characters
+ if [[ "$BASE_BRANCH" =~ ^[a-zA-Z0-9/_.-]+$ ]] && [ ${#BASE_BRANCH} -le 255 ]; then
+ printf 'base-branch=%s\n' "$BASE_BRANCH" >> "$GITHUB_OUTPUT"
+ echo "Extracted base branch from safe output: $BASE_BRANCH"
+ fi
+ fi
- name: Checkout repository
if: (!cancelled()) && needs.agent.result != 'skipped' && contains(needs.agent.outputs.output_types, 'create_pull_request') || (!cancelled()) && needs.agent.result != 'skipped' && contains(needs.agent.outputs.output_types, 'push_to_pull_request_branch')
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
- ref: ${{ github.base_ref || github.event.pull_request.base.ref || github.ref_name || github.event.repository.default_branch }}
+ ref: ${{ steps.extract-base-branch.outputs.base-branch || github.base_ref || github.event.pull_request.base.ref || github.ref_name || github.event.repository.default_branch }}
token: ${{ secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
persist-credentials: false
fetch-depth: 1
@@ -1472,7 +1515,7 @@ jobs:
GH_AW_ALLOWED_DOMAINS: "*.githubusercontent.com,api.business.githubcopilot.com,api.enterprise.githubcopilot.com,api.github.com,api.githubcopilot.com,api.individual.githubcopilot.com,api.snapcraft.io,archive.ubuntu.com,azure.archive.ubuntu.com,codeload.github.com,crl.geotrust.com,crl.globalsign.com,crl.identrust.com,crl.sectigo.com,crl.thawte.com,crl.usertrust.com,crl.verisign.com,crl3.digicert.com,crl4.digicert.com,crls.ssl.com,docs.github.com,github-cloud.githubusercontent.com,github-cloud.s3.amazonaws.com,github.blog,github.com,github.githubassets.com,host.docker.internal,json-schema.org,json.schemastore.org,keyserver.ubuntu.com,lfs.github.com,objects.githubusercontent.com,ocsp.digicert.com,ocsp.geotrust.com,ocsp.globalsign.com,ocsp.identrust.com,ocsp.sectigo.com,ocsp.ssl.com,ocsp.thawte.com,ocsp.usertrust.com,ocsp.verisign.com,packagecloud.io,packages.cloud.google.com,packages.microsoft.com,ppa.launchpad.net,raw.githubusercontent.com,registry.npmjs.org,s.symcb.com,s.symcd.com,security.ubuntu.com,telemetry.enterprise.githubcopilot.com,ts-crl.ws.symantec.com,ts-ocsp.ws.symantec.com,www.googleapis.com"
GITHUB_SERVER_URL: ${{ github.server_url }}
GITHUB_API_URL: ${{ github.api_url }}
- GH_AW_SAFE_OUTPUTS_HANDLER_CONFIG: "{\"add_comment\":{\"max\":10,\"target\":\"*\"},\"add_labels\":{\"max\":10,\"target\":\"*\"},\"create_pull_request\":{\"max\":10,\"max_patch_files\":100,\"max_patch_size\":1024,\"protect_top_level_dot_folders\":true,\"protected_files\":[\"package.json\",\"bun.lockb\",\"bunfig.toml\",\"deno.json\",\"deno.jsonc\",\"deno.lock\",\"global.json\",\"NuGet.Config\",\"Directory.Packages.props\",\"mix.exs\",\"mix.lock\",\"go.mod\",\"go.sum\",\"stack.yaml\",\"stack.yaml.lock\",\"pom.xml\",\"build.gradle\",\"build.gradle.kts\",\"settings.gradle\",\"settings.gradle.kts\",\"gradle.properties\",\"package-lock.json\",\"yarn.lock\",\"pnpm-lock.yaml\",\"npm-shrinkwrap.json\",\"requirements.txt\",\"Pipfile\",\"Pipfile.lock\",\"pyproject.toml\",\"setup.py\",\"setup.cfg\",\"Gemfile\",\"Gemfile.lock\",\"uv.lock\",\"CODEOWNERS\",\"DESIGN.md\",\"README.md\",\"CONTRIBUTING.md\",\"CHANGELOG.md\",\"SECURITY.md\",\"CODE_OF_CONDUCT.md\",\"AGENTS.md\",\"CLAUDE.md\",\"GEMINI.md\"]},\"create_report_incomplete_issue\":{},\"merge_pull_request\":{\"max\":10},\"missing_data\":{},\"missing_tool\":{},\"noop\":{\"max\":1,\"report-as-issue\":\"true\"},\"push_to_pull_request_branch\":{\"if_no_changes\":\"warn\",\"max\":10,\"max_patch_size\":1024,\"protect_top_level_dot_folders\":true,\"protected_files\":[\"package.json\",\"bun.lockb\",\"bunfig.toml\",\"deno.json\",\"deno.jsonc\",\"deno.lock\",\"global.json\",\"NuGet.Config\",\"Directory.Packages.props\",\"mix.exs\",\"mix.lock\",\"go.mod\",\"go.sum\",\"stack.yaml\",\"stack.yaml.lock\",\"pom.xml\",\"build.gradle\",\"build.gradle.kts\",\"settings.gradle\",\"settings.gradle.kts\",\"gradle.properties\",\"package-lock.json\",\"yarn.lock\",\"pnpm-lock.yaml\",\"npm-shrinkwrap.json\",\"requirements.txt\",\"Pipfile\",\"Pipfile.lock\",\"pyproject.toml\",\"setup.py\",\"setup.cfg\",\"Gemfile\",\"Gemfile.lock\",\"uv.lock\",\"CODEOWNERS\",\"DESIGN.md\",\"README.md\",\"CONTRIBUTING.md\",\"CHANGELOG.md\",\"SECURITY.md\",\"CODE_OF_CONDUCT.md\",\"AGENTS.md\",\"CLAUDE.md\",\"GEMINI.md\"]},\"report_incomplete\":{},\"update_pull_request\":{\"allow_body\":true,\"allow_title\":true,\"max\":10,\"update_branch\":false}}"
+ GH_AW_SAFE_OUTPUTS_HANDLER_CONFIG: "{\"add_comment\":{\"max\":10,\"target\":\"*\"},\"add_labels\":{\"max\":10,\"target\":\"*\"},\"create_pull_request\":{\"allowed_base_branches\":[\"net[0-9]*.0\",\"xcode[0-9]*\"],\"max\":10,\"max_patch_files\":100,\"max_patch_size\":1024,\"protect_top_level_dot_folders\":true,\"protected_files\":[\"package.json\",\"bun.lockb\",\"bunfig.toml\",\"deno.json\",\"deno.jsonc\",\"deno.lock\",\"global.json\",\"NuGet.Config\",\"Directory.Packages.props\",\"mix.exs\",\"mix.lock\",\"go.mod\",\"go.sum\",\"stack.yaml\",\"stack.yaml.lock\",\"pom.xml\",\"build.gradle\",\"build.gradle.kts\",\"settings.gradle\",\"settings.gradle.kts\",\"gradle.properties\",\"package-lock.json\",\"yarn.lock\",\"pnpm-lock.yaml\",\"npm-shrinkwrap.json\",\"requirements.txt\",\"Pipfile\",\"Pipfile.lock\",\"pyproject.toml\",\"setup.py\",\"setup.cfg\",\"Gemfile\",\"Gemfile.lock\",\"uv.lock\",\"CODEOWNERS\",\"DESIGN.md\",\"README.md\",\"CONTRIBUTING.md\",\"CHANGELOG.md\",\"SECURITY.md\",\"CODE_OF_CONDUCT.md\",\"AGENTS.md\",\"CLAUDE.md\",\"GEMINI.md\"]},\"create_report_incomplete_issue\":{},\"merge_pull_request\":{\"max\":10},\"missing_data\":{},\"missing_tool\":{},\"noop\":{\"max\":1,\"report-as-issue\":\"true\"},\"push_to_pull_request_branch\":{\"if_no_changes\":\"warn\",\"max\":10,\"max_patch_size\":1024,\"protect_top_level_dot_folders\":true,\"protected_files\":[\"package.json\",\"bun.lockb\",\"bunfig.toml\",\"deno.json\",\"deno.jsonc\",\"deno.lock\",\"global.json\",\"NuGet.Config\",\"Directory.Packages.props\",\"mix.exs\",\"mix.lock\",\"go.mod\",\"go.sum\",\"stack.yaml\",\"stack.yaml.lock\",\"pom.xml\",\"build.gradle\",\"build.gradle.kts\",\"settings.gradle\",\"settings.gradle.kts\",\"gradle.properties\",\"package-lock.json\",\"yarn.lock\",\"pnpm-lock.yaml\",\"npm-shrinkwrap.json\",\"requirements.txt\",\"Pipfile\",\"Pipfile.lock\",\"pyproject.toml\",\"setup.py\",\"setup.cfg\",\"Gemfile\",\"Gemfile.lock\",\"uv.lock\",\"CODEOWNERS\",\"DESIGN.md\",\"README.md\",\"CONTRIBUTING.md\",\"CHANGELOG.md\",\"SECURITY.md\",\"CODE_OF_CONDUCT.md\",\"AGENTS.md\",\"CLAUDE.md\",\"GEMINI.md\"],\"target\":\"*\",\"title_prefix\":\"🤖 Merge 'main' =\\u003e '\"},\"report_incomplete\":{},\"update_pull_request\":{\"allow_body\":true,\"allow_title\":true,\"max\":10,\"update_branch\":false}}"
GH_AW_CI_TRIGGER_TOKEN: ${{ secrets.GH_AW_CI_TRIGGER_TOKEN }}
with:
github-token: ${{ secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
diff --git a/.github/workflows/code-radiator.md b/.github/workflows/code-radiator.md
index 64c78bc90562..b19f43eb2dc6 100644
--- a/.github/workflows/code-radiator.md
+++ b/.github/workflows/code-radiator.md
@@ -21,9 +21,15 @@ tools:
toolsets: [pull_requests, repos]
min-integrity: approved
bash: true
+checkout:
+ fetch: ["*"]
+ fetch-depth: 0
safe-outputs:
create-pull-request:
max: 10
+ allowed-base-branches:
+ - "net[0-9]*.0"
+ - "xcode[0-9]*"
add-comment:
max: 10
target: "*"
@@ -34,6 +40,8 @@ safe-outputs:
max: 10
push-to-pull-request-branch:
max: 10
+ target: "*"
+ title-prefix: "🤖 Merge 'main' => '"
update-pull-request:
max: 10
---
diff --git a/.github/workflows/copilot-setup-steps.yml b/.github/workflows/copilot-setup-steps.yml
index f5f09b80ef69..0ae42f6f5c4b 100644
--- a/.github/workflows/copilot-setup-steps.yml
+++ b/.github/workflows/copilot-setup-steps.yml
@@ -21,6 +21,6 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v6
- name: Install gh-aw extension
- uses: github/gh-aw-actions/setup-cli@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+ uses: github/gh-aw-actions/setup-cli@bc56a0cad2f450c562810785ef38649c04db812a # v0.72.1
with:
- version: v0.71.5
+ version: v0.72.1
diff --git a/.github/workflows/macios-reviewer.lock.yml b/.github/workflows/macios-reviewer.lock.yml
index 716dd4acf735..616d54825de5 100644
--- a/.github/workflows/macios-reviewer.lock.yml
+++ b/.github/workflows/macios-reviewer.lock.yml
@@ -1,5 +1,5 @@
-# gh-aw-metadata: {"schema_version":"v3","frontmatter_hash":"a0f64139dbc6fe8697f9fd99f5489155b561c37ec0b13d7eaf30bda56d034e7f","compiler_version":"v0.71.5","strict":true,"agent_id":"copilot","agent_model":"claude-sonnet-4.5"}
-# gh-aw-manifest: {"version":1,"secrets":["COPILOT_GITHUB_TOKEN","GH_AW_GITHUB_MCP_SERVER_TOKEN","GH_AW_GITHUB_TOKEN","GITHUB_TOKEN"],"actions":[{"repo":"actions/checkout","sha":"de0fac2e4500dabe0009e67214ff5f5447ce83dd","version":"v6.0.2"},{"repo":"actions/download-artifact","sha":"3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c","version":"v8.0.1"},{"repo":"actions/github-script","sha":"3a2844b7e9c422d3c10d287c895573f7108da1b3","version":"v9.0.0"},{"repo":"actions/setup-node","sha":"48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e","version":"v6.4.0"},{"repo":"actions/upload-artifact","sha":"043fb46d1a93c77aae656e7c1c64a875d1fc6a0a","version":"v7.0.1"},{"repo":"github/gh-aw-actions/setup","sha":"b8068426813005612b960b5ab0b8bd2c27142323","version":"v0.71.5"}],"containers":[{"image":"ghcr.io/github/gh-aw-firewall/agent:0.25.40","digest":"sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504","pinned_image":"ghcr.io/github/gh-aw-firewall/agent:0.25.40@sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504"},{"image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40","digest":"sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280","pinned_image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40@sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280"},{"image":"ghcr.io/github/gh-aw-firewall/squid:0.25.40","digest":"sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51","pinned_image":"ghcr.io/github/gh-aw-firewall/squid:0.25.40@sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51"},{"image":"ghcr.io/github/gh-aw-mcpg:v0.3.6","digest":"sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c","pinned_image":"ghcr.io/github/gh-aw-mcpg:v0.3.6@sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c"},{"image":"ghcr.io/github/github-mcp-server:v1.0.3","digest":"sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959","pinned_image":"ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959"},{"image":"node:lts-alpine","digest":"sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f","pinned_image":"node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f"}]}
+# gh-aw-metadata: {"schema_version":"v3","frontmatter_hash":"a0f64139dbc6fe8697f9fd99f5489155b561c37ec0b13d7eaf30bda56d034e7f","compiler_version":"v0.72.1","strict":true,"agent_id":"copilot","agent_model":"claude-sonnet-4.5"}
+# gh-aw-manifest: {"version":1,"secrets":["COPILOT_GITHUB_TOKEN","GH_AW_GITHUB_MCP_SERVER_TOKEN","GH_AW_GITHUB_TOKEN","GITHUB_TOKEN"],"actions":[{"repo":"actions/checkout","sha":"de0fac2e4500dabe0009e67214ff5f5447ce83dd","version":"v6.0.2"},{"repo":"actions/download-artifact","sha":"3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c","version":"v8.0.1"},{"repo":"actions/github-script","sha":"3a2844b7e9c422d3c10d287c895573f7108da1b3","version":"v9.0.0"},{"repo":"actions/setup-node","sha":"48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e","version":"v6.4.0"},{"repo":"actions/upload-artifact","sha":"043fb46d1a93c77aae656e7c1c64a875d1fc6a0a","version":"v7.0.1"},{"repo":"github/gh-aw-actions/setup","sha":"bc56a0cad2f450c562810785ef38649c04db812a","version":"v0.72.1"}],"containers":[{"image":"ghcr.io/github/gh-aw-firewall/agent:0.25.41","digest":"sha256:cb2b565d070116d4b67e355775340528b5a2c3cb18b2c9049638bcc2df681770","pinned_image":"ghcr.io/github/gh-aw-firewall/agent:0.25.41@sha256:cb2b565d070116d4b67e355775340528b5a2c3cb18b2c9049638bcc2df681770"},{"image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.41","digest":"sha256:fadd0de387209f69a9a7a1b8722bb5e7fdfb80ba9749a5c60f0e4cd7582a74d0","pinned_image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.41@sha256:fadd0de387209f69a9a7a1b8722bb5e7fdfb80ba9749a5c60f0e4cd7582a74d0"},{"image":"ghcr.io/github/gh-aw-firewall/squid:0.25.41","digest":"sha256:1260445d25968dbf3ae70143964177a0e5914cf2ce07a6117f7d3caec6c3e3c4","pinned_image":"ghcr.io/github/gh-aw-firewall/squid:0.25.41@sha256:1260445d25968dbf3ae70143964177a0e5914cf2ce07a6117f7d3caec6c3e3c4"},{"image":"ghcr.io/github/gh-aw-mcpg:v0.3.6","digest":"sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c","pinned_image":"ghcr.io/github/gh-aw-mcpg:v0.3.6@sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c"},{"image":"ghcr.io/github/github-mcp-server:v1.0.3","digest":"sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959","pinned_image":"ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959"},{"image":"node:lts-alpine","digest":"sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f","pinned_image":"node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f"}]}
# ___ _ _
# / _ \ | | (_)
# | |_| | __ _ ___ _ __ | |_ _ ___
@@ -14,7 +14,7 @@
# \ /\ / (_) | | | | ( | | | | (_) \ V V /\__ \
# \/ \/ \___/|_| |_|\_\|_| |_|\___/ \_/\_/ |___/
#
-# This file was automatically generated by gh-aw (v0.71.5). DO NOT EDIT.
+# This file was automatically generated by gh-aw (v0.72.1). DO NOT EDIT.
#
# To update this file, edit the corresponding .md file and run:
# gh aw compile
@@ -35,12 +35,12 @@
# - actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
# - actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
# - actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
-# - github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+# - github/gh-aw-actions/setup@bc56a0cad2f450c562810785ef38649c04db812a # v0.72.1
#
# Container images used:
-# - ghcr.io/github/gh-aw-firewall/agent:0.25.40@sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504
-# - ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40@sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280
-# - ghcr.io/github/gh-aw-firewall/squid:0.25.40@sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51
+# - ghcr.io/github/gh-aw-firewall/agent:0.25.41@sha256:cb2b565d070116d4b67e355775340528b5a2c3cb18b2c9049638bcc2df681770
+# - ghcr.io/github/gh-aw-firewall/api-proxy:0.25.41@sha256:fadd0de387209f69a9a7a1b8722bb5e7fdfb80ba9749a5c60f0e4cd7582a74d0
+# - ghcr.io/github/gh-aw-firewall/squid:0.25.41@sha256:1260445d25968dbf3ae70143964177a0e5914cf2ce07a6117f7d3caec6c3e3c4
# - ghcr.io/github/gh-aw-mcpg:v0.3.6@sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c
# - ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959
# - node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f
@@ -91,7 +91,7 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+ uses: github/gh-aw-actions/setup@bc56a0cad2f450c562810785ef38649c04db812a # v0.72.1
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
@@ -108,14 +108,14 @@ jobs:
GH_AW_INFO_MODEL: "claude-sonnet-4.5"
GH_AW_INFO_VERSION: "1.0.40"
GH_AW_INFO_AGENT_VERSION: "1.0.40"
- GH_AW_INFO_CLI_VERSION: "v0.71.5"
+ GH_AW_INFO_CLI_VERSION: "v0.72.1"
GH_AW_INFO_WORKFLOW_NAME: ".NET for Apple Platforms PR Reviewer"
GH_AW_INFO_EXPERIMENTAL: "false"
GH_AW_INFO_SUPPORTS_TOOLS_ALLOWLIST: "true"
GH_AW_INFO_STAGED: "false"
GH_AW_INFO_ALLOWED_DOMAINS: '["defaults","dotnet","github","aka.ms","dev.azure.com","microsoft.com","vsassets.io"]'
GH_AW_INFO_FIREWALL_ENABLED: "true"
- GH_AW_INFO_AWF_VERSION: "v0.25.40"
+ GH_AW_INFO_AWF_VERSION: "v0.25.41"
GH_AW_INFO_AWMG_VERSION: ""
GH_AW_INFO_FIREWALL_TYPE: "squid"
GH_AW_COMPILED_STRICT: "true"
@@ -180,7 +180,7 @@ jobs:
- name: Check compile-agentic version
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
- GH_AW_COMPILED_VERSION: "v0.71.5"
+ GH_AW_COMPILED_VERSION: "v0.72.1"
with:
script: |
const { setupGlobals } = require('${{ runner.temp }}/gh-aw/actions/setup_globals.cjs');
@@ -350,8 +350,11 @@ jobs:
path: |
/tmp/gh-aw/aw_info.json
/tmp/gh-aw/aw-prompts/prompt.txt
+ /tmp/gh-aw/aw-prompts/prompt-template.txt
+ /tmp/gh-aw/aw-prompts/prompt-import-tree.json
/tmp/gh-aw/github_rate_limits.jsonl
/tmp/gh-aw/base
+ /tmp/gh-aw/.github/agents
if-no-files-found: ignore
retention-days: 1
@@ -383,7 +386,7 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+ uses: github/gh-aw-actions/setup@bc56a0cad2f450c562810785ef38649c04db812a # v0.72.1
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
@@ -442,7 +445,7 @@ jobs:
env:
GH_HOST: github.com
- name: Install AWF binary
- run: bash "${RUNNER_TEMP}/gh-aw/actions/install_awf_binary.sh" v0.25.40
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/install_awf_binary.sh" v0.25.41
- name: Parse integrity filter lists
id: parse-guard-vars
env:
@@ -461,8 +464,13 @@ jobs:
GH_AW_AGENT_FOLDERS: ".agents .claude .codex .crush .gemini .github .opencode .pi"
GH_AW_AGENT_FILES: ".crush.json AGENTS.md CLAUDE.md GEMINI.md PI.md opencode.jsonc"
run: bash "${RUNNER_TEMP}/gh-aw/actions/restore_base_github_folders.sh"
+ - name: Restore inline sub-agents from activation artifact
+ env:
+ GH_AW_SUB_AGENT_DIR: ".github/agents"
+ GH_AW_SUB_AGENT_EXT: ".agent.md"
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/restore_inline_sub_agents.sh"
- name: Download container images
- run: bash "${RUNNER_TEMP}/gh-aw/actions/download_docker_images.sh" ghcr.io/github/gh-aw-firewall/agent:0.25.40@sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504 ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40@sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280 ghcr.io/github/gh-aw-firewall/squid:0.25.40@sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51 ghcr.io/github/gh-aw-mcpg:v0.3.6@sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959 node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/download_docker_images.sh" ghcr.io/github/gh-aw-firewall/agent:0.25.41@sha256:cb2b565d070116d4b67e355775340528b5a2c3cb18b2c9049638bcc2df681770 ghcr.io/github/gh-aw-firewall/api-proxy:0.25.41@sha256:fadd0de387209f69a9a7a1b8722bb5e7fdfb80ba9749a5c60f0e4cd7582a74d0 ghcr.io/github/gh-aw-firewall/squid:0.25.41@sha256:1260445d25968dbf3ae70143964177a0e5914cf2ce07a6117f7d3caec6c3e3c4 ghcr.io/github/gh-aw-mcpg:v0.3.6@sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959 node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f
- name: Generate Safe Outputs Config
run: |
mkdir -p "${RUNNER_TEMP}/gh-aw/safeoutputs"
@@ -767,11 +775,12 @@ jobs:
GH_AW_NODE_BIN=$(command -v node 2>/dev/null || true)
export GH_AW_NODE_BIN
(umask 177 && touch /tmp/gh-aw/agent-stdio.log)
- printf '%s\n' '{"$schema":"https://github.com/github/gh-aw-firewall/releases/download/v0.25.40/awf-config.schema.json","network":{"allowDomains":["*.githubusercontent.com","*.vsblob.vsassets.io","aka.ms","api.business.githubcopilot.com","api.enterprise.githubcopilot.com","api.github.com","api.githubcopilot.com","api.individual.githubcopilot.com","api.nuget.org","api.snapcraft.io","archive.ubuntu.com","azure.archive.ubuntu.com","azuresearch-usnc.nuget.org","azuresearch-ussc.nuget.org","builds.dotnet.microsoft.com","ci.dot.net","codeload.github.com","crl.geotrust.com","crl.globalsign.com","crl.identrust.com","crl.sectigo.com","crl.thawte.com","crl.usertrust.com","crl.verisign.com","crl3.digicert.com","crl4.digicert.com","crls.ssl.com","dc.services.visualstudio.com","dev.azure.com","dist.nuget.org","docs.github.com","dot.net","dotnet.microsoft.com","dotnetcli.blob.core.windows.net","github-cloud.githubusercontent.com","github-cloud.s3.amazonaws.com","github.blog","github.com","github.githubassets.com","host.docker.internal","json-schema.org","json.schemastore.org","keyserver.ubuntu.com","lfs.github.com","microsoft.com","nuget.org","nuget.pkg.github.com","nugetregistryv2prod.blob.core.windows.net","objects.githubusercontent.com","ocsp.digicert.com","ocsp.geotrust.com","ocsp.globalsign.com","ocsp.identrust.com","ocsp.sectigo.com","ocsp.ssl.com","ocsp.thawte.com","ocsp.usertrust.com","ocsp.verisign.com","oneocsp.microsoft.com","packagecloud.io","packages.cloud.google.com","packages.microsoft.com","pkgs.dev.azure.com","ppa.launchpad.net","raw.githubusercontent.com","registry.npmjs.org","s.symcb.com","s.symcd.com","security.ubuntu.com","telemetry.enterprise.githubcopilot.com","ts-crl.ws.symantec.com","ts-ocsp.ws.symantec.com","vsassets.io","www.googleapis.com","www.microsoft.com"]},"apiProxy":{"enabled":true,"models":{"auto":["large"],"deep-research":["copilot/deep-research*","google/deep-research*"],"gemini-flash":["copilot/gemini-*flash*","google/gemini-*flash*"],"gemini-pro":["copilot/gemini-*pro*","google/gemini-*pro*"],"gpt-4.1":["copilot/gpt-4.1*","openai/gpt-4.1*"],"gpt-5":["copilot/gpt-5*","openai/gpt-5*"],"gpt-5-codex":["copilot/gpt-5*codex*","openai/gpt-5*codex*"],"gpt-5-mini":["copilot/gpt-5*mini*","openai/gpt-5*mini*"],"gpt-5-nano":["copilot/gpt-5*nano*","openai/gpt-5*nano*"],"gpt-5-pro":["copilot/gpt-5*pro*","openai/gpt-5*pro*"],"haiku":["copilot/*haiku*","anthropic/*haiku*"],"large":["sonnet","gpt-5-pro","gpt-5","gemini-pro"],"mini":["haiku","gpt-5-mini","gpt-5-nano","gemini-flash"],"opus":["copilot/*opus*","anthropic/*opus*"],"reasoning":["copilot/o1*","copilot/o3*","copilot/o4*","openai/o1*","openai/o3*","openai/o4*"],"small":["mini"],"sonnet":["copilot/*sonnet*","anthropic/*sonnet*"]}},"container":{"imageTag":"0.25.40,squid=sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51,agent=sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504,api-proxy=sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280,cli-proxy=sha256:3e7152911d4b4b7b97beef9d3d7d924ff7902227e86001ef3838fb728d5d514c"}}' > "${RUNNER_TEMP}/gh-aw/awf-config.json" && cp "${RUNNER_TEMP}/gh-aw/awf-config.json" /tmp/gh-aw/awf-config.json
+ printf '%s\n' '{"$schema":"https://github.com/github/gh-aw-firewall/releases/download/v0.25.41/awf-config.schema.json","network":{"allowDomains":["*.githubusercontent.com","*.vsblob.vsassets.io","aka.ms","api.business.githubcopilot.com","api.enterprise.githubcopilot.com","api.github.com","api.githubcopilot.com","api.individual.githubcopilot.com","api.nuget.org","api.snapcraft.io","archive.ubuntu.com","azure.archive.ubuntu.com","azuresearch-usnc.nuget.org","azuresearch-ussc.nuget.org","builds.dotnet.microsoft.com","ci.dot.net","codeload.github.com","crl.geotrust.com","crl.globalsign.com","crl.identrust.com","crl.sectigo.com","crl.thawte.com","crl.usertrust.com","crl.verisign.com","crl3.digicert.com","crl4.digicert.com","crls.ssl.com","dc.services.visualstudio.com","dev.azure.com","dist.nuget.org","docs.github.com","dot.net","dotnet.microsoft.com","dotnetcli.blob.core.windows.net","github-cloud.githubusercontent.com","github-cloud.s3.amazonaws.com","github.blog","github.com","github.githubassets.com","host.docker.internal","json-schema.org","json.schemastore.org","keyserver.ubuntu.com","lfs.github.com","microsoft.com","nuget.org","nuget.pkg.github.com","nugetregistryv2prod.blob.core.windows.net","objects.githubusercontent.com","ocsp.digicert.com","ocsp.geotrust.com","ocsp.globalsign.com","ocsp.identrust.com","ocsp.sectigo.com","ocsp.ssl.com","ocsp.thawte.com","ocsp.usertrust.com","ocsp.verisign.com","oneocsp.microsoft.com","packagecloud.io","packages.cloud.google.com","packages.microsoft.com","pkgs.dev.azure.com","ppa.launchpad.net","raw.githubusercontent.com","registry.npmjs.org","s.symcb.com","s.symcd.com","security.ubuntu.com","telemetry.enterprise.githubcopilot.com","ts-crl.ws.symantec.com","ts-ocsp.ws.symantec.com","vsassets.io","www.googleapis.com","www.microsoft.com"]},"apiProxy":{"enabled":true,"models":{"auto":["large"],"deep-research":["copilot/deep-research*","copilot/o3-deep-research*","copilot/o4-mini-deep-research*","google/deep-research*","openai/o3-deep-research*","openai/o4-mini-deep-research*"],"gemini-flash":["copilot/gemini-*flash*","google/gemini-*flash*"],"gemini-pro":["copilot/gemini-*pro*","google/gemini-*pro*"],"gpt-4.1":["copilot/gpt-4.1*","openai/gpt-4.1*"],"gpt-5":["copilot/gpt-5*","openai/gpt-5*"],"gpt-5-codex":["copilot/gpt-5*codex*","openai/gpt-5*codex*"],"gpt-5-mini":["copilot/gpt-5*mini*","openai/gpt-5*mini*"],"gpt-5-nano":["copilot/gpt-5*nano*","openai/gpt-5*nano*"],"gpt-5-pro":["copilot/gpt-5*pro*","openai/gpt-5*pro*"],"haiku":["copilot/*haiku*","anthropic/*haiku*"],"large":["sonnet","gpt-5-pro","gpt-5","gemini-pro"],"mini":["haiku","gpt-5-mini","gpt-5-nano","gemini-flash"],"opus":["copilot/*opus*","anthropic/*opus*"],"reasoning":["copilot/o1*","copilot/o3*","copilot/o4*","openai/o1*","openai/o3*","openai/o4*"],"small":["mini"],"sonnet":["copilot/*sonnet*","anthropic/*sonnet*"]}},"container":{"imageTag":"0.25.41,squid=sha256:1260445d25968dbf3ae70143964177a0e5914cf2ce07a6117f7d3caec6c3e3c4,agent=sha256:cb2b565d070116d4b67e355775340528b5a2c3cb18b2c9049638bcc2df681770,api-proxy=sha256:fadd0de387209f69a9a7a1b8722bb5e7fdfb80ba9749a5c60f0e4cd7582a74d0"}}' > "${RUNNER_TEMP}/gh-aw/awf-config.json" && cp "${RUNNER_TEMP}/gh-aw/awf-config.json" /tmp/gh-aw/awf-config.json
# shellcheck disable=SC1003
sudo -E awf --config "${RUNNER_TEMP}/gh-aw/awf-config.json" --container-workdir "${GITHUB_WORKSPACE}" --mount "${RUNNER_TEMP}/gh-aw:${RUNNER_TEMP}/gh-aw:ro" --mount "${RUNNER_TEMP}/gh-aw:/host${RUNNER_TEMP}/gh-aw:ro" --env-all --exclude-env COPILOT_GITHUB_TOKEN --exclude-env GITHUB_MCP_SERVER_TOKEN --exclude-env MCP_GATEWAY_API_KEY --log-level info --proxy-logs-dir /tmp/gh-aw/sandbox/firewall/logs --audit-dir /tmp/gh-aw/sandbox/firewall/audit --enable-host-access --allow-host-ports 80,443,8080 --skip-pull \
-- /bin/bash -c 'export PATH="${RUNNER_TEMP}/gh-aw/mcp-cli/bin:$PATH" && export PATH="$(find /opt/hostedtoolcache /home/runner/work/_tool -maxdepth 4 -type d -name bin 2>/dev/null | tr '\''\n'\'' '\'':'\'')$PATH"; [ -n "$GOROOT" ] && export PATH="$GOROOT/bin:$PATH" || true && GH_AW_NODE_EXEC="${GH_AW_NODE_BIN:-}"; if [ -z "$GH_AW_NODE_EXEC" ] || [ ! -x "$GH_AW_NODE_EXEC" ]; then GH_AW_NODE_EXEC="$(command -v node 2>/dev/null || echo node)"; fi; "$GH_AW_NODE_EXEC" ${RUNNER_TEMP}/gh-aw/actions/copilot_harness.cjs /usr/local/bin/copilot --add-dir /tmp/gh-aw/ --log-level all --log-dir /tmp/gh-aw/sandbox/agent/logs/ --disable-builtin-mcps --no-ask-user --allow-all-tools --allow-all-paths --add-dir "${GITHUB_WORKSPACE}" --prompt-file /tmp/gh-aw/aw-prompts/prompt.txt' 2>&1 | tee -a /tmp/gh-aw/agent-stdio.log
env:
+ AWF_REFLECT_ENABLED: 1
COPILOT_AGENT_RUNNER_TYPE: STANDALONE
COPILOT_API_KEY: dummy-byok-key-for-offline-mode
COPILOT_GITHUB_TOKEN: ${{ secrets.COPILOT_GITHUB_TOKEN }}
@@ -780,7 +789,7 @@ jobs:
GH_AW_PHASE: agent
GH_AW_PROMPT: /tmp/gh-aw/aw-prompts/prompt.txt
GH_AW_SAFE_OUTPUTS: ${{ steps.set-runtime-paths.outputs.GH_AW_SAFE_OUTPUTS }}
- GH_AW_VERSION: v0.71.5
+ GH_AW_VERSION: v0.72.1
GITHUB_API_URL: ${{ github.api_url }}
GITHUB_AW: true
GITHUB_COPILOT_INTEGRATION_ID: agentic-workflows
@@ -896,7 +905,7 @@ jobs:
run: |
# Fix permissions on firewall logs/audit dirs so they can be uploaded as artifacts
# AWF runs with sudo, creating files owned by root
- sudo chmod -R a+r /tmp/gh-aw/sandbox/firewall 2>/dev/null || true
+ sudo chmod -R a+rX /tmp/gh-aw/sandbox/firewall 2>/dev/null || true
# Only run awf logs summary if awf command exists (it may not be installed if workflow failed before install step)
if command -v awf &> /dev/null; then
awf logs summary | tee -a "$GITHUB_STEP_SUMMARY"
@@ -981,7 +990,7 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+ uses: github/gh-aw-actions/setup@bc56a0cad2f450c562810785ef38649c04db812a # v0.72.1
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
@@ -1108,6 +1117,7 @@ jobs:
GH_AW_RUN_URL: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
GH_AW_WORKFLOW_NAME: ".NET for Apple Platforms PR Reviewer"
GH_AW_AGENT_CONCLUSION: ${{ needs.agent.result }}
+ GH_AW_SAFE_OUTPUTS_RESULT: ${{ needs.safe_outputs.result }}
GH_AW_DETECTION_CONCLUSION: ${{ needs.detection.outputs.detection_conclusion }}
GH_AW_DETECTION_REASON: ${{ needs.detection.outputs.detection_reason }}
with:
@@ -1134,7 +1144,7 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+ uses: github/gh-aw-actions/setup@bc56a0cad2f450c562810785ef38649c04db812a # v0.72.1
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
@@ -1168,7 +1178,7 @@ jobs:
rm -rf /tmp/gh-aw/sandbox/firewall/logs
rm -rf /tmp/gh-aw/sandbox/firewall/audit
- name: Download container images
- run: bash "${RUNNER_TEMP}/gh-aw/actions/download_docker_images.sh" ghcr.io/github/gh-aw-firewall/agent:0.25.40@sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504 ghcr.io/github/gh-aw-firewall/api-proxy:0.25.40@sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280 ghcr.io/github/gh-aw-firewall/squid:0.25.40@sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/download_docker_images.sh" ghcr.io/github/gh-aw-firewall/agent:0.25.41@sha256:cb2b565d070116d4b67e355775340528b5a2c3cb18b2c9049638bcc2df681770 ghcr.io/github/gh-aw-firewall/api-proxy:0.25.41@sha256:fadd0de387209f69a9a7a1b8722bb5e7fdfb80ba9749a5c60f0e4cd7582a74d0 ghcr.io/github/gh-aw-firewall/squid:0.25.41@sha256:1260445d25968dbf3ae70143964177a0e5914cf2ce07a6117f7d3caec6c3e3c4
- name: Check if detection needed
id: detection_guard
if: always()
@@ -1231,7 +1241,7 @@ jobs:
env:
GH_HOST: github.com
- name: Install AWF binary
- run: bash "${RUNNER_TEMP}/gh-aw/actions/install_awf_binary.sh" v0.25.40
+ run: bash "${RUNNER_TEMP}/gh-aw/actions/install_awf_binary.sh" v0.25.41
- name: Execute GitHub Copilot CLI
if: always() && steps.detection_guard.outputs.run_detection == 'true'
continue-on-error: true
@@ -1244,18 +1254,19 @@ jobs:
GH_AW_NODE_BIN=$(command -v node 2>/dev/null || true)
export GH_AW_NODE_BIN
(umask 177 && touch /tmp/gh-aw/threat-detection/detection.log)
- printf '%s\n' '{"$schema":"https://github.com/github/gh-aw-firewall/releases/download/v0.25.40/awf-config.schema.json","network":{"allowDomains":["api.business.githubcopilot.com","api.enterprise.githubcopilot.com","api.github.com","api.githubcopilot.com","api.individual.githubcopilot.com","github.com","host.docker.internal","telemetry.enterprise.githubcopilot.com"]},"apiProxy":{"enabled":true},"container":{"imageTag":"0.25.40,squid=sha256:b084f4a2c771f584ee68084ced52fa6b3245197a1889645d817462d307d3ac51,agent=sha256:14ff567e8d9d4c2fbc5e55c973488381c71d7e0fdbe72d30ee7b8a738fd86504,api-proxy=sha256:2883ca3e5ae9f330cafdd9345bfd4ae17fc8da36c96d4c9a1f76e922b4c45280,cli-proxy=sha256:3e7152911d4b4b7b97beef9d3d7d924ff7902227e86001ef3838fb728d5d514c"}}' > "${RUNNER_TEMP}/gh-aw/awf-config.json" && cp "${RUNNER_TEMP}/gh-aw/awf-config.json" /tmp/gh-aw/awf-config.json
+ printf '%s\n' '{"$schema":"https://github.com/github/gh-aw-firewall/releases/download/v0.25.41/awf-config.schema.json","network":{"allowDomains":["api.business.githubcopilot.com","api.enterprise.githubcopilot.com","api.github.com","api.githubcopilot.com","api.individual.githubcopilot.com","github.com","host.docker.internal","telemetry.enterprise.githubcopilot.com"]},"apiProxy":{"enabled":true},"container":{"imageTag":"0.25.41"}}' > "${RUNNER_TEMP}/gh-aw/awf-config.json" && cp "${RUNNER_TEMP}/gh-aw/awf-config.json" /tmp/gh-aw/awf-config.json
# shellcheck disable=SC1003
sudo -E awf --config "${RUNNER_TEMP}/gh-aw/awf-config.json" --container-workdir "${GITHUB_WORKSPACE}" --mount "${RUNNER_TEMP}/gh-aw:${RUNNER_TEMP}/gh-aw:ro" --mount "${RUNNER_TEMP}/gh-aw:/host${RUNNER_TEMP}/gh-aw:ro" --env-all --exclude-env COPILOT_GITHUB_TOKEN --log-level info --proxy-logs-dir /tmp/gh-aw/sandbox/firewall/logs --audit-dir /tmp/gh-aw/sandbox/firewall/audit --enable-host-access --allow-host-ports 80,443,8080 --skip-pull \
-- /bin/bash -c 'export PATH="$(find /opt/hostedtoolcache /home/runner/work/_tool -maxdepth 4 -type d -name bin 2>/dev/null | tr '\''\n'\'' '\'':'\'')$PATH"; [ -n "$GOROOT" ] && export PATH="$GOROOT/bin:$PATH" || true && GH_AW_NODE_EXEC="${GH_AW_NODE_BIN:-}"; if [ -z "$GH_AW_NODE_EXEC" ] || [ ! -x "$GH_AW_NODE_EXEC" ]; then GH_AW_NODE_EXEC="$(command -v node 2>/dev/null || echo node)"; fi; "$GH_AW_NODE_EXEC" ${RUNNER_TEMP}/gh-aw/actions/copilot_harness.cjs /usr/local/bin/copilot --add-dir /tmp/gh-aw/ --log-level all --log-dir /tmp/gh-aw/sandbox/agent/logs/ --disable-builtin-mcps --no-ask-user --allow-all-tools --add-dir "${GITHUB_WORKSPACE}" --prompt-file /tmp/gh-aw/aw-prompts/prompt.txt' 2>&1 | tee -a /tmp/gh-aw/threat-detection/detection.log
env:
+ AWF_REFLECT_ENABLED: 1
COPILOT_AGENT_RUNNER_TYPE: STANDALONE
COPILOT_API_KEY: dummy-byok-key-for-offline-mode
COPILOT_GITHUB_TOKEN: ${{ secrets.COPILOT_GITHUB_TOKEN }}
COPILOT_MODEL: claude-sonnet-4.5
GH_AW_PHASE: detection
GH_AW_PROMPT: /tmp/gh-aw/aw-prompts/prompt.txt
- GH_AW_VERSION: v0.71.5
+ GH_AW_VERSION: v0.72.1
GITHUB_API_URL: ${{ github.api_url }}
GITHUB_AW: true
GITHUB_COPILOT_INTEGRATION_ID: agentic-workflows
@@ -1317,7 +1328,7 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+ uses: github/gh-aw-actions/setup@bc56a0cad2f450c562810785ef38649c04db812a # v0.72.1
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
@@ -1380,7 +1391,7 @@ jobs:
steps:
- name: Setup Scripts
id: setup
- uses: github/gh-aw-actions/setup@b8068426813005612b960b5ab0b8bd2c27142323 # v0.71.5
+ uses: github/gh-aw-actions/setup@bc56a0cad2f450c562810785ef38649c04db812a # v0.72.1
with:
destination: ${{ runner.temp }}/gh-aw/actions
job-name: ${{ github.job }}
From 2daba49c5f20e620a620da6ac1cfc2ec47406fbf Mon Sep 17 00:00:00 2001
From: Copilot <198982749+Copilot@users.noreply.github.com>
Date: Wed, 13 May 2026 13:46:16 +0000
Subject: [PATCH 047/156] [tests] Treat missing expected cookie as transient
network failure in TestNSurlSessionHandlerCookieContainerSetCookie (#25420)
- [x] Fix `TestNSurlSessionHandlerCookieContainerSetCookie` to treat missing expected cookie as transient network failure (ignore in CI)
- [x] Address race condition: move `CookieContainer` inspection after `!completed` guard to avoid concurrent access
- [x] Address exception masking: separate `!completed` and `!hasExpectedCookie` CI-ignore guards so real exceptions still fail the test
Fixes https://github.com/dotnet/macios/issues/25385.
---------
Co-authored-by: rolfbjarne <249268+rolfbjarne@users.noreply.github.com>
---
tests/monotouch-test/System.Net.Http/MessageHandlers.cs | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/tests/monotouch-test/System.Net.Http/MessageHandlers.cs b/tests/monotouch-test/System.Net.Http/MessageHandlers.cs
index 03f759bdf6c6..7fe1bbc448db 100644
--- a/tests/monotouch-test/System.Net.Http/MessageHandlers.cs
+++ b/tests/monotouch-test/System.Net.Http/MessageHandlers.cs
@@ -201,7 +201,10 @@ public void TestNSurlSessionHandlerCookieContainerSetCookie ()
Assert.IsNull (ex, "Exception");
Assert.IsNotNull (nativeCookieResult, "Native cookies result");
var cookiesFromServer = cookieContainer.GetCookies (new Uri (url));
- Assert.That (cookiesFromServer.Cast ().Any (v => v.Name == "cookie" && v.Value == "chocolate-chip"), Is.True, "Cookies received from server.");
+ var hasExpectedCookie = cookiesFromServer.Cast ().Any (v => v.Name == "cookie" && v.Value == "chocolate-chip");
+ if (!hasExpectedCookie)
+ TestRuntime.IgnoreInCI ("Transient network failure - ignore in CI");
+ Assert.That (hasExpectedCookie, Is.True, "Cookies received from server.");
}
[Test]
From ae1375a10fa36521a34709e2c86eda851d586617 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Wed, 13 May 2026 16:17:45 +0200
Subject: [PATCH 048/156] [src] Attempt to fix a race condition with
NSObject.GetData. Fixes #25373. (#25399)
Use a ConditionalWeakTable to store the additional native memory we need for each NSObject.
A bit of testing seems to indicate entries aren't removed from ConditionalWeakTable until they're deallocated (or at the very least can't be resurrected), however a value in the ConditionalWeakTable are *finalized* as soon as the corresponding key is finalizable, which means we need to do some shenanigans to make it work:
* We create a class to store the native memory we want to use.
* We create one instance of this class for each NSObject instance, and add it
to a static ConditionalWeakTable.
* In this class' finalizer we free the native memory, but only if the NSObject
has been garbage collected.
* We determine whether the NSObject has been garbage collected by creating a
weak resurrection-tracking GCHandle to the NSObject, and if we determine the
NSObject hasn't been garbage collected, we re-schedule the finalizer.
This hopefully fixes #25373, where for some reason (I wasn't able to reproduce the problem unfortunately), live NSObject instances ended up with a null pointer for the additional native memory.
Fixes https://github.com/dotnet/macios/issues/25373.
---
src/Foundation/NSObject2.cs | 170 ++++++------------
src/ObjCRuntime/Runtime.cs | 8 +
...alyst-MonoVM-interpreter-preservedapis.txt | 32 +---
.../MacCatalyst-MonoVM-interpreter-size.txt | 10 +-
.../MacCatalyst-MonoVM-preservedapis.txt | 32 +---
.../expected/MacCatalyst-MonoVM-size.txt | 14 +-
...atalyst-NativeAOT-TrimmableStatic-size.txt | 6 +-
.../expected/MacCatalyst-NativeAOT-size.txt | 4 +-
...reCLR-Interpreter-TrimmableStatic-size.txt | 10 +-
.../MacOSX-CoreCLR-Interpreter-size.txt | 10 +-
.../MacOSX-NativeAOT-TrimmableStatic-size.txt | 6 +-
.../expected/MacOSX-NativeAOT-size.txt | 4 +-
.../TVOS-MonoVM-interpreter-preservedapis.txt | 32 +---
.../expected/TVOS-MonoVM-interpreter-size.txt | 10 +-
.../expected/TVOS-MonoVM-preservedapis.txt | 32 +---
.../UnitTests/expected/TVOS-MonoVM-size.txt | 14 +-
.../TVOS-NativeAOT-TrimmableStatic-size.txt | 6 +-
.../expected/TVOS-NativeAOT-size.txt | 6 +-
.../iOS-MonoVM-interpreter-preservedapis.txt | 32 +---
.../expected/iOS-MonoVM-interpreter-size.txt | 10 +-
.../expected/iOS-MonoVM-preservedapis.txt | 32 +---
.../UnitTests/expected/iOS-MonoVM-size.txt | 12 +-
.../iOS-NativeAOT-TrimmableStatic-size.txt | 6 +-
.../UnitTests/expected/iOS-NativeAOT-size.txt | 6 +-
24 files changed, 182 insertions(+), 322 deletions(-)
diff --git a/src/Foundation/NSObject2.cs b/src/Foundation/NSObject2.cs
index f27d8abdd8fb..00a5bdb5ac64 100644
--- a/src/Foundation/NSObject2.cs
+++ b/src/Foundation/NSObject2.cs
@@ -124,47 +124,46 @@ struct NSObjectData {
public NSObject.Flags flags;
}
- class NSObjectDataHandle : CriticalHandle {
- bool invalidated;
+ // This type wraps native memory that will track an NSObject, and free the native memory
+ // once the NSObject is finalized and completely gone / unresurrectable. It does so by
+ // creating a GCHandle that tracks the NSObject in question, and if this instance's
+ // finalizer is called, but the NSObject is still reachable, then re-schedule this instance's
+ // finalizer to run again later.
+ // This is similar to how NativeAOT handles the tagged memory returned by ObjectiveCMarshal.CreateReferenceTrackingHandle
+ // * https://github.com/AustinWise/runtime/blob/2bd10ad43df967950657ae0ade1f899dc1b18a41/src/coreclr/nativeaot/System.Private.CoreLib/src/System/Runtime/InteropServices/ObjectiveCMarshal.NativeAot.cs#L15
+ // * https://github.com/AustinWise/runtime/blob/2bd10ad43df967950657ae0ade1f899dc1b18a41/src/coreclr/nativeaot/System.Private.CoreLib/src/System/Runtime/InteropServices/ObjectiveCMarshal.NativeAot.cs#L59-L71
+ // * https://github.com/AustinWise/runtime/blob/2bd10ad43df967950657ae0ade1f899dc1b18a41/src/coreclr/nativeaot/System.Private.CoreLib/src/System/Runtime/InteropServices/ObjectiveCMarshal.NativeAot.cs#L181-L185
+ unsafe class NSObjectDataHandle {
+ NSObjectData* data;
+ GCHandle handle;
+
+ public NSObjectData* Data { get => data; }
+
public NSObjectDataHandle ()
- : base (IntPtr.Zero)
{
- unsafe {
- this.handle = (IntPtr) NativeMemory.AllocZeroed ((nuint) sizeof (NSObjectData));
- }
+ data = Runtime.AllocZeroed ();
}
- public NSObjectDataHandle (IntPtr handle)
- : base (handle)
+ public void CreateHandle (NSObject obj)
{
+ handle = GCHandle.Alloc (obj, GCHandleType.WeakTrackResurrection);
}
- public void Invalidate ()
+ ~NSObjectDataHandle ()
{
- invalidated = true;
- }
+ var handleAllocated = handle.IsAllocated;
- public unsafe NSObjectData* Data {
- get => (NSObjectData*) handle;
- }
+ if (handleAllocated && handle.Target is not null) {
+ // The NSObject instance isn't gone yet, we have to try again later.
+ GC.ReRegisterForFinalize (this);
+ return;
+ }
- public override bool IsInvalid {
- get => handle == IntPtr.Zero;
- }
+ NativeMemory.Free (data);
+ data = null;
- protected override bool ReleaseHandle ()
- {
- if (handle != IntPtr.Zero) {
- if (invalidated) {
- // nothing to do here.
- } else {
- unsafe {
- NativeMemory.Free ((void*) handle);
- }
- }
- }
- handle = IntPtr.Zero;
- return true;
+ if (handleAllocated)
+ handle.Free ();
}
}
#endif
@@ -195,51 +194,39 @@ public partial class NSObject : INativeObject
/// The assembly containing the platform-specific Foundation types.
public static readonly Assembly PlatformAssembly = typeof (NSObject).Assembly;
- // This is exclusively for Mono
- unsafe NSObjectData* __data_for_mono; // Read directly from several places in the runtime
-
- unsafe NativeHandle handle {
- get => GetData ()->handle;
- set => GetData ()->handle = value;
- }
+#pragma warning disable CS8618 // "Non-nullable field '...' must contain a non-null value when exiting constructor.": this field is always non-null, because NSObject.Initialize is called before anything else is done.
+ static ConditionalWeakTable data_table;
+#pragma warning restore CS8618
// The NSObjectData contains some data we want to keep in native memory, so that it can be accessed
// safely from native code without having to make sure the GC doesn't move the memory around. Among
// other things, this means it's accessible from threads that has never seen/run managed code without
// having to attach those threads to to the managed runtime.
- NSObjectDataHandle? data_handle;
-
- internal unsafe NSObjectData* GetData ()
- {
- var rv = AllocateData ().Data;
-
- if (rv is null) {
- // Throwing an exception here is better than returning a null pointer, because that will crash the process when the pointer is dereferenced
- // (and none of the callers can do anything useful with a null pointer anyway).
- throw new ObjectDisposedException ($"This object (of type {GetType ().Name}) does not have a data pointer anymore, possibly because of a race condition. Please file a bug at https://github.com/dotnet/macios/issues.");
- }
+ IntPtr /* unsafe NSObjectData* */ __data; // Read directly from several places in the runtime
- return rv;
+ unsafe NativeHandle handle {
+ get => GetData ()->handle;
+ set => GetData ()->handle = value;
}
- unsafe NSObjectDataHandle AllocateData ()
+ internal unsafe NSObjectData* GetData ()
{
- var dh = data_handle;
- if (dh is not null)
- return dh;
-
- var data = new NSObjectDataHandle ();
- var previousValue = Interlocked.CompareExchange (ref data_handle, data, null);
- if (previousValue is not null) {
- // somebody beat us to the allocation and assignment.
- data.Dispose ();
- return previousValue;
+ var data = __data;
+ if (data != IntPtr.Zero)
+ return (NSObjectData*) data;
+
+ var data_handle = new NSObjectDataHandle ();
+ var existing_data = Interlocked.CompareExchange (ref __data, (IntPtr) data_handle.Data, IntPtr.Zero);
+ if (existing_data != IntPtr.Zero) {
+ // return the existing data, the GC will collect the other one we just created
+ return (NSObjectData*) existing_data;
}
-
- if (!Runtime.IsCoreCLR) // This condition (and the assignment to __handle_for_mono if applicable) is trimmed away by the linker.
- __data_for_mono = data.Data;
-
- return data;
+ // tell the data handle we just created to track us
+ data_handle.CreateHandle (this);
+ // make sure the data isn't freed before this NSObject is collected, but also
+ // that it is freed after this NSObject is collected.
+ data_table.Add (this, data_handle);
+ return data_handle.Data;
}
unsafe Flags flags {
@@ -407,6 +394,7 @@ unsafe NativeHandle GetSuper ()
internal static NativeHandle Initialize ()
{
+ data_table = new ConditionalWeakTable ();
return class_ptr;
}
@@ -1115,62 +1103,10 @@ protected virtual void Dispose (bool disposing)
ReleaseManagedRef ();
} else {
NSObject_Disposer.Add (this);
- RecreateDataHandle ();
}
}
}
- void RecreateDataHandle ()
- {
- // OK, this code is _weird_.
- // We need to delay the deletion of the native memory pointed to by data_handle until
- // after this instance has been collected. A CriticalHandle seems to fit this purpose like a glove, until
- // you realize that a CriticalHandle is only kept alive until the parent object _becomes finalizable_,
- // not _is collected_, which is very different - in other words, resurrected objects don't keep CriticalHandles
- // they contain alive. This is a problem because every single managed NSObject instance is resurrected, and we
- // need the native memory to stay alive after resurrection.
- //
- // So this solution depends on a few bits:
- // * At this point, this instance may have become finalizable, but the native memory shouldn't have been freed yet.
- // * The original NSObjectDataHandle (aka CriticalHandle) will be collected in this/upcoming GC cycle, and can't
- // be trusted to keep the native memory alive anymore.
- // * So we just create a new one, pointing to the same native memory, and replace the original NSObjectDataHandle (aka
- // CriticalHandle) with it
- // * This works, because since this instance has become / will become resurrected, it's not finalizable anymore,
- // and it will keep the new NSObjectDataHandle instance (and the native memory it points to) alive.
- // * Now if this instance is deemed finalizable, and then resurrected *again*, bad things will likely happen. This
- // is a bit more unlikely though, because we don't re-register the finalizer for execution, so unless somebody
- // else does that, it's quite unlikely this instance will become resurrected a second time.
- var previous_data = data_handle;
- if (previous_data is null) {
- var msg = $"This object (of type {GetType ().Name}) does not have an existing data pointer, possibly because of a race condition. Please file a bug at https://github.com/dotnet/macios/issues.";
-#if CONSISTENCY_CHECKS
- throw new InvalidOperationException (msg);
-#else
- Runtime.NSLog (msg);
- return;
-#endif
- }
-
- unsafe {
- data_handle = new NSObjectDataHandle ((IntPtr) previous_data.Data);
- }
-
- if (previous_data.IsInvalid) {
- var msg = $"This object (of type {GetType ().Name}) does not have valid data pointer, possibly because of a race condition. Please file a bug at https://github.com/dotnet/macios/issues.";
-#if CONSISTENCY_CHECKS
- throw new InvalidOperationException (msg);
-#else
- Runtime.NSLog (msg);
- return;
-#endif
- }
-
- previous_data.Invalidate ();
- // Don't dispose previous_data, because another thread might be referencing it, and trying to access its pointer - which is still valid.
- // The GC will dispose of previous_data when its not accessible anymore.
- }
-
[Register ("__NSObject_Disposer")]
[Preserve (AllMembers = true)]
internal class NSObject_Disposer : NSObject {
diff --git a/src/ObjCRuntime/Runtime.cs b/src/ObjCRuntime/Runtime.cs
index 55378e8e6128..20665071523d 100644
--- a/src/ObjCRuntime/Runtime.cs
+++ b/src/ObjCRuntime/Runtime.cs
@@ -19,6 +19,7 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Text;
+using System.Threading;
using CoreFoundation;
using Registrar;
@@ -2857,6 +2858,13 @@ internal static bool ValidateObjectPointers {
get => validate_object_pointers;
set => validate_object_pointers = value;
}
+
+ /// Allocate unmanaged zeroed memory of the specified struct.
+ /// Call to free the returned pointer.
+ internal unsafe static T* AllocZeroed () where T : unmanaged
+ {
+ return (T*) NativeMemory.AllocZeroed ((nuint) sizeof (T));
+ }
}
diff --git a/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-preservedapis.txt b/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-preservedapis.txt
index 52362f2102f1..a8fb5747d13e 100644
--- a/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-preservedapis.txt
+++ b/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-preservedapis.txt
@@ -121,7 +121,6 @@ Microsoft.MacCatalyst.dll:Foundation.NSObject..ctor()
Microsoft.MacCatalyst.dll:Foundation.NSObject..ctor(Foundation.NSObjectFlag)
Microsoft.MacCatalyst.dll:Foundation.NSObject..ctor(ObjCRuntime.NativeHandle, System.Boolean)
Microsoft.MacCatalyst.dll:Foundation.NSObject..ctor(ObjCRuntime.NativeHandle)
-Microsoft.MacCatalyst.dll:Foundation.NSObject.AllocateData()
Microsoft.MacCatalyst.dll:Foundation.NSObject.AllocIfNeeded()
Microsoft.MacCatalyst.dll:Foundation.NSObject.ClearHandle()
Microsoft.MacCatalyst.dll:Foundation.NSObject.ConformsToProtocol(ObjCRuntime.NativeHandle)
@@ -160,7 +159,6 @@ Microsoft.MacCatalyst.dll:Foundation.NSObject.InitializeObject(System.Boolean)
Microsoft.MacCatalyst.dll:Foundation.NSObject.InvokeConformsToProtocol(ObjCRuntime.NativeHandle)
Microsoft.MacCatalyst.dll:Foundation.NSObject.IsEqual(Foundation.NSObject)
Microsoft.MacCatalyst.dll:Foundation.NSObject.IsProtocol(System.Type, System.IntPtr)
-Microsoft.MacCatalyst.dll:Foundation.NSObject.RecreateDataHandle()
Microsoft.MacCatalyst.dll:Foundation.NSObject.ReleaseManagedRef()
Microsoft.MacCatalyst.dll:Foundation.NSObject.set_disposed(System.Boolean)
Microsoft.MacCatalyst.dll:Foundation.NSObject.set_flags(Foundation.NSObject/Flags)
@@ -199,16 +197,13 @@ Microsoft.MacCatalyst.dll:Foundation.NSObject/XamarinGCHandleFlags Foundation.NS
Microsoft.MacCatalyst.dll:Foundation.NSObject/XamarinGCHandleFlags Foundation.NSObject/XamarinGCHandleFlags::InitialSet
Microsoft.MacCatalyst.dll:Foundation.NSObject/XamarinGCHandleFlags Foundation.NSObject/XamarinGCHandleFlags::None
Microsoft.MacCatalyst.dll:Foundation.NSObjectData
-Microsoft.MacCatalyst.dll:Foundation.NSObjectData* Foundation.NSObject::__data_for_mono
+Microsoft.MacCatalyst.dll:Foundation.NSObjectData* Foundation.NSObjectDataHandle::data
Microsoft.MacCatalyst.dll:Foundation.NSObjectData* Foundation.NSObjectDataHandle::Data()
Microsoft.MacCatalyst.dll:Foundation.NSObjectDataHandle
-Microsoft.MacCatalyst.dll:Foundation.NSObjectDataHandle Foundation.NSObject::data_handle
Microsoft.MacCatalyst.dll:Foundation.NSObjectDataHandle..ctor()
-Microsoft.MacCatalyst.dll:Foundation.NSObjectDataHandle..ctor(System.IntPtr)
+Microsoft.MacCatalyst.dll:Foundation.NSObjectDataHandle.CreateHandle(Foundation.NSObject)
+Microsoft.MacCatalyst.dll:Foundation.NSObjectDataHandle.Finalize()
Microsoft.MacCatalyst.dll:Foundation.NSObjectDataHandle.get_Data()
-Microsoft.MacCatalyst.dll:Foundation.NSObjectDataHandle.get_IsInvalid()
-Microsoft.MacCatalyst.dll:Foundation.NSObjectDataHandle.Invalidate()
-Microsoft.MacCatalyst.dll:Foundation.NSObjectDataHandle.ReleaseHandle()
Microsoft.MacCatalyst.dll:Foundation.NSObjectFlag
Microsoft.MacCatalyst.dll:Foundation.NSObjectFlag Foundation.NSObjectFlag::Empty
Microsoft.MacCatalyst.dll:Foundation.NSString
@@ -596,6 +591,7 @@ Microsoft.MacCatalyst.dll:ObjCRuntime.Runtime.g__Constru
Microsoft.MacCatalyst.dll:ObjCRuntime.Runtime.g__ConstructNSObjectViaFactoryMethod|288_0`1(ObjCRuntime.NativeHandle)
Microsoft.MacCatalyst.dll:ObjCRuntime.Runtime.AllocGCHandle(System.Object, System.Runtime.InteropServices.GCHandleType)
Microsoft.MacCatalyst.dll:ObjCRuntime.Runtime.AllocGCHandle(System.Object)
+Microsoft.MacCatalyst.dll:ObjCRuntime.Runtime.AllocZeroed`1()
Microsoft.MacCatalyst.dll:ObjCRuntime.Runtime.AppendAdditionalInformation(System.Text.StringBuilder, System.IntPtr, System.RuntimeMethodHandle)
Microsoft.MacCatalyst.dll:ObjCRuntime.Runtime.attempt_retain_nsobject(System.IntPtr, System.IntPtr*)
Microsoft.MacCatalyst.dll:ObjCRuntime.Runtime.AttemptRetainNSObject(System.IntPtr)
@@ -1215,8 +1211,6 @@ Microsoft.MacCatalyst.dll:System.Boolean Foundation.NSObject::IsDirectBinding()
Microsoft.MacCatalyst.dll:System.Boolean Foundation.NSObject::IsRegisteredToggleRef()
Microsoft.MacCatalyst.dll:System.Boolean Foundation.NSObject::RemoveFromObjectMap()
Microsoft.MacCatalyst.dll:System.Boolean Foundation.NSObject/NSObject_Disposer::draining
-Microsoft.MacCatalyst.dll:System.Boolean Foundation.NSObjectDataHandle::invalidated
-Microsoft.MacCatalyst.dll:System.Boolean Foundation.NSObjectDataHandle::IsInvalid()
Microsoft.MacCatalyst.dll:System.Boolean Foundation.ProtocolAttribute::k__BackingField
Microsoft.MacCatalyst.dll:System.Boolean Foundation.ProtocolAttribute::k__BackingField
Microsoft.MacCatalyst.dll:System.Boolean Foundation.ProtocolAttribute::IsInformal()
@@ -1337,6 +1331,7 @@ Microsoft.MacCatalyst.dll:System.Int64 Foundation.NSComparisonResult::value__
Microsoft.MacCatalyst.dll:System.IntPtr CoreFoundation.CFArray::_CFNullHandle()
Microsoft.MacCatalyst.dll:System.IntPtr CoreFoundation.CFRange::len
Microsoft.MacCatalyst.dll:System.IntPtr CoreFoundation.CFRange::loc
+Microsoft.MacCatalyst.dll:System.IntPtr Foundation.NSObject::__data
Microsoft.MacCatalyst.dll:System.IntPtr Foundation.NSObject/NSObject_Disposer::class_ptr
Microsoft.MacCatalyst.dll:System.IntPtr ObjCRuntime.AdoptsAttribute::ProtocolHandle()
Microsoft.MacCatalyst.dll:System.IntPtr ObjCRuntime.BlockCollector::block
@@ -1500,8 +1495,10 @@ Microsoft.MacCatalyst.dll:System.Reflection.MethodBase Registrar.Registrar::invo
Microsoft.MacCatalyst.dll:System.Reflection.MethodBase Registrar.Registrar/ObjCMethod::Method
Microsoft.MacCatalyst.dll:System.Reflection.PropertyInfo Registrar.Registrar/ObjCProperty::Property
Microsoft.MacCatalyst.dll:System.Reflection.TypeFilter Registrar.SharedDynamic/<>c::<>9__0_0
+Microsoft.MacCatalyst.dll:System.Runtime.CompilerServices.ConditionalWeakTable`2 Foundation.NSObject::data_table
Microsoft.MacCatalyst.dll:System.Runtime.CompilerServices.ConditionalWeakTable`2 ObjCRuntime.Runtime::block_lifetime_table
Microsoft.MacCatalyst.dll:System.Runtime.CompilerServices.ConditionalWeakTable`2 ObjCRuntime.Class::assembly_to_name
+Microsoft.MacCatalyst.dll:System.Runtime.InteropServices.GCHandle Foundation.NSObjectDataHandle::handle
Microsoft.MacCatalyst.dll:System.Runtime.InteropServices.NFloat CoreGraphics.CGRect::height
Microsoft.MacCatalyst.dll:System.Runtime.InteropServices.NFloat CoreGraphics.CGRect::width
Microsoft.MacCatalyst.dll:System.Runtime.InteropServices.NFloat CoreGraphics.CGRect::x
@@ -2724,14 +2721,12 @@ System.Private.CoreLib.dll:System.Boolean System.Runtime.CompilerServices.Runtim
System.Private.CoreLib.dll:System.Boolean System.Runtime.CompilerServices.RuntimeFeature::IsDynamicCodeCompiled()
System.Private.CoreLib.dll:System.Boolean System.Runtime.CompilerServices.RuntimeFeature::IsDynamicCodeSupported()
System.Private.CoreLib.dll:System.Boolean System.Runtime.DependentHandle::IsAllocated()
-System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.CriticalHandle::_isClosed
-System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.CriticalHandle::IsClosed()
-System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.CriticalHandle::IsInvalid()
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::BestFitMapping
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::ExactSpelling
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::PreserveSig
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::SetLastError
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::ThrowOnUnmappableChar
+System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.GCHandle::IsAllocated()
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller`1/ManagedToUnmanagedIn::_addRefd
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller`1/ManagedToUnmanagedOut::_initialized
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.Marshalling.Utf8StringMarshaller/ManagedToUnmanagedIn::_allocated
@@ -6949,7 +6944,6 @@ System.Private.CoreLib.dll:System.IntPtr System.Reflection.RuntimePropertyInfo::
System.Private.CoreLib.dll:System.IntPtr System.Reflection.RuntimePropertyInfo::prop
System.Private.CoreLib.dll:System.IntPtr System.Runtime.CompilerServices.QCallAssembly::_assembly
System.Private.CoreLib.dll:System.IntPtr System.Runtime.CompilerServices.QCallTypeHandle::_handle
-System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.CriticalHandle::handle
System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.GCHandle::_handle
System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.SafeHandle::handle
System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.WeakGCHandle`1::_handle
@@ -10849,15 +10843,6 @@ System.Private.CoreLib.dll:System.Runtime.InteropServices.CollectionsMarshal
System.Private.CoreLib.dll:System.Runtime.InteropServices.CollectionsMarshal.GetValueRefOrAddDefault`2(System.Collections.Generic.Dictionary`2, TKey, out System.Boolean&)
System.Private.CoreLib.dll:System.Runtime.InteropServices.ComImportAttribute
System.Private.CoreLib.dll:System.Runtime.InteropServices.ComImportAttribute..ctor()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle..ctor(System.IntPtr)
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Cleanup()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Dispose()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Dispose(System.Boolean)
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Finalize()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.get_IsClosed()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.get_IsInvalid()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.ReleaseHandle()
System.Private.CoreLib.dll:System.Runtime.InteropServices.DefaultDllImportSearchPathsAttribute
System.Private.CoreLib.dll:System.Runtime.InteropServices.DefaultDllImportSearchPathsAttribute..ctor(System.Runtime.InteropServices.DllImportSearchPath)
System.Private.CoreLib.dll:System.Runtime.InteropServices.DllImportAttribute
@@ -10886,6 +10871,7 @@ System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.Equals(System
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.Equals(System.Runtime.InteropServices.GCHandle)
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.Free()
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.FromIntPtr(System.IntPtr)
+System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.get_IsAllocated()
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.get_Target()
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.GetHandleValue(System.IntPtr)
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.GetHashCode()
diff --git a/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-size.txt b/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-size.txt
index ecd8aa0ec456..acd310b0378a 100644
--- a/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-size.txt
@@ -1,12 +1,12 @@
-AppBundleSize: 5,791,518 bytes (5,655.8 KB = 5.5 MB)
+AppBundleSize: 5,792,339 bytes (5,656.6 KB = 5.5 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 3,310 bytes (3.2 KB = 0.0 MB)
-Contents/Info.plist: 1,099 bytes (1.1 KB = 0.0 MB)
-Contents/MacOS/SizeTestApp: 4,566,848 bytes (4,459.8 KB = 4.4 MB)
-Contents/MonoBundle/Microsoft.MacCatalyst.dll: 158,208 bytes (154.5 KB = 0.2 MB)
+Contents/Info.plist: 1,112 bytes (1.1 KB = 0.0 MB)
+Contents/MacOS/SizeTestApp: 4,568,704 bytes (4,461.6 KB = 4.4 MB)
+Contents/MonoBundle/Microsoft.MacCatalyst.dll: 157,184 bytes (153.5 KB = 0.1 MB)
Contents/MonoBundle/runtimeconfig.bin: 1,405 bytes (1.4 KB = 0.0 MB)
Contents/MonoBundle/SizeTestApp.dll: 7,680 bytes (7.5 KB = 0.0 MB)
-Contents/MonoBundle/System.Private.CoreLib.aotdata.arm64: 41,248 bytes (40.3 KB = 0.0 MB)
+Contents/MonoBundle/System.Private.CoreLib.aotdata.arm64: 41,224 bytes (40.3 KB = 0.0 MB)
Contents/MonoBundle/System.Private.CoreLib.dll: 998,400 bytes (975.0 KB = 1.0 MB)
Contents/MonoBundle/System.Runtime.dll: 5,120 bytes (5.0 KB = 0.0 MB)
Contents/MonoBundle/System.Runtime.InteropServices.dll: 8,192 bytes (8.0 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-preservedapis.txt b/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-preservedapis.txt
index 09e20015e7f9..36ed14ba4f7c 100644
--- a/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-preservedapis.txt
+++ b/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-preservedapis.txt
@@ -107,7 +107,6 @@ Microsoft.MacCatalyst.dll:Foundation.NSObject..ctor()
Microsoft.MacCatalyst.dll:Foundation.NSObject..ctor(Foundation.NSObjectFlag)
Microsoft.MacCatalyst.dll:Foundation.NSObject..ctor(ObjCRuntime.NativeHandle, System.Boolean)
Microsoft.MacCatalyst.dll:Foundation.NSObject..ctor(ObjCRuntime.NativeHandle)
-Microsoft.MacCatalyst.dll:Foundation.NSObject.AllocateData()
Microsoft.MacCatalyst.dll:Foundation.NSObject.AllocIfNeeded()
Microsoft.MacCatalyst.dll:Foundation.NSObject.ClearHandle()
Microsoft.MacCatalyst.dll:Foundation.NSObject.ConformsToProtocol(ObjCRuntime.NativeHandle)
@@ -144,7 +143,6 @@ Microsoft.MacCatalyst.dll:Foundation.NSObject.InitializeHandle(ObjCRuntime.Nativ
Microsoft.MacCatalyst.dll:Foundation.NSObject.InitializeObject(System.Boolean)
Microsoft.MacCatalyst.dll:Foundation.NSObject.InvokeConformsToProtocol(ObjCRuntime.NativeHandle)
Microsoft.MacCatalyst.dll:Foundation.NSObject.IsEqual(Foundation.NSObject)
-Microsoft.MacCatalyst.dll:Foundation.NSObject.RecreateDataHandle()
Microsoft.MacCatalyst.dll:Foundation.NSObject.ReleaseManagedRef()
Microsoft.MacCatalyst.dll:Foundation.NSObject.set_disposed(System.Boolean)
Microsoft.MacCatalyst.dll:Foundation.NSObject.set_flags(Foundation.NSObject/Flags)
@@ -182,16 +180,13 @@ Microsoft.MacCatalyst.dll:Foundation.NSObject/XamarinGCHandleFlags Foundation.NS
Microsoft.MacCatalyst.dll:Foundation.NSObject/XamarinGCHandleFlags Foundation.NSObject/XamarinGCHandleFlags::InitialSet
Microsoft.MacCatalyst.dll:Foundation.NSObject/XamarinGCHandleFlags Foundation.NSObject/XamarinGCHandleFlags::None
Microsoft.MacCatalyst.dll:Foundation.NSObjectData
-Microsoft.MacCatalyst.dll:Foundation.NSObjectData* Foundation.NSObject::__data_for_mono
+Microsoft.MacCatalyst.dll:Foundation.NSObjectData* Foundation.NSObjectDataHandle::data
Microsoft.MacCatalyst.dll:Foundation.NSObjectData* Foundation.NSObjectDataHandle::Data()
Microsoft.MacCatalyst.dll:Foundation.NSObjectDataHandle
-Microsoft.MacCatalyst.dll:Foundation.NSObjectDataHandle Foundation.NSObject::data_handle
Microsoft.MacCatalyst.dll:Foundation.NSObjectDataHandle..ctor()
-Microsoft.MacCatalyst.dll:Foundation.NSObjectDataHandle..ctor(System.IntPtr)
+Microsoft.MacCatalyst.dll:Foundation.NSObjectDataHandle.CreateHandle(Foundation.NSObject)
+Microsoft.MacCatalyst.dll:Foundation.NSObjectDataHandle.Finalize()
Microsoft.MacCatalyst.dll:Foundation.NSObjectDataHandle.get_Data()
-Microsoft.MacCatalyst.dll:Foundation.NSObjectDataHandle.get_IsInvalid()
-Microsoft.MacCatalyst.dll:Foundation.NSObjectDataHandle.Invalidate()
-Microsoft.MacCatalyst.dll:Foundation.NSObjectDataHandle.ReleaseHandle()
Microsoft.MacCatalyst.dll:Foundation.NSObjectFlag
Microsoft.MacCatalyst.dll:Foundation.NSObjectFlag Foundation.NSObjectFlag::Empty
Microsoft.MacCatalyst.dll:Foundation.ProtocolAttribute
@@ -454,6 +449,7 @@ Microsoft.MacCatalyst.dll:ObjCRuntime.Runtime.g__Constru
Microsoft.MacCatalyst.dll:ObjCRuntime.Runtime.g__ConstructNSObjectViaFactoryMethod|288_0`1(ObjCRuntime.NativeHandle)
Microsoft.MacCatalyst.dll:ObjCRuntime.Runtime.AllocGCHandle(System.Object, System.Runtime.InteropServices.GCHandleType)
Microsoft.MacCatalyst.dll:ObjCRuntime.Runtime.AllocGCHandle(System.Object)
+Microsoft.MacCatalyst.dll:ObjCRuntime.Runtime.AllocZeroed`1()
Microsoft.MacCatalyst.dll:ObjCRuntime.Runtime.AppendAdditionalInformation(System.Text.StringBuilder, System.IntPtr, System.RuntimeMethodHandle)
Microsoft.MacCatalyst.dll:ObjCRuntime.Runtime.attempt_retain_nsobject(System.IntPtr, System.IntPtr*)
Microsoft.MacCatalyst.dll:ObjCRuntime.Runtime.AttemptRetainNSObject(System.IntPtr)
@@ -667,8 +663,6 @@ Microsoft.MacCatalyst.dll:System.Boolean Foundation.NSObject::InFinalizerQueue()
Microsoft.MacCatalyst.dll:System.Boolean Foundation.NSObject::IsDirectBinding()
Microsoft.MacCatalyst.dll:System.Boolean Foundation.NSObject::IsRegisteredToggleRef()
Microsoft.MacCatalyst.dll:System.Boolean Foundation.NSObject/NSObject_Disposer::draining
-Microsoft.MacCatalyst.dll:System.Boolean Foundation.NSObjectDataHandle::invalidated
-Microsoft.MacCatalyst.dll:System.Boolean Foundation.NSObjectDataHandle::IsInvalid()
Microsoft.MacCatalyst.dll:System.Boolean Foundation.ProtocolAttribute::k__BackingField
Microsoft.MacCatalyst.dll:System.Boolean Foundation.RegisterAttribute::is_wrapper
Microsoft.MacCatalyst.dll:System.Boolean Foundation.RegisterAttribute::IsWrapper()
@@ -724,6 +718,7 @@ Microsoft.MacCatalyst.dll:System.Int32 ObjCRuntime.TransientString/Encoding::val
Microsoft.MacCatalyst.dll:System.IntPtr CoreFoundation.CFArray::_CFNullHandle()
Microsoft.MacCatalyst.dll:System.IntPtr CoreFoundation.CFRange::len
Microsoft.MacCatalyst.dll:System.IntPtr CoreFoundation.CFRange::loc
+Microsoft.MacCatalyst.dll:System.IntPtr Foundation.NSObject::__data
Microsoft.MacCatalyst.dll:System.IntPtr Foundation.NSObject/NSObject_Disposer::class_ptr
Microsoft.MacCatalyst.dll:System.IntPtr ObjCRuntime.BlockCollector::block
Microsoft.MacCatalyst.dll:System.IntPtr ObjCRuntime.Libraries/CoreFoundation::Handle
@@ -855,8 +850,10 @@ Microsoft.MacCatalyst.dll:System.Object Foundation.NSObject/NSObject_Disposer::l
Microsoft.MacCatalyst.dll:System.Object ObjCRuntime.Class::verification_lock
Microsoft.MacCatalyst.dll:System.Object ObjCRuntime.Runtime::lock_obj
Microsoft.MacCatalyst.dll:System.Reflection.Assembly Foundation.NSObject::PlatformAssembly
+Microsoft.MacCatalyst.dll:System.Runtime.CompilerServices.ConditionalWeakTable`2 Foundation.NSObject::data_table
Microsoft.MacCatalyst.dll:System.Runtime.CompilerServices.ConditionalWeakTable`2 ObjCRuntime.Runtime::block_lifetime_table
Microsoft.MacCatalyst.dll:System.Runtime.CompilerServices.ConditionalWeakTable`2 ObjCRuntime.Class::assembly_to_name
+Microsoft.MacCatalyst.dll:System.Runtime.InteropServices.GCHandle Foundation.NSObjectDataHandle::handle
Microsoft.MacCatalyst.dll:System.Runtime.InteropServices.NFloat CoreGraphics.CGRect::height
Microsoft.MacCatalyst.dll:System.Runtime.InteropServices.NFloat CoreGraphics.CGRect::width
Microsoft.MacCatalyst.dll:System.Runtime.InteropServices.NFloat CoreGraphics.CGRect::x
@@ -1951,14 +1948,12 @@ System.Private.CoreLib.dll:System.Boolean System.Runtime.CompilerServices.Nullab
System.Private.CoreLib.dll:System.Boolean System.Runtime.CompilerServices.RuntimeCompatibilityAttribute::k__BackingField
System.Private.CoreLib.dll:System.Boolean System.Runtime.CompilerServices.RuntimeCompatibilityAttribute::WrapNonExceptionThrows()
System.Private.CoreLib.dll:System.Boolean System.Runtime.DependentHandle::IsAllocated()
-System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.CriticalHandle::_isClosed
-System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.CriticalHandle::IsClosed()
-System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.CriticalHandle::IsInvalid()
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::BestFitMapping
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::ExactSpelling
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::PreserveSig
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::SetLastError
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::ThrowOnUnmappableChar
+System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.GCHandle::IsAllocated()
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller`1/ManagedToUnmanagedIn::_addRefd
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller`1/ManagedToUnmanagedOut::_initialized
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.Marshalling.Utf8StringMarshaller/ManagedToUnmanagedIn::_allocated
@@ -6024,7 +6019,6 @@ System.Private.CoreLib.dll:System.IntPtr System.Reflection.RuntimePropertyInfo::
System.Private.CoreLib.dll:System.IntPtr System.Reflection.RuntimePropertyInfo::prop
System.Private.CoreLib.dll:System.IntPtr System.Runtime.CompilerServices.QCallAssembly::_assembly
System.Private.CoreLib.dll:System.IntPtr System.Runtime.CompilerServices.QCallTypeHandle::_handle
-System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.CriticalHandle::handle
System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.GCHandle::_handle
System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.SafeHandle::handle
System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.WeakGCHandle`1::_handle
@@ -8550,15 +8544,6 @@ System.Private.CoreLib.dll:System.Runtime.InteropServices.CollectionsMarshal
System.Private.CoreLib.dll:System.Runtime.InteropServices.CollectionsMarshal.GetValueRefOrAddDefault`2(System.Collections.Generic.Dictionary`2, TKey, out System.Boolean&)
System.Private.CoreLib.dll:System.Runtime.InteropServices.ComImportAttribute
System.Private.CoreLib.dll:System.Runtime.InteropServices.ComImportAttribute..ctor()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle..ctor(System.IntPtr)
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Cleanup()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Dispose()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Dispose(System.Boolean)
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Finalize()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.get_IsClosed()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.get_IsInvalid()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.ReleaseHandle()
System.Private.CoreLib.dll:System.Runtime.InteropServices.DefaultDllImportSearchPathsAttribute
System.Private.CoreLib.dll:System.Runtime.InteropServices.DefaultDllImportSearchPathsAttribute..ctor(System.Runtime.InteropServices.DllImportSearchPath)
System.Private.CoreLib.dll:System.Runtime.InteropServices.DllImportAttribute
@@ -8586,6 +8571,7 @@ System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.Equals(System
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.Equals(System.Runtime.InteropServices.GCHandle)
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.Free()
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.FromIntPtr(System.IntPtr)
+System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.get_IsAllocated()
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.get_Target()
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.GetHandleValue(System.IntPtr)
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.GetHashCode()
diff --git a/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-size.txt b/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-size.txt
index 59e70bf96ffd..7512634ffdcc 100644
--- a/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-size.txt
@@ -1,15 +1,15 @@
-AppBundleSize: 16,326,690 bytes (15,944.0 KB = 15.6 MB)
+AppBundleSize: 16,328,311 bytes (15,945.6 KB = 15.6 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 4,134 bytes (4.0 KB = 0.0 MB)
-Contents/Info.plist: 1,099 bytes (1.1 KB = 0.0 MB)
-Contents/MacOS/SizeTestApp: 13,815,840 bytes (13,492.0 KB = 13.2 MB)
+Contents/Info.plist: 1,112 bytes (1.1 KB = 0.0 MB)
+Contents/MacOS/SizeTestApp: 13,817,152 bytes (13,493.3 KB = 13.2 MB)
Contents/MonoBundle/aot-instances.aotdata.arm64: 1,045,032 bytes (1,020.5 KB = 1.0 MB)
-Contents/MonoBundle/Microsoft.MacCatalyst.aotdata.arm64: 36,048 bytes (35.2 KB = 0.0 MB)
-Contents/MonoBundle/Microsoft.MacCatalyst.dll: 51,200 bytes (50.0 KB = 0.0 MB)
+Contents/MonoBundle/Microsoft.MacCatalyst.aotdata.arm64: 36,320 bytes (35.5 KB = 0.0 MB)
+Contents/MonoBundle/Microsoft.MacCatalyst.dll: 50,688 bytes (49.5 KB = 0.0 MB)
Contents/MonoBundle/runtimeconfig.bin: 1,481 bytes (1.4 KB = 0.0 MB)
Contents/MonoBundle/SizeTestApp.aotdata.arm64: 1,552 bytes (1.5 KB = 0.0 MB)
-Contents/MonoBundle/SizeTestApp.dll: 7,168 bytes (7.0 KB = 0.0 MB)
-Contents/MonoBundle/System.Private.CoreLib.aotdata.arm64: 814,328 bytes (795.2 KB = 0.8 MB)
+Contents/MonoBundle/SizeTestApp.dll: 7,680 bytes (7.5 KB = 0.0 MB)
+Contents/MonoBundle/System.Private.CoreLib.aotdata.arm64: 814,352 bytes (795.3 KB = 0.8 MB)
Contents/MonoBundle/System.Private.CoreLib.dll: 534,528 bytes (522.0 KB = 0.5 MB)
Contents/MonoBundle/System.Runtime.aotdata.arm64: 472 bytes (0.5 KB = 0.0 MB)
Contents/MonoBundle/System.Runtime.dll: 5,120 bytes (5.0 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-TrimmableStatic-size.txt b/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-TrimmableStatic-size.txt
index 76fb1f7ee130..ffb9f2f06ec5 100644
--- a/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-TrimmableStatic-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-TrimmableStatic-size.txt
@@ -1,7 +1,7 @@
-AppBundleSize: 8,759,329 bytes (8,554.0 KB = 8.4 MB)
+AppBundleSize: 8,742,942 bytes (8,538.0 KB = 8.3 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 2,358 bytes (2.3 KB = 0.0 MB)
-Contents/Info.plist: 1,099 bytes (1.1 KB = 0.0 MB)
-Contents/MacOS/SizeTestApp: 8,753,968 bytes (8,548.8 KB = 8.3 MB)
+Contents/Info.plist: 1,112 bytes (1.1 KB = 0.0 MB)
+Contents/MacOS/SizeTestApp: 8,737,568 bytes (8,532.8 KB = 8.3 MB)
Contents/MonoBundle/runtimeconfig.bin: 1,896 bytes (1.9 KB = 0.0 MB)
Contents/PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-size.txt b/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-size.txt
index 8d0cf443f128..e8c5a0324ea1 100644
--- a/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-size.txt
@@ -1,7 +1,7 @@
-AppBundleSize: 2,781,129 bytes (2,715.9 KB = 2.7 MB)
+AppBundleSize: 2,781,142 bytes (2,716.0 KB = 2.7 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 2,358 bytes (2.3 KB = 0.0 MB)
-Contents/Info.plist: 1,099 bytes (1.1 KB = 0.0 MB)
+Contents/Info.plist: 1,112 bytes (1.1 KB = 0.0 MB)
Contents/MacOS/SizeTestApp: 2,775,856 bytes (2,710.8 KB = 2.6 MB)
Contents/MonoBundle/runtimeconfig.bin: 1,808 bytes (1.8 KB = 0.0 MB)
Contents/PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-TrimmableStatic-size.txt b/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-TrimmableStatic-size.txt
index 79bce275d232..643cf28d6c9d 100644
--- a/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-TrimmableStatic-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-TrimmableStatic-size.txt
@@ -1,12 +1,12 @@
-AppBundleSize: 259,373,212 bytes (253,294.2 KB = 247.4 MB)
+AppBundleSize: 259,379,553 bytes (253,300.3 KB = 247.4 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 67,868 bytes (66.3 KB = 0.1 MB)
-Contents/Info.plist: 738 bytes (0.7 KB = 0.0 MB)
-Contents/MacOS/SizeTestApp: 7,430,864 bytes (7,256.7 KB = 7.1 MB)
+Contents/Info.plist: 743 bytes (0.7 KB = 0.0 MB)
+Contents/MacOS/SizeTestApp: 7,432,080 bytes (7,257.9 KB = 7.1 MB)
Contents/MonoBundle/.xamarin/osx-arm64/_Microsoft.macOS.TypeMap.dll: 4,847,616 bytes (4,734.0 KB = 4.6 MB)
Contents/MonoBundle/.xamarin/osx-arm64/_SizeTestApp.TypeMap.dll: 3,072 bytes (3.0 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.CSharp.dll: 893,192 bytes (872.3 KB = 0.9 MB)
-Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.macOS.dll: 38,145,536 bytes (37,251.5 KB = 36.4 MB)
+Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.macOS.dll: 38,148,096 bytes (37,254.0 KB = 36.4 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.VisualBasic.Core.dll: 1,335,096 bytes (1,303.8 KB = 1.3 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.VisualBasic.dll: 17,680 bytes (17.3 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.Win32.Primitives.dll: 16,144 bytes (15.8 KB = 0.0 MB)
@@ -182,7 +182,7 @@ Contents/MonoBundle/.xamarin/osx-arm64/WindowsBase.dll: 16,688 bytes (16.3 KB =
Contents/MonoBundle/.xamarin/osx-x64/_Microsoft.macOS.TypeMap.dll: 4,847,616 bytes (4,734.0 KB = 4.6 MB)
Contents/MonoBundle/.xamarin/osx-x64/_SizeTestApp.TypeMap.dll: 3,072 bytes (3.0 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.CSharp.dll: 796,432 bytes (777.8 KB = 0.8 MB)
-Contents/MonoBundle/.xamarin/osx-x64/Microsoft.macOS.dll: 38,145,536 bytes (37,251.5 KB = 36.4 MB)
+Contents/MonoBundle/.xamarin/osx-x64/Microsoft.macOS.dll: 38,148,096 bytes (37,254.0 KB = 36.4 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.VisualBasic.Core.dll: 1,166,648 bytes (1,139.3 KB = 1.1 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.VisualBasic.dll: 17,680 bytes (17.3 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.Win32.Primitives.dll: 16,176 bytes (15.8 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-size.txt b/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-size.txt
index 70b2fa7905e5..2ac55e068fe2 100644
--- a/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-size.txt
@@ -1,10 +1,10 @@
-AppBundleSize: 247,534,854 bytes (241,733.3 KB = 236.1 MB)
+AppBundleSize: 247,542,219 bytes (241,740.4 KB = 236.1 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 67,160 bytes (65.6 KB = 0.1 MB)
-Contents/Info.plist: 738 bytes (0.7 KB = 0.0 MB)
-Contents/MacOS/SizeTestApp: 8,087,120 bytes (7,897.6 KB = 7.7 MB)
+Contents/Info.plist: 743 bytes (0.7 KB = 0.0 MB)
+Contents/MacOS/SizeTestApp: 8,088,336 bytes (7,898.8 KB = 7.7 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.CSharp.dll: 893,192 bytes (872.3 KB = 0.9 MB)
-Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.macOS.dll: 36,748,800 bytes (35,887.5 KB = 35.0 MB)
+Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.macOS.dll: 36,751,872 bytes (35,890.5 KB = 35.0 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.VisualBasic.Core.dll: 1,335,096 bytes (1,303.8 KB = 1.3 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.VisualBasic.dll: 17,680 bytes (17.3 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.Win32.Primitives.dll: 16,144 bytes (15.8 KB = 0.0 MB)
@@ -178,7 +178,7 @@ Contents/MonoBundle/.xamarin/osx-arm64/System.Xml.XPath.dll: 16,144 bytes (15.8
Contents/MonoBundle/.xamarin/osx-arm64/System.Xml.XPath.XDocument.dll: 17,672 bytes (17.3 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-arm64/WindowsBase.dll: 16,688 bytes (16.3 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.CSharp.dll: 796,432 bytes (777.8 KB = 0.8 MB)
-Contents/MonoBundle/.xamarin/osx-x64/Microsoft.macOS.dll: 36,748,800 bytes (35,887.5 KB = 35.0 MB)
+Contents/MonoBundle/.xamarin/osx-x64/Microsoft.macOS.dll: 36,751,872 bytes (35,890.5 KB = 35.0 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.VisualBasic.Core.dll: 1,166,648 bytes (1,139.3 KB = 1.1 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.VisualBasic.dll: 17,680 bytes (17.3 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.Win32.Primitives.dll: 16,176 bytes (15.8 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-TrimmableStatic-size.txt b/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-TrimmableStatic-size.txt
index b4ab89c40241..5ca361d42edc 100644
--- a/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-TrimmableStatic-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-TrimmableStatic-size.txt
@@ -1,8 +1,8 @@
-AppBundleSize: 21,482,500 bytes (20,979.0 KB = 20.5 MB)
+AppBundleSize: 21,449,705 bytes (20,947.0 KB = 20.5 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 3,489 bytes (3.4 KB = 0.0 MB)
-Contents/Info.plist: 738 bytes (0.7 KB = 0.0 MB)
-Contents/MacOS/SizeTestApp: 18,488,832 bytes (18,055.5 KB = 17.6 MB)
+Contents/Info.plist: 743 bytes (0.7 KB = 0.0 MB)
+Contents/MacOS/SizeTestApp: 18,456,032 bytes (18,023.5 KB = 17.6 MB)
Contents/MonoBundle/libSystem.Globalization.Native.dylib: 252,176 bytes (246.3 KB = 0.2 MB)
Contents/MonoBundle/libSystem.IO.Compression.Native.dylib: 2,005,440 bytes (1,958.4 KB = 1.9 MB)
Contents/MonoBundle/libSystem.Native.dylib: 292,176 bytes (285.3 KB = 0.3 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-size.txt b/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-size.txt
index 80dca93a72af..e8b63372eb52 100644
--- a/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-size.txt
@@ -1,7 +1,7 @@
-AppBundleSize: 8,818,810 bytes (8,612.1 KB = 8.4 MB)
+AppBundleSize: 8,818,823 bytes (8,612.1 KB = 8.4 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 3,489 bytes (3.4 KB = 0.0 MB)
-Contents/Info.plist: 730 bytes (0.7 KB = 0.0 MB)
+Contents/Info.plist: 743 bytes (0.7 KB = 0.0 MB)
Contents/MacOS/SizeTestApp: 5,825,232 bytes (5,688.7 KB = 5.6 MB)
Contents/MonoBundle/libSystem.Globalization.Native.dylib: 252,176 bytes (246.3 KB = 0.2 MB)
Contents/MonoBundle/libSystem.IO.Compression.Native.dylib: 2,005,440 bytes (1,958.4 KB = 1.9 MB)
diff --git a/tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-preservedapis.txt b/tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-preservedapis.txt
index 57d50d17b7d0..69dd2bddea06 100644
--- a/tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-preservedapis.txt
+++ b/tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-preservedapis.txt
@@ -113,7 +113,6 @@ Microsoft.tvOS.dll:Foundation.NSObject..ctor()
Microsoft.tvOS.dll:Foundation.NSObject..ctor(Foundation.NSObjectFlag)
Microsoft.tvOS.dll:Foundation.NSObject..ctor(ObjCRuntime.NativeHandle, System.Boolean)
Microsoft.tvOS.dll:Foundation.NSObject..ctor(ObjCRuntime.NativeHandle)
-Microsoft.tvOS.dll:Foundation.NSObject.AllocateData()
Microsoft.tvOS.dll:Foundation.NSObject.AllocIfNeeded()
Microsoft.tvOS.dll:Foundation.NSObject.ClearHandle()
Microsoft.tvOS.dll:Foundation.NSObject.ConformsToProtocol(ObjCRuntime.NativeHandle)
@@ -152,7 +151,6 @@ Microsoft.tvOS.dll:Foundation.NSObject.InitializeObject(System.Boolean)
Microsoft.tvOS.dll:Foundation.NSObject.InvokeConformsToProtocol(ObjCRuntime.NativeHandle)
Microsoft.tvOS.dll:Foundation.NSObject.IsEqual(Foundation.NSObject)
Microsoft.tvOS.dll:Foundation.NSObject.IsProtocol(System.Type, System.IntPtr)
-Microsoft.tvOS.dll:Foundation.NSObject.RecreateDataHandle()
Microsoft.tvOS.dll:Foundation.NSObject.ReleaseManagedRef()
Microsoft.tvOS.dll:Foundation.NSObject.set_disposed(System.Boolean)
Microsoft.tvOS.dll:Foundation.NSObject.set_flags(Foundation.NSObject/Flags)
@@ -191,16 +189,13 @@ Microsoft.tvOS.dll:Foundation.NSObject/XamarinGCHandleFlags Foundation.NSObject/
Microsoft.tvOS.dll:Foundation.NSObject/XamarinGCHandleFlags Foundation.NSObject/XamarinGCHandleFlags::InitialSet
Microsoft.tvOS.dll:Foundation.NSObject/XamarinGCHandleFlags Foundation.NSObject/XamarinGCHandleFlags::None
Microsoft.tvOS.dll:Foundation.NSObjectData
-Microsoft.tvOS.dll:Foundation.NSObjectData* Foundation.NSObject::__data_for_mono
+Microsoft.tvOS.dll:Foundation.NSObjectData* Foundation.NSObjectDataHandle::data
Microsoft.tvOS.dll:Foundation.NSObjectData* Foundation.NSObjectDataHandle::Data()
Microsoft.tvOS.dll:Foundation.NSObjectDataHandle
-Microsoft.tvOS.dll:Foundation.NSObjectDataHandle Foundation.NSObject::data_handle
Microsoft.tvOS.dll:Foundation.NSObjectDataHandle..ctor()
-Microsoft.tvOS.dll:Foundation.NSObjectDataHandle..ctor(System.IntPtr)
+Microsoft.tvOS.dll:Foundation.NSObjectDataHandle.CreateHandle(Foundation.NSObject)
+Microsoft.tvOS.dll:Foundation.NSObjectDataHandle.Finalize()
Microsoft.tvOS.dll:Foundation.NSObjectDataHandle.get_Data()
-Microsoft.tvOS.dll:Foundation.NSObjectDataHandle.get_IsInvalid()
-Microsoft.tvOS.dll:Foundation.NSObjectDataHandle.Invalidate()
-Microsoft.tvOS.dll:Foundation.NSObjectDataHandle.ReleaseHandle()
Microsoft.tvOS.dll:Foundation.NSObjectFlag
Microsoft.tvOS.dll:Foundation.NSObjectFlag Foundation.NSObjectFlag::Empty
Microsoft.tvOS.dll:Foundation.NSString
@@ -592,6 +587,7 @@ Microsoft.tvOS.dll:ObjCRuntime.Runtime.g__ConstructINati
Microsoft.tvOS.dll:ObjCRuntime.Runtime.g__ConstructNSObjectViaFactoryMethod|288_0`1(ObjCRuntime.NativeHandle)
Microsoft.tvOS.dll:ObjCRuntime.Runtime.AllocGCHandle(System.Object, System.Runtime.InteropServices.GCHandleType)
Microsoft.tvOS.dll:ObjCRuntime.Runtime.AllocGCHandle(System.Object)
+Microsoft.tvOS.dll:ObjCRuntime.Runtime.AllocZeroed`1()
Microsoft.tvOS.dll:ObjCRuntime.Runtime.AppendAdditionalInformation(System.Text.StringBuilder, System.IntPtr, System.RuntimeMethodHandle)
Microsoft.tvOS.dll:ObjCRuntime.Runtime.attempt_retain_nsobject(System.IntPtr, System.IntPtr*)
Microsoft.tvOS.dll:ObjCRuntime.Runtime.AttemptRetainNSObject(System.IntPtr)
@@ -1207,8 +1203,6 @@ Microsoft.tvOS.dll:System.Boolean Foundation.NSObject::IsDirectBinding()
Microsoft.tvOS.dll:System.Boolean Foundation.NSObject::IsRegisteredToggleRef()
Microsoft.tvOS.dll:System.Boolean Foundation.NSObject::RemoveFromObjectMap()
Microsoft.tvOS.dll:System.Boolean Foundation.NSObject/NSObject_Disposer::draining
-Microsoft.tvOS.dll:System.Boolean Foundation.NSObjectDataHandle::invalidated
-Microsoft.tvOS.dll:System.Boolean Foundation.NSObjectDataHandle::IsInvalid()
Microsoft.tvOS.dll:System.Boolean Foundation.ProtocolAttribute::k__BackingField
Microsoft.tvOS.dll:System.Boolean Foundation.ProtocolAttribute::k__BackingField
Microsoft.tvOS.dll:System.Boolean Foundation.ProtocolAttribute::IsInformal()
@@ -1327,6 +1321,7 @@ Microsoft.tvOS.dll:System.Int64 Foundation.NSComparisonResult::value__
Microsoft.tvOS.dll:System.IntPtr CoreFoundation.CFArray::_CFNullHandle()
Microsoft.tvOS.dll:System.IntPtr CoreFoundation.CFRange::len
Microsoft.tvOS.dll:System.IntPtr CoreFoundation.CFRange::loc
+Microsoft.tvOS.dll:System.IntPtr Foundation.NSObject::__data
Microsoft.tvOS.dll:System.IntPtr Foundation.NSObject/NSObject_Disposer::class_ptr
Microsoft.tvOS.dll:System.IntPtr ObjCRuntime.AdoptsAttribute::ProtocolHandle()
Microsoft.tvOS.dll:System.IntPtr ObjCRuntime.BlockCollector::block
@@ -1488,8 +1483,10 @@ Microsoft.tvOS.dll:System.Reflection.MethodBase Registrar.Registrar::invoke_conf
Microsoft.tvOS.dll:System.Reflection.MethodBase Registrar.Registrar/ObjCMethod::Method
Microsoft.tvOS.dll:System.Reflection.PropertyInfo Registrar.Registrar/ObjCProperty::Property
Microsoft.tvOS.dll:System.Reflection.TypeFilter Registrar.SharedDynamic/<>c::<>9__0_0
+Microsoft.tvOS.dll:System.Runtime.CompilerServices.ConditionalWeakTable`2 Foundation.NSObject::data_table
Microsoft.tvOS.dll:System.Runtime.CompilerServices.ConditionalWeakTable`2 ObjCRuntime.Runtime::block_lifetime_table
Microsoft.tvOS.dll:System.Runtime.CompilerServices.ConditionalWeakTable`2 ObjCRuntime.Class::assembly_to_name
+Microsoft.tvOS.dll:System.Runtime.InteropServices.GCHandle Foundation.NSObjectDataHandle::handle
Microsoft.tvOS.dll:System.Runtime.InteropServices.NFloat CoreGraphics.CGRect::height
Microsoft.tvOS.dll:System.Runtime.InteropServices.NFloat CoreGraphics.CGRect::width
Microsoft.tvOS.dll:System.Runtime.InteropServices.NFloat CoreGraphics.CGRect::x
@@ -2710,14 +2707,12 @@ System.Private.CoreLib.dll:System.Boolean System.Runtime.CompilerServices.Runtim
System.Private.CoreLib.dll:System.Boolean System.Runtime.CompilerServices.RuntimeFeature::k__BackingField
System.Private.CoreLib.dll:System.Boolean System.Runtime.CompilerServices.RuntimeFeature::IsDynamicCodeSupported()
System.Private.CoreLib.dll:System.Boolean System.Runtime.DependentHandle::IsAllocated()
-System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.CriticalHandle::_isClosed
-System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.CriticalHandle::IsClosed()
-System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.CriticalHandle::IsInvalid()
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::BestFitMapping
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::ExactSpelling
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::PreserveSig
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::SetLastError
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::ThrowOnUnmappableChar
+System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.GCHandle::IsAllocated()
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller`1/ManagedToUnmanagedIn::_addRefd
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller`1/ManagedToUnmanagedOut::_initialized
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.Marshalling.Utf8StringMarshaller/ManagedToUnmanagedIn::_allocated
@@ -6888,7 +6883,6 @@ System.Private.CoreLib.dll:System.IntPtr System.Reflection.RuntimePropertyInfo::
System.Private.CoreLib.dll:System.IntPtr System.Reflection.RuntimePropertyInfo::prop
System.Private.CoreLib.dll:System.IntPtr System.Runtime.CompilerServices.QCallAssembly::_assembly
System.Private.CoreLib.dll:System.IntPtr System.Runtime.CompilerServices.QCallTypeHandle::_handle
-System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.CriticalHandle::handle
System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.GCHandle::_handle
System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.SafeHandle::handle
System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.WeakGCHandle`1::_handle
@@ -10773,15 +10767,6 @@ System.Private.CoreLib.dll:System.Runtime.InteropServices.CollectionsMarshal
System.Private.CoreLib.dll:System.Runtime.InteropServices.CollectionsMarshal.GetValueRefOrAddDefault`2(System.Collections.Generic.Dictionary`2, TKey, out System.Boolean&)
System.Private.CoreLib.dll:System.Runtime.InteropServices.ComImportAttribute
System.Private.CoreLib.dll:System.Runtime.InteropServices.ComImportAttribute..ctor()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle..ctor(System.IntPtr)
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Cleanup()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Dispose()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Dispose(System.Boolean)
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Finalize()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.get_IsClosed()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.get_IsInvalid()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.ReleaseHandle()
System.Private.CoreLib.dll:System.Runtime.InteropServices.DefaultDllImportSearchPathsAttribute
System.Private.CoreLib.dll:System.Runtime.InteropServices.DefaultDllImportSearchPathsAttribute..ctor(System.Runtime.InteropServices.DllImportSearchPath)
System.Private.CoreLib.dll:System.Runtime.InteropServices.DllImportAttribute
@@ -10810,6 +10795,7 @@ System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.Equals(System
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.Equals(System.Runtime.InteropServices.GCHandle)
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.Free()
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.FromIntPtr(System.IntPtr)
+System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.get_IsAllocated()
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.get_Target()
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.GetHandleValue(System.IntPtr)
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.GetHashCode()
diff --git a/tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-size.txt b/tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-size.txt
index 54ecb9e249c2..690044239400 100644
--- a/tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-size.txt
+++ b/tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-size.txt
@@ -1,14 +1,14 @@
-AppBundleSize: 3,617,465 bytes (3,532.7 KB = 3.4 MB)
+AppBundleSize: 3,615,919 bytes (3,531.2 KB = 3.4 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 3,999 bytes (3.9 KB = 0.0 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,117 bytes (1.1 KB = 0.0 MB)
-Microsoft.tvOS.dll: 155,136 bytes (151.5 KB = 0.1 MB)
+Info.plist: 1,131 bytes (1.1 KB = 0.0 MB)
+Microsoft.tvOS.dll: 154,112 bytes (150.5 KB = 0.1 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,405 bytes (1.4 KB = 0.0 MB)
SizeTestApp: 2,404,416 bytes (2,348.1 KB = 2.3 MB)
SizeTestApp.dll: 7,680 bytes (7.5 KB = 0.0 MB)
-System.Private.CoreLib.aotdata.arm64: 41,336 bytes (40.4 KB = 0.0 MB)
-System.Private.CoreLib.dll: 988,672 bytes (965.5 KB = 0.9 MB)
+System.Private.CoreLib.aotdata.arm64: 41,312 bytes (40.3 KB = 0.0 MB)
+System.Private.CoreLib.dll: 988,160 bytes (965.0 KB = 0.9 MB)
System.Runtime.dll: 5,120 bytes (5.0 KB = 0.0 MB)
System.Runtime.InteropServices.dll: 8,192 bytes (8.0 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/TVOS-MonoVM-preservedapis.txt b/tests/dotnet/UnitTests/expected/TVOS-MonoVM-preservedapis.txt
index a003cb6ee979..39615d782921 100644
--- a/tests/dotnet/UnitTests/expected/TVOS-MonoVM-preservedapis.txt
+++ b/tests/dotnet/UnitTests/expected/TVOS-MonoVM-preservedapis.txt
@@ -99,7 +99,6 @@ Microsoft.tvOS.dll:Foundation.NSObject..ctor()
Microsoft.tvOS.dll:Foundation.NSObject..ctor(Foundation.NSObjectFlag)
Microsoft.tvOS.dll:Foundation.NSObject..ctor(ObjCRuntime.NativeHandle, System.Boolean)
Microsoft.tvOS.dll:Foundation.NSObject..ctor(ObjCRuntime.NativeHandle)
-Microsoft.tvOS.dll:Foundation.NSObject.AllocateData()
Microsoft.tvOS.dll:Foundation.NSObject.AllocIfNeeded()
Microsoft.tvOS.dll:Foundation.NSObject.ClearHandle()
Microsoft.tvOS.dll:Foundation.NSObject.ConformsToProtocol(ObjCRuntime.NativeHandle)
@@ -136,7 +135,6 @@ Microsoft.tvOS.dll:Foundation.NSObject.InitializeHandle(ObjCRuntime.NativeHandle
Microsoft.tvOS.dll:Foundation.NSObject.InitializeObject(System.Boolean)
Microsoft.tvOS.dll:Foundation.NSObject.InvokeConformsToProtocol(ObjCRuntime.NativeHandle)
Microsoft.tvOS.dll:Foundation.NSObject.IsEqual(Foundation.NSObject)
-Microsoft.tvOS.dll:Foundation.NSObject.RecreateDataHandle()
Microsoft.tvOS.dll:Foundation.NSObject.ReleaseManagedRef()
Microsoft.tvOS.dll:Foundation.NSObject.set_disposed(System.Boolean)
Microsoft.tvOS.dll:Foundation.NSObject.set_flags(Foundation.NSObject/Flags)
@@ -174,16 +172,13 @@ Microsoft.tvOS.dll:Foundation.NSObject/XamarinGCHandleFlags Foundation.NSObject/
Microsoft.tvOS.dll:Foundation.NSObject/XamarinGCHandleFlags Foundation.NSObject/XamarinGCHandleFlags::InitialSet
Microsoft.tvOS.dll:Foundation.NSObject/XamarinGCHandleFlags Foundation.NSObject/XamarinGCHandleFlags::None
Microsoft.tvOS.dll:Foundation.NSObjectData
-Microsoft.tvOS.dll:Foundation.NSObjectData* Foundation.NSObject::__data_for_mono
+Microsoft.tvOS.dll:Foundation.NSObjectData* Foundation.NSObjectDataHandle::data
Microsoft.tvOS.dll:Foundation.NSObjectData* Foundation.NSObjectDataHandle::Data()
Microsoft.tvOS.dll:Foundation.NSObjectDataHandle
-Microsoft.tvOS.dll:Foundation.NSObjectDataHandle Foundation.NSObject::data_handle
Microsoft.tvOS.dll:Foundation.NSObjectDataHandle..ctor()
-Microsoft.tvOS.dll:Foundation.NSObjectDataHandle..ctor(System.IntPtr)
+Microsoft.tvOS.dll:Foundation.NSObjectDataHandle.CreateHandle(Foundation.NSObject)
+Microsoft.tvOS.dll:Foundation.NSObjectDataHandle.Finalize()
Microsoft.tvOS.dll:Foundation.NSObjectDataHandle.get_Data()
-Microsoft.tvOS.dll:Foundation.NSObjectDataHandle.get_IsInvalid()
-Microsoft.tvOS.dll:Foundation.NSObjectDataHandle.Invalidate()
-Microsoft.tvOS.dll:Foundation.NSObjectDataHandle.ReleaseHandle()
Microsoft.tvOS.dll:Foundation.NSObjectFlag
Microsoft.tvOS.dll:Foundation.NSObjectFlag Foundation.NSObjectFlag::Empty
Microsoft.tvOS.dll:Foundation.ProtocolAttribute
@@ -450,6 +445,7 @@ Microsoft.tvOS.dll:ObjCRuntime.Runtime.g__ConstructINati
Microsoft.tvOS.dll:ObjCRuntime.Runtime.g__ConstructNSObjectViaFactoryMethod|288_0`1(ObjCRuntime.NativeHandle)
Microsoft.tvOS.dll:ObjCRuntime.Runtime.AllocGCHandle(System.Object, System.Runtime.InteropServices.GCHandleType)
Microsoft.tvOS.dll:ObjCRuntime.Runtime.AllocGCHandle(System.Object)
+Microsoft.tvOS.dll:ObjCRuntime.Runtime.AllocZeroed`1()
Microsoft.tvOS.dll:ObjCRuntime.Runtime.AppendAdditionalInformation(System.Text.StringBuilder, System.IntPtr, System.RuntimeMethodHandle)
Microsoft.tvOS.dll:ObjCRuntime.Runtime.attempt_retain_nsobject(System.IntPtr, System.IntPtr*)
Microsoft.tvOS.dll:ObjCRuntime.Runtime.AttemptRetainNSObject(System.IntPtr)
@@ -662,8 +658,6 @@ Microsoft.tvOS.dll:System.Boolean Foundation.NSObject::InFinalizerQueue()
Microsoft.tvOS.dll:System.Boolean Foundation.NSObject::IsDirectBinding()
Microsoft.tvOS.dll:System.Boolean Foundation.NSObject::IsRegisteredToggleRef()
Microsoft.tvOS.dll:System.Boolean Foundation.NSObject/NSObject_Disposer::draining
-Microsoft.tvOS.dll:System.Boolean Foundation.NSObjectDataHandle::invalidated
-Microsoft.tvOS.dll:System.Boolean Foundation.NSObjectDataHandle::IsInvalid()
Microsoft.tvOS.dll:System.Boolean Foundation.ProtocolAttribute::k__BackingField
Microsoft.tvOS.dll:System.Boolean Foundation.RegisterAttribute::is_wrapper
Microsoft.tvOS.dll:System.Boolean Foundation.RegisterAttribute::IsWrapper()
@@ -719,6 +713,7 @@ Microsoft.tvOS.dll:System.Int32 ObjCRuntime.TransientString/Encoding::value__
Microsoft.tvOS.dll:System.IntPtr CoreFoundation.CFArray::_CFNullHandle()
Microsoft.tvOS.dll:System.IntPtr CoreFoundation.CFRange::len
Microsoft.tvOS.dll:System.IntPtr CoreFoundation.CFRange::loc
+Microsoft.tvOS.dll:System.IntPtr Foundation.NSObject::__data
Microsoft.tvOS.dll:System.IntPtr Foundation.NSObject/NSObject_Disposer::class_ptr
Microsoft.tvOS.dll:System.IntPtr ObjCRuntime.BlockCollector::block
Microsoft.tvOS.dll:System.IntPtr ObjCRuntime.Libraries/CoreFoundation::Handle
@@ -848,8 +843,10 @@ Microsoft.tvOS.dll:System.IntPtr* ObjCRuntime.Runtime/MTRegistrationMap::classHa
Microsoft.tvOS.dll:System.Object Foundation.NSObject/NSObject_Disposer::lock_obj
Microsoft.tvOS.dll:System.Object ObjCRuntime.Runtime::lock_obj
Microsoft.tvOS.dll:System.Reflection.Assembly Foundation.NSObject::PlatformAssembly
+Microsoft.tvOS.dll:System.Runtime.CompilerServices.ConditionalWeakTable`2 Foundation.NSObject::data_table
Microsoft.tvOS.dll:System.Runtime.CompilerServices.ConditionalWeakTable`2 ObjCRuntime.Runtime::block_lifetime_table
Microsoft.tvOS.dll:System.Runtime.CompilerServices.ConditionalWeakTable`2 ObjCRuntime.Class::assembly_to_name
+Microsoft.tvOS.dll:System.Runtime.InteropServices.GCHandle Foundation.NSObjectDataHandle::handle
Microsoft.tvOS.dll:System.Runtime.InteropServices.NFloat CoreGraphics.CGRect::height
Microsoft.tvOS.dll:System.Runtime.InteropServices.NFloat CoreGraphics.CGRect::width
Microsoft.tvOS.dll:System.Runtime.InteropServices.NFloat CoreGraphics.CGRect::x
@@ -1943,14 +1940,12 @@ System.Private.CoreLib.dll:System.Boolean System.Runtime.CompilerServices.Nullab
System.Private.CoreLib.dll:System.Boolean System.Runtime.CompilerServices.RuntimeCompatibilityAttribute::k__BackingField
System.Private.CoreLib.dll:System.Boolean System.Runtime.CompilerServices.RuntimeCompatibilityAttribute::WrapNonExceptionThrows()
System.Private.CoreLib.dll:System.Boolean System.Runtime.DependentHandle::IsAllocated()
-System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.CriticalHandle::_isClosed
-System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.CriticalHandle::IsClosed()
-System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.CriticalHandle::IsInvalid()
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::BestFitMapping
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::ExactSpelling
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::PreserveSig
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::SetLastError
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::ThrowOnUnmappableChar
+System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.GCHandle::IsAllocated()
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller`1/ManagedToUnmanagedIn::_addRefd
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller`1/ManagedToUnmanagedOut::_initialized
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.Marshalling.Utf8StringMarshaller/ManagedToUnmanagedIn::_allocated
@@ -5969,7 +5964,6 @@ System.Private.CoreLib.dll:System.IntPtr System.Reflection.RuntimePropertyInfo::
System.Private.CoreLib.dll:System.IntPtr System.Reflection.RuntimePropertyInfo::prop
System.Private.CoreLib.dll:System.IntPtr System.Runtime.CompilerServices.QCallAssembly::_assembly
System.Private.CoreLib.dll:System.IntPtr System.Runtime.CompilerServices.QCallTypeHandle::_handle
-System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.CriticalHandle::handle
System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.GCHandle::_handle
System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.SafeHandle::handle
System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.WeakGCHandle`1::_handle
@@ -8485,15 +8479,6 @@ System.Private.CoreLib.dll:System.Runtime.InteropServices.CollectionsMarshal
System.Private.CoreLib.dll:System.Runtime.InteropServices.CollectionsMarshal.GetValueRefOrAddDefault`2(System.Collections.Generic.Dictionary`2, TKey, out System.Boolean&)
System.Private.CoreLib.dll:System.Runtime.InteropServices.ComImportAttribute
System.Private.CoreLib.dll:System.Runtime.InteropServices.ComImportAttribute..ctor()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle..ctor(System.IntPtr)
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Cleanup()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Dispose()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Dispose(System.Boolean)
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Finalize()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.get_IsClosed()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.get_IsInvalid()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.ReleaseHandle()
System.Private.CoreLib.dll:System.Runtime.InteropServices.DefaultDllImportSearchPathsAttribute
System.Private.CoreLib.dll:System.Runtime.InteropServices.DefaultDllImportSearchPathsAttribute..ctor(System.Runtime.InteropServices.DllImportSearchPath)
System.Private.CoreLib.dll:System.Runtime.InteropServices.DllImportAttribute
@@ -8521,6 +8506,7 @@ System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.Equals(System
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.Equals(System.Runtime.InteropServices.GCHandle)
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.Free()
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.FromIntPtr(System.IntPtr)
+System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.get_IsAllocated()
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.get_Target()
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.GetHandleValue(System.IntPtr)
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.GetHashCode()
diff --git a/tests/dotnet/UnitTests/expected/TVOS-MonoVM-size.txt b/tests/dotnet/UnitTests/expected/TVOS-MonoVM-size.txt
index c8fe10c3eb92..5e627a186b79 100644
--- a/tests/dotnet/UnitTests/expected/TVOS-MonoVM-size.txt
+++ b/tests/dotnet/UnitTests/expected/TVOS-MonoVM-size.txt
@@ -1,17 +1,17 @@
-AppBundleSize: 9,364,023 bytes (9,144.6 KB = 8.9 MB)
+AppBundleSize: 9,364,125 bytes (9,144.7 KB = 8.9 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 5,233 bytes (5.1 KB = 0.0 MB)
aot-instances.aotdata.arm64: 827,592 bytes (808.2 KB = 0.8 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,117 bytes (1.1 KB = 0.0 MB)
-Microsoft.tvOS.aotdata.arm64: 22,640 bytes (22.1 KB = 0.0 MB)
-Microsoft.tvOS.dll: 49,152 bytes (48.0 KB = 0.0 MB)
+Info.plist: 1,131 bytes (1.1 KB = 0.0 MB)
+Microsoft.tvOS.aotdata.arm64: 22,880 bytes (22.3 KB = 0.0 MB)
+Microsoft.tvOS.dll: 48,640 bytes (47.5 KB = 0.0 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,481 bytes (1.4 KB = 0.0 MB)
-SizeTestApp: 7,261,152 bytes (7,091.0 KB = 6.9 MB)
+SizeTestApp: 7,261,136 bytes (7,091.0 KB = 6.9 MB)
SizeTestApp.aotdata.arm64: 1,464 bytes (1.4 KB = 0.0 MB)
-SizeTestApp.dll: 7,168 bytes (7.0 KB = 0.0 MB)
-System.Private.CoreLib.aotdata.arm64: 640,792 bytes (625.8 KB = 0.6 MB)
+SizeTestApp.dll: 7,680 bytes (7.5 KB = 0.0 MB)
+System.Private.CoreLib.aotdata.arm64: 640,656 bytes (625.6 KB = 0.6 MB)
System.Private.CoreLib.dll: 530,944 bytes (518.5 KB = 0.5 MB)
System.Runtime.aotdata.arm64: 784 bytes (0.8 KB = 0.0 MB)
System.Runtime.dll: 5,120 bytes (5.0 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-TrimmableStatic-size.txt b/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-TrimmableStatic-size.txt
index de72f82de756..dfd9e745144b 100644
--- a/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-TrimmableStatic-size.txt
+++ b/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-TrimmableStatic-size.txt
@@ -1,8 +1,8 @@
-AppBundleSize: 7,905,347 bytes (7,720.1 KB = 7.5 MB)
+AppBundleSize: 7,888,849 bytes (7,704.0 KB = 7.5 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 2,589 bytes (2.5 KB = 0.0 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,117 bytes (1.1 KB = 0.0 MB)
+Info.plist: 1,131 bytes (1.1 KB = 0.0 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,889 bytes (1.8 KB = 0.0 MB)
-SizeTestApp: 7,899,360 bytes (7,714.2 KB = 7.5 MB)
+SizeTestApp: 7,882,848 bytes (7,698.1 KB = 7.5 MB)
diff --git a/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-size.txt b/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-size.txt
index a17ad92e4f57..e31f38da129e 100644
--- a/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-size.txt
+++ b/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-size.txt
@@ -1,8 +1,8 @@
-AppBundleSize: 2,783,138 bytes (2,717.9 KB = 2.7 MB)
+AppBundleSize: 2,783,136 bytes (2,717.9 KB = 2.7 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 2,589 bytes (2.5 KB = 0.0 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,117 bytes (1.1 KB = 0.0 MB)
+Info.plist: 1,131 bytes (1.1 KB = 0.0 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,808 bytes (1.8 KB = 0.0 MB)
-SizeTestApp: 2,777,232 bytes (2,712.1 KB = 2.6 MB)
+SizeTestApp: 2,777,216 bytes (2,712.1 KB = 2.6 MB)
diff --git a/tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-preservedapis.txt b/tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-preservedapis.txt
index 31c45a23253c..4f60ff683f87 100644
--- a/tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-preservedapis.txt
+++ b/tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-preservedapis.txt
@@ -113,7 +113,6 @@ Microsoft.iOS.dll:Foundation.NSObject..ctor()
Microsoft.iOS.dll:Foundation.NSObject..ctor(Foundation.NSObjectFlag)
Microsoft.iOS.dll:Foundation.NSObject..ctor(ObjCRuntime.NativeHandle, System.Boolean)
Microsoft.iOS.dll:Foundation.NSObject..ctor(ObjCRuntime.NativeHandle)
-Microsoft.iOS.dll:Foundation.NSObject.AllocateData()
Microsoft.iOS.dll:Foundation.NSObject.AllocIfNeeded()
Microsoft.iOS.dll:Foundation.NSObject.ClearHandle()
Microsoft.iOS.dll:Foundation.NSObject.ConformsToProtocol(ObjCRuntime.NativeHandle)
@@ -152,7 +151,6 @@ Microsoft.iOS.dll:Foundation.NSObject.InitializeObject(System.Boolean)
Microsoft.iOS.dll:Foundation.NSObject.InvokeConformsToProtocol(ObjCRuntime.NativeHandle)
Microsoft.iOS.dll:Foundation.NSObject.IsEqual(Foundation.NSObject)
Microsoft.iOS.dll:Foundation.NSObject.IsProtocol(System.Type, System.IntPtr)
-Microsoft.iOS.dll:Foundation.NSObject.RecreateDataHandle()
Microsoft.iOS.dll:Foundation.NSObject.ReleaseManagedRef()
Microsoft.iOS.dll:Foundation.NSObject.set_disposed(System.Boolean)
Microsoft.iOS.dll:Foundation.NSObject.set_flags(Foundation.NSObject/Flags)
@@ -191,16 +189,13 @@ Microsoft.iOS.dll:Foundation.NSObject/XamarinGCHandleFlags Foundation.NSObject/X
Microsoft.iOS.dll:Foundation.NSObject/XamarinGCHandleFlags Foundation.NSObject/XamarinGCHandleFlags::InitialSet
Microsoft.iOS.dll:Foundation.NSObject/XamarinGCHandleFlags Foundation.NSObject/XamarinGCHandleFlags::None
Microsoft.iOS.dll:Foundation.NSObjectData
-Microsoft.iOS.dll:Foundation.NSObjectData* Foundation.NSObject::__data_for_mono
+Microsoft.iOS.dll:Foundation.NSObjectData* Foundation.NSObjectDataHandle::data
Microsoft.iOS.dll:Foundation.NSObjectData* Foundation.NSObjectDataHandle::Data()
Microsoft.iOS.dll:Foundation.NSObjectDataHandle
-Microsoft.iOS.dll:Foundation.NSObjectDataHandle Foundation.NSObject::data_handle
Microsoft.iOS.dll:Foundation.NSObjectDataHandle..ctor()
-Microsoft.iOS.dll:Foundation.NSObjectDataHandle..ctor(System.IntPtr)
+Microsoft.iOS.dll:Foundation.NSObjectDataHandle.CreateHandle(Foundation.NSObject)
+Microsoft.iOS.dll:Foundation.NSObjectDataHandle.Finalize()
Microsoft.iOS.dll:Foundation.NSObjectDataHandle.get_Data()
-Microsoft.iOS.dll:Foundation.NSObjectDataHandle.get_IsInvalid()
-Microsoft.iOS.dll:Foundation.NSObjectDataHandle.Invalidate()
-Microsoft.iOS.dll:Foundation.NSObjectDataHandle.ReleaseHandle()
Microsoft.iOS.dll:Foundation.NSObjectFlag
Microsoft.iOS.dll:Foundation.NSObjectFlag Foundation.NSObjectFlag::Empty
Microsoft.iOS.dll:Foundation.NSString
@@ -592,6 +587,7 @@ Microsoft.iOS.dll:ObjCRuntime.Runtime.g__ConstructINativ
Microsoft.iOS.dll:ObjCRuntime.Runtime.g__ConstructNSObjectViaFactoryMethod|288_0`1(ObjCRuntime.NativeHandle)
Microsoft.iOS.dll:ObjCRuntime.Runtime.AllocGCHandle(System.Object, System.Runtime.InteropServices.GCHandleType)
Microsoft.iOS.dll:ObjCRuntime.Runtime.AllocGCHandle(System.Object)
+Microsoft.iOS.dll:ObjCRuntime.Runtime.AllocZeroed`1()
Microsoft.iOS.dll:ObjCRuntime.Runtime.AppendAdditionalInformation(System.Text.StringBuilder, System.IntPtr, System.RuntimeMethodHandle)
Microsoft.iOS.dll:ObjCRuntime.Runtime.attempt_retain_nsobject(System.IntPtr, System.IntPtr*)
Microsoft.iOS.dll:ObjCRuntime.Runtime.AttemptRetainNSObject(System.IntPtr)
@@ -1207,8 +1203,6 @@ Microsoft.iOS.dll:System.Boolean Foundation.NSObject::IsDirectBinding()
Microsoft.iOS.dll:System.Boolean Foundation.NSObject::IsRegisteredToggleRef()
Microsoft.iOS.dll:System.Boolean Foundation.NSObject::RemoveFromObjectMap()
Microsoft.iOS.dll:System.Boolean Foundation.NSObject/NSObject_Disposer::draining
-Microsoft.iOS.dll:System.Boolean Foundation.NSObjectDataHandle::invalidated
-Microsoft.iOS.dll:System.Boolean Foundation.NSObjectDataHandle::IsInvalid()
Microsoft.iOS.dll:System.Boolean Foundation.ProtocolAttribute::k__BackingField
Microsoft.iOS.dll:System.Boolean Foundation.ProtocolAttribute::k__BackingField
Microsoft.iOS.dll:System.Boolean Foundation.ProtocolAttribute::IsInformal()
@@ -1327,6 +1321,7 @@ Microsoft.iOS.dll:System.Int64 Foundation.NSComparisonResult::value__
Microsoft.iOS.dll:System.IntPtr CoreFoundation.CFArray::_CFNullHandle()
Microsoft.iOS.dll:System.IntPtr CoreFoundation.CFRange::len
Microsoft.iOS.dll:System.IntPtr CoreFoundation.CFRange::loc
+Microsoft.iOS.dll:System.IntPtr Foundation.NSObject::__data
Microsoft.iOS.dll:System.IntPtr Foundation.NSObject/NSObject_Disposer::class_ptr
Microsoft.iOS.dll:System.IntPtr ObjCRuntime.AdoptsAttribute::ProtocolHandle()
Microsoft.iOS.dll:System.IntPtr ObjCRuntime.BlockCollector::block
@@ -1488,8 +1483,10 @@ Microsoft.iOS.dll:System.Reflection.MethodBase Registrar.Registrar::invoke_confo
Microsoft.iOS.dll:System.Reflection.MethodBase Registrar.Registrar/ObjCMethod::Method
Microsoft.iOS.dll:System.Reflection.PropertyInfo Registrar.Registrar/ObjCProperty::Property
Microsoft.iOS.dll:System.Reflection.TypeFilter Registrar.SharedDynamic/<>c::<>9__0_0
+Microsoft.iOS.dll:System.Runtime.CompilerServices.ConditionalWeakTable`2 Foundation.NSObject::data_table
Microsoft.iOS.dll:System.Runtime.CompilerServices.ConditionalWeakTable`2 ObjCRuntime.Runtime::block_lifetime_table
Microsoft.iOS.dll:System.Runtime.CompilerServices.ConditionalWeakTable`2 ObjCRuntime.Class::assembly_to_name
+Microsoft.iOS.dll:System.Runtime.InteropServices.GCHandle Foundation.NSObjectDataHandle::handle
Microsoft.iOS.dll:System.Runtime.InteropServices.NFloat CoreGraphics.CGRect::height
Microsoft.iOS.dll:System.Runtime.InteropServices.NFloat CoreGraphics.CGRect::width
Microsoft.iOS.dll:System.Runtime.InteropServices.NFloat CoreGraphics.CGRect::x
@@ -2710,14 +2707,12 @@ System.Private.CoreLib.dll:System.Boolean System.Runtime.CompilerServices.Runtim
System.Private.CoreLib.dll:System.Boolean System.Runtime.CompilerServices.RuntimeFeature::k__BackingField
System.Private.CoreLib.dll:System.Boolean System.Runtime.CompilerServices.RuntimeFeature::IsDynamicCodeSupported()
System.Private.CoreLib.dll:System.Boolean System.Runtime.DependentHandle::IsAllocated()
-System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.CriticalHandle::_isClosed
-System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.CriticalHandle::IsClosed()
-System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.CriticalHandle::IsInvalid()
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::BestFitMapping
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::ExactSpelling
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::PreserveSig
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::SetLastError
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::ThrowOnUnmappableChar
+System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.GCHandle::IsAllocated()
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller`1/ManagedToUnmanagedIn::_addRefd
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller`1/ManagedToUnmanagedOut::_initialized
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.Marshalling.Utf8StringMarshaller/ManagedToUnmanagedIn::_allocated
@@ -6888,7 +6883,6 @@ System.Private.CoreLib.dll:System.IntPtr System.Reflection.RuntimePropertyInfo::
System.Private.CoreLib.dll:System.IntPtr System.Reflection.RuntimePropertyInfo::prop
System.Private.CoreLib.dll:System.IntPtr System.Runtime.CompilerServices.QCallAssembly::_assembly
System.Private.CoreLib.dll:System.IntPtr System.Runtime.CompilerServices.QCallTypeHandle::_handle
-System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.CriticalHandle::handle
System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.GCHandle::_handle
System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.SafeHandle::handle
System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.WeakGCHandle`1::_handle
@@ -10773,15 +10767,6 @@ System.Private.CoreLib.dll:System.Runtime.InteropServices.CollectionsMarshal
System.Private.CoreLib.dll:System.Runtime.InteropServices.CollectionsMarshal.GetValueRefOrAddDefault`2(System.Collections.Generic.Dictionary`2, TKey, out System.Boolean&)
System.Private.CoreLib.dll:System.Runtime.InteropServices.ComImportAttribute
System.Private.CoreLib.dll:System.Runtime.InteropServices.ComImportAttribute..ctor()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle..ctor(System.IntPtr)
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Cleanup()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Dispose()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Dispose(System.Boolean)
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Finalize()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.get_IsClosed()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.get_IsInvalid()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.ReleaseHandle()
System.Private.CoreLib.dll:System.Runtime.InteropServices.DefaultDllImportSearchPathsAttribute
System.Private.CoreLib.dll:System.Runtime.InteropServices.DefaultDllImportSearchPathsAttribute..ctor(System.Runtime.InteropServices.DllImportSearchPath)
System.Private.CoreLib.dll:System.Runtime.InteropServices.DllImportAttribute
@@ -10810,6 +10795,7 @@ System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.Equals(System
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.Equals(System.Runtime.InteropServices.GCHandle)
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.Free()
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.FromIntPtr(System.IntPtr)
+System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.get_IsAllocated()
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.get_Target()
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.GetHandleValue(System.IntPtr)
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.GetHashCode()
diff --git a/tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-size.txt b/tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-size.txt
index 95938f6bec29..a8a3f09e5f33 100644
--- a/tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-size.txt
+++ b/tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-size.txt
@@ -1,14 +1,14 @@
-AppBundleSize: 3,603,919 bytes (3,519.5 KB = 3.4 MB)
+AppBundleSize: 3,602,372 bytes (3,517.9 KB = 3.4 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 3,997 bytes (3.9 KB = 0.0 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,141 bytes (1.1 KB = 0.0 MB)
-Microsoft.iOS.dll: 155,136 bytes (151.5 KB = 0.1 MB)
+Info.plist: 1,154 bytes (1.1 KB = 0.0 MB)
+Microsoft.iOS.dll: 154,112 bytes (150.5 KB = 0.1 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,405 bytes (1.4 KB = 0.0 MB)
SizeTestApp: 2,390,848 bytes (2,334.8 KB = 2.3 MB)
SizeTestApp.dll: 7,680 bytes (7.5 KB = 0.0 MB)
-System.Private.CoreLib.aotdata.arm64: 41,336 bytes (40.4 KB = 0.0 MB)
-System.Private.CoreLib.dll: 988,672 bytes (965.5 KB = 0.9 MB)
+System.Private.CoreLib.aotdata.arm64: 41,312 bytes (40.3 KB = 0.0 MB)
+System.Private.CoreLib.dll: 988,160 bytes (965.0 KB = 0.9 MB)
System.Runtime.dll: 5,120 bytes (5.0 KB = 0.0 MB)
System.Runtime.InteropServices.dll: 8,192 bytes (8.0 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/iOS-MonoVM-preservedapis.txt b/tests/dotnet/UnitTests/expected/iOS-MonoVM-preservedapis.txt
index b10321267993..9636d8f67412 100644
--- a/tests/dotnet/UnitTests/expected/iOS-MonoVM-preservedapis.txt
+++ b/tests/dotnet/UnitTests/expected/iOS-MonoVM-preservedapis.txt
@@ -99,7 +99,6 @@ Microsoft.iOS.dll:Foundation.NSObject..ctor()
Microsoft.iOS.dll:Foundation.NSObject..ctor(Foundation.NSObjectFlag)
Microsoft.iOS.dll:Foundation.NSObject..ctor(ObjCRuntime.NativeHandle, System.Boolean)
Microsoft.iOS.dll:Foundation.NSObject..ctor(ObjCRuntime.NativeHandle)
-Microsoft.iOS.dll:Foundation.NSObject.AllocateData()
Microsoft.iOS.dll:Foundation.NSObject.AllocIfNeeded()
Microsoft.iOS.dll:Foundation.NSObject.ClearHandle()
Microsoft.iOS.dll:Foundation.NSObject.ConformsToProtocol(ObjCRuntime.NativeHandle)
@@ -136,7 +135,6 @@ Microsoft.iOS.dll:Foundation.NSObject.InitializeHandle(ObjCRuntime.NativeHandle,
Microsoft.iOS.dll:Foundation.NSObject.InitializeObject(System.Boolean)
Microsoft.iOS.dll:Foundation.NSObject.InvokeConformsToProtocol(ObjCRuntime.NativeHandle)
Microsoft.iOS.dll:Foundation.NSObject.IsEqual(Foundation.NSObject)
-Microsoft.iOS.dll:Foundation.NSObject.RecreateDataHandle()
Microsoft.iOS.dll:Foundation.NSObject.ReleaseManagedRef()
Microsoft.iOS.dll:Foundation.NSObject.set_disposed(System.Boolean)
Microsoft.iOS.dll:Foundation.NSObject.set_flags(Foundation.NSObject/Flags)
@@ -174,16 +172,13 @@ Microsoft.iOS.dll:Foundation.NSObject/XamarinGCHandleFlags Foundation.NSObject/X
Microsoft.iOS.dll:Foundation.NSObject/XamarinGCHandleFlags Foundation.NSObject/XamarinGCHandleFlags::InitialSet
Microsoft.iOS.dll:Foundation.NSObject/XamarinGCHandleFlags Foundation.NSObject/XamarinGCHandleFlags::None
Microsoft.iOS.dll:Foundation.NSObjectData
-Microsoft.iOS.dll:Foundation.NSObjectData* Foundation.NSObject::__data_for_mono
+Microsoft.iOS.dll:Foundation.NSObjectData* Foundation.NSObjectDataHandle::data
Microsoft.iOS.dll:Foundation.NSObjectData* Foundation.NSObjectDataHandle::Data()
Microsoft.iOS.dll:Foundation.NSObjectDataHandle
-Microsoft.iOS.dll:Foundation.NSObjectDataHandle Foundation.NSObject::data_handle
Microsoft.iOS.dll:Foundation.NSObjectDataHandle..ctor()
-Microsoft.iOS.dll:Foundation.NSObjectDataHandle..ctor(System.IntPtr)
+Microsoft.iOS.dll:Foundation.NSObjectDataHandle.CreateHandle(Foundation.NSObject)
+Microsoft.iOS.dll:Foundation.NSObjectDataHandle.Finalize()
Microsoft.iOS.dll:Foundation.NSObjectDataHandle.get_Data()
-Microsoft.iOS.dll:Foundation.NSObjectDataHandle.get_IsInvalid()
-Microsoft.iOS.dll:Foundation.NSObjectDataHandle.Invalidate()
-Microsoft.iOS.dll:Foundation.NSObjectDataHandle.ReleaseHandle()
Microsoft.iOS.dll:Foundation.NSObjectFlag
Microsoft.iOS.dll:Foundation.NSObjectFlag Foundation.NSObjectFlag::Empty
Microsoft.iOS.dll:Foundation.ProtocolAttribute
@@ -450,6 +445,7 @@ Microsoft.iOS.dll:ObjCRuntime.Runtime.g__ConstructINativ
Microsoft.iOS.dll:ObjCRuntime.Runtime.g__ConstructNSObjectViaFactoryMethod|288_0`1(ObjCRuntime.NativeHandle)
Microsoft.iOS.dll:ObjCRuntime.Runtime.AllocGCHandle(System.Object, System.Runtime.InteropServices.GCHandleType)
Microsoft.iOS.dll:ObjCRuntime.Runtime.AllocGCHandle(System.Object)
+Microsoft.iOS.dll:ObjCRuntime.Runtime.AllocZeroed`1()
Microsoft.iOS.dll:ObjCRuntime.Runtime.AppendAdditionalInformation(System.Text.StringBuilder, System.IntPtr, System.RuntimeMethodHandle)
Microsoft.iOS.dll:ObjCRuntime.Runtime.attempt_retain_nsobject(System.IntPtr, System.IntPtr*)
Microsoft.iOS.dll:ObjCRuntime.Runtime.AttemptRetainNSObject(System.IntPtr)
@@ -662,8 +658,6 @@ Microsoft.iOS.dll:System.Boolean Foundation.NSObject::InFinalizerQueue()
Microsoft.iOS.dll:System.Boolean Foundation.NSObject::IsDirectBinding()
Microsoft.iOS.dll:System.Boolean Foundation.NSObject::IsRegisteredToggleRef()
Microsoft.iOS.dll:System.Boolean Foundation.NSObject/NSObject_Disposer::draining
-Microsoft.iOS.dll:System.Boolean Foundation.NSObjectDataHandle::invalidated
-Microsoft.iOS.dll:System.Boolean Foundation.NSObjectDataHandle::IsInvalid()
Microsoft.iOS.dll:System.Boolean Foundation.ProtocolAttribute::k__BackingField
Microsoft.iOS.dll:System.Boolean Foundation.RegisterAttribute::is_wrapper
Microsoft.iOS.dll:System.Boolean Foundation.RegisterAttribute::IsWrapper()
@@ -719,6 +713,7 @@ Microsoft.iOS.dll:System.Int32 ObjCRuntime.TransientString/Encoding::value__
Microsoft.iOS.dll:System.IntPtr CoreFoundation.CFArray::_CFNullHandle()
Microsoft.iOS.dll:System.IntPtr CoreFoundation.CFRange::len
Microsoft.iOS.dll:System.IntPtr CoreFoundation.CFRange::loc
+Microsoft.iOS.dll:System.IntPtr Foundation.NSObject::__data
Microsoft.iOS.dll:System.IntPtr Foundation.NSObject/NSObject_Disposer::class_ptr
Microsoft.iOS.dll:System.IntPtr ObjCRuntime.BlockCollector::block
Microsoft.iOS.dll:System.IntPtr ObjCRuntime.Libraries/CoreFoundation::Handle
@@ -848,8 +843,10 @@ Microsoft.iOS.dll:System.IntPtr* ObjCRuntime.Runtime/MTRegistrationMap::classHan
Microsoft.iOS.dll:System.Object Foundation.NSObject/NSObject_Disposer::lock_obj
Microsoft.iOS.dll:System.Object ObjCRuntime.Runtime::lock_obj
Microsoft.iOS.dll:System.Reflection.Assembly Foundation.NSObject::PlatformAssembly
+Microsoft.iOS.dll:System.Runtime.CompilerServices.ConditionalWeakTable`2 Foundation.NSObject::data_table
Microsoft.iOS.dll:System.Runtime.CompilerServices.ConditionalWeakTable`2 ObjCRuntime.Runtime::block_lifetime_table
Microsoft.iOS.dll:System.Runtime.CompilerServices.ConditionalWeakTable`2 ObjCRuntime.Class::assembly_to_name
+Microsoft.iOS.dll:System.Runtime.InteropServices.GCHandle Foundation.NSObjectDataHandle::handle
Microsoft.iOS.dll:System.Runtime.InteropServices.NFloat CoreGraphics.CGRect::height
Microsoft.iOS.dll:System.Runtime.InteropServices.NFloat CoreGraphics.CGRect::width
Microsoft.iOS.dll:System.Runtime.InteropServices.NFloat CoreGraphics.CGRect::x
@@ -1943,14 +1940,12 @@ System.Private.CoreLib.dll:System.Boolean System.Runtime.CompilerServices.Nullab
System.Private.CoreLib.dll:System.Boolean System.Runtime.CompilerServices.RuntimeCompatibilityAttribute::k__BackingField
System.Private.CoreLib.dll:System.Boolean System.Runtime.CompilerServices.RuntimeCompatibilityAttribute::WrapNonExceptionThrows()
System.Private.CoreLib.dll:System.Boolean System.Runtime.DependentHandle::IsAllocated()
-System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.CriticalHandle::_isClosed
-System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.CriticalHandle::IsClosed()
-System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.CriticalHandle::IsInvalid()
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::BestFitMapping
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::ExactSpelling
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::PreserveSig
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::SetLastError
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.DllImportAttribute::ThrowOnUnmappableChar
+System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.GCHandle::IsAllocated()
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller`1/ManagedToUnmanagedIn::_addRefd
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.Marshalling.SafeHandleMarshaller`1/ManagedToUnmanagedOut::_initialized
System.Private.CoreLib.dll:System.Boolean System.Runtime.InteropServices.Marshalling.Utf8StringMarshaller/ManagedToUnmanagedIn::_allocated
@@ -5969,7 +5964,6 @@ System.Private.CoreLib.dll:System.IntPtr System.Reflection.RuntimePropertyInfo::
System.Private.CoreLib.dll:System.IntPtr System.Reflection.RuntimePropertyInfo::prop
System.Private.CoreLib.dll:System.IntPtr System.Runtime.CompilerServices.QCallAssembly::_assembly
System.Private.CoreLib.dll:System.IntPtr System.Runtime.CompilerServices.QCallTypeHandle::_handle
-System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.CriticalHandle::handle
System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.GCHandle::_handle
System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.SafeHandle::handle
System.Private.CoreLib.dll:System.IntPtr System.Runtime.InteropServices.WeakGCHandle`1::_handle
@@ -8485,15 +8479,6 @@ System.Private.CoreLib.dll:System.Runtime.InteropServices.CollectionsMarshal
System.Private.CoreLib.dll:System.Runtime.InteropServices.CollectionsMarshal.GetValueRefOrAddDefault`2(System.Collections.Generic.Dictionary`2, TKey, out System.Boolean&)
System.Private.CoreLib.dll:System.Runtime.InteropServices.ComImportAttribute
System.Private.CoreLib.dll:System.Runtime.InteropServices.ComImportAttribute..ctor()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle..ctor(System.IntPtr)
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Cleanup()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Dispose()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Dispose(System.Boolean)
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.Finalize()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.get_IsClosed()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.get_IsInvalid()
-System.Private.CoreLib.dll:System.Runtime.InteropServices.CriticalHandle.ReleaseHandle()
System.Private.CoreLib.dll:System.Runtime.InteropServices.DefaultDllImportSearchPathsAttribute
System.Private.CoreLib.dll:System.Runtime.InteropServices.DefaultDllImportSearchPathsAttribute..ctor(System.Runtime.InteropServices.DllImportSearchPath)
System.Private.CoreLib.dll:System.Runtime.InteropServices.DllImportAttribute
@@ -8521,6 +8506,7 @@ System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.Equals(System
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.Equals(System.Runtime.InteropServices.GCHandle)
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.Free()
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.FromIntPtr(System.IntPtr)
+System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.get_IsAllocated()
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.get_Target()
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.GetHandleValue(System.IntPtr)
System.Private.CoreLib.dll:System.Runtime.InteropServices.GCHandle.GetHashCode()
diff --git a/tests/dotnet/UnitTests/expected/iOS-MonoVM-size.txt b/tests/dotnet/UnitTests/expected/iOS-MonoVM-size.txt
index c86caef51f9b..34257d903055 100644
--- a/tests/dotnet/UnitTests/expected/iOS-MonoVM-size.txt
+++ b/tests/dotnet/UnitTests/expected/iOS-MonoVM-size.txt
@@ -1,17 +1,17 @@
-AppBundleSize: 9,338,363 bytes (9,119.5 KB = 8.9 MB)
+AppBundleSize: 9,338,488 bytes (9,119.6 KB = 8.9 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 5,229 bytes (5.1 KB = 0.0 MB)
aot-instances.aotdata.arm64: 827,592 bytes (808.2 KB = 0.8 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,141 bytes (1.1 KB = 0.0 MB)
-Microsoft.iOS.aotdata.arm64: 22,992 bytes (22.5 KB = 0.0 MB)
-Microsoft.iOS.dll: 49,152 bytes (48.0 KB = 0.0 MB)
+Info.plist: 1,154 bytes (1.1 KB = 0.0 MB)
+Microsoft.iOS.aotdata.arm64: 23,240 bytes (22.7 KB = 0.0 MB)
+Microsoft.iOS.dll: 48,640 bytes (47.5 KB = 0.0 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,481 bytes (1.4 KB = 0.0 MB)
SizeTestApp: 7,235,120 bytes (7,065.5 KB = 6.9 MB)
SizeTestApp.aotdata.arm64: 1,464 bytes (1.4 KB = 0.0 MB)
-SizeTestApp.dll: 7,168 bytes (7.0 KB = 0.0 MB)
-System.Private.CoreLib.aotdata.arm64: 640,792 bytes (625.8 KB = 0.6 MB)
+SizeTestApp.dll: 7,680 bytes (7.5 KB = 0.0 MB)
+System.Private.CoreLib.aotdata.arm64: 640,656 bytes (625.6 KB = 0.6 MB)
System.Private.CoreLib.dll: 530,944 bytes (518.5 KB = 0.5 MB)
System.Runtime.aotdata.arm64: 784 bytes (0.8 KB = 0.0 MB)
System.Runtime.dll: 5,120 bytes (5.0 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/iOS-NativeAOT-TrimmableStatic-size.txt b/tests/dotnet/UnitTests/expected/iOS-NativeAOT-TrimmableStatic-size.txt
index a367ebbb43e2..21809140aee4 100644
--- a/tests/dotnet/UnitTests/expected/iOS-NativeAOT-TrimmableStatic-size.txt
+++ b/tests/dotnet/UnitTests/expected/iOS-NativeAOT-TrimmableStatic-size.txt
@@ -1,8 +1,8 @@
-AppBundleSize: 9,038,986 bytes (8,827.1 KB = 8.6 MB)
+AppBundleSize: 9,022,567 bytes (8,811.1 KB = 8.6 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 2,589 bytes (2.5 KB = 0.0 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,141 bytes (1.1 KB = 0.0 MB)
+Info.plist: 1,154 bytes (1.1 KB = 0.0 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,888 bytes (1.8 KB = 0.0 MB)
-SizeTestApp: 9,032,976 bytes (8,821.3 KB = 8.6 MB)
+SizeTestApp: 9,016,544 bytes (8,805.2 KB = 8.6 MB)
diff --git a/tests/dotnet/UnitTests/expected/iOS-NativeAOT-size.txt b/tests/dotnet/UnitTests/expected/iOS-NativeAOT-size.txt
index f137a40fb64b..8b40666ad139 100644
--- a/tests/dotnet/UnitTests/expected/iOS-NativeAOT-size.txt
+++ b/tests/dotnet/UnitTests/expected/iOS-NativeAOT-size.txt
@@ -1,8 +1,8 @@
-AppBundleSize: 2,783,882 bytes (2,718.6 KB = 2.7 MB)
+AppBundleSize: 2,783,879 bytes (2,718.6 KB = 2.7 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 2,589 bytes (2.5 KB = 0.0 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,141 bytes (1.1 KB = 0.0 MB)
+Info.plist: 1,154 bytes (1.1 KB = 0.0 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,808 bytes (1.8 KB = 0.0 MB)
-SizeTestApp: 2,777,952 bytes (2,712.8 KB = 2.6 MB)
+SizeTestApp: 2,777,936 bytes (2,712.8 KB = 2.6 MB)
From 4d19356164c94e89e8702460ff52a908063144e0 Mon Sep 17 00:00:00 2001
From: "CSIGS@microsoft.com"
Date: Wed, 13 May 2026 07:39:03 -0700
Subject: [PATCH 049/156] LEGO: Pull request from
lego/hb_5df43909-4a19-4f55-bc3f-9ea8fccf3c82_20260508175345648 to main
(#25377)
LEGO: Pull request from lego/hb_5df43909-4a19-4f55-bc3f-9ea8fccf3c82_20260508175345648 to main with localized lcls
---
.../fr/macios/tools/mtouch/Errors.resx.lcl | 36 +++++++++++++++++++
.../it/macios/tools/mtouch/Errors.resx.lcl | 36 +++++++++++++++++++
.../ja/macios/tools/mtouch/Errors.resx.lcl | 36 +++++++++++++++++++
.../pt-BR/macios/tools/mtouch/Errors.resx.lcl | 36 +++++++++++++++++++
.../ru/macios/tools/mtouch/Errors.resx.lcl | 36 +++++++++++++++++++
.../macios/tools/mtouch/Errors.resx.lcl | 36 +++++++++++++++++++
6 files changed, 216 insertions(+)
diff --git a/macios/Localize/loc/fr/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/fr/macios/tools/mtouch/Errors.resx.lcl
index 8ef8855f9da5..439ef012fd7b 100644
--- a/macios/Localize/loc/fr/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/fr/macios/tools/mtouch/Errors.resx.lcl
@@ -4501,6 +4501,42 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/it/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/it/macios/tools/mtouch/Errors.resx.lcl
index db37a2986208..8d2aabef8e04 100644
--- a/macios/Localize/loc/it/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/it/macios/tools/mtouch/Errors.resx.lcl
@@ -4501,6 +4501,42 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/ja/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/ja/macios/tools/mtouch/Errors.resx.lcl
index b3fd520db049..c50f56ff5b52 100644
--- a/macios/Localize/loc/ja/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/ja/macios/tools/mtouch/Errors.resx.lcl
@@ -4501,6 +4501,42 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/pt-BR/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/pt-BR/macios/tools/mtouch/Errors.resx.lcl
index b6e107f5acc2..e3b73c2c3c7c 100644
--- a/macios/Localize/loc/pt-BR/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/pt-BR/macios/tools/mtouch/Errors.resx.lcl
@@ -4501,6 +4501,42 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/ru/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/ru/macios/tools/mtouch/Errors.resx.lcl
index e076f441c2eb..0db83b0b25dc 100644
--- a/macios/Localize/loc/ru/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/ru/macios/tools/mtouch/Errors.resx.lcl
@@ -4501,6 +4501,42 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/zh-Hans/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/zh-Hans/macios/tools/mtouch/Errors.resx.lcl
index a2d73ba8d17a..1cd1c84e82c5 100644
--- a/macios/Localize/loc/zh-Hans/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/zh-Hans/macios/tools/mtouch/Errors.resx.lcl
@@ -4501,6 +4501,42 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
From 3c5f6c6dee232a1cc70dcf11b5c6d0e7c2cdbb73 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Wed, 13 May 2026 16:43:22 +0200
Subject: [PATCH 050/156] [xharness] Honor system dark mode in xharness web UI
(#25401)
Add @media (prefers-color-scheme: dark) rules to xharness.css with
dark background, light text, and appropriate link/nav colors. Replace
hardcoded 'black' color values with 'currentcolor' so text remains
visible in both light and dark modes. Use CSS system color 'Canvas'
for nav dropdown background instead of hardcoded #ffffff.
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
.../Jenkins/Reports/HtmlReportWriter.cs | 2 +-
.../Jenkins/TestTasks/ITestTaskExtensions.cs | 8 +++---
tests/xharness/xharness.css | 26 ++++++++++++++++++-
3 files changed, 30 insertions(+), 6 deletions(-)
diff --git a/tests/xharness/Jenkins/Reports/HtmlReportWriter.cs b/tests/xharness/Jenkins/Reports/HtmlReportWriter.cs
index 670799a45514..38f48645f457 100644
--- a/tests/xharness/Jenkins/Reports/HtmlReportWriter.cs
+++ b/tests/xharness/Jenkins/Reports/HtmlReportWriter.cs
@@ -124,7 +124,7 @@ public void Write (IList allTasks, StreamWriter writer)
writer.WriteLine ("{1}
", GetLinkFullPath (log.FullPath.Substring (jenkins.LogDirectory.Length + 1)), log.Description);
writer.WriteLine ("");
- var headerColor = "black";
+ var headerColor = "currentcolor";
if (unfinishedTests.Any ()) {
; // default
} else if (failedTests.Any ()) {
diff --git a/tests/xharness/Jenkins/TestTasks/ITestTaskExtensions.cs b/tests/xharness/Jenkins/TestTasks/ITestTaskExtensions.cs
index 1992fdc66afa..5c68672fe0c3 100644
--- a/tests/xharness/Jenkins/TestTasks/ITestTaskExtensions.cs
+++ b/tests/xharness/Jenkins/TestTasks/ITestTaskExtensions.cs
@@ -7,7 +7,7 @@ public static class ITestTaskExtensions {
public static string GetTestColor (this IEnumerable tests)
{
if (!tests.Any ())
- return "black";
+ return "currentcolor";
var first = tests.First ();
if (tests.All ((v) => v.ExecutionResult == first.ExecutionResult))
@@ -23,7 +23,7 @@ public static string GetTestColor (this IEnumerable tests)
else if (tests.Any ((v) => v.Failed))
return "red";
else if (tests.Any ((v) => v.NotStarted))
- return "black";
+ return "currentcolor";
else if (tests.Any ((v) => v.Ignored))
return "gray";
else if (tests.Any ((v) => v.DeviceNotFound))
@@ -33,13 +33,13 @@ public static string GetTestColor (this IEnumerable tests)
else if (tests.All ((v) => v.Succeeded))
return "green";
else
- return "black";
+ return "currentcolor";
}
public static string GetTestColor (this TestTask test)
{
if (test.NotStarted) {
- return "black";
+ return "currentcolor";
} else if (test.InProgress) {
if (test.Building) {
return "darkblue";
diff --git a/tests/xharness/xharness.css b/tests/xharness/xharness.css
index f00919012edf..6753e130b1e5 100644
--- a/tests/xharness/xharness.css
+++ b/tests/xharness/xharness.css
@@ -1,3 +1,27 @@
+:root {
+ color-scheme: light dark;
+}
+
+@media (prefers-color-scheme: dark) {
+ body {
+ background-color: #1e1e1e;
+ color: #d4d4d4;
+ }
+
+ a {
+ color: #6db3f2;
+ }
+
+ a:visited {
+ color: #b48ead;
+ }
+
+ #nav ul {
+ background: #2d2d2d;
+ border-color: #555;
+ }
+}
+
.pdiv {
display: table;
padding-top: 10px;
@@ -43,7 +67,7 @@
}
#nav ul {
- background: #ffffff;
+ background: Canvas;
list-style: none;
position: absolute;
left: -9999px;
From 672b410c72629496bb24147a3676aeb69ec60df8 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Wed, 13 May 2026 20:16:57 +0200
Subject: [PATCH 051/156] [tools] Fix IL2009 warning for generic types in
linker XML descriptors (#25415)
When a method has generic parameter types (like 'T' in Callback),
the linker XML descriptor can't resolve the generic parameter name in
the method signature. Use the method 'name' attribute instead of
'signature' for such methods, which matches by name and avoids the
IL2009 warning.
Fixes this warning, which shows up in MAUI's tests (and our own too, just not
in a place where we were validating warnings):
> warning IL2009: Could not find method 'System.Void Activated(T)' on type 'UIKit.UIGestureRecognizer.Callback`1'
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
tests/dotnet/UnitTests/ProjectTest.cs | 48 +++++++++++++++++++
.../ApplyPreserveAttributeStep.cs | 32 +++++++++++--
2 files changed, 76 insertions(+), 4 deletions(-)
diff --git a/tests/dotnet/UnitTests/ProjectTest.cs b/tests/dotnet/UnitTests/ProjectTest.cs
index 1361fb4b26b2..23d89f113666 100644
--- a/tests/dotnet/UnitTests/ProjectTest.cs
+++ b/tests/dotnet/UnitTests/ProjectTest.cs
@@ -2583,6 +2583,54 @@ public void PublishAot (ApplePlatform platform, string runtimeIdentifiers, strin
});
}
+ [Test]
+ [TestCase (ApplePlatform.iOS, "iossimulator-arm64")]
+ [TestCase (ApplePlatform.MacCatalyst, "maccatalyst-arm64")]
+ [TestCase (ApplePlatform.TVOS, "tvossimulator-arm64")]
+ [TestCase (ApplePlatform.MacOSX, "osx-arm64")]
+ public void PublishAotMonoTouchTest_NoIL2009 (ApplePlatform platform, string runtimeIdentifiers)
+ {
+ Configuration.IgnoreIfIgnoredPlatform (platform);
+ Configuration.AssertRuntimeIdentifiersAvailable (platform, runtimeIdentifiers);
+
+ var project_path = Path.Combine (Configuration.SourceRoot, "tests", "monotouch-test", "dotnet", platform.AsString (), "monotouch-test.csproj");
+ Clean (project_path);
+ var properties = GetDefaultProperties (runtimeIdentifiers);
+ properties ["PublishAot"] = "true";
+ properties ["_IsPublishing"] = "true";
+ properties ["TrimmerSingleWarn"] = "false";
+ var rv = DotNet.AssertBuild (project_path, properties);
+
+ var config = "Debug";
+ var runtimeIdentifierInfix = $"/{runtimeIdentifiers}/";
+ var warnings = BinLog.GetBuildLogWarnings (rv.BinLogPath)
+ .Where (evt => {
+ if (platform == ApplePlatform.iOS && evt.Message?.Trim () == "Supported iPhone orientations have not been set")
+ return false;
+ return true;
+ });
+ var expectedWarnings = new ExpectedBuildMessage [] {
+ new ExpectedBuildMessage ($"ILLINK", $"It's not safe to remove the dynamic registrar, because monotouchtest references 'ObjCRuntime.Runtime.ConnectMethod (System.Reflection.MethodInfo, ObjCRuntime.Selector)'."),
+ new ExpectedBuildMessage ($"ILLINK", $"It's not safe to remove the dynamic registrar, because monotouchtest references 'ObjCRuntime.Runtime.ConnectMethod (System.Type, System.Reflection.MethodInfo, Foundation.ExportAttribute)'."),
+ new ExpectedBuildMessage ($"ILLINK", $"It's not safe to remove the dynamic registrar, because monotouchtest references 'ObjCRuntime.Runtime.ConnectMethod (System.Type, System.Reflection.MethodInfo, ObjCRuntime.Selector)'."),
+ new ExpectedBuildMessage ($"ILLINK", $"It's not safe to remove the dynamic registrar, because monotouchtest references 'ObjCRuntime.Runtime.RegisterAssembly (System.Reflection.Assembly)'."),
+ new ExpectedBuildMessage ($"tests/bindings-test/RegistrarBindingTest.cs", $"Unable to locate the block to delegate conversion method for the method System.Void Xamarin.BindingTests.RegistrarBindingTest/FakePropertyBlock::set_MyOptionalProperty(Bindings.Test.SimpleCallback)'s parameter #1."),
+ new ExpectedBuildMessage ($"tests/bindings-test/RegistrarBindingTest.cs", $"Unable to locate the block to delegate conversion method for the method System.Void Xamarin.BindingTests.RegistrarBindingTest/FakePropertyBlock::set_MyOptionalStaticProperty(Bindings.Test.SimpleCallback)'s parameter #1."),
+ new ExpectedBuildMessage ($"tests/bindings-test/RegistrarBindingTest.cs", $"Unable to locate the block to delegate conversion method for the method System.Void Xamarin.BindingTests.RegistrarBindingTest/FakePropertyBlock::set_MyRequiredProperty(Bindings.Test.SimpleCallback)'s parameter #1."),
+ new ExpectedBuildMessage ($"tests/bindings-test/RegistrarBindingTest.cs", $"Unable to locate the block to delegate conversion method for the method System.Void Xamarin.BindingTests.RegistrarBindingTest/FakePropertyBlock::set_MyRequiredStaticProperty(Bindings.Test.SimpleCallback)'s parameter #1."),
+ new ExpectedBuildMessage ($"tests/bindings-test/RegistrarBindingTest.cs", $"Unable to locate the delegate to block conversion type for the return value of the method Bindings.Test.SimpleCallback Xamarin.BindingTests.RegistrarBindingTest/FakePropertyBlock::get_MyOptionalProperty()."),
+ new ExpectedBuildMessage ($"tests/bindings-test/RegistrarBindingTest.cs", $"Unable to locate the delegate to block conversion type for the return value of the method Bindings.Test.SimpleCallback Xamarin.BindingTests.RegistrarBindingTest/FakePropertyBlock::get_MyOptionalStaticProperty()."),
+ new ExpectedBuildMessage ($"tests/bindings-test/RegistrarBindingTest.cs", $"Unable to locate the delegate to block conversion type for the return value of the method Bindings.Test.SimpleCallback Xamarin.BindingTests.RegistrarBindingTest/FakePropertyBlock::get_MyRequiredProperty()."),
+ new ExpectedBuildMessage ($"tests/bindings-test/RegistrarBindingTest.cs", $"Unable to locate the delegate to block conversion type for the return value of the method Bindings.Test.SimpleCallback Xamarin.BindingTests.RegistrarBindingTest/FakePropertyBlock::get_MyRequiredStaticProperty()."),
+ new ExpectedBuildMessage ($"tests/monotouch-test/dotnet/{platform.AsString ()}/obj/{config}/{Configuration.DotNetTfm}-{platform.AsString ().ToLower ()}{runtimeIdentifierInfix}linked/nunit.framework.dll", $"Assembly 'nunit.framework' produced AOT analysis warnings."),
+ new ExpectedBuildMessage ($"tests/monotouch-test/ObjCRuntime/ClassTest.cs", $"MonoTouchFixtures.ObjCRuntime.ClassTest.GetHandle(): Using member 'System.Type.MakeArrayType()' which has 'RequiresDynamicCodeAttribute' can break functionality when AOT compiling. The code for an array of the specified type might not be available."),
+ new ExpectedBuildMessage ($"tests/monotouch-test/ObjCRuntime/RegistrarTest.cs", $"Unable to locate the block to delegate conversion method for the method System.Void MonoTouchFixtures.ObjCRuntime.GHIssue7733::DoWork(System.String,MonoTouchFixtures.ObjCRuntime.ACompletionHandler)'s parameter #2."),
+ new ExpectedBuildMessage ($"tests/monotouch-test/ObjCRuntime/RegistrarTest.cs", $"Unable to locate the block to delegate conversion method for the method System.Void MonoTouchFixtures.ObjCRuntime.RegistrarTest/ClosedGenericParameter::Foo(System.Action`1)'s parameter #1."),
+ new ExpectedBuildMessage ($"tests/monotouch-test/ObjCRuntime/RegistrarTest.cs", $"Unable to locate the block to delegate conversion method for the method System.Void MonoTouchFixtures.ObjCRuntime.RegistrarTest/RegistrarTestClass::TestNSAction(System.Action)'s parameter #1."),
+ };
+ warnings.AssertWarnings (expectedWarnings);
+ }
+
void AssertThatDylibExistsAndIsReidentified (string appPath, string dylibRelPath)
{
var dylibPath = Path.Join (appPath, "Contents", "MonoBundle", dylibRelPath);
diff --git a/tools/dotnet-linker/ApplyPreserveAttributeStep.cs b/tools/dotnet-linker/ApplyPreserveAttributeStep.cs
index d25a335b4d0c..18436ab2de88 100644
--- a/tools/dotnet-linker/ApplyPreserveAttributeStep.cs
+++ b/tools/dotnet-linker/ApplyPreserveAttributeStep.cs
@@ -25,7 +25,7 @@ public XmlTypeDescription (TypeDefinition type)
public bool PreserveFields { get; set; }
public bool PreserveType { get; set; }
public Dictionary Fields { get; } = new (StringComparer.Ordinal);
- public Dictionary Methods { get; } = new (StringComparer.Ordinal);
+ public Dictionary Methods { get; } = new (StringComparer.Ordinal);
}
ApplyPreserveAttributeImpl impl;
@@ -186,6 +186,20 @@ static string GetXmlSignature (MethodDefinition method)
return method.FullName.Substring (0, index) + method.FullName.Substring (index + marker.Length);
}
+ // Check if a method has any generic parameters in its signature (return type or parameter types).
+ // This includes generic parameters nested inside other types (e.g. Action, T[], ref T, Nullable).
+ // The linker XML descriptor can't resolve generic parameter names like 'T' in method signatures.
+ static bool HasGenericParameterInSignature (MethodDefinition method)
+ {
+ if (method.ReturnType.ContainsGenericParameter)
+ return true;
+ foreach (var param in method.Parameters) {
+ if (param.ParameterType.ContainsGenericParameter)
+ return true;
+ }
+ return false;
+ }
+
XmlTypeDescription GetOrCreateXmlDescription (TypeDefinition type)
{
var assemblyName = type.Module.Assembly.Name.Name;
@@ -222,7 +236,7 @@ void AddXmlDescription (TypeDefinition onType, MethodDefinition forMethod, bool
var description = GetOrCreateXmlDescription (onType);
if (!conditional)
description.PreserveType = true;
- description.Methods [GetXmlSignature (forMethod)] = conditional;
+ description.Methods [GetXmlSignature (forMethod)] = (conditional, forMethod);
}
void AddUnconditionalXmlDescription (IMetadataTokenProvider provider)
@@ -261,8 +275,18 @@ XElement CreateXmlTypeElement (XmlTypeDescription description)
foreach (var field in description.Fields.OrderBy (v => v.Key, System.StringComparer.Ordinal))
type.Add (new XElement ("field", new XAttribute ("name", field.Key), new XAttribute ("required", field.Value ? "false" : "true")));
- foreach (var method in description.Methods.OrderBy (v => v.Key, System.StringComparer.Ordinal))
- type.Add (new XElement ("method", new XAttribute ("signature", method.Key), new XAttribute ("required", method.Value ? "false" : "true")));
+ foreach (var method in description.Methods.OrderBy (v => v.Key, System.StringComparer.Ordinal)) {
+ var element = new XElement ("method");
+ // ILC (NativeAOT compiler) can't resolve generic parameter names (like 'T') in XML descriptor
+ // method signatures (see https://github.com/dotnet/runtime/issues/128121), so use the method
+ // name instead of the full signature when the method has generic parameter types.
+ if (HasGenericParameterInSignature (method.Value.Method))
+ element.SetAttributeValue ("name", method.Value.Method.Name);
+ else
+ element.SetAttributeValue ("signature", method.Key);
+ element.SetAttributeValue ("required", method.Value.Conditional ? "false" : "true");
+ type.Add (element);
+ }
return type;
}
From 75040aff7b2e198737803f1625ebe0e62cbe2bb7 Mon Sep 17 00:00:00 2001
From: "CSIGS@microsoft.com"
Date: Wed, 13 May 2026 11:17:40 -0700
Subject: [PATCH 052/156] LEGO: Pull request from
lego/hb_5df43909-4a19-4f55-bc3f-9ea8fccf3c82_20260513055157079 to main
(#25414)
LEGO: Pull request from lego/hb_5df43909-4a19-4f55-bc3f-9ea8fccf3c82_20260513055157079 to main with localized lcls
---
.../de/macios/tools/mtouch/Errors.resx.lcl | 72 +++++++++++++++++++
.../macios/tools/mtouch/Errors.resx.lcl | 72 +++++++++++++++++++
2 files changed, 144 insertions(+)
diff --git a/macios/Localize/loc/de/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/de/macios/tools/mtouch/Errors.resx.lcl
index 53208ba1ba08..272d0fd57cab 100644
--- a/macios/Localize/loc/de/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/de/macios/tools/mtouch/Errors.resx.lcl
@@ -4501,6 +4501,78 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/zh-Hant/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/zh-Hant/macios/tools/mtouch/Errors.resx.lcl
index 3d2193f28959..f987a2aa5168 100644
--- a/macios/Localize/loc/zh-Hant/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/zh-Hant/macios/tools/mtouch/Errors.resx.lcl
@@ -4501,6 +4501,78 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
From d230e9b6db8c22c30df5e610921230780efcf04f Mon Sep 17 00:00:00 2001
From: Copilot <198982749+Copilot@users.noreply.github.com>
Date: Wed, 13 May 2026 18:18:42 +0000
Subject: [PATCH 053/156] [tests] Treat unexpected cookie values as transient
network failures in cookie handler tests (#25419)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
`TestNSUrlSessionHandlerCookies` and `TestNSUrlSessionEphemeralHandlerCookies` were flaky across unrelated PRs because the CI-ignore guard only checked whether `Set-Cookie` headers were *present*, not whether they contained the expected value. When `httpbin.org` transiently returns a different cookie (e.g. from a CDN/load balancer), `managedCookieResult` is `true` but the value assertion fails — escaping the guard entirely.
## Changes
- **`tests/monotouch-test/System.Net.Http/MessageHandlers.cs`** — In `TestNSUrlSessionHandlerCookiesImpl`, pre-compute `managedHasExpectedCookie` / `nativeHasExpectedCookie` after the async block and fold them into the `IgnoreInCI` condition alongside the existing presence checks:
```csharp
// Before: only guarded on header presence
if (!completed || !managedCookieResult || !nativeCookieResult)
TestRuntime.IgnoreInCI ("Transient network failure - ignore in CI");
// After: also guard on expected cookie value
var managedHasExpectedCookie = managedCookies?.Any (v => v.StartsWith ("cookie=chocolate-chip;", StringComparison.Ordinal)) == true;
var nativeHasExpectedCookie = nativeCookies?.Any (v => v.StartsWith ("cookie=chocolate-chip;", StringComparison.Ordinal)) == true;
if (!completed || !managedCookieResult || !nativeCookieResult || !managedHasExpectedCookie || !nativeHasExpectedCookie)
TestRuntime.IgnoreInCI ("Transient network failure - ignore in CI");
```
The downstream assertions reuse the pre-computed booleans, keeping local runs semantically identical.
---------
Co-authored-by: rolfbjarne <249268+rolfbjarne@users.noreply.github.com>
---
tests/monotouch-test/System.Net.Http/MessageHandlers.cs | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/tests/monotouch-test/System.Net.Http/MessageHandlers.cs b/tests/monotouch-test/System.Net.Http/MessageHandlers.cs
index 7fe1bbc448db..949a29ecfe3f 100644
--- a/tests/monotouch-test/System.Net.Http/MessageHandlers.cs
+++ b/tests/monotouch-test/System.Net.Http/MessageHandlers.cs
@@ -107,14 +107,17 @@ void TestNSUrlSessionHandlerCookiesImpl (NSUrlSessionHandler nativeHandler)
Assert.That (nativeHandler.UseCookies, Is.EqualTo (true), "UseCookies");
}, out var ex);
- if (!completed || !managedCookieResult || !nativeCookieResult)
+ var managedHasExpectedCookie = managedCookies?.Any (v => v.StartsWith ("cookie=chocolate-chip;", StringComparison.Ordinal)) == true;
+ var nativeHasExpectedCookie = nativeCookies?.Any (v => v.StartsWith ("cookie=chocolate-chip;", StringComparison.Ordinal)) == true;
+
+ if (!completed || !managedCookieResult || !nativeCookieResult || !managedHasExpectedCookie || !nativeHasExpectedCookie)
TestRuntime.IgnoreInCI ("Transient network failure - ignore in CI");
Assert.IsTrue (completed, "Network request completed");
Assert.IsNull (ex, "Exception");
Assert.IsTrue (managedCookieResult, $"Failed to get managed cookies");
Assert.IsTrue (nativeCookieResult, $"Failed to get native cookies");
- Assert.That (managedCookies.Any (v => v.StartsWith ("cookie=chocolate-chip;", StringComparison.Ordinal)), Is.True, $"Managed Cookie Value");
- Assert.That (nativeCookies.Any (v => v.StartsWith ("cookie=chocolate-chip;", StringComparison.Ordinal)), Is.True, $"Native Cookie Value");
+ Assert.That (managedHasExpectedCookie, Is.True, $"Managed Cookie Value");
+ Assert.That (nativeHasExpectedCookie, Is.True, $"Native Cookie Value");
}
// ensure that we can use a cookie container to set the cookies for a url
From e67eb98d3e680e7086e9b785bd76c03d22061a24 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Wed, 13 May 2026 20:28:06 +0200
Subject: [PATCH 054/156] [main] Keep using the desktop MSBuild assemblies when
building from within Visual Studio. (#25417)
Keep using the desktop MSBuild assemblies when building from within Visual
Studio, while we track down why it's not working and fix it for a future release.
Ref: https://devdiv.visualstudio.com/DevDiv/_workitems/edit/2968169
Ref: https://github.com/dotnet/macios/issues/25418
Backport of #25249.
---
dotnet/Microsoft.iOS.Sdk/targets/Microsoft.iOS.Sdk.props | 1 +
1 file changed, 1 insertion(+)
diff --git a/dotnet/Microsoft.iOS.Sdk/targets/Microsoft.iOS.Sdk.props b/dotnet/Microsoft.iOS.Sdk/targets/Microsoft.iOS.Sdk.props
index 563467607ff5..4f21cc40f0a9 100644
--- a/dotnet/Microsoft.iOS.Sdk/targets/Microsoft.iOS.Sdk.props
+++ b/dotnet/Microsoft.iOS.Sdk/targets/Microsoft.iOS.Sdk.props
@@ -4,6 +4,7 @@
<_PlatformName>iOS
<_PlatformRidNoArch>ios
+ <_UseDesktopTaskAssemblies Condition="'$(_UseDesktopTaskAssemblies)' == '' And '$(BuildingInsideVisualStudio)' == 'true'">true
$(MSBuildThisFileDirectory)..\tools\msbuild\net$(BundledNETCoreAppTargetFrameworkVersion)\
$(MSBuildThisFileDirectory)..\tools\msbuild\netstandard2.0\
From a082c0bc08e349c426561cb2cebba248f2bf6fb6 Mon Sep 17 00:00:00 2001
From: "CSIGS@microsoft.com"
Date: Wed, 13 May 2026 23:38:17 -0700
Subject: [PATCH 055/156] LEGO: Pull request from
lego/hb_5df43909-4a19-4f55-bc3f-9ea8fccf3c82_20260513174343331 to main
(#25423)
LEGO: Pull request from lego/hb_5df43909-4a19-4f55-bc3f-9ea8fccf3c82_20260513174343331 to main with localized lcls
---
.../ja/macios/tools/mtouch/Errors.resx.lcl | 36 +++++++++++++++++++
.../ko/macios/tools/mtouch/Errors.resx.lcl | 36 +++++++++++++++++++
.../pt-BR/macios/tools/mtouch/Errors.resx.lcl | 36 +++++++++++++++++++
.../ru/macios/tools/mtouch/Errors.resx.lcl | 36 +++++++++++++++++++
.../tr/macios/tools/mtouch/Errors.resx.lcl | 36 +++++++++++++++++++
.../macios/tools/mtouch/Errors.resx.lcl | 36 +++++++++++++++++++
6 files changed, 216 insertions(+)
diff --git a/macios/Localize/loc/ja/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/ja/macios/tools/mtouch/Errors.resx.lcl
index c50f56ff5b52..0326c3f3dc31 100644
--- a/macios/Localize/loc/ja/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/ja/macios/tools/mtouch/Errors.resx.lcl
@@ -4537,6 +4537,42 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/ko/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/ko/macios/tools/mtouch/Errors.resx.lcl
index e1f509268f52..36785bba0430 100644
--- a/macios/Localize/loc/ko/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/ko/macios/tools/mtouch/Errors.resx.lcl
@@ -4537,6 +4537,42 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/pt-BR/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/pt-BR/macios/tools/mtouch/Errors.resx.lcl
index e3b73c2c3c7c..cb12d7bf13cc 100644
--- a/macios/Localize/loc/pt-BR/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/pt-BR/macios/tools/mtouch/Errors.resx.lcl
@@ -4537,6 +4537,42 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/ru/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/ru/macios/tools/mtouch/Errors.resx.lcl
index 0db83b0b25dc..720865503b6d 100644
--- a/macios/Localize/loc/ru/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/ru/macios/tools/mtouch/Errors.resx.lcl
@@ -4537,6 +4537,42 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/tr/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/tr/macios/tools/mtouch/Errors.resx.lcl
index a0735f829e81..69c6f943eadf 100644
--- a/macios/Localize/loc/tr/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/tr/macios/tools/mtouch/Errors.resx.lcl
@@ -4537,6 +4537,42 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/zh-Hans/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/zh-Hans/macios/tools/mtouch/Errors.resx.lcl
index 1cd1c84e82c5..c37d02e4d78a 100644
--- a/macios/Localize/loc/zh-Hans/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/zh-Hans/macios/tools/mtouch/Errors.resx.lcl
@@ -4537,6 +4537,42 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
From b5ef771fde626b19273f9f5c363d8d05b94eba23 Mon Sep 17 00:00:00 2001
From: "CSIGS@microsoft.com"
Date: Thu, 14 May 2026 03:27:57 -0700
Subject: [PATCH 056/156] LEGO: Pull request from
lego/hb_5df43909-4a19-4f55-bc3f-9ea8fccf3c82_20260514054804289 to main
(#25425)
LEGO: Pull request from lego/hb_5df43909-4a19-4f55-bc3f-9ea8fccf3c82_20260514054804289 to main with localized lcls
---
.../cs/macios/tools/mtouch/Errors.resx.lcl | 36 ++++++++++
.../es/macios/tools/mtouch/Errors.resx.lcl | 72 +++++++++++++++++++
.../fr/macios/tools/mtouch/Errors.resx.lcl | 36 ++++++++++
.../it/macios/tools/mtouch/Errors.resx.lcl | 36 ++++++++++
.../pl/macios/tools/mtouch/Errors.resx.lcl | 36 ++++++++++
5 files changed, 216 insertions(+)
diff --git a/macios/Localize/loc/cs/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/cs/macios/tools/mtouch/Errors.resx.lcl
index 93308563ebb8..029bc250773a 100644
--- a/macios/Localize/loc/cs/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/cs/macios/tools/mtouch/Errors.resx.lcl
@@ -4537,6 +4537,42 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/es/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/es/macios/tools/mtouch/Errors.resx.lcl
index 63e741058a55..6ae060269c6e 100644
--- a/macios/Localize/loc/es/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/es/macios/tools/mtouch/Errors.resx.lcl
@@ -4501,6 +4501,78 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/fr/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/fr/macios/tools/mtouch/Errors.resx.lcl
index 439ef012fd7b..c46996116ac1 100644
--- a/macios/Localize/loc/fr/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/fr/macios/tools/mtouch/Errors.resx.lcl
@@ -4537,6 +4537,42 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/it/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/it/macios/tools/mtouch/Errors.resx.lcl
index 8d2aabef8e04..5a5bbaefc1ae 100644
--- a/macios/Localize/loc/it/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/it/macios/tools/mtouch/Errors.resx.lcl
@@ -4537,6 +4537,42 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
diff --git a/macios/Localize/loc/pl/macios/tools/mtouch/Errors.resx.lcl b/macios/Localize/loc/pl/macios/tools/mtouch/Errors.resx.lcl
index 85a0c823e2ea..8e3eafdf8f62 100644
--- a/macios/Localize/loc/pl/macios/tools/mtouch/Errors.resx.lcl
+++ b/macios/Localize/loc/pl/macios/tools/mtouch/Errors.resx.lcl
@@ -4537,6 +4537,42 @@
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
-
From 4e6c9b2619d876b20d38d5a1a791a8d42eba7a95 Mon Sep 17 00:00:00 2001
From: Copilot <198982749+Copilot@users.noreply.github.com>
Date: Thu, 14 May 2026 07:10:59 -0400
Subject: [PATCH 057/156] [aw] Allow dotted Xcode branches in Code Radiator PR
base policy (#25426)
Code Radiator failed when attempting to emit `create_pull_request` for
`xcode26.5` because safe outputs only allowed `xcode[0-9]*` (no dotted
minor form). This updates the workflow policy so existing branch
selection rules and safe-output enforcement are aligned.
- **Safe-output base branch policy**
- Added dotted Xcode branch support to
`create-pull-request.allowed-base-branches` in
`.github/workflows/code-radiator.md`.
- New allowed pattern: `xcode[0-9]*.[0-9]*`.
- **Compiled workflow lock update**
- Regenerated `.github/workflows/code-radiator.lock.yml` so runtime
safe-output config includes the new pattern.
- **Resulting policy shape**
- Supports both major and minor Xcode branch naming:
- `xcode26`
- `xcode26.5`
```yaml
safe-outputs:
create-pull-request:
allowed-base-branches:
- "net[0-9]*.0"
- "xcode[0-9]*"
- "xcode[0-9]*.[0-9]*"
```
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: rolfbjarne <249268+rolfbjarne@users.noreply.github.com>
Co-authored-by: Rolf Bjarne Kvinge
---
.github/workflows/code-radiator.lock.yml | 34 ++++++++++++------------
.github/workflows/code-radiator.md | 1 +
2 files changed, 18 insertions(+), 17 deletions(-)
diff --git a/.github/workflows/code-radiator.lock.yml b/.github/workflows/code-radiator.lock.yml
index a9fbf6808f54..8c0f8d46a7c0 100644
--- a/.github/workflows/code-radiator.lock.yml
+++ b/.github/workflows/code-radiator.lock.yml
@@ -1,4 +1,4 @@
-# gh-aw-metadata: {"schema_version":"v3","frontmatter_hash":"d2239141a1fb75dd529ab1ac4919d3b325cce94b8ab3bb1f7f2dcb291481fd7d","compiler_version":"v0.72.1","strict":true,"agent_id":"copilot","agent_model":"claude-sonnet-4.5"}
+# gh-aw-metadata: {"schema_version":"v3","frontmatter_hash":"a665debda1a902047622496aa625b015b0b9f053d3892454a63ac7b73cc61808","compiler_version":"v0.72.1","strict":true,"agent_id":"copilot","agent_model":"claude-sonnet-4.5"}
# gh-aw-manifest: {"version":1,"secrets":["COPILOT_GITHUB_TOKEN","GH_AW_CI_TRIGGER_TOKEN","GH_AW_GITHUB_MCP_SERVER_TOKEN","GH_AW_GITHUB_TOKEN","GITHUB_TOKEN"],"actions":[{"repo":"actions/checkout","sha":"de0fac2e4500dabe0009e67214ff5f5447ce83dd","version":"v6.0.2"},{"repo":"actions/download-artifact","sha":"3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c","version":"v8.0.1"},{"repo":"actions/github-script","sha":"3a2844b7e9c422d3c10d287c895573f7108da1b3","version":"v9.0.0"},{"repo":"actions/setup-node","sha":"48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e","version":"v6.4.0"},{"repo":"actions/upload-artifact","sha":"043fb46d1a93c77aae656e7c1c64a875d1fc6a0a","version":"v7.0.1"},{"repo":"github/gh-aw-actions/setup","sha":"bc56a0cad2f450c562810785ef38649c04db812a","version":"v0.72.1"}],"containers":[{"image":"ghcr.io/github/gh-aw-firewall/agent:0.25.41","digest":"sha256:cb2b565d070116d4b67e355775340528b5a2c3cb18b2c9049638bcc2df681770","pinned_image":"ghcr.io/github/gh-aw-firewall/agent:0.25.41@sha256:cb2b565d070116d4b67e355775340528b5a2c3cb18b2c9049638bcc2df681770"},{"image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.41","digest":"sha256:fadd0de387209f69a9a7a1b8722bb5e7fdfb80ba9749a5c60f0e4cd7582a74d0","pinned_image":"ghcr.io/github/gh-aw-firewall/api-proxy:0.25.41@sha256:fadd0de387209f69a9a7a1b8722bb5e7fdfb80ba9749a5c60f0e4cd7582a74d0"},{"image":"ghcr.io/github/gh-aw-firewall/squid:0.25.41","digest":"sha256:1260445d25968dbf3ae70143964177a0e5914cf2ce07a6117f7d3caec6c3e3c4","pinned_image":"ghcr.io/github/gh-aw-firewall/squid:0.25.41@sha256:1260445d25968dbf3ae70143964177a0e5914cf2ce07a6117f7d3caec6c3e3c4"},{"image":"ghcr.io/github/gh-aw-mcpg:v0.3.6","digest":"sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c","pinned_image":"ghcr.io/github/gh-aw-mcpg:v0.3.6@sha256:2bb8eef86006a4c5963c55616a9c51c32f27bfdecb023b8aa6f91f6718d9171c"},{"image":"ghcr.io/github/github-mcp-server:v1.0.3","digest":"sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959","pinned_image":"ghcr.io/github/github-mcp-server:v1.0.3@sha256:2ac27ef03461ef2b877031b838a7d1fd7f12b12d4ace7796d8cad91446d55959"},{"image":"node:lts-alpine","digest":"sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f","pinned_image":"node:lts-alpine@sha256:d1b3b4da11eefd5941e7f0b9cf17783fc99d9c6fc34884a665f40a06dbdfc94f"}]}
# ___ _ _
# / _ \ | | (_)
@@ -187,24 +187,24 @@ jobs:
run: |
bash "${RUNNER_TEMP}/gh-aw/actions/create_prompt_first.sh"
{
- cat << 'GH_AW_PROMPT_3513a5223ca2e9d0_EOF'
+ cat << 'GH_AW_PROMPT_0170a78c8d56645a_EOF'
- GH_AW_PROMPT_3513a5223ca2e9d0_EOF
+ GH_AW_PROMPT_0170a78c8d56645a_EOF
cat "${RUNNER_TEMP}/gh-aw/prompts/xpia.md"
cat "${RUNNER_TEMP}/gh-aw/prompts/temp_folder_prompt.md"
cat "${RUNNER_TEMP}/gh-aw/prompts/markdown.md"
cat "${RUNNER_TEMP}/gh-aw/prompts/safe_outputs_prompt.md"
- cat << 'GH_AW_PROMPT_3513a5223ca2e9d0_EOF'
+ cat << 'GH_AW_PROMPT_0170a78c8d56645a_EOF'
Tools: add_comment(max:10), create_pull_request(max:10), update_pull_request(max:10), add_labels(max:10), push_to_pull_request_branch(max:10), missing_tool, missing_data, noop
- GH_AW_PROMPT_3513a5223ca2e9d0_EOF
+ GH_AW_PROMPT_0170a78c8d56645a_EOF
cat "${RUNNER_TEMP}/gh-aw/prompts/safe_outputs_create_pull_request.md"
cat "${RUNNER_TEMP}/gh-aw/prompts/safe_outputs_push_to_pr_branch.md"
- cat << 'GH_AW_PROMPT_3513a5223ca2e9d0_EOF'
+ cat << 'GH_AW_PROMPT_0170a78c8d56645a_EOF'
- GH_AW_PROMPT_3513a5223ca2e9d0_EOF
+ GH_AW_PROMPT_0170a78c8d56645a_EOF
cat "${RUNNER_TEMP}/gh-aw/prompts/mcp_cli_tools_prompt.md"
- cat << 'GH_AW_PROMPT_3513a5223ca2e9d0_EOF'
+ cat << 'GH_AW_PROMPT_0170a78c8d56645a_EOF'
The following GitHub context information is available for this workflow:
{{#if __GH_AW_GITHUB_ACTOR__ }}
@@ -236,12 +236,12 @@ jobs:
- **Note**: If a branch you need is not in the list above and is not listed as an additional fetched ref, it has NOT been checked out. For private repositories you cannot fetch it without proper authentication. If the branch is required and not available, exit with an error and ask the user to add it to the `fetch:` option of the `checkout:` configuration (e.g., `fetch: ["refs/pulls/open/*"]` for all open PR refs, or `fetch: ["main", "feature/my-branch"]` for specific branches).
- GH_AW_PROMPT_3513a5223ca2e9d0_EOF
+ GH_AW_PROMPT_0170a78c8d56645a_EOF
cat "${RUNNER_TEMP}/gh-aw/prompts/github_mcp_tools_with_safeoutputs_prompt.md"
- cat << 'GH_AW_PROMPT_3513a5223ca2e9d0_EOF'
+ cat << 'GH_AW_PROMPT_0170a78c8d56645a_EOF'
{{#runtime-import .github/workflows/code-radiator.md}}
- GH_AW_PROMPT_3513a5223ca2e9d0_EOF
+ GH_AW_PROMPT_0170a78c8d56645a_EOF
} > "$GH_AW_PROMPT"
- name: Interpolate variables and render templates
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
@@ -443,9 +443,9 @@ jobs:
mkdir -p "${RUNNER_TEMP}/gh-aw/safeoutputs"
mkdir -p /tmp/gh-aw/safeoutputs
mkdir -p /tmp/gh-aw/mcp-logs/safeoutputs
- cat > "${RUNNER_TEMP}/gh-aw/safeoutputs/config.json" << 'GH_AW_SAFE_OUTPUTS_CONFIG_2d619531306fbf49_EOF'
- {"add_comment":{"max":10,"target":"*"},"add_labels":{"max":10,"target":"*"},"create_pull_request":{"allowed_base_branches":["net[0-9]*.0","xcode[0-9]*"],"max":10,"max_patch_files":100,"max_patch_size":1024,"protect_top_level_dot_folders":true,"protected_files":["package.json","bun.lockb","bunfig.toml","deno.json","deno.jsonc","deno.lock","global.json","NuGet.Config","Directory.Packages.props","mix.exs","mix.lock","go.mod","go.sum","stack.yaml","stack.yaml.lock","pom.xml","build.gradle","build.gradle.kts","settings.gradle","settings.gradle.kts","gradle.properties","package-lock.json","yarn.lock","pnpm-lock.yaml","npm-shrinkwrap.json","requirements.txt","Pipfile","Pipfile.lock","pyproject.toml","setup.py","setup.cfg","Gemfile","Gemfile.lock","uv.lock","CODEOWNERS","DESIGN.md","README.md","CONTRIBUTING.md","CHANGELOG.md","SECURITY.md","CODE_OF_CONDUCT.md","AGENTS.md","CLAUDE.md","GEMINI.md"]},"create_report_incomplete_issue":{},"merge_pull_request":{"max":10},"missing_data":{},"missing_tool":{},"noop":{"max":1,"report-as-issue":"true"},"push_to_pull_request_branch":{"if_no_changes":"warn","max":10,"max_patch_size":1024,"protect_top_level_dot_folders":true,"protected_files":["package.json","bun.lockb","bunfig.toml","deno.json","deno.jsonc","deno.lock","global.json","NuGet.Config","Directory.Packages.props","mix.exs","mix.lock","go.mod","go.sum","stack.yaml","stack.yaml.lock","pom.xml","build.gradle","build.gradle.kts","settings.gradle","settings.gradle.kts","gradle.properties","package-lock.json","yarn.lock","pnpm-lock.yaml","npm-shrinkwrap.json","requirements.txt","Pipfile","Pipfile.lock","pyproject.toml","setup.py","setup.cfg","Gemfile","Gemfile.lock","uv.lock","CODEOWNERS","DESIGN.md","README.md","CONTRIBUTING.md","CHANGELOG.md","SECURITY.md","CODE_OF_CONDUCT.md","AGENTS.md","CLAUDE.md","GEMINI.md"],"target":"*","title_prefix":"🤖 Merge 'main' =\u003e '"},"report_incomplete":{},"update_pull_request":{"allow_body":true,"allow_title":true,"max":10,"update_branch":false}}
- GH_AW_SAFE_OUTPUTS_CONFIG_2d619531306fbf49_EOF
+ cat > "${RUNNER_TEMP}/gh-aw/safeoutputs/config.json" << 'GH_AW_SAFE_OUTPUTS_CONFIG_1344cecc882c8d36_EOF'
+ {"add_comment":{"max":10,"target":"*"},"add_labels":{"max":10,"target":"*"},"create_pull_request":{"allowed_base_branches":["net[0-9]*.0","xcode[0-9]*","xcode[0-9]*.[0-9]*"],"max":10,"max_patch_files":100,"max_patch_size":1024,"protect_top_level_dot_folders":true,"protected_files":["package.json","bun.lockb","bunfig.toml","deno.json","deno.jsonc","deno.lock","global.json","NuGet.Config","Directory.Packages.props","mix.exs","mix.lock","go.mod","go.sum","stack.yaml","stack.yaml.lock","pom.xml","build.gradle","build.gradle.kts","settings.gradle","settings.gradle.kts","gradle.properties","package-lock.json","yarn.lock","pnpm-lock.yaml","npm-shrinkwrap.json","requirements.txt","Pipfile","Pipfile.lock","pyproject.toml","setup.py","setup.cfg","Gemfile","Gemfile.lock","uv.lock","CODEOWNERS","DESIGN.md","README.md","CONTRIBUTING.md","CHANGELOG.md","SECURITY.md","CODE_OF_CONDUCT.md","AGENTS.md","CLAUDE.md","GEMINI.md"]},"create_report_incomplete_issue":{},"merge_pull_request":{"max":10},"missing_data":{},"missing_tool":{},"noop":{"max":1,"report-as-issue":"true"},"push_to_pull_request_branch":{"if_no_changes":"warn","max":10,"max_patch_size":1024,"protect_top_level_dot_folders":true,"protected_files":["package.json","bun.lockb","bunfig.toml","deno.json","deno.jsonc","deno.lock","global.json","NuGet.Config","Directory.Packages.props","mix.exs","mix.lock","go.mod","go.sum","stack.yaml","stack.yaml.lock","pom.xml","build.gradle","build.gradle.kts","settings.gradle","settings.gradle.kts","gradle.properties","package-lock.json","yarn.lock","pnpm-lock.yaml","npm-shrinkwrap.json","requirements.txt","Pipfile","Pipfile.lock","pyproject.toml","setup.py","setup.cfg","Gemfile","Gemfile.lock","uv.lock","CODEOWNERS","DESIGN.md","README.md","CONTRIBUTING.md","CHANGELOG.md","SECURITY.md","CODE_OF_CONDUCT.md","AGENTS.md","CLAUDE.md","GEMINI.md"],"target":"*","title_prefix":"🤖 Merge 'main' =\u003e '"},"report_incomplete":{},"update_pull_request":{"allow_body":true,"allow_title":true,"max":10,"update_branch":false}}
+ GH_AW_SAFE_OUTPUTS_CONFIG_1344cecc882c8d36_EOF
- name: Generate Safe Outputs Tools
env:
GH_AW_TOOLS_META_JSON: |
@@ -783,7 +783,7 @@ jobs:
mkdir -p /home/runner/.copilot
GH_AW_NODE=$(which node 2>/dev/null || command -v node 2>/dev/null || echo node)
- cat << GH_AW_MCP_CONFIG_2faa3bb664926a36_EOF | "$GH_AW_NODE" "${RUNNER_TEMP}/gh-aw/actions/start_mcp_gateway.cjs"
+ cat << GH_AW_MCP_CONFIG_2bd87db1366a659d_EOF | "$GH_AW_NODE" "${RUNNER_TEMP}/gh-aw/actions/start_mcp_gateway.cjs"
{
"mcpServers": {
"github": {
@@ -827,7 +827,7 @@ jobs:
"payloadDir": "${MCP_GATEWAY_PAYLOAD_DIR}"
}
}
- GH_AW_MCP_CONFIG_2faa3bb664926a36_EOF
+ GH_AW_MCP_CONFIG_2bd87db1366a659d_EOF
- name: Mount MCP servers as CLIs
id: mount-mcp-clis
continue-on-error: true
@@ -1515,7 +1515,7 @@ jobs:
GH_AW_ALLOWED_DOMAINS: "*.githubusercontent.com,api.business.githubcopilot.com,api.enterprise.githubcopilot.com,api.github.com,api.githubcopilot.com,api.individual.githubcopilot.com,api.snapcraft.io,archive.ubuntu.com,azure.archive.ubuntu.com,codeload.github.com,crl.geotrust.com,crl.globalsign.com,crl.identrust.com,crl.sectigo.com,crl.thawte.com,crl.usertrust.com,crl.verisign.com,crl3.digicert.com,crl4.digicert.com,crls.ssl.com,docs.github.com,github-cloud.githubusercontent.com,github-cloud.s3.amazonaws.com,github.blog,github.com,github.githubassets.com,host.docker.internal,json-schema.org,json.schemastore.org,keyserver.ubuntu.com,lfs.github.com,objects.githubusercontent.com,ocsp.digicert.com,ocsp.geotrust.com,ocsp.globalsign.com,ocsp.identrust.com,ocsp.sectigo.com,ocsp.ssl.com,ocsp.thawte.com,ocsp.usertrust.com,ocsp.verisign.com,packagecloud.io,packages.cloud.google.com,packages.microsoft.com,ppa.launchpad.net,raw.githubusercontent.com,registry.npmjs.org,s.symcb.com,s.symcd.com,security.ubuntu.com,telemetry.enterprise.githubcopilot.com,ts-crl.ws.symantec.com,ts-ocsp.ws.symantec.com,www.googleapis.com"
GITHUB_SERVER_URL: ${{ github.server_url }}
GITHUB_API_URL: ${{ github.api_url }}
- GH_AW_SAFE_OUTPUTS_HANDLER_CONFIG: "{\"add_comment\":{\"max\":10,\"target\":\"*\"},\"add_labels\":{\"max\":10,\"target\":\"*\"},\"create_pull_request\":{\"allowed_base_branches\":[\"net[0-9]*.0\",\"xcode[0-9]*\"],\"max\":10,\"max_patch_files\":100,\"max_patch_size\":1024,\"protect_top_level_dot_folders\":true,\"protected_files\":[\"package.json\",\"bun.lockb\",\"bunfig.toml\",\"deno.json\",\"deno.jsonc\",\"deno.lock\",\"global.json\",\"NuGet.Config\",\"Directory.Packages.props\",\"mix.exs\",\"mix.lock\",\"go.mod\",\"go.sum\",\"stack.yaml\",\"stack.yaml.lock\",\"pom.xml\",\"build.gradle\",\"build.gradle.kts\",\"settings.gradle\",\"settings.gradle.kts\",\"gradle.properties\",\"package-lock.json\",\"yarn.lock\",\"pnpm-lock.yaml\",\"npm-shrinkwrap.json\",\"requirements.txt\",\"Pipfile\",\"Pipfile.lock\",\"pyproject.toml\",\"setup.py\",\"setup.cfg\",\"Gemfile\",\"Gemfile.lock\",\"uv.lock\",\"CODEOWNERS\",\"DESIGN.md\",\"README.md\",\"CONTRIBUTING.md\",\"CHANGELOG.md\",\"SECURITY.md\",\"CODE_OF_CONDUCT.md\",\"AGENTS.md\",\"CLAUDE.md\",\"GEMINI.md\"]},\"create_report_incomplete_issue\":{},\"merge_pull_request\":{\"max\":10},\"missing_data\":{},\"missing_tool\":{},\"noop\":{\"max\":1,\"report-as-issue\":\"true\"},\"push_to_pull_request_branch\":{\"if_no_changes\":\"warn\",\"max\":10,\"max_patch_size\":1024,\"protect_top_level_dot_folders\":true,\"protected_files\":[\"package.json\",\"bun.lockb\",\"bunfig.toml\",\"deno.json\",\"deno.jsonc\",\"deno.lock\",\"global.json\",\"NuGet.Config\",\"Directory.Packages.props\",\"mix.exs\",\"mix.lock\",\"go.mod\",\"go.sum\",\"stack.yaml\",\"stack.yaml.lock\",\"pom.xml\",\"build.gradle\",\"build.gradle.kts\",\"settings.gradle\",\"settings.gradle.kts\",\"gradle.properties\",\"package-lock.json\",\"yarn.lock\",\"pnpm-lock.yaml\",\"npm-shrinkwrap.json\",\"requirements.txt\",\"Pipfile\",\"Pipfile.lock\",\"pyproject.toml\",\"setup.py\",\"setup.cfg\",\"Gemfile\",\"Gemfile.lock\",\"uv.lock\",\"CODEOWNERS\",\"DESIGN.md\",\"README.md\",\"CONTRIBUTING.md\",\"CHANGELOG.md\",\"SECURITY.md\",\"CODE_OF_CONDUCT.md\",\"AGENTS.md\",\"CLAUDE.md\",\"GEMINI.md\"],\"target\":\"*\",\"title_prefix\":\"🤖 Merge 'main' =\\u003e '\"},\"report_incomplete\":{},\"update_pull_request\":{\"allow_body\":true,\"allow_title\":true,\"max\":10,\"update_branch\":false}}"
+ GH_AW_SAFE_OUTPUTS_HANDLER_CONFIG: "{\"add_comment\":{\"max\":10,\"target\":\"*\"},\"add_labels\":{\"max\":10,\"target\":\"*\"},\"create_pull_request\":{\"allowed_base_branches\":[\"net[0-9]*.0\",\"xcode[0-9]*\",\"xcode[0-9]*.[0-9]*\"],\"max\":10,\"max_patch_files\":100,\"max_patch_size\":1024,\"protect_top_level_dot_folders\":true,\"protected_files\":[\"package.json\",\"bun.lockb\",\"bunfig.toml\",\"deno.json\",\"deno.jsonc\",\"deno.lock\",\"global.json\",\"NuGet.Config\",\"Directory.Packages.props\",\"mix.exs\",\"mix.lock\",\"go.mod\",\"go.sum\",\"stack.yaml\",\"stack.yaml.lock\",\"pom.xml\",\"build.gradle\",\"build.gradle.kts\",\"settings.gradle\",\"settings.gradle.kts\",\"gradle.properties\",\"package-lock.json\",\"yarn.lock\",\"pnpm-lock.yaml\",\"npm-shrinkwrap.json\",\"requirements.txt\",\"Pipfile\",\"Pipfile.lock\",\"pyproject.toml\",\"setup.py\",\"setup.cfg\",\"Gemfile\",\"Gemfile.lock\",\"uv.lock\",\"CODEOWNERS\",\"DESIGN.md\",\"README.md\",\"CONTRIBUTING.md\",\"CHANGELOG.md\",\"SECURITY.md\",\"CODE_OF_CONDUCT.md\",\"AGENTS.md\",\"CLAUDE.md\",\"GEMINI.md\"]},\"create_report_incomplete_issue\":{},\"merge_pull_request\":{\"max\":10},\"missing_data\":{},\"missing_tool\":{},\"noop\":{\"max\":1,\"report-as-issue\":\"true\"},\"push_to_pull_request_branch\":{\"if_no_changes\":\"warn\",\"max\":10,\"max_patch_size\":1024,\"protect_top_level_dot_folders\":true,\"protected_files\":[\"package.json\",\"bun.lockb\",\"bunfig.toml\",\"deno.json\",\"deno.jsonc\",\"deno.lock\",\"global.json\",\"NuGet.Config\",\"Directory.Packages.props\",\"mix.exs\",\"mix.lock\",\"go.mod\",\"go.sum\",\"stack.yaml\",\"stack.yaml.lock\",\"pom.xml\",\"build.gradle\",\"build.gradle.kts\",\"settings.gradle\",\"settings.gradle.kts\",\"gradle.properties\",\"package-lock.json\",\"yarn.lock\",\"pnpm-lock.yaml\",\"npm-shrinkwrap.json\",\"requirements.txt\",\"Pipfile\",\"Pipfile.lock\",\"pyproject.toml\",\"setup.py\",\"setup.cfg\",\"Gemfile\",\"Gemfile.lock\",\"uv.lock\",\"CODEOWNERS\",\"DESIGN.md\",\"README.md\",\"CONTRIBUTING.md\",\"CHANGELOG.md\",\"SECURITY.md\",\"CODE_OF_CONDUCT.md\",\"AGENTS.md\",\"CLAUDE.md\",\"GEMINI.md\"],\"target\":\"*\",\"title_prefix\":\"🤖 Merge 'main' =\\u003e '\"},\"report_incomplete\":{},\"update_pull_request\":{\"allow_body\":true,\"allow_title\":true,\"max\":10,\"update_branch\":false}}"
GH_AW_CI_TRIGGER_TOKEN: ${{ secrets.GH_AW_CI_TRIGGER_TOKEN }}
with:
github-token: ${{ secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }}
diff --git a/.github/workflows/code-radiator.md b/.github/workflows/code-radiator.md
index b19f43eb2dc6..9fec3bff181d 100644
--- a/.github/workflows/code-radiator.md
+++ b/.github/workflows/code-radiator.md
@@ -30,6 +30,7 @@ safe-outputs:
allowed-base-branches:
- "net[0-9]*.0"
- "xcode[0-9]*"
+ - "xcode[0-9]*.[0-9]*"
add-comment:
max: 10
target: "*"
From 18a22fd0812016cfdc8397d9b70981a1fc365fed Mon Sep 17 00:00:00 2001
From: Alex Soto
Date: Thu, 14 May 2026 16:29:52 -0400
Subject: [PATCH 058/156] [main] Update dependencies from dotnet/macios
(#25433)
---
Make.versions | 8 ++++----
NuGet.config | 2 +-
eng/Version.Details.props | 16 ++++++++--------
eng/Version.Details.xml | 18 +++++++++---------
4 files changed, 22 insertions(+), 22 deletions(-)
diff --git a/Make.versions b/Make.versions
index 2499d5bb498b..e34932ddad38 100644
--- a/Make.versions
+++ b/Make.versions
@@ -115,10 +115,10 @@ SUPPORTED_API_VERSIONS_TVOS+=net9.0-18.0
SUPPORTED_API_VERSIONS_MACOS+=net9.0-15.0
SUPPORTED_API_VERSIONS_MACCATALYST+=net9.0-18.0
-SUPPORTED_API_VERSIONS_IOS+=net9.0-26.4
-SUPPORTED_API_VERSIONS_TVOS+=net9.0-26.4
-SUPPORTED_API_VERSIONS_MACOS+=net9.0-26.4
-SUPPORTED_API_VERSIONS_MACCATALYST+=net9.0-26.4
+SUPPORTED_API_VERSIONS_IOS+=net9.0-26.5
+SUPPORTED_API_VERSIONS_TVOS+=net9.0-26.5
+SUPPORTED_API_VERSIONS_MACOS+=net9.0-26.5
+SUPPORTED_API_VERSIONS_MACCATALYST+=net9.0-26.5
SUPPORTED_API_VERSIONS_IOS+=net10.0-26.0
SUPPORTED_API_VERSIONS_TVOS+=net10.0-26.0
diff --git a/NuGet.config b/NuGet.config
index 2a29638a04d1..20f61861e687 100644
--- a/NuGet.config
+++ b/NuGet.config
@@ -12,7 +12,7 @@
-
+
diff --git a/eng/Version.Details.props b/eng/Version.Details.props
index 33ea6a861727..a6893d69a1f6 100644
--- a/eng/Version.Details.props
+++ b/eng/Version.Details.props
@@ -19,16 +19,16 @@ This file should be imported by eng/Versions.props
26.0.11017
18.5.9227
- 26.4.9017
+ 26.5.9001
26.0.11017
18.5.9227
- 26.4.9017
+ 26.5.9001
26.0.11017
15.5.9227
- 26.4.9017
+ 26.5.9001
26.0.11017
18.5.9227
- 26.4.9017
+ 26.5.9001
11.0.0-prerelease.26230.4
@@ -53,16 +53,16 @@ This file should be imported by eng/Versions.props
$(MicrosoftiOSSdknet100_260PackageVersion)
$(MicrosoftiOSSdknet90_185PackageVersion)
- $(MicrosoftiOSSdknet90_264PackageVersion)
+ $(MicrosoftiOSSdknet90_265PackageVersion)
$(MicrosoftMacCatalystSdknet100_260PackageVersion)
$(MicrosoftMacCatalystSdknet90_185PackageVersion)
- $(MicrosoftMacCatalystSdknet90_264PackageVersion)
+ $(MicrosoftMacCatalystSdknet90_265PackageVersion)
$(MicrosoftmacOSSdknet100_260PackageVersion)
$(MicrosoftmacOSSdknet90_155PackageVersion)
- $(MicrosoftmacOSSdknet90_264PackageVersion)
+ $(MicrosoftmacOSSdknet90_265PackageVersion)
$(MicrosofttvOSSdknet100_260PackageVersion)
$(MicrosofttvOSSdknet90_185PackageVersion)
- $(MicrosofttvOSSdknet90_264PackageVersion)
+ $(MicrosofttvOSSdknet90_265PackageVersion)
$(MicrosoftDotNetXHarnessiOSSharedPackageVersion)
diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml
index 5eb61a033c7d..27e9e6c4437a 100644
--- a/eng/Version.Details.xml
+++ b/eng/Version.Details.xml
@@ -59,22 +59,22 @@
https://github.com/xamarin/xamarin-macios
797d30720e5e629d23eb146935da94cb1b61047e
-
-
+
+
https://github.com/dotnet/macios
- fde62395708fce0a6f65ec9df9656c4c6e1f9d2b
+ 1e1deb87ce9428d975d718366a2e01c61624fe55
-
+
https://github.com/dotnet/macios
- fde62395708fce0a6f65ec9df9656c4c6e1f9d2b
+ 1e1deb87ce9428d975d718366a2e01c61624fe55
-
+
https://github.com/dotnet/macios
- fde62395708fce0a6f65ec9df9656c4c6e1f9d2b
+ 1e1deb87ce9428d975d718366a2e01c61624fe55
-
+
https://github.com/dotnet/macios
- fde62395708fce0a6f65ec9df9656c4c6e1f9d2b
+ 1e1deb87ce9428d975d718366a2e01c61624fe55
From e8b342b8106dcd82621eaf03eb140298eefd4a17 Mon Sep 17 00:00:00 2001
From: "dotnet-maestro[bot]"
<42748379+dotnet-maestro[bot]@users.noreply.github.com>
Date: Fri, 15 May 2026 07:23:04 +0000
Subject: [PATCH 059/156] [main] Update dependencies from dotnet/xharness
(#25436)
This pull request updates the following dependencies
## From https://github.com/dotnet/xharness
- **Subscription**: [02e03784-16b3-4ced-b02a-3715797fc7da](https://maestro.dot.net/subscriptions?search=02e03784-16b3-4ced-b02a-3715797fc7da)
- **Build**: [20260514.1](https://dev.azure.com/dnceng/internal/_build/results?buildId=2974748) ([314304](https://maestro.dot.net/channel/2/github:dotnet:xharness/build/314304))
- **Date Produced**: May 14, 2026 9:16:56 AM UTC
- **Commit**: [51ca379106cfd749a498cb0822210ef1aa926e41](https://github.com/dotnet/xharness/commit/51ca379106cfd749a498cb0822210ef1aa926e41)
- **Branch**: [main](https://github.com/dotnet/xharness/tree/main)
- **Dependency Updates**:
- From [11.0.0-prerelease.26230.4 to 11.0.0-prerelease.26264.1][1]
- Microsoft.DotNet.XHarness.iOS.Shared
[1]: https://github.com/dotnet/xharness/compare/92962e5c46...51ca379106
---
NuGet.config | 3 ++-
eng/Version.Details.props | 2 +-
eng/Version.Details.xml | 4 ++--
3 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/NuGet.config b/NuGet.config
index 20f61861e687..d9588597df42 100644
--- a/NuGet.config
+++ b/NuGet.config
@@ -12,7 +12,8 @@
-
+
+
diff --git a/eng/Version.Details.props b/eng/Version.Details.props
index a6893d69a1f6..13e094bf3616 100644
--- a/eng/Version.Details.props
+++ b/eng/Version.Details.props
@@ -30,7 +30,7 @@ This file should be imported by eng/Versions.props
18.5.9227
26.5.9001
- 11.0.0-prerelease.26230.4
+ 11.0.0-prerelease.26264.1
18.0.9617
18.0.9617
diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml
index 27e9e6c4437a..f19d57393d5b 100644
--- a/eng/Version.Details.xml
+++ b/eng/Version.Details.xml
@@ -107,9 +107,9 @@
https://github.com/dotnet/dotnet
e43cbe04901ea4cf359ed0883b0533abab224ba2
-
+
https://github.com/dotnet/xharness
- 92962e5c46ac08a66ded4c5696209cc60f1a232f
+ 51ca379106cfd749a498cb0822210ef1aa926e41
https://github.com/dotnet/dotnet
From 44c6b888b0be6c72fc1f66c8148cfe056a1ebee4 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Fri, 15 May 2026 10:22:02 +0200
Subject: [PATCH 060/156] [tests] Upgrade tests/msbuild to NUnit v4 Assert.That
syntax (#25431)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Convert classic NUnit assertions (`Assert.AreEqual`, `Assert.IsTrue`, `Assert.IsNotNull`, etc.) to NUnit v4's constraint-based `Assert.That` syntax in the msbuild test projects.
Also update package references to use centralized version properties from `Directory.Build.props`:
- `NUnit` → `$(NUnitPackageVersion)`
- `NUnit3TestAdapter` → `$(NUnit3TestAdapterPackageVersion)`
- `Microsoft.NET.Test.Sdk` → `$(MicrosoftNETTestSdkPackageVersion)`
Two shared files (`tests/common/DotNet.cs`, `tests/common/mac/ProjectTestHelpers.cs`) are also converted — the `Assert.That` constraint syntax is compatible with both NUnit 3 and 4, so other projects referencing these files are unaffected.
All `tests-msbuild` tests pass (495 passed, 0 failed).
🤖 Pull request created by Copilot
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
tests/common/DotNet.cs | 10 +--
tests/common/mac/ProjectTestHelpers.cs | 6 +-
.../TaskTests/ACToolTaskTest.cs | 20 +++---
.../TaskTests/BundleResourceTests.cs | 12 ++--
.../CollectITunesArtworkTaskTests.cs | 6 +-
.../TaskTests/CompileAppManifestTaskTests.cs | 14 ++---
.../TaskTests/CompileEntitlementsTaskTests.cs | 62 +++++++++----------
.../ComputeCodesignItemsTaskTests.cs | 16 ++---
.../CreateBindingResourceTaskTests.cs | 22 +++----
.../TaskTests/DetectSdkLocationsTaskTests.cs | 2 +-
.../DetectSigningIdentityTaskTests.cs | 30 ++++-----
.../GeneratePlistTaskTests_Core.cs | 24 +++----
.../GeneratePlistTaskTests_iOS.cs | 12 ++--
...GeneratePlistTaskTests_iOS_AppExtension.cs | 2 +-
.../TaskTests/GetAvailableDevicesTest.cs | 20 +++---
.../TaskTests/GetBundleNameTaskTests.cs | 2 +-
.../GetPropertyListValueTaskTests.cs | 2 +-
.../TaskTests/IBToolTaskTests.cs | 16 ++---
.../TaskTests/LocalizationStringTest.cs | 10 +--
.../TaskTests/MergeAppBundleTaskTest.cs | 36 +++++------
.../TaskTests/ParseBundlerArgumentsTests.cs | 44 ++++++-------
.../TaskTests/PropertyListEditorTaskTests.cs | 20 +++---
.../TaskTests/ReadAppManifestTaskTests.cs | 2 +-
.../ResolveNativeReferencesTaskTest.cs | 6 +-
.../TestHelpers/TestBase.cs | 4 +-
.../UtilityTests.cs | 2 +-
.../Xamarin.MacDev.Tasks.Tests.csproj | 6 +-
.../TargetTests/CollectAppManifestsTests.cs | 6 +-
.../TargetTests/DetectSigningIdentityTests.cs | 4 +-
.../TargetTests/TargetTests.cs | 24 +++----
.../TestHelpers/TestBase.cs | 28 ++++-----
.../Xamarin.MacDev.Tests.csproj | 6 +-
32 files changed, 236 insertions(+), 240 deletions(-)
diff --git a/tests/common/DotNet.cs b/tests/common/DotNet.cs
index 0d0b0de77088..1f7a5c73e868 100644
--- a/tests/common/DotNet.cs
+++ b/tests/common/DotNet.cs
@@ -33,7 +33,7 @@ public static ExecutionResult AssertPack (string project, Dictionary? properties = null, bool? msbuildParallelism = null)
{
var rv = Execute ("pack", project, properties, false, msbuildParallelism: msbuildParallelism);
- Assert.AreNotEqual (0, rv.ExitCode, "Unexpected success");
+ Assert.That (rv.ExitCode, Is.Not.EqualTo (0), "Unexpected success");
return rv;
}
@@ -45,7 +45,7 @@ public static ExecutionResult AssertPublish (string project, Dictionary? properties = null)
{
var rv = Execute ("publish", project, properties, false);
- Assert.AreNotEqual (0, rv.ExitCode, "Unexpected success");
+ Assert.That (rv.ExitCode, Is.Not.EqualTo (0), "Unexpected success");
return rv;
}
@@ -73,7 +73,7 @@ public static ExecutionResult AssertRun (string project, Dictionary? properties = null)
{
var rv = Execute ("build", project, properties, false);
- Assert.AreNotEqual (0, rv.ExitCode, "Unexpected success");
+ Assert.That (rv.ExitCode, Is.Not.EqualTo (0), "Unexpected success");
return rv;
}
@@ -107,7 +107,7 @@ public static ExecutionResult AssertNew (string outputDirectory, string template
if (rv.ExitCode != 0) {
Console.WriteLine ($"'{Executable} {StringUtils.FormatArguments (args)}' failed with exit code {rv.ExitCode}.");
Console.WriteLine (output);
- Assert.AreEqual (0, rv.ExitCode, $"Exit code: {Executable} {StringUtils.FormatArguments (args)}");
+ Assert.That (rv.ExitCode, Is.EqualTo (0), $"Exit code: {Executable} {StringUtils.FormatArguments (args)}");
}
return new ExecutionResult (output, output, rv.ExitCode);
}
@@ -336,7 +336,7 @@ public static ExecutionResult Execute (string verb, string project, Dictionary (), "Run");
string guidPath = Path.Combine (tmpDir, guid.ToString ());
- Assert.IsTrue (File.Exists (guidPath), "Generated program did not create expected guid file: " + output);
+ Assert.That (File.Exists (guidPath), Is.True, "Generated program did not create expected guid file: " + output);
// Let's delete the guid file so re-runs inside same tests are accurate
File.Delete (guidPath);
@@ -442,7 +442,7 @@ public static string FindSourceDirectory ()
public static void CopyDirectory (string src, string target)
{
- Assert.AreEqual (0, ExecutionHelper.Execute ("/bin/cp", new [] { "-r", src, target }));
+ Assert.That (ExecutionHelper.Execute ("/bin/cp", new [] { "-r", src, target }), Is.EqualTo (0));
}
public static string CopyFileWithSubstitutions (string src, string target, Func replacementAction)
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ACToolTaskTest.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ACToolTaskTest.cs
index ef806c289d0a..56c9f2b5c35a 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ACToolTaskTest.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ACToolTaskTest.cs
@@ -92,10 +92,10 @@ public void DefaultAppIcons (ApplePlatform platform)
var actool = CreateACToolTaskWithResources (platform);
ExecuteTask (actool);
- Assert.IsNotNull (actool.PartialAppManifest, "PartialAppManifest");
+ Assert.That (actool.PartialAppManifest, Is.Not.Null, "PartialAppManifest");
var appIconsManifestPath = actool.PartialAppManifest?.ItemSpec ?? "";
var appIconsManifest = PDictionary.FromFile (appIconsManifestPath)!;
- Assert.AreEqual (0, appIconsManifest.Count, $"Partial plist contents: {actool.PartialAppManifest?.ItemSpec}");
+ Assert.That (appIconsManifest.Count, Is.EqualTo (0), $"Partial plist contents: {actool.PartialAppManifest?.ItemSpec}");
var expectedXml =
"""
@@ -120,7 +120,7 @@ public void AllAppIcons (ApplePlatform platform)
ExecuteTask (actool);
- Assert.IsNotNull (actool.PartialAppManifest, "PartialAppManifest");
+ Assert.That (actool.PartialAppManifest, Is.Not.Null, "PartialAppManifest");
var appIconsManifestPath = actool.PartialAppManifest?.ItemSpec ?? "";
string expectedXml;
@@ -168,7 +168,7 @@ public void AllAppIconsWithAppIcon (ApplePlatform platform)
ExecuteTask (actool);
- Assert.IsNotNull (actool.PartialAppManifest, "PartialAppManifest");
+ Assert.That (actool.PartialAppManifest, Is.Not.Null, "PartialAppManifest");
var appIconsManifestPath = actool.PartialAppManifest?.ItemSpec!;
string expectedXml;
@@ -293,7 +293,7 @@ public void AppIcon (ApplePlatform platform)
ExecuteTask (actool);
- Assert.IsNotNull (actool.PartialAppManifest, "PartialAppManifest");
+ Assert.That (actool.PartialAppManifest, Is.Not.Null, "PartialAppManifest");
var appIconsManifestPath = actool.PartialAppManifest?.ItemSpec ?? "";
string expectedXml;
@@ -390,7 +390,7 @@ public void AppIconAndAlternateIcons (ApplePlatform platform)
ExecuteTask (actool);
- Assert.IsNotNull (actool.PartialAppManifest, "PartialAppManifest");
+ Assert.That (actool.PartialAppManifest, Is.Not.Null, "PartialAppManifest");
var appIconsManifestPath = actool.PartialAppManifest?.ItemSpec ?? "";
string expectedXml;
@@ -575,7 +575,7 @@ public void InexistentAppIcon (ApplePlatform platform)
default:
throw new NotImplementedException (platform.ToString ());
}
- Assert.AreEqual (expectedErrorMessage, Engine.Logger.ErrorEvents [0].Message, "Error message");
+ Assert.That (Engine.Logger.ErrorEvents [0].Message, Is.EqualTo (expectedErrorMessage), "Error message");
}
[Test]
@@ -602,7 +602,7 @@ public void InexistentAlternateIcons (ApplePlatform platform)
default:
throw new NotImplementedException (platform.ToString ());
}
- Assert.AreEqual (expectedErrorMessage, Engine.Logger.ErrorEvents [0].Message, "Error message");
+ Assert.That (Engine.Logger.ErrorEvents [0].Message, Is.EqualTo (expectedErrorMessage), "Error message");
}
[Test]
@@ -617,7 +617,7 @@ public void BothAlternateAndMainIcon (ApplePlatform platform)
actool.AppIcon = "AppIcons";
ExecuteTask (actool, 1);
- Assert.AreEqual ($"The image resource '{actool.AppIcon}' is specified as both 'AppIcon' and 'AlternateAppIcon'.", Engine.Logger.ErrorEvents [0].Message, "Error message");
+ Assert.That (Engine.Logger.ErrorEvents [0].Message, Is.EqualTo ($"The image resource '{actool.AppIcon}' is specified as both 'AppIcon' and 'AlternateAppIcon'."), "Error message");
}
[Test]
@@ -632,7 +632,7 @@ public void XSAppIconAssetsAndAppIcon (ApplePlatform platform)
actool.XSAppIconAssets = "Resources/Images.xcassets/AppIcons.appiconset";
ExecuteTask (actool, 1);
- Assert.AreEqual ("Can't specify both 'XSAppIconAssets' in the Info.plist and 'AppIcon' in the project file. Please select one or the other.", Engine.Logger.ErrorEvents [0].Message, "Error message");
+ Assert.That (Engine.Logger.ErrorEvents [0].Message, Is.EqualTo ("Can't specify both 'XSAppIconAssets' in the Info.plist and 'AppIcon' in the project file. Please select one or the other."), "Error message");
}
}
}
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/BundleResourceTests.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/BundleResourceTests.cs
index d005250d7603..58c9eb2aba3d 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/BundleResourceTests.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/BundleResourceTests.cs
@@ -38,8 +38,7 @@ class ResourceTask : Task, IHasSessionId, IHasProjectDir {
public void GetVirtualProjectPathTest ()
{
Assert.Multiple (() => {
- Assert.AreEqual ("Archer_Attack.atlas/archer_attack_0001.png",
- BundleResource.GetVirtualProjectPath (
+ Assert.That (BundleResource.GetVirtualProjectPath (
new ResourceTask {
BuildEngine = new TestEngine (),
ProjectDir = "/Users/rolf/work/maccore/windows/xamarin-macios/tests/dotnet/LibraryWithResources/iOS",
@@ -48,11 +47,9 @@ public void GetVirtualProjectPathTest ()
"../Archer_Attack.atlas/archer_attack_0001.png",
localMSBuildProjectFullPath: "/Users/rolf/work/maccore/windows/xamarin-macios/tests/dotnet/LibraryWithResources/shared.csproj",
localDefiningProjectFullPath: "/Users/rolf/work/maccore/windows/xamarin-macios/tests/dotnet/LibraryWithResources/shared.csproj"
- )),
- "A");
+ )), Is.EqualTo ("Archer_Attack.atlas/archer_attack_0001.png"), "A");
- Assert.AreEqual ("Archer_Attack.atlas/archer_attack_0001.png",
- BundleResource.GetVirtualProjectPath (
+ Assert.That (BundleResource.GetVirtualProjectPath (
new ResourceTask {
BuildEngine = new TestEngine (),
ProjectDir = "C:/src/xamarin-macios/tests/dotnet/LibraryWithResources/iOS",
@@ -62,8 +59,7 @@ public void GetVirtualProjectPathTest ()
"../Archer_Attack.atlas/archer_attack_0001.png",
localMSBuildProjectFullPath: @"C:\src\xamarin-macios\tests\dotnet\LibraryWithResources\shared.csproj",
localDefiningProjectFullPath: @"C:\src\xamarin-macios\tests\dotnet\LibraryWithResources\shared.csproj"
- )),
- "B");
+ )), Is.EqualTo ("Archer_Attack.atlas/archer_attack_0001.png"), "B");
});
}
}
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CollectITunesArtworkTaskTests.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CollectITunesArtworkTaskTests.cs
index 7237be4e39d7..14b75f2f1a4c 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CollectITunesArtworkTaskTests.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CollectITunesArtworkTaskTests.cs
@@ -69,10 +69,10 @@ public void Valid (string extension)
};
ExecuteTask (task);
- Assert.AreEqual (2, task.ITunesArtworkWithLogicalNames.Length, "ITunesArtworkWithLogicalNames.Count");
+ Assert.That (task.ITunesArtworkWithLogicalNames.Length, Is.EqualTo (2), "ITunesArtworkWithLogicalNames.Count");
for (var i = 0; i < task.ITunesArtworkWithLogicalNames.Length; i++) {
- Assert.AreEqual (Path.GetFileNameWithoutExtension (task.ITunesArtwork [i].GetMetadata ("FullPath")), task.ITunesArtworkWithLogicalNames [i].GetMetadata ("LogicalName"), $"LogicalName #{i}");
- Assert.AreEqual ("false", task.ITunesArtworkWithLogicalNames [i].GetMetadata ("Optimize"), $"Optimize #{i}");
+ Assert.That (task.ITunesArtworkWithLogicalNames [i].GetMetadata ("LogicalName"), Is.EqualTo (Path.GetFileNameWithoutExtension (task.ITunesArtwork [i].GetMetadata ("FullPath"))), $"LogicalName #{i}");
+ Assert.That (task.ITunesArtworkWithLogicalNames [i].GetMetadata ("Optimize"), Is.EqualTo ("false"), $"Optimize #{i}");
}
}
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CompileAppManifestTaskTests.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CompileAppManifestTaskTests.cs
index 17f5f44f93ad..d8c31662cb06 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CompileAppManifestTaskTests.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CompileAppManifestTaskTests.cs
@@ -46,7 +46,7 @@ public void MainMinimumOSVersions ()
ExecuteTask (task);
var plist = PDictionary.FromFile (task.CompiledAppManifest!.ItemSpec)!;
- Assert.AreEqual ("14.0", plist.GetMinimumOSVersion (), "MinimumOSVersion");
+ Assert.That (plist.GetMinimumOSVersion (), Is.EqualTo ("14.0"), "MinimumOSVersion");
}
[Test]
@@ -73,7 +73,7 @@ public void MultipleMinimumOSVersions ()
ExecuteTask (task);
var plist = PDictionary.FromFile (task.CompiledAppManifest!.ItemSpec)!;
- Assert.AreEqual ("13.0", plist.GetMinimumOSVersion (), "MinimumOSVersion");
+ Assert.That (plist.GetMinimumOSVersion (), Is.EqualTo ("13.0"), "MinimumOSVersion");
}
[Test]
@@ -103,7 +103,7 @@ public void MultipleMinimumOSVersions_Overwrite (bool overwrite, string expected
ExecuteTask (task);
var plist = PDictionary.FromFile (task.CompiledAppManifest!.ItemSpec)!;
- Assert.AreEqual (expectedMinimumOSVersion, plist.GetMinimumOSVersion (), "MinimumOSVersion");
+ Assert.That (plist.GetMinimumOSVersion (), Is.EqualTo (expectedMinimumOSVersion), "MinimumOSVersion");
}
[Test]
@@ -120,7 +120,7 @@ public void ErrorWithMismatchedInfoPlistMinimumOSVersion ()
task.SupportedOSPlatformVersion = "11.0";
ExecuteTask (task, expectedErrorCount: 1);
- Assert.AreEqual ("The MinimumOSVersion value in the Info.plist (10.0) does not match the SupportedOSPlatformVersion value (11.0) in the project file (if there is no SupportedOSPlatformVersion value in the project file, then a default value has been assumed). Either change the value in the Info.plist to match the SupportedOSPlatformVersion value, or remove the value in the Info.plist (and add a SupportedOSPlatformVersion value to the project file if it doesn't already exist).", Engine.Logger.ErrorEvents [0].Message);
+ Assert.That (Engine.Logger.ErrorEvents [0].Message, Is.EqualTo ("The MinimumOSVersion value in the Info.plist (10.0) does not match the SupportedOSPlatformVersion value (11.0) in the project file (if there is no SupportedOSPlatformVersion value in the project file, then a default value has been assumed). Either change the value in the Info.plist to match the SupportedOSPlatformVersion value, or remove the value in the Info.plist (and add a SupportedOSPlatformVersion value to the project file if it doesn't already exist)."));
}
[Test]
@@ -134,7 +134,7 @@ public void SupportedOSPlatformVersion ()
ExecuteTask (task);
var plist = PDictionary.FromFile (task.CompiledAppManifest!.ItemSpec)!;
- Assert.AreEqual ("11.0", plist.GetMinimumOSVersion (), "MinimumOSVersion");
+ Assert.That (plist.GetMinimumOSVersion (), Is.EqualTo ("11.0"), "MinimumOSVersion");
}
[Test]
@@ -145,7 +145,7 @@ public void MacCatalystVersionCheck ()
ExecuteTask (task);
var plist = PDictionary.FromFile (task.CompiledAppManifest!.ItemSpec)!;
- Assert.AreEqual ("11.0", plist.GetMinimumSystemVersion (), "MinimumOSVersion");
+ Assert.That (plist.GetMinimumSystemVersion (), Is.EqualTo ("11.0"), "MinimumOSVersion");
}
[Test]
@@ -186,7 +186,7 @@ public void XcodeVariables (ApplePlatform platform, bool isSimulator, string exp
var value = plist.GetString (variable)?.Value;
Assert.That (value, Is.Not.Null.And.Not.Empty, variable);
}
- Assert.AreEqual (expectedDTPlatformName, plist.GetString ("DTPlatformName")?.Value, "Expected DTPlatformName");
+ Assert.That (plist.GetString ("DTPlatformName")?.Value, Is.EqualTo (expectedDTPlatformName), "Expected DTPlatformName");
}
}
}
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CompileEntitlementsTaskTests.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CompileEntitlementsTaskTests.cs
index 0a3d632d94ae..ae9bd55240bc 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CompileEntitlementsTaskTests.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CompileEntitlementsTaskTests.cs
@@ -115,7 +115,7 @@ void ExecuteAndCheckValidationErrors (Task task, params string [] expectedMessag
expectedCode = expectedMessage [0..6];
expectedMessage = expectedMessage [7..];
}
- Assert.AreEqual (expectedMessage, buildEvents [i].Message, $"Error message #{i + 1}");
+ Assert.That (buildEvents [i].Message, Is.EqualTo (expectedMessage), $"Error message #{i + 1}");
if (expectedCode is not null) {
string actualCode;
if (buildEvents [i] is BuildErrorEventArgs beea) {
@@ -140,16 +140,16 @@ public void ValidateEntitlement ()
"The app requests the entitlement 'com.apple.developer.ubiquity-kvstore-identifier', but the provisioning profile 'iOS Team Provisioning Profile: *' doesn't contain this entitlement.");
var compiled = PDictionary.FromFile (compiledEntitlements)!;
- Assert.IsTrue (compiled.Get (EntitlementKeys.GetTaskAllow)?.Value, "#1");
- Assert.AreEqual ("32UV7A8CDE.com.xamarin.MySingleView", compiled.Get ("application-identifier")?.Value, "#2");
- Assert.AreEqual ("Z8CSQKJE7R", compiled.Get ("com.apple.developer.team-identifier")?.Value, "#3");
- Assert.AreEqual ("applinks:*.xamarin.com", compiled.GetAssociatedDomains ().ToStringArray ().First (), "#4");
- Assert.AreEqual ("Z8CSQKJE7R.*", compiled.GetPassBookIdentifiers ().ToStringArray ().First (), "#5");
- Assert.AreEqual ("Z8CSQKJE7R.com.xamarin.MySingleView", compiled.GetUbiquityKeyValueStore (), "#6");
- Assert.AreEqual ("32UV7A8CDE.com.xamarin.MySingleView", compiled.GetKeychainAccessGroups ().ToStringArray ().First (), "#7");
+ Assert.That (compiled.Get (EntitlementKeys.GetTaskAllow)?.Value, Is.True, "#1");
+ Assert.That (compiled.Get ("application-identifier")?.Value, Is.EqualTo ("32UV7A8CDE.com.xamarin.MySingleView"), "#2");
+ Assert.That (compiled.Get ("com.apple.developer.team-identifier")?.Value, Is.EqualTo ("Z8CSQKJE7R"), "#3");
+ Assert.That (compiled.GetAssociatedDomains ().ToStringArray ().First (), Is.EqualTo ("applinks:*.xamarin.com"), "#4");
+ Assert.That (compiled.GetPassBookIdentifiers ().ToStringArray ().First (), Is.EqualTo ("Z8CSQKJE7R.*"), "#5");
+ Assert.That (compiled.GetUbiquityKeyValueStore (), Is.EqualTo ("Z8CSQKJE7R.com.xamarin.MySingleView"), "#6");
+ Assert.That (compiled.GetKeychainAccessGroups ().ToStringArray ().First (), Is.EqualTo ("32UV7A8CDE.com.xamarin.MySingleView"), "#7");
var archived = PDictionary.FromFile (archivedEntitlements);
- Assert.IsTrue (compiled.ContainsKey ("application-identifier"), "archived");
+ Assert.That (compiled.ContainsKey ("application-identifier"), Is.True, "archived");
}
[TestCase ("Invalid", null, "Unknown type 'Invalid' for the entitlement 'com.xamarin.custom.entitlement' specified in the CustomEntitlements item group. Expected 'Remove', 'Boolean', 'String', or 'StringArray'.")]
@@ -172,7 +172,7 @@ public void InvalidCustomEntitlements (string type, string? value, string errorM
task.CustomEntitlements = customEntitlements;
task.ProvisioningProfile = GetResourcePath ("WildCardMacAppDevelopment.provisionprofile");
ExecuteTask (task, expectedErrorCount: 1);
- Assert.AreEqual (errorMessage, Engine.Logger.ErrorEvents [0].Message, "Error message");
+ Assert.That (Engine.Logger.ErrorEvents [0].Message, Is.EqualTo (errorMessage), "Error message");
}
[Test]
@@ -194,8 +194,8 @@ public void CustomEntitlemements_String (string value)
task.ProvisioningProfile = GetResourcePath ("WildCardMacAppDevelopment.provisionprofile");
ExecuteTask (task);
var compiled = PDictionary.FromFile (compiledEntitlements)!;
- Assert.AreEqual (value ?? string.Empty, compiled.GetString ("com.xamarin.custom.entitlement")?.Value, "#1");
- Assert.IsTrue (Engine.Logger.MessageEvents.Any (v => v.Message?.Contains ("The app requests the entitlement 'com.xamarin.custom.entitlement', but provisioning profile WildCardMacAppDevelopment does not grant this entitlement. This is probably not OK.") == true), "custom entitlement");
+ Assert.That (compiled.GetString ("com.xamarin.custom.entitlement")?.Value, Is.EqualTo (value ?? string.Empty), "#1");
+ Assert.That (Engine.Logger.MessageEvents.Any (v => v.Message?.Contains ("The app requests the entitlement 'com.xamarin.custom.entitlement', but provisioning profile WildCardMacAppDevelopment does not grant this entitlement. This is probably not OK.") == true), Is.True, "custom entitlement");
}
[Test]
@@ -216,9 +216,9 @@ public void CustomEntitlemements_StringArray ()
ExecuteTask (task);
var compiled = PDictionary.FromFile (compiledEntitlements)!;
var array = compiled.GetArray ("com.xamarin.custom.entitlement");
- Assert.NotNull (array, "array");
- Assert.AreEqual (new string [] { "A", "B", "C" }, array.ToStringArray (), "array contents");
- Assert.IsTrue (Engine.Logger.MessageEvents.Any (v => v.Message?.Contains ("The app requests the entitlement 'com.xamarin.custom.entitlement', but provisioning profile WildCardMacAppDevelopment does not grant this entitlement. This is probably not OK.") == true), "custom entitlement");
+ Assert.That (array, Is.Not.Null, "array");
+ Assert.That (array.ToStringArray (), Is.EqualTo (new string [] { "A", "B", "C" }), "array contents");
+ Assert.That (Engine.Logger.MessageEvents.Any (v => v.Message?.Contains ("The app requests the entitlement 'com.xamarin.custom.entitlement', but provisioning profile WildCardMacAppDevelopment does not grant this entitlement. This is probably not OK.") == true), Is.True, "custom entitlement");
}
[Test]
@@ -241,8 +241,8 @@ public void CustomEntitlemements_StringArray_CustomSeparator (string separator)
ExecuteTask (task);
var compiled = PDictionary.FromFile (compiledEntitlements)!;
var array = compiled.GetArray ("com.xamarin.custom.entitlement");
- Assert.NotNull (array, "array");
- Assert.AreEqual (new string [] { "A;B;C", "D", "E" }, array.ToStringArray (), "array contents");
+ Assert.That (array, Is.Not.Null, "array");
+ Assert.That (array.ToStringArray (), Is.EqualTo (new string [] { "A;B;C", "D", "E" }), "array contents");
}
[Test]
@@ -253,7 +253,7 @@ public void AllowJit_Default ()
task.ProvisioningProfile = GetResourcePath ("WildCardMacAppDevelopment.provisionprofile");
ExecuteTask (task);
var compiled = PDictionary.FromFile (compiledEntitlements)!;
- Assert.IsFalse (compiled.ContainsKey (EntitlementKeys.AllowExecutionOfJitCode), "#1");
+ Assert.That (compiled.ContainsKey (EntitlementKeys.AllowExecutionOfJitCode), Is.False, "#1");
}
[Test]
@@ -268,8 +268,8 @@ public void AllowJit_True ()
task.CustomEntitlements = customEntitlements;
ExecuteTask (task);
var compiled = PDictionary.FromFile (compiledEntitlements)!;
- Assert.IsTrue (compiled.ContainsKey (EntitlementKeys.AllowExecutionOfJitCode), "#1");
- Assert.IsTrue (compiled.Get (EntitlementKeys.AllowExecutionOfJitCode)?.Value, "#2");
+ Assert.That (compiled.ContainsKey (EntitlementKeys.AllowExecutionOfJitCode), Is.True, "#1");
+ Assert.That (compiled.Get (EntitlementKeys.AllowExecutionOfJitCode)?.Value, Is.True, "#2");
}
[Test]
@@ -284,8 +284,8 @@ public void AllowJit_False ()
task.CustomEntitlements = customEntitlements;
ExecuteTask (task);
var compiled = PDictionary.FromFile (compiledEntitlements)!;
- Assert.IsTrue (compiled.ContainsKey (EntitlementKeys.AllowExecutionOfJitCode), "#1");
- Assert.IsFalse (compiled.Get (EntitlementKeys.AllowExecutionOfJitCode)?.Value, "#2");
+ Assert.That (compiled.ContainsKey (EntitlementKeys.AllowExecutionOfJitCode), Is.True, "#1");
+ Assert.That (compiled.Get (EntitlementKeys.AllowExecutionOfJitCode)?.Value, Is.False, "#2");
Assert.That (archivedEntitlements, Does.Not.Exist, "No archived entitlements");
}
@@ -302,7 +302,7 @@ public void AllowJit_None ()
task.CustomEntitlements = customEntitlements;
ExecuteTask (task);
var compiled = PDictionary.FromFile (compiledEntitlements)!;
- Assert.IsFalse (compiled.ContainsKey (EntitlementKeys.AllowExecutionOfJitCode), "#1");
+ Assert.That (compiled.ContainsKey (EntitlementKeys.AllowExecutionOfJitCode), Is.False, "#1");
}
[Test]
@@ -316,12 +316,12 @@ public void AppIdentifierPrefix ()
task.CustomEntitlements = customEntitlements;
ExecuteTask (task);
var compiled = PDictionary.FromFile (compiledEntitlements)!;
- Assert.IsFalse (compiled.ContainsKey (EntitlementKeys.AllowExecutionOfJitCode), "#1");
+ Assert.That (compiled.ContainsKey (EntitlementKeys.AllowExecutionOfJitCode), Is.False, "#1");
var kag = ((PString?) compiled ["keychain-access-groups"])?.Value;
Assert.That (kag, Is.EqualTo ("32UV7A8CDE.org.xamarin"), "value 1");
var archived = PDictionary.FromFile (archivedEntitlements)!;
- Assert.IsTrue (archived.ContainsKey ("keychain-access-groups"), "archived");
+ Assert.That (archived.ContainsKey ("keychain-access-groups"), Is.True, "archived");
var archivedKag = ((PString?) archived ["keychain-access-groups"])?.Value;
Assert.That (archivedKag, Is.EqualTo ("32UV7A8CDE.org.xamarin"), "archived value 1");
}
@@ -337,12 +337,12 @@ public void TeamIdentifierPrefix ()
task.CustomEntitlements = customEntitlements;
ExecuteTask (task);
var compiled = PDictionary.FromFile (compiledEntitlements)!;
- Assert.IsFalse (compiled.ContainsKey (EntitlementKeys.AllowExecutionOfJitCode), "#1");
+ Assert.That (compiled.ContainsKey (EntitlementKeys.AllowExecutionOfJitCode), Is.False, "#1");
var kag = ((PString?) compiled ["keychain-access-groups"])?.Value;
Assert.That (kag, Is.EqualTo ("Z8CSQKJE7R.org.xamarin"), "value 1");
var archived = PDictionary.FromFile (archivedEntitlements)!;
- Assert.IsTrue (archived.ContainsKey ("keychain-access-groups"), "archived");
+ Assert.That (archived.ContainsKey ("keychain-access-groups"), Is.True, "archived");
var archivedKag = ((PString?) archived ["keychain-access-groups"])?.Value;
Assert.That (archivedKag, Is.EqualTo ("Z8CSQKJE7R.org.xamarin"), "archived value 1");
}
@@ -364,12 +364,12 @@ public void TeamIdentifierPrefix_Simulator ()
var inExecutable = PDictionary.FromFile (task.EntitlementsInExecutable!.ItemSpec)!;
Assert.That (inExecutable.Count, Is.EqualTo (4), $"in executable count");
- Assert.IsFalse (inExecutable.ContainsKey (EntitlementKeys.AllowExecutionOfJitCode), "#1");
- Assert.IsTrue (inExecutable.ContainsKey ("keychain-access-groups"), "in executable");
+ Assert.That (inExecutable.ContainsKey (EntitlementKeys.AllowExecutionOfJitCode), Is.False, "#1");
+ Assert.That (inExecutable.ContainsKey ("keychain-access-groups"), Is.True, "in executable");
Assert.That (((PString?) inExecutable ["keychain-access-groups"])?.Value, Is.EqualTo ("Z8CSQKJE7R.org.xamarin"), "in executable value 1");
- Assert.IsFalse (inExecutable.ContainsKey ("com.apple.security.get-task-allow"), "in executable com.apple.security.get-task-allow");
- Assert.IsTrue (inExecutable.ContainsKey ("get-task-allow"), $"in executable get-task-allow");
+ Assert.That (inExecutable.ContainsKey ("com.apple.security.get-task-allow"), Is.False, "in executable com.apple.security.get-task-allow");
+ Assert.That (inExecutable.ContainsKey ("get-task-allow"), Is.True, $"in executable get-task-allow");
var inSignature = PDictionary.FromFile (task.EntitlementsInSignature!.ItemSpec)!;
Assert.That (inSignature.Count, Is.EqualTo (0), $"in signature count");
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ComputeCodesignItemsTaskTests.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ComputeCodesignItemsTaskTests.cs
index 6e964fc46e09..3c3cfff6ff63 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ComputeCodesignItemsTaskTests.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ComputeCodesignItemsTaskTests.cs
@@ -345,7 +345,7 @@ public void Compute (ApplePlatform platform)
task.NativeStripItems = nativeStripItems.ToArray ();
task.TargetFrameworkMoniker = TargetFramework.GetTargetFramework (platform).ToString ();
ExecuteTask (task);
- Assert.AreEqual (0, Engine.Logger.WarningsEvents.Count, "Warning Count");
+ Assert.That (Engine.Logger.WarningsEvents.Count, Is.EqualTo (0), "Warning Count");
VerifyCodesigningResults (infos, task.OutputCodesignItems, platform);
} finally {
@@ -413,7 +413,7 @@ public void Symlinks (ApplePlatform platform)
task.CodesignStampPath = "codesign-stamp-path/";
task.TargetFrameworkMoniker = TargetFramework.GetTargetFramework (platform).ToString ();
ExecuteTask (task);
- Assert.AreEqual (0, Engine.Logger.WarningsEvents.Count, "Warning Count");
+ Assert.That (Engine.Logger.WarningsEvents.Count, Is.EqualTo (0), "Warning Count");
VerifyCodesigningResults (infos, task.OutputCodesignItems, platform);
} finally {
@@ -494,7 +494,7 @@ public void SkipDirectories (ApplePlatform platform)
task.CodesignStampPath = "codesign-stamp-path/";
task.TargetFrameworkMoniker = TargetFramework.GetTargetFramework (platform).ToString ();
ExecuteTask (task);
- Assert.AreEqual (0, Engine.Logger.WarningsEvents.Count, "Warning Count");
+ Assert.That (Engine.Logger.WarningsEvents.Count, Is.EqualTo (0), "Warning Count");
VerifyCodesigningResults (infos, task.OutputCodesignItems, platform);
} finally {
@@ -557,7 +557,7 @@ public void Duplicated (ApplePlatform platform)
task.CodesignStampPath = "codesign-stamp-path/";
task.TargetFrameworkMoniker = TargetFramework.GetTargetFramework (platform).ToString ();
ExecuteTask (task);
- Assert.AreEqual (0, Engine.Logger.WarningsEvents.Count, "Warning Count");
+ Assert.That (Engine.Logger.WarningsEvents.Count, Is.EqualTo (0), "Warning Count");
VerifyCodesigningResults (infos, task.OutputCodesignItems, platform);
} finally {
@@ -631,10 +631,10 @@ public void DuplicatedWithDifferentMetadata (ApplePlatform platform)
task.CodesignStampPath = "codesign-stamp-path/";
task.TargetFrameworkMoniker = TargetFramework.GetTargetFramework (platform).ToString ();
ExecuteTask (task);
- Assert.AreEqual (3, Engine.Logger.WarningsEvents.Count, "Warning Count");
- Assert.AreEqual ("Code signing has been requested multiple times for 'Bundle.app/Contents/MonoBundle/createdump', with different metadata. The metadata 'OnlyIn1=true' has been set for one item, but not the other.", Engine.Logger.WarningsEvents [0].Message, "Message #0");
- Assert.AreEqual ("Code signing has been requested multiple times for 'Bundle.app/Contents/MonoBundle/createdump', with different metadata. The metadata 'InOneAndTwoWithDifferentValues' has different values for each item (once it's '1', another time it's '2').", Engine.Logger.WarningsEvents [1].Message, "Message #1");
- Assert.AreEqual ("Code signing has been requested multiple times for 'Bundle.app/Contents/MonoBundle/createdump', with different metadata. The metadata for one are: 'CodesignStampFile, InOneAndTwoWithDifferentValues, OnlyIn1, RequireCodeSigning', while the metadata for the other are: 'CodesignStampFile, RequireCodeSigning'", Engine.Logger.WarningsEvents [2].Message, "Message #2");
+ Assert.That (Engine.Logger.WarningsEvents.Count, Is.EqualTo (3), "Warning Count");
+ Assert.That (Engine.Logger.WarningsEvents [0].Message, Is.EqualTo ("Code signing has been requested multiple times for 'Bundle.app/Contents/MonoBundle/createdump', with different metadata. The metadata 'OnlyIn1=true' has been set for one item, but not the other."), "Message #0");
+ Assert.That (Engine.Logger.WarningsEvents [1].Message, Is.EqualTo ("Code signing has been requested multiple times for 'Bundle.app/Contents/MonoBundle/createdump', with different metadata. The metadata 'InOneAndTwoWithDifferentValues' has different values for each item (once it's '1', another time it's '2')."), "Message #1");
+ Assert.That (Engine.Logger.WarningsEvents [2].Message, Is.EqualTo ("Code signing has been requested multiple times for 'Bundle.app/Contents/MonoBundle/createdump', with different metadata. The metadata for one are: 'CodesignStampFile, InOneAndTwoWithDifferentValues, OnlyIn1, RequireCodeSigning', while the metadata for the other are: 'CodesignStampFile, RequireCodeSigning'"), "Message #2");
VerifyCodesigningResults (infos, task.OutputCodesignItems, platform);
} finally {
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CreateBindingResourceTaskTests.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CreateBindingResourceTaskTests.cs
index f5d655244035..fbfdae8f49a8 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CreateBindingResourceTaskTests.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/CreateBindingResourceTaskTests.cs
@@ -95,7 +95,7 @@ void Extract (string zipArchive, string targetDirectory)
unzipArguments.Add (targetDirectory);
unzipArguments.Add (zipArchive);
var rv = Execution.RunAsync ("unzip", unzipArguments).Result;
- Assert.AreEqual (0, rv.ExitCode, "ExitCode\n" + rv.Output.MergedOutput);
+ Assert.That (rv.ExitCode, Is.EqualTo (0), "ExitCode\n" + rv.Output.MergedOutput);
}
void AssertResourceDirectory (string directory, bool symlinks)
@@ -104,22 +104,22 @@ void AssertResourceDirectory (string directory, bool symlinks)
foreach (var file in allFiles)
Console.WriteLine (file);
if (symlinks) {
- Assert.AreEqual (7, allFiles.Length, "Length");
+ Assert.That (allFiles.Length, Is.EqualTo (7), "Length");
} else {
- Assert.AreEqual (5, allFiles.Length, "Length");
+ Assert.That (allFiles.Length, Is.EqualTo (5), "Length");
}
- Assert.AreEqual ("ABCDEFGHIJKLMAAA", File.ReadAllText (Path.Combine (directory, "A.txt")), "A.txt");
- Assert.AreEqual ("ABCDEFGHIJKLMBBB", File.ReadAllText (Path.Combine (directory, "B.txt")), "B.txt");
- Assert.AreEqual ("ABCDEFGHIJKLMCCC", File.ReadAllText (Path.Combine (directory, "C.framework/C.txt")), "C.txt");
+ Assert.That (File.ReadAllText (Path.Combine (directory, "A.txt")), Is.EqualTo ("ABCDEFGHIJKLMAAA"), "A.txt");
+ Assert.That (File.ReadAllText (Path.Combine (directory, "B.txt")), Is.EqualTo ("ABCDEFGHIJKLMBBB"), "B.txt");
+ Assert.That (File.ReadAllText (Path.Combine (directory, "C.framework/C.txt")), Is.EqualTo ("ABCDEFGHIJKLMCCC"), "C.txt");
if (symlinks) {
var linkToCPath = Path.Combine (directory, "C.framework/LinkToC.txt");
- Assert.AreEqual ("ABCDEFGHIJKLMCCC", File.ReadAllText (linkToCPath), "LinkToC.txt");
- Assert.IsTrue (PathUtils.IsSymlink (linkToCPath), "LinkToC.txt - IsSymlink");
- Assert.AreEqual ("C.txt", PathUtils.GetSymlinkTarget (linkToCPath), "LinkToC.txt - IsSymlink target");
+ Assert.That (File.ReadAllText (linkToCPath), Is.EqualTo ("ABCDEFGHIJKLMCCC"), "LinkToC.txt");
+ Assert.That (PathUtils.IsSymlink (linkToCPath), Is.True, "LinkToC.txt - IsSymlink");
+ Assert.That (PathUtils.GetSymlinkTarget (linkToCPath), Is.EqualTo ("C.txt"), "LinkToC.txt - IsSymlink target");
var linkToNowherePath = Path.Combine (directory, "C.framework/LinkToNowhere.txt");
Assert.Throws (() => File.ReadAllText (linkToNowherePath), "LinkToNowhere.txt");
- Assert.AreEqual ("Nowhere.txt", PathUtils.GetSymlinkTarget (linkToNowherePath), "LinkToNowhere.txt - IsSymlink target");
+ Assert.That (PathUtils.GetSymlinkTarget (linkToNowherePath), Is.EqualTo ("Nowhere.txt"), "LinkToNowhere.txt - IsSymlink target");
}
var manifest = @"
@@ -157,7 +157,7 @@ void AssertResourceDirectory (string directory, bool symlinks)
";
- Assert.AreEqual (manifest, File.ReadAllText (Path.Combine (directory, "manifest")), "Manifest");
+ Assert.That (File.ReadAllText (Path.Combine (directory, "manifest")), Is.EqualTo (manifest), "Manifest");
}
ITaskItem [] CreateNativeReferences (string tmpdir, bool symlinks)
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/DetectSdkLocationsTaskTests.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/DetectSdkLocationsTaskTests.cs
index e073eda32d71..7c49889b880f 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/DetectSdkLocationsTaskTests.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/DetectSdkLocationsTaskTests.cs
@@ -18,7 +18,7 @@ public void InvalidXamarinSdkRoot ()
task.TargetFrameworkMoniker = TargetFramework.DotNet_iOS_String;
ExecuteTask (task, 1);
- Assert.AreEqual ("XYZ", task.XamarinSdkRoot, "#1");
+ Assert.That (task.XamarinSdkRoot, Is.EqualTo ("XYZ"), "#1");
}
}
}
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/DetectSigningIdentityTaskTests.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/DetectSigningIdentityTaskTests.cs
index ae959e2c7f31..2b30d1a51326 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/DetectSigningIdentityTaskTests.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/DetectSigningIdentityTaskTests.cs
@@ -35,11 +35,11 @@ public void Default ()
ExecuteTask (task);
Assert.That (task.DetectedAppId, Is.Null.Or.Empty, "DetectedAppId");
- Assert.AreEqual ("-", task.DetectedCodeSigningKey, "DetectedCodeSigningKey");
- Assert.AreEqual ($"{Xamarin.Tests.Configuration.XcodeLocation}/Toolchains/XcodeDefault.xctoolchain/usr/bin/codesign_allocate", task.DetectedCodesignAllocate, "DetectedCodesignAllocate");
- Assert.AreEqual ("Any", task.DetectedDistributionType, "DetectedDistributionType");
+ Assert.That (task.DetectedCodeSigningKey, Is.EqualTo ("-"), "DetectedCodeSigningKey");
+ Assert.That (task.DetectedCodesignAllocate, Is.EqualTo ($"{Xamarin.Tests.Configuration.XcodeLocation}/Toolchains/XcodeDefault.xctoolchain/usr/bin/codesign_allocate"), "DetectedCodesignAllocate");
+ Assert.That (task.DetectedDistributionType, Is.EqualTo ("Any"), "DetectedDistributionType");
Assert.That (task.DetectedProvisioningProfile, Is.Null.Or.Empty, "DetectedProvisioningProfile");
- Assert.IsFalse (task.HasEntitlements, "HasEntitlements");
+ Assert.That (task.HasEntitlements, Is.False, "HasEntitlements");
}
const string EmptyEntitlements1 = @"
@@ -142,17 +142,17 @@ public void EmptyEntitlements (EntitlementTestCase testCase)
Assert.That (task.DetectedAppId, Does.EndWith (".com.tests.emptyentitlements"), "DetectedAppId");
Assert.That (task.DetectedProvisioningProfile, Is.Not.Null.And.Not.Empty, "DetectedProvisioningProfile");
} else {
- Assert.AreEqual ("com.tests.emptyentitlements", task.DetectedAppId, "DetectedAppId");
+ Assert.That (task.DetectedAppId, Is.EqualTo ("com.tests.emptyentitlements"), "DetectedAppId");
Assert.That (task.DetectedProvisioningProfile, Is.Null.Or.Empty, "DetectedProvisioningProfile");
}
if (testCase.IsSimulator || !requiresProvisioningProfile) {
- Assert.AreEqual ("-", task.DetectedCodeSigningKey, "DetectedCodeSigningKey");
+ Assert.That (task.DetectedCodeSigningKey, Is.EqualTo ("-"), "DetectedCodeSigningKey");
Assert.That (task.DetectedDistributionType, Is.EqualTo ("Any"), "DetectedDistributionType");
} else {
Assert.That (task.DetectedCodeSigningKey, Has.Length.EqualTo ("20D63576DE3EA7BE419C18997CF948D759B43D53".Length), "DetectedCodeSigningKey");
Assert.That (task.DetectedDistributionType, Is.EqualTo ("Development").Or.EqualTo ("AppStore").Or.EqualTo ("Any"), "DetectedDistributionType");
}
- Assert.AreEqual ($"{Xamarin.Tests.Configuration.XcodeLocation}/Toolchains/XcodeDefault.xctoolchain/usr/bin/codesign_allocate", task.DetectedCodesignAllocate, "DetectedCodesignAllocate");
+ Assert.That (task.DetectedCodesignAllocate, Is.EqualTo ($"{Xamarin.Tests.Configuration.XcodeLocation}/Toolchains/XcodeDefault.xctoolchain/usr/bin/codesign_allocate"), "DetectedCodesignAllocate");
}
[Test]
@@ -164,11 +164,11 @@ public void CustomEntitlements ()
ExecuteTask (task);
Assert.That (task.DetectedAppId, Is.Not.Null.And.Not.Empty, "DetectedAppId");
- Assert.AreEqual ("-", task.DetectedCodeSigningKey, "DetectedCodeSigningKey");
- Assert.AreEqual ($"{Xamarin.Tests.Configuration.XcodeLocation}/Toolchains/XcodeDefault.xctoolchain/usr/bin/codesign_allocate", task.DetectedCodesignAllocate, "DetectedCodesignAllocate");
- Assert.AreEqual ("Any", task.DetectedDistributionType, "DetectedDistributionType");
+ Assert.That (task.DetectedCodeSigningKey, Is.EqualTo ("-"), "DetectedCodeSigningKey");
+ Assert.That (task.DetectedCodesignAllocate, Is.EqualTo ($"{Xamarin.Tests.Configuration.XcodeLocation}/Toolchains/XcodeDefault.xctoolchain/usr/bin/codesign_allocate"), "DetectedCodesignAllocate");
+ Assert.That (task.DetectedDistributionType, Is.EqualTo ("Any"), "DetectedDistributionType");
Assert.That (task.DetectedProvisioningProfile, Is.Not.Null.And.Not.Empty, "DetectedProvisioningProfile");
- Assert.IsTrue (task.HasEntitlements, "HasEntitlements");
+ Assert.That (task.HasEntitlements, Is.True, "HasEntitlements");
}
[Test]
@@ -183,11 +183,11 @@ public void Simulator ()
Assert.Multiple (() => {
Assert.That (task.DetectedAppId, Does.EndWith ("." + task.BundleIdentifier), "DetectedAppId");
- Assert.AreEqual ("-", task.DetectedCodeSigningKey, "DetectedCodeSigningKey");
- Assert.AreEqual ($"{Xamarin.Tests.Configuration.XcodeLocation}/Toolchains/XcodeDefault.xctoolchain/usr/bin/codesign_allocate", task.DetectedCodesignAllocate, "DetectedCodesignAllocate");
- Assert.AreEqual ("Any", task.DetectedDistributionType, "DetectedDistributionType");
+ Assert.That (task.DetectedCodeSigningKey, Is.EqualTo ("-"), "DetectedCodeSigningKey");
+ Assert.That (task.DetectedCodesignAllocate, Is.EqualTo ($"{Xamarin.Tests.Configuration.XcodeLocation}/Toolchains/XcodeDefault.xctoolchain/usr/bin/codesign_allocate"), "DetectedCodesignAllocate");
+ Assert.That (task.DetectedDistributionType, Is.EqualTo ("Any"), "DetectedDistributionType");
Assert.That (task.DetectedProvisioningProfile, Is.Not.Null.And.Not.Empty, "DetectedProvisioningProfile");
- Assert.IsTrue (task.HasEntitlements, "HasEntitlements");
+ Assert.That (task.HasEntitlements, Is.True, "HasEntitlements");
});
}
}
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GeneratePlistTaskTests/GeneratePlistTaskTests_Core.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GeneratePlistTaskTests/GeneratePlistTaskTests_Core.cs
index f369b2035fad..a8e81d00e169 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GeneratePlistTaskTests/GeneratePlistTaskTests_Core.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GeneratePlistTaskTests/GeneratePlistTaskTests_Core.cs
@@ -68,16 +68,16 @@ public override void Setup ()
public void PlistMissing ()
{
File.Delete (Task.AppManifest!.ItemSpec);
- Assert.IsTrue (Task.Execute (), "#1");
+ Assert.That (Task.Execute (), Is.True, "#1");
Assert.That (Task.CompiledAppManifest!.ItemSpec, Does.Exist, "#2");
}
[Test]
public void NormalPlist ()
{
- Assert.IsTrue (Task.Execute (), "#1");
- Assert.IsNotNull (Task.CompiledAppManifest?.ItemSpec, "#2");
- Assert.IsTrue (File.Exists (Task.CompiledAppManifest!.ItemSpec), "#3");
+ Assert.That (Task.Execute (), Is.True, "#1");
+ Assert.That (Task.CompiledAppManifest?.ItemSpec, Is.Not.Null, "#2");
+ Assert.That (File.Exists (Task.CompiledAppManifest!.ItemSpec), Is.True, "#3");
}
[Test]
@@ -85,7 +85,7 @@ public void MissingBundleIdentifier ()
{
Plist.Remove ("CFBundleIdentifier");
Plist.Save (Task.AppManifest!.ItemSpec);
- Assert.IsTrue (Task.Execute (), "#1");
+ Assert.That (Task.Execute (), Is.True, "#1");
}
[Test]
@@ -93,7 +93,7 @@ public void MissingDisplayName ()
{
Plist.Remove ("CFBundleDisplayName");
Plist.Save (Task.AppManifest!.ItemSpec);
- Assert.IsTrue (Task.Execute (), "#1");
+ Assert.That (Task.Execute (), Is.True, "#1");
}
[Test]
@@ -116,28 +116,28 @@ public void BuildMachineOSBuild ()
[Test]
public void BundleDevelopmentRegion ()
{
- Assert.IsFalse (CompiledPlist.ContainsKey (ManifestKeys.CFBundleDevelopmentRegion), "#1");
+ Assert.That (CompiledPlist.ContainsKey (ManifestKeys.CFBundleDevelopmentRegion), Is.False, "#1");
}
[Test]
public virtual void BundleExecutable ()
{
Assert.That (CompiledPlist.ContainsKey (ManifestKeys.CFBundleExecutable), "#1");
- Assert.AreEqual (CompiledPlist.Get (ManifestKeys.CFBundleExecutable)?.Value, assemblyName, "#2");
+ Assert.That (assemblyName, Is.EqualTo (CompiledPlist.Get (ManifestKeys.CFBundleExecutable)?.Value), "#2");
}
[Test]
public virtual void BundleName ()
{
Assert.That (CompiledPlist.ContainsKey (ManifestKeys.CFBundleName), "#1");
- Assert.AreEqual (CompiledPlist.Get (ManifestKeys.CFBundleName)?.Value, appBundleName, "#2");
+ Assert.That (appBundleName, Is.EqualTo (CompiledPlist.Get (ManifestKeys.CFBundleName)?.Value), "#2");
}
[Test]
public virtual void BundleIdentifier ()
{
Assert.That (CompiledPlist.ContainsKey (ManifestKeys.CFBundleIdentifier), "#1");
- Assert.AreEqual (CompiledPlist.Get (ManifestKeys.CFBundleIdentifier)?.Value, bundleIdentifier, "#2");
+ Assert.That (bundleIdentifier, Is.EqualTo (CompiledPlist.Get (ManifestKeys.CFBundleIdentifier)?.Value), "#2");
}
[Test]
@@ -151,14 +151,14 @@ public virtual void BundleInfoDictionaryVersion ()
public virtual void BundlePackageType ()
{
Assert.That (CompiledPlist.ContainsKey (ManifestKeys.CFBundlePackageType), "#1");
- Assert.AreEqual (CompiledPlist.Get (ManifestKeys.CFBundlePackageType)?.Value, "APPL", "#2");
+ Assert.That ("APPL", Is.EqualTo (CompiledPlist.Get (ManifestKeys.CFBundlePackageType)?.Value), "#2");
}
[Test]
public virtual void BundleSignature ()
{
Assert.That (CompiledPlist.ContainsKey (ManifestKeys.CFBundleSignature), "#1");
- Assert.AreEqual (CompiledPlist.Get (ManifestKeys.CFBundleSignature)?.Value, "????", "#2");
+ Assert.That ("????", Is.EqualTo (CompiledPlist.Get (ManifestKeys.CFBundleSignature)?.Value), "#2");
}
[Test]
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GeneratePlistTaskTests/GeneratePlistTaskTests_iOS.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GeneratePlistTaskTests/GeneratePlistTaskTests_iOS.cs
index 9ccd1a1b8930..144e00166d4f 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GeneratePlistTaskTests/GeneratePlistTaskTests_iOS.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GeneratePlistTaskTests/GeneratePlistTaskTests_iOS.cs
@@ -26,14 +26,14 @@ public override void BundleExecutable ()
base.BundleExecutable ();
// Adding ".app" to the assembly name isn't allowed because iOS may fail to launch the app.
Task.BundleExecutable = "AssemblyName.app";
- Assert.IsFalse (Task.Execute (), "#1");
+ Assert.That (Task.Execute (), Is.False, "#1");
}
[Test]
public override void BundleName ()
{
Assert.That (CompiledPlist.ContainsKey (ManifestKeys.CFBundleName), "#1");
- Assert.AreEqual (CompiledPlist.Get (ManifestKeys.CFBundleName)?.Value, appBundleName, "#2");
+ Assert.That (appBundleName, Is.EqualTo (CompiledPlist.Get (ManifestKeys.CFBundleName)?.Value), "#2");
}
[Test]
@@ -41,10 +41,10 @@ public void RequiredDeviceCapabilities ()
{
PArray? array;
- Assert.IsTrue (CompiledPlist.TryGetValue (ManifestKeys.UIRequiredDeviceCapabilities, out array), "#1");
- Assert.IsTrue (array?.OfType ().Any (x => x.Value == "arm64") == true, "#2");
- Assert.IsFalse (array?.OfType ().Any (x => x.Value == "armv6") == true, "#3");
- Assert.IsFalse (array?.OfType ().Any (x => x.Value == "armv7") == true, "#4");
+ Assert.That (CompiledPlist.TryGetValue (ManifestKeys.UIRequiredDeviceCapabilities, out array), Is.True, "#1");
+ Assert.That (array?.OfType ().Any (x => x.Value == "arm64") == true, Is.True, "#2");
+ Assert.That (array?.OfType ().Any (x => x.Value == "armv6") == true, Is.False, "#3");
+ Assert.That (array?.OfType ().Any (x => x.Value == "armv7") == true, Is.False, "#4");
}
}
}
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GeneratePlistTaskTests/GeneratePlistTaskTests_iOS_AppExtension.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GeneratePlistTaskTests/GeneratePlistTaskTests_iOS_AppExtension.cs
index dace42f2137e..49adae09756d 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GeneratePlistTaskTests/GeneratePlistTaskTests_iOS_AppExtension.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GeneratePlistTaskTests/GeneratePlistTaskTests_iOS_AppExtension.cs
@@ -14,7 +14,7 @@ protected override void ConfigureTask ()
public override void BundlePackageType ()
{
Assert.That (CompiledPlist.ContainsKey (ManifestKeys.CFBundlePackageType), "#1");
- Assert.AreEqual (CompiledPlist.Get (ManifestKeys.CFBundlePackageType)?.Value, "XPC!", "#2");
+ Assert.That ("XPC!", Is.EqualTo (CompiledPlist.Get (ManifestKeys.CFBundlePackageType)?.Value), "#2");
}
}
}
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GetAvailableDevicesTest.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GetAvailableDevicesTest.cs
index b8e71570aeb0..1d874fcb732c 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GetAvailableDevicesTest.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GetAvailableDevicesTest.cs
@@ -58,7 +58,7 @@ public void EmptyJsons (string simctl, string devicectl)
{
var platform = ApplePlatform.iOS;
var task = CreateTask (platform, simctl, devicectl);
- Assert.IsTrue (task.Execute (), "Task should have succeeded.");
+ Assert.That (task.Execute (), Is.True, "Task should have succeeded.");
Assert.That (task.Devices.Count, Is.EqualTo (0), "Devices should be empty.");
Assert.That (task.DiscardedDevices.Count, Is.EqualTo (0), "No devices should have been discarded.");
}
@@ -68,7 +68,7 @@ public void DeviceCtl1 ()
{
var platform = ApplePlatform.iOS;
var task = CreateTask (platform, "", DEVICECTL_JSON_1);
- Assert.IsTrue (task.Execute (), "Task should have succeeded.");
+ Assert.That (task.Execute (), Is.True, "Task should have succeeded.");
Assert.Multiple (() => {
Assert.That (task.Devices.Count, Is.EqualTo (3), "Devices count mismatch.");
Assert.That (task.DiscardedDevices.Count, Is.EqualTo (1), "Discarded device count mismatch.");
@@ -111,7 +111,7 @@ public void SimCtl1 ()
var platform = ApplePlatform.iOS;
var task = CreateTask (platform, SIMCTL_JSON_1, "");
- Assert.IsTrue (task.Execute (), "Task should have succeeded.");
+ Assert.That (task.Execute (), Is.True, "Task should have succeeded.");
Assert.Multiple (() => {
Assert.That (task.Devices.Count, Is.EqualTo (2), "Devices count mismatch.");
Assert.That (task.DiscardedDevices.Count, Is.EqualTo (3), "Discarded device count mismatch.");
@@ -160,7 +160,7 @@ public void Ctl1 ()
var platform = ApplePlatform.iOS;
var task = CreateTask (platform, SIMCTL_JSON_1, DEVICECTL_JSON_1);
- Assert.IsTrue (task.Execute (), "Task should have succeeded.");
+ Assert.That (task.Execute (), Is.True, "Task should have succeeded.");
Assert.Multiple (() => {
Assert.That (task.Devices.Count, Is.EqualTo (5), "Devices count mismatch.");
Assert.That (task.DiscardedDevices.Count, Is.EqualTo (4), "Discarded device count mismatch.");
@@ -250,7 +250,7 @@ public void Ctl1_iPhone ()
""";
var task = CreateTask (platform, SIMCTL_JSON_1, DEVICECTL_JSON_1, appManifestXml);
- Assert.IsTrue (task.Execute (), "Task should have succeeded.");
+ Assert.That (task.Execute (), Is.True, "Task should have succeeded.");
Assert.Multiple (() => {
Assert.That (task.Devices.Count, Is.EqualTo (5), "Devices count mismatch.");
Assert.That (task.DiscardedDevices.Count, Is.EqualTo (4), "Discarded device count mismatch.");
@@ -344,7 +344,7 @@ public void Ctl1_iPad ()
var task = CreateTask (platform, SIMCTL_JSON_1, DEVICECTL_JSON_1, appManifestXml);
- Assert.IsTrue (task.Execute (), "Task should have succeeded.");
+ Assert.That (task.Execute (), Is.True, "Task should have succeeded.");
Assert.Multiple (() => {
Assert.That (task.Devices.Count, Is.EqualTo (2), "Devices count mismatch.");
Assert.That (task.DiscardedDevices.Count, Is.EqualTo (7), "Discarded device count mismatch.");
@@ -438,7 +438,7 @@ public void Ctl1_OSVersion ()
File.WriteAllText (appManifestPath, appManifestXml);
task.AppBundleManifestPath = appManifestPath;
- Assert.IsTrue (task.Execute (), "Task should have succeeded.");
+ Assert.That (task.Execute (), Is.True, "Task should have succeeded.");
Assert.Multiple (() => {
Assert.That (task.Devices.Count, Is.EqualTo (3), "Devices count mismatch.");
Assert.That (task.DiscardedDevices.Count, Is.EqualTo (6), "Discarded device count mismatch.");
@@ -531,7 +531,7 @@ public void Ctl1_RuntimeIdentifier ()
task.AppBundleManifestPath = appManifestPath;
task.RuntimeIdentifier = $"ios-arm64";
- Assert.IsTrue (task.Execute (), "Task should have succeeded.");
+ Assert.That (task.Execute (), Is.True, "Task should have succeeded.");
Assert.Multiple (() => {
Assert.That (task.Devices.Count, Is.EqualTo (3), "Devices count mismatch.");
Assert.That (task.DiscardedDevices.Count, Is.EqualTo (6), "Discarded device count mismatch.");
@@ -609,7 +609,7 @@ public void Ctl1_AppleTV ()
var platform = ApplePlatform.TVOS;
var task = CreateTask (platform, SIMCTL_JSON_1, DEVICECTL_JSON_1);
- Assert.IsTrue (task.Execute (), "Task should have succeeded.");
+ Assert.That (task.Execute (), Is.True, "Task should have succeeded.");
Assert.Multiple (() => {
Assert.That (task.Devices.Count, Is.EqualTo (1), "Devices count mismatch.");
Assert.That (task.DiscardedDevices.Count, Is.EqualTo (8), "Discarded device count mismatch.");
@@ -684,7 +684,7 @@ public void DeviceCtl2_Mac ()
{
var platform = ApplePlatform.iOS;
var task = CreateTask (platform, "", DEVICECTL_JSON_2);
- Assert.IsTrue (task.Execute (), "Task should have succeeded.");
+ Assert.That (task.Execute (), Is.True, "Task should have succeeded.");
Assert.Multiple (() => {
Assert.That (task.DiscardedDevices [0].ItemSpec, Is.EqualTo ("12345678-1234-1234-ABCD-1234567980AB"), "Discarded Device 1 itemspec mismatch.");
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GetBundleNameTaskTests.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GetBundleNameTaskTests.cs
index 516fe565cacc..4676f3bee06a 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GetBundleNameTaskTests.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GetBundleNameTaskTests.cs
@@ -21,7 +21,7 @@ public void GetBundleName ()
task.ProjectName = "!@£///Hello_World%£";
ExecuteTask (task);
- Assert.AreEqual ("Hello_World", task.BundleName, "#2");
+ Assert.That (task.BundleName, Is.EqualTo ("Hello_World"), "#2");
}
}
}
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GetPropertyListValueTaskTests.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GetPropertyListValueTaskTests.cs
index 22554e631acc..38eb9c5a3a32 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GetPropertyListValueTaskTests.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/GetPropertyListValueTaskTests.cs
@@ -23,7 +23,7 @@ void TestExecuteTask (string property, string? expected)
ExecuteTask (task);
- Assert.AreEqual (expected, task.Value, "Task produced the incorrect plist output.");
+ Assert.That (task.Value, Is.EqualTo (expected), "Task produced the incorrect plist output.");
}
[Test]
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/IBToolTaskTests.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/IBToolTaskTests.cs
index 8c301b35e3c8..ee14b269122d 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/IBToolTaskTests.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/IBToolTaskTests.cs
@@ -62,10 +62,10 @@ public void TestBasicIBToolFunctionality ()
var ibtool = CreateIBToolTask (ApplePlatform.iOS, srcdir, tmp);
var bundleResources = new HashSet ();
- Assert.IsTrue (ibtool.Execute (), "Execution of IBTool task failed.");
+ Assert.That (ibtool.Execute (), Is.True, "Execution of IBTool task failed.");
foreach (var bundleResource in ibtool.BundleResources) {
- Assert.IsTrue (File.Exists (bundleResource.ItemSpec), "File does not exist: {0}", bundleResource.ItemSpec);
+ Assert.That (File.Exists (bundleResource.ItemSpec), Is.True, $"File does not exist: {bundleResource.ItemSpec}");
Assert.That (bundleResource.GetMetadata ("LogicalName"), Is.Not.Null.Or.Empty, "The 'LogicalName' metadata must be set.");
Assert.That (bundleResource.GetMetadata ("Optimize"), Is.Not.Null.Or.Empty, "The 'Optimize' metadata must be set.");
@@ -104,18 +104,18 @@ public void TestAdvancedIBToolFunctionality ()
ibtool.EnableOnDemandResources = true;
- Assert.IsTrue (ibtool.Execute (), "Execution of IBTool task failed.");
+ Assert.That (ibtool.Execute (), Is.True, "Execution of IBTool task failed.");
foreach (var bundleResource in ibtool.BundleResources) {
var bundleName = bundleResource.GetMetadata ("LogicalName");
var tag = bundleResource.GetMetadata ("ResourceTags");
- Assert.IsTrue (File.Exists (bundleResource.ItemSpec), "File does not exist: {0}", bundleResource.ItemSpec);
+ Assert.That (File.Exists (bundleResource.ItemSpec), Is.True, $"File does not exist: {bundleResource.ItemSpec}");
Assert.That (bundleResource.GetMetadata ("LogicalName"), Is.Not.Null.Or.Empty, "The 'LogicalName' metadata must be set.");
Assert.That (bundleResource.GetMetadata ("Optimize"), Is.Not.Null.Or.Empty, "The 'Optimize' metadata must be set.");
Assert.That (tag, Is.Not.Null.Or.Empty, "The 'ResourceTags' metadata should be set.");
- Assert.IsTrue (bundleName.Contains (".lproj/" + tag + ".storyboardc/"), "BundleResource does not have the proper ResourceTags set: {0}", bundleName);
+ Assert.That (bundleName.Contains (".lproj/" + tag + ".storyboardc/"), Is.True, $"BundleResource does not have the proper ResourceTags set: {bundleName}");
bundleResources.Add (bundleName);
}
@@ -179,18 +179,18 @@ void TestGenericAndDeviceSpecificXibsGeneric (params string [] fileNames)
ibtool.EnableOnDemandResources = true;
- Assert.IsTrue (ibtool.Execute (), "Execution of IBTool task failed.");
+ Assert.That (ibtool.Execute (), Is.True, "Execution of IBTool task failed.");
foreach (var bundleResource in ibtool.BundleResources) {
var bundleName = bundleResource.GetMetadata ("LogicalName");
var tag = bundleResource.GetMetadata ("ResourceTags");
- Assert.IsTrue (File.Exists (bundleResource.ItemSpec), "File does not exist: {0}", bundleResource.ItemSpec);
+ Assert.That (File.Exists (bundleResource.ItemSpec), Is.True, $"File does not exist: {bundleResource.ItemSpec}");
Assert.That (bundleResource.GetMetadata ("LogicalName"), Is.Not.Null.Or.Empty, "The 'LogicalName' metadata must be set.");
Assert.That (bundleResource.GetMetadata ("Optimize"), Is.Not.Null.Or.Empty, "The 'Optimize' metadata must be set.");
Assert.That (tag, Is.Not.Null.Or.Empty, "The 'ResourceTags' metadata should be set.");
- Assert.AreEqual (Path.Combine (tmp, "ibtool", tag + ".nib"), bundleResource.ItemSpec, $"BundleResource {bundleName} is not at the expected location.");
+ Assert.That (bundleResource.ItemSpec, Is.EqualTo (Path.Combine (tmp, "ibtool", tag + ".nib")), $"BundleResource {bundleName} is not at the expected location.");
bundleResources.Add (bundleName);
}
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/LocalizationStringTest.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/LocalizationStringTest.cs
index d6bb024a3940..ac38aee0da38 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/LocalizationStringTest.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/LocalizationStringTest.cs
@@ -43,7 +43,7 @@ public void AllSupportedTranslations (string culture, string errorMessage)
ExecuteTask (task, 1);
bool isTranslated = Engine.Logger.ErrorEvents [0].Message?.Contains (errorMessage) == true;
- Assert.IsTrue (isTranslated, $"Should contain \"{errorMessage}\", but instead has value: \"{Engine.Logger.ErrorEvents [0].Message}\"");
+ Assert.That (isTranslated, Is.True, $"Should contain \"{errorMessage}\", but instead has value: \"{Engine.Logger.ErrorEvents [0].Message}\"");
} finally {
Thread.CurrentThread.CurrentUICulture = originalUICulture;
Thread.CurrentThread.CurrentCulture = originalCulture;
@@ -71,11 +71,11 @@ public void SpecificErrorTranslation (string culture)
CultureInfo originalCulture = Thread.CurrentThread.CurrentCulture;
try {
- Assert.IsFalse (string.IsNullOrEmpty (errorCode), "Error code is null or empty");
+ Assert.That (string.IsNullOrEmpty (errorCode), Is.False, "Error code is null or empty");
string? englishError = TranslateError ("en-US", errorCode);
string? newCultureError = TranslateError (culture, errorCode);
- Assert.AreNotEqual (englishError, newCultureError, $"\"{errorCode}\" is not translated in {culture}.");
+ Assert.That (newCultureError, Is.Not.EqualTo (englishError), $"\"{errorCode}\" is not translated in {culture}.");
} catch (NullReferenceException) {
Assert.Fail ($"Error code \"{errorCode}\" was not found");
} finally {
@@ -110,8 +110,8 @@ public void UpdatedResources ()
var errorsNotInResources = string.Join (" ", resxHashSet.Where (n => !resourceHashSet.Contains (n) && !ignoreList.Contains (n)));
var errorsNotInResx = string.Join (" ", resourceHashSet.Where (n => !resxHashSet.Contains (n) && !ignoreList.Contains (n)));
- Assert.IsEmpty (errorsNotInResources, $"The following error(s) were found in MSBStrings.resx but not through the MSBStrings resource. Try to recompile the msbuild project and then the test project\n{errorsNotInResources}");
- Assert.IsEmpty (errorsNotInResx, $"The following error(s) were found in the MSBStrings resource but not in MSBStrings.resx. Try to recompile the msbuild project and then the test project\n{errorsNotInResx}");
+ Assert.That (errorsNotInResources, Is.Empty, $"The following error(s) were found in MSBStrings.resx but not through the MSBStrings resource. Try to recompile the msbuild project and then the test project\n{errorsNotInResources}");
+ Assert.That (errorsNotInResx, Is.Empty, $"The following error(s) were found in the MSBStrings resource but not in MSBStrings.resx. Try to recompile the msbuild project and then the test project\n{errorsNotInResx}");
}
}
}
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/MergeAppBundleTaskTest.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/MergeAppBundleTaskTest.cs
index 29a8e9650f2b..309d9aa597f9 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/MergeAppBundleTaskTest.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/MergeAppBundleTaskTest.cs
@@ -102,13 +102,13 @@ public void TestLipoExecutable ()
ExecuteTask (task);
// The bundle should only contain a single file.
- Assert.AreEqual (1, Directory.GetFileSystemEntries (outputBundle).Length, "Files in bundle");
+ Assert.That (Directory.GetFileSystemEntries (outputBundle).Length, Is.EqualTo (1), "Files in bundle");
// The resulting dylib should contain 2 architectures.
var fatLibrary = Path.Combine (outputBundle, "libframework.dylib");
Assert.That (fatLibrary, Does.Exist, "Existence");
var machO = MachO.Read (fatLibrary).ToArray ();
- Assert.AreEqual (2, machO.Length, "Architecture Count");
+ Assert.That (machO.Length, Is.EqualTo (2), "Architecture Count");
}
[Test]
@@ -132,7 +132,7 @@ public void TestPEAssembly ()
ExecuteTask (task);
// The bundle should have all the files
- Assert.AreEqual (complexFiles.Length, Directory.GetFileSystemEntries (outputBundle).Length, "Files in bundle");
+ Assert.That (Directory.GetFileSystemEntries (outputBundle).Length, Is.EqualTo (complexFiles.Length), "Files in bundle");
// with the same structure
foreach (var file in complexFiles)
@@ -152,7 +152,7 @@ public void TestDifferentOtherFiles ()
var outputBundle = Path.Combine (Cache.CreateTemporaryDirectory (), "Merged.app");
var task = CreateTask (outputBundle, bundles);
ExecuteTask (task, 3);
- Assert.AreEqual ("Unable to merge the file 'Something.txt', it's different between the input app bundles.", Engine.Logger.ErrorEvents [0].Message, "Error message");
+ Assert.That (Engine.Logger.ErrorEvents [0].Message, Is.EqualTo ("Unable to merge the file 'Something.txt', it's different between the input app bundles."), "Error message");
Assert.That (Engine.Logger.ErrorEvents [1].Message, Does.Match ("App bundle file #1: .*/MergeMe.app/Something.txt"), "Error message 2");
Assert.That (Engine.Logger.ErrorEvents [2].Message, Does.Match ("App bundle file #2: .*/MergeMe.app/Something.txt"), "Error message 3");
}
@@ -170,14 +170,14 @@ public void TestSymlinks ()
File.WriteAllText (fileB, "A");
var linkA = Path.Combine (bundleA, "B.txt");
var linkB = Path.Combine (bundleB, "B.txt");
- Assert.IsTrue (PathUtils.Symlink ("A.txt", linkA), "Link A");
- Assert.IsTrue (PathUtils.Symlink ("A.txt", linkB), "Link B");
+ Assert.That (PathUtils.Symlink ("A.txt", linkA), Is.True, "Link A");
+ Assert.That (PathUtils.Symlink ("A.txt", linkB), Is.True, "Link B");
var outputBundle = Path.Combine (Cache.CreateTemporaryDirectory (), "Merged.app");
var task = CreateTask (outputBundle, bundleA, bundleB);
ExecuteTask (task);
- Assert.IsTrue (PathUtils.IsSymlink (Path.Combine (outputBundle, "B.txt")), "IsSymlink");
+ Assert.That (PathUtils.IsSymlink (Path.Combine (outputBundle, "B.txt")), Is.True, "IsSymlink");
}
[Test]
@@ -198,14 +198,14 @@ public void TestSymlinksWithDifferentTargets ()
// There's a symlink in both apps, but they have different targets.
var linkA = Path.Combine (bundleA, "B.txt");
var linkB = Path.Combine (bundleB, "B.txt");
- Assert.IsTrue (PathUtils.Symlink ("A.txt", linkA), "Link A");
- Assert.IsTrue (PathUtils.Symlink ("C.txt", linkB), "Link B");
+ Assert.That (PathUtils.Symlink ("A.txt", linkA), Is.True, "Link A");
+ Assert.That (PathUtils.Symlink ("C.txt", linkB), Is.True, "Link B");
var outputBundle = Path.Combine (Cache.CreateTemporaryDirectory (), "Merged.app");
var task = CreateTask (outputBundle, bundleA, bundleB);
ExecuteTask (task, 3);
- Assert.AreEqual ("Can't merge the symlink 'B.txt', it has different targets.", Engine.Logger.ErrorEvents [0].Message, "Error message");
+ Assert.That (Engine.Logger.ErrorEvents [0].Message, Is.EqualTo ("Can't merge the symlink 'B.txt', it has different targets."), "Error message");
Assert.That (Engine.Logger.ErrorEvents [1].Message, Does.Match ("App bundle file #1: .*/MergeMe.app/B.txt"), "Error message 2");
Assert.That (Engine.Logger.ErrorEvents [2].Message, Does.Match ("App bundle file #2: .*/MergeMe.app/B.txt"), "Error message 3");
}
@@ -248,7 +248,7 @@ public void TestDirectories ()
Assert.That (Path.Combine (outputBundle, nestedSharedOnlyB), Does.Exist, "nestedSharedOnlyB");
// Verify that there aren't any other directories
- Assert.AreEqual (7, Directory.GetFileSystemEntries (outputBundle).Length, "Directories in bundle");
+ Assert.That (Directory.GetFileSystemEntries (outputBundle).Length, Is.EqualTo (7), "Directories in bundle");
}
[Test]
@@ -262,13 +262,13 @@ public void TestSingleInput ()
ExecuteTask (task);
// The bundle should only contain a single file.
- Assert.AreEqual (1, Directory.GetFileSystemEntries (outputBundle).Length, "Files in bundle");
+ Assert.That (Directory.GetFileSystemEntries (outputBundle).Length, Is.EqualTo (1), "Files in bundle");
// The resulting dylib should contain 1 architecture.
var nonFatBinary = Path.Combine (outputBundle, "libframework.dylib");
Assert.That (nonFatBinary, Does.Exist, "Existence");
var machO = MachO.Read (nonFatBinary).ToArray ();
- Assert.AreEqual (1, machO.Length, "Architecture Count");
+ Assert.That (machO.Length, Is.EqualTo (1), "Architecture Count");
// and the file size should be the same as the input
Assert.That (new FileInfo (fileA).Length, Is.EqualTo (new FileInfo (nonFatBinary).Length), "File length");
@@ -287,15 +287,15 @@ public void TestDirectoriesAsSymlinks ()
File.WriteAllText (fileB, "A");
var linkA = Path.Combine (bundleA, "B");
var linkB = Path.Combine (bundleB, "B");
- Assert.IsTrue (PathUtils.Symlink ("A", linkA), "Link A");
- Assert.IsTrue (PathUtils.Symlink ("A", linkB), "Link B");
+ Assert.That (PathUtils.Symlink ("A", linkA), Is.True, "Link A");
+ Assert.That (PathUtils.Symlink ("A", linkB), Is.True, "Link B");
var outputBundle = Path.Combine (Cache.CreateTemporaryDirectory (), "Merged.app");
var task = CreateTask (outputBundle, bundleA, bundleB);
ExecuteTask (task);
- Assert.IsTrue (PathUtils.IsSymlink (Path.Combine (outputBundle, "B")), "IsSymlink");
- Assert.IsFalse (PathUtils.IsSymlink (Path.Combine (outputBundle, "A", "A.txt")), "IsSymlink");
- Assert.IsFalse (PathUtils.IsSymlink (Path.Combine (outputBundle, "B", "A.txt")), "IsSymlink");
+ Assert.That (PathUtils.IsSymlink (Path.Combine (outputBundle, "B")), Is.True, "IsSymlink");
+ Assert.That (PathUtils.IsSymlink (Path.Combine (outputBundle, "A", "A.txt")), Is.False, "IsSymlink");
+ Assert.That (PathUtils.IsSymlink (Path.Combine (outputBundle, "B", "A.txt")), Is.False, "IsSymlink");
}
}
}
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ParseBundlerArgumentsTests.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ParseBundlerArgumentsTests.cs
index feeeb720781f..bea30b23b970 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ParseBundlerArgumentsTests.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ParseBundlerArgumentsTests.cs
@@ -16,14 +16,14 @@ public void NoExtraArgs ()
{
var task = CreateTask ();
ExecuteTask (task);
- Assert.AreEqual ("false", task.NoSymbolStrip, "nosymbolstrip");
- Assert.AreEqual ("false", task.NoDSymUtil, "nodsymutil");
+ Assert.That (task.NoSymbolStrip, Is.EqualTo ("false"), "nosymbolstrip");
+ Assert.That (task.NoDSymUtil, Is.EqualTo ("false"), "nodsymutil");
task = CreateTask ();
task.ExtraArgs = string.Empty;
ExecuteTask (task);
- Assert.AreEqual ("false", task.NoSymbolStrip, "nosymbolstrip");
- Assert.AreEqual ("false", task.NoDSymUtil, "nodsymutil");
+ Assert.That (task.NoSymbolStrip, Is.EqualTo ("false"), "nosymbolstrip");
+ Assert.That (task.NoDSymUtil, Is.EqualTo ("false"), "nodsymutil");
}
[Test]
@@ -48,16 +48,16 @@ public void NoSymbolStrip ()
var task = CreateTask ();
task.ExtraArgs = variation;
ExecuteTask (task, message: "execute: " + variation);
- Assert.AreEqual ("false", task.NoSymbolStrip, "nosymbolstrip: " + variation);
- Assert.AreEqual ("false", task.NoDSymUtil, "nodsymutil: " + variation);
+ Assert.That (task.NoSymbolStrip, Is.EqualTo ("false"), "nosymbolstrip: " + variation);
+ Assert.That (task.NoDSymUtil, Is.EqualTo ("false"), "nodsymutil: " + variation);
}
foreach (var variation in true_variations) {
var task = CreateTask ();
task.ExtraArgs = variation;
ExecuteTask (task, message: "execute: " + variation);
- Assert.AreEqual ("true", task.NoSymbolStrip, "nosymbolstrip: " + variation);
- Assert.AreEqual ("false", task.NoDSymUtil, "nodsymutil: " + variation);
+ Assert.That (task.NoSymbolStrip, Is.EqualTo ("true"), "nosymbolstrip: " + variation);
+ Assert.That (task.NoDSymUtil, Is.EqualTo ("false"), "nodsymutil: " + variation);
}
}
@@ -86,16 +86,16 @@ public void NoDSymUtil ()
var task = CreateTask ();
task.ExtraArgs = variation;
ExecuteTask (task, message: "execute: " + variation);
- Assert.AreEqual ("false", task.NoSymbolStrip, "nosymbolstrip: " + variation);
- Assert.AreEqual ("false", task.NoDSymUtil, "nodsymutil: " + variation);
+ Assert.That (task.NoSymbolStrip, Is.EqualTo ("false"), "nosymbolstrip: " + variation);
+ Assert.That (task.NoDSymUtil, Is.EqualTo ("false"), "nodsymutil: " + variation);
}
foreach (var variation in true_variations) {
var task = CreateTask ();
task.ExtraArgs = variation;
ExecuteTask (task, message: "execute: " + variation);
- Assert.AreEqual ("false", task.NoSymbolStrip, "nosymbolstrip: " + variation);
- Assert.AreEqual ("true", task.NoDSymUtil, "nodsymutil: " + variation);
+ Assert.That (task.NoSymbolStrip, Is.EqualTo ("false"), "nosymbolstrip: " + variation);
+ Assert.That (task.NoDSymUtil, Is.EqualTo ("true"), "nodsymutil: " + variation);
}
}
@@ -117,7 +117,7 @@ public void MarshalManagedExceptionMode (string input, string output, string exi
task.MarshalManagedExceptionMode = existingValue;
task.ExtraArgs = input;
ExecuteTask (task, message: input);
- Assert.AreEqual (output, task.MarshalManagedExceptionMode, output);
+ Assert.That (task.MarshalManagedExceptionMode, Is.EqualTo (output), output);
}
[Test]
@@ -138,7 +138,7 @@ public void MarshalObjetiveCExceptionMode (string input, string output, string e
task.MarshalObjectiveCExceptionMode = existingValue;
task.ExtraArgs = input;
ExecuteTask (task, message: input);
- Assert.AreEqual (output, task.MarshalObjectiveCExceptionMode, output);
+ Assert.That (task.MarshalObjectiveCExceptionMode, Is.EqualTo (output), output);
}
[Test]
@@ -156,7 +156,7 @@ public void Optimize (string input, string output)
var task = CreateTask ();
task.ExtraArgs = input;
ExecuteTask (task, message: input);
- Assert.AreEqual (output, task.Optimize, output);
+ Assert.That (task.Optimize, Is.EqualTo (output), output);
}
[TestCase ("--registrar", "")]
@@ -172,7 +172,7 @@ public void Registrar (string input, string output)
var task = CreateTask ();
task.ExtraArgs = input;
ExecuteTask (task, message: input);
- Assert.AreEqual (output, task.Registrar, output);
+ Assert.That (task.Registrar, Is.EqualTo (output), output);
}
[TestCase ("--xml", null, "")]
@@ -198,7 +198,7 @@ void XmlDefinitionsTest (string input, string existing, string output)
task.XmlDefinitions = existing.Split (new char [] { ';' }, StringSplitOptions.RemoveEmptyEntries).Select (v => new TaskItem (v)).ToArray ();
task.ExtraArgs = input;
ExecuteTask (task, message: input);
- Assert.AreEqual (output, string.Join (";", task.XmlDefinitions.Select (v => v.ItemSpec).ToArray ()), output);
+ Assert.That (string.Join (";", task.XmlDefinitions.Select (v => v.ItemSpec).ToArray ()), Is.EqualTo (output), output);
}
[TestCase ("/xml:\\path\\a /xml:/path/b", null, "/path/a;/path/b")]
@@ -219,7 +219,7 @@ public void CustomBundleName (string input, string output)
var task = CreateTask ();
task.ExtraArgs = input;
ExecuteTask (task, message: input);
- Assert.AreEqual (output, task.CustomBundleName, output);
+ Assert.That (task.CustomBundleName, Is.EqualTo (output), output);
}
[TestCase ("--gcc_flags -dead_strip", new string [] { "-dead_strip" })]
@@ -236,7 +236,7 @@ public void CustomLinkFlags (string input, string [] output)
var task = CreateTask ();
task.ExtraArgs = input;
ExecuteTask (task, message: input);
- CollectionAssert.AreEquivalent (output, task.CustomLinkFlags.Select (v => v.ItemSpec).ToArray (), string.Join (" ", output));
+ Assert.That (task.CustomLinkFlags.Select (v => v.ItemSpec).ToArray (), Is.EquivalentTo (output), string.Join (" ", output));
}
[TestCase ("-v", "1")]
@@ -250,7 +250,7 @@ public void Verbosity (string input, string output)
var task = CreateTask ();
task.ExtraArgs = input;
ExecuteTask (task, message: input);
- Assert.AreEqual (output, task.Verbosity, "Equality");
+ Assert.That (task.Verbosity, Is.EqualTo (output), "Equality");
}
[TestCase ("--nowarn", "-1")]
@@ -264,7 +264,7 @@ public void NoWarn (string input, string output)
var task = CreateTask ();
task.ExtraArgs = input;
ExecuteTask (task, message: input);
- Assert.AreEqual (output, task.NoWarn, output);
+ Assert.That (task.NoWarn, Is.EqualTo (output), output);
}
[TestCase ("--warnaserror", "-1")]
@@ -278,7 +278,7 @@ public void WarnAsError (string input, string output)
var task = CreateTask ();
task.ExtraArgs = input;
ExecuteTask (task, message: input);
- Assert.AreEqual (output, task.WarnAsError, output);
+ Assert.That (task.WarnAsError, Is.EqualTo (output), output);
}
}
}
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/PropertyListEditorTaskTests.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/PropertyListEditorTaskTests.cs
index 120a3b6d6838..b91585a23bf7 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/PropertyListEditorTaskTests.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/PropertyListEditorTaskTests.cs
@@ -11,10 +11,10 @@ namespace Xamarin.MacDev.Tasks {
public class PropertyListEditorTaskTests : TestBase {
static void CheckArray (PArray array, PArray expected)
{
- Assert.AreEqual (expected.Count, array.Count, "Unexpected number of array elements");
+ Assert.That (array.Count, Is.EqualTo (expected.Count), "Unexpected number of array elements");
for (int i = 0; i < expected.Count; i++) {
- Assert.AreEqual (expected [i].Type, array [i].Type, "Type-mismatch for array element {0}", i);
+ Assert.That (array [i].Type, Is.EqualTo (expected [i].Type), $"Type-mismatch for array element {i}");
CheckValue (array [i], expected [i]);
}
}
@@ -22,10 +22,10 @@ static void CheckArray (PArray array, PArray expected)
static void CheckDictionary (PDictionary dict, PDictionary expected)
{
foreach (var kvp in expected) {
- Assert.IsTrue (dict.TryGetValue (kvp.Key, out PObject? value), "Expected key '{0}'", kvp.Key);
+ Assert.That (dict.TryGetValue (kvp.Key, out PObject? value), Is.True, $"Expected key '{kvp.Key}'");
if (value is null)
continue;
- Assert.AreEqual (kvp.Value.Type, value.Type, "Type-mismatch for '{0}'", kvp.Key);
+ Assert.That (value.Type, Is.EqualTo (kvp.Value.Type), $"Type-mismatch for '{kvp.Key}'");
CheckValue (value, kvp.Value);
}
@@ -45,22 +45,22 @@ static void CheckValue (PObject value, PObject expected)
CheckArray ((PArray) value, (PArray) expected);
break;
case PObjectType.Real:
- Assert.AreEqual (((PReal) expected).Value, ((PReal) value).Value);
+ Assert.That (((PReal) value).Value, Is.EqualTo (((PReal) expected).Value));
break;
case PObjectType.Number:
- Assert.AreEqual (((PNumber) expected).Value, ((PNumber) value).Value);
+ Assert.That (((PNumber) value).Value, Is.EqualTo (((PNumber) expected).Value));
break;
case PObjectType.Boolean:
- Assert.AreEqual (((PBoolean) expected).Value, ((PBoolean) value).Value);
+ Assert.That (((PBoolean) value).Value, Is.EqualTo (((PBoolean) expected).Value));
break;
case PObjectType.Data:
// TODO: implement this
break;
case PObjectType.String:
- Assert.AreEqual (((PString) expected).Value, ((PString) value).Value);
+ Assert.That (((PString) value).Value, Is.EqualTo (((PString) expected).Value));
break;
case PObjectType.Date:
- Assert.AreEqual (((PDate) expected).Value, ((PDate) value).Value);
+ Assert.That (((PDate) value).Value, Is.EqualTo (((PDate) expected).Value));
break;
}
}
@@ -90,7 +90,7 @@ void TestExecuteTask (string propertyList, PropertyListEditorAction action, stri
var output = PObject.FromFile (task.PropertyList) ?? throw new InvalidOperationException ("PObject.FromFile returned null");
- Assert.AreEqual (expected.Type, output.Type, "Task produced the incorrect plist output.");
+ Assert.That (output.Type, Is.EqualTo (expected.Type), "Task produced the incorrect plist output.");
CheckValue (output, expected);
}
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ReadAppManifestTaskTests.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ReadAppManifestTaskTests.cs
index 1e5a9546e502..813da25c467e 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ReadAppManifestTaskTests.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ReadAppManifestTaskTests.cs
@@ -35,7 +35,7 @@ public void MacCatalystVersionConversion ()
plist.SetMinimumSystemVersion ("10.15.2");
});
ExecuteTask (task);
- Assert.AreEqual ("13.3", task.MinimumOSVersion, "MinimumOSVersion");
+ Assert.That (task.MinimumOSVersion, Is.EqualTo ("13.3"), "MinimumOSVersion");
}
[Test]
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ResolveNativeReferencesTaskTest.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ResolveNativeReferencesTaskTest.cs
index ec39d36da20e..c53c09d87877 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ResolveNativeReferencesTaskTest.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TaskTests/ResolveNativeReferencesTaskTest.cs
@@ -38,7 +38,7 @@ public void Xcode12_x (string targetFrameworkMoniker, bool isSimulator, string a
var path = Path.Combine (Path.GetDirectoryName (GetType ().Assembly.Location)!, "Resources", "xcf-xcode12.2.plist");
var plist = PDictionary.FromFile (path)!;
var result = ResolveNativeReferences.TryResolveXCFramework (log, plist, "N/A", targetFrameworkMoniker, isSimulator, architecture, null, out var frameworkPath);
- Assert.AreEqual (result, !string.IsNullOrEmpty (expected), "result");
+ Assert.That (!string.IsNullOrEmpty (expected), Is.EqualTo (result), "result");
Assert.That (frameworkPath, Is.EqualTo (expected), "frameworkPath");
}
@@ -48,7 +48,7 @@ public void PreXcode12 (string targetFrameworkMoniker, bool isSimulator, string
var path = Path.Combine (Path.GetDirectoryName (GetType ().Assembly.Location)!, "Resources", "xcf-prexcode12.plist");
var plist = PDictionary.FromFile (path)!;
var result = ResolveNativeReferences.TryResolveXCFramework (log, plist, "N/A", targetFrameworkMoniker, isSimulator, architecture, null, out var frameworkPath);
- Assert.AreEqual (result, !string.IsNullOrEmpty (expected), "result");
+ Assert.That (!string.IsNullOrEmpty (expected), Is.EqualTo (result), "result");
Assert.That (frameworkPath, Is.EqualTo (expected), "frameworkPath");
}
@@ -57,7 +57,7 @@ public void BadInfoPlist ()
{
var plist = new PDictionary ();
var result = ResolveNativeReferences.TryResolveXCFramework (log, plist, "N/A", TargetFramework.DotNet_iOS_String, false, "x86_64", null, out var frameworkPath);
- Assert.IsFalse (result, "Invalid Info.plist");
+ Assert.That (result, Is.False, "Invalid Info.plist");
}
}
}
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TestHelpers/TestBase.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TestHelpers/TestBase.cs
index 93371c0fd435..05b391b10fbf 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TestHelpers/TestBase.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/TestHelpers/TestBase.cs
@@ -73,9 +73,9 @@ public void ExecuteTask (Task task, int expectedErrorCount = 0, string message =
messages = "\n\t" + string.Join ("\n\t", allEvents.Select ((v) => v.AsString ()).ToArray ());
}
if (expectedErrorCount != Engine.Logger.ErrorEvents.Count) {
- Assert.AreEqual (expectedErrorCount, Engine.Logger.ErrorEvents.Count, $"#RunTask-ErrorCount{(string.IsNullOrEmpty (message) ? "" : $" ({message})")}" + messages);
+ Assert.That (Engine.Logger.ErrorEvents.Count, Is.EqualTo (expectedErrorCount), $"#RunTask-ErrorCount{(string.IsNullOrEmpty (message) ? "" : $" ({message})")}" + messages);
}
- Assert.AreEqual (expectedErrorCount == 0, rv, $"Failure{(string.IsNullOrEmpty (message) ? "" : $" ({message})")}" + messages);
+ Assert.That (rv, Is.EqualTo (expectedErrorCount == 0), $"Failure{(string.IsNullOrEmpty (message) ? "" : $" ({message})")}" + messages);
}
protected string CreateTempFile (string path)
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/UtilityTests.cs b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/UtilityTests.cs
index f057607731db..4dfc91c8446b 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/UtilityTests.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/UtilityTests.cs
@@ -19,7 +19,7 @@ public void TestAbsoluteToRelativePath ()
string rpath;
rpath = PathUtils.AbsoluteToRelative ("/Users/user/source/Project", "/Users/user/Source/Project/Info.plist");
- Assert.AreEqual ("Info.plist", rpath, "#1");
+ Assert.That (rpath, Is.EqualTo ("Info.plist"), "#1");
}
}
}
diff --git a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/Xamarin.MacDev.Tasks.Tests.csproj b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/Xamarin.MacDev.Tasks.Tests.csproj
index dc2e2f8e0aa2..bbd8daba35b8 100644
--- a/tests/msbuild/Xamarin.MacDev.Tasks.Tests/Xamarin.MacDev.Tasks.Tests.csproj
+++ b/tests/msbuild/Xamarin.MacDev.Tasks.Tests/Xamarin.MacDev.Tasks.Tests.csproj
@@ -37,9 +37,9 @@
-
-
-
+
+
+
diff --git a/tests/msbuild/Xamarin.MacDev.Tests/TargetTests/CollectAppManifestsTests.cs b/tests/msbuild/Xamarin.MacDev.Tests/TargetTests/CollectAppManifestsTests.cs
index 300230c060e4..953cfde67f47 100644
--- a/tests/msbuild/Xamarin.MacDev.Tests/TargetTests/CollectAppManifestsTests.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tests/TargetTests/CollectAppManifestsTests.cs
@@ -65,14 +65,14 @@ public void PartialAppManifest ()
{ "_CreateAppManifest", "true" },
};
var rv = engine.RunTarget (ApplePlatform.MacOSX, csprojPath, target: "_WriteAppManifest", properties: properties);
- Assert.AreEqual (0, rv.ExitCode, "Exit code");
+ Assert.That (rv.ExitCode, Is.EqualTo (0), "Exit code");
var appManifestPath = Path.Combine (tmpdir, "bin", "Debug", Configuration.DotNetTfm + "-macos", "osx-x64", "PartialAppManifest.app", "Contents", "Info.plist");
Assert.That (appManifestPath, Does.Exist, "App manifest existence");
var plist = PDictionary.FromFile (appManifestPath);
- Assert.AreEqual ("PartialAppManifestDisplayName", plist.GetCFBundleDisplayName (), "Bundle display name");
- Assert.AreEqual ("com.xamarin.partialappmanifest", plist.GetCFBundleIdentifier (), "Bundle identifier");
+ Assert.That (plist.GetCFBundleDisplayName (), Is.EqualTo ("PartialAppManifestDisplayName"), "Bundle display name");
+ Assert.That (plist.GetCFBundleIdentifier (), Is.EqualTo ("com.xamarin.partialappmanifest"), "Bundle identifier");
}
}
}
diff --git a/tests/msbuild/Xamarin.MacDev.Tests/TargetTests/DetectSigningIdentityTests.cs b/tests/msbuild/Xamarin.MacDev.Tests/TargetTests/DetectSigningIdentityTests.cs
index 92e257e81b9e..f9e4383a7f83 100644
--- a/tests/msbuild/Xamarin.MacDev.Tests/TargetTests/DetectSigningIdentityTests.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tests/TargetTests/DetectSigningIdentityTests.cs
@@ -59,7 +59,7 @@ public void BundleIdentifierInPartialAppManifest ()
{ "_CanOutputAppBundle", "true" },
};
var rv = engine.RunTarget (ApplePlatform.MacOSX, csprojPath, target: "_DetectSigningIdentity", properties: properties);
- Assert.AreEqual (0, rv.ExitCode, "Exit code");
+ Assert.That (rv.ExitCode, Is.EqualTo (0), "Exit code");
// Find the BundleIdentifier parameter to the DetectSigningIdentity task.
var recordArgs = BinLog.ReadBuildEvents (rv.BinLogPath).ToList ();
@@ -85,7 +85,7 @@ public void BundleIdentifierInPartialAppManifest ()
} else {
bundleIdentifier = "Unhandled task message format.";
}
- Assert.AreEqual ("com.xamarin.detectsigningidentitytest", bundleIdentifier, "Bundle identifier");
+ Assert.That (bundleIdentifier, Is.EqualTo ("com.xamarin.detectsigningidentitytest"), "Bundle identifier");
}
}
}
diff --git a/tests/msbuild/Xamarin.MacDev.Tests/TargetTests/TargetTests.cs b/tests/msbuild/Xamarin.MacDev.Tests/TargetTests/TargetTests.cs
index 5d7261bcd7e3..6e31147643ed 100644
--- a/tests/msbuild/Xamarin.MacDev.Tests/TargetTests/TargetTests.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tests/TargetTests/TargetTests.cs
@@ -25,14 +25,14 @@ public void CleanExecutable ()
// .NET: we don't have a test that verifies that the Clean target works as expected, this needs to be added before we can remove this test.
RunTarget (MonoTouchProject, TargetName.Clean);
- Assert.IsFalse (Directory.Exists (MonoTouchProjectBinPath), "#1a");
- Assert.IsFalse (Directory.Exists (MonoTouchProjectObjPath), "#1b");
+ Assert.That (Directory.Exists (MonoTouchProjectBinPath), Is.False, "#1a");
+ Assert.That (Directory.Exists (MonoTouchProjectObjPath), Is.False, "#1b");
RunTarget (MonoTouchProject, TargetName.Build);
RunTarget (MonoTouchProject, TargetName.Clean);
- Assert.IsEmpty (Directory.GetDirectories (MonoTouchProjectBinPath, "*.dSYM", SearchOption.AllDirectories), "#2a");
- Assert.IsEmpty (Directory.GetFiles (MonoTouchProjectBinPath, "*.*", SearchOption.AllDirectories), "#2b");
- Assert.IsFalse (Directory.Exists (MonoTouchProjectObjPath), "#2c");
+ Assert.That (Directory.GetDirectories (MonoTouchProjectBinPath, "*.dSYM", SearchOption.AllDirectories), Is.Empty, "#2a");
+ Assert.That (Directory.GetFiles (MonoTouchProjectBinPath, "*.*", SearchOption.AllDirectories), Is.Empty, "#2b");
+ Assert.That (Directory.Exists (MonoTouchProjectObjPath), Is.False, "#2c");
}
[Test]
@@ -43,13 +43,13 @@ public void CleanLibrary ()
// .NET: we don't have a test that verifies that the Clean target works as expected, this needs to be added before we can remove this test.
RunTarget (LibraryProject, TargetName.Clean);
- Assert.IsFalse (Directory.Exists (LibraryProjectBinPath), "#1a");
- Assert.IsFalse (Directory.Exists (LibraryProjectObjPath), "#1b");
+ Assert.That (Directory.Exists (LibraryProjectBinPath), Is.False, "#1a");
+ Assert.That (Directory.Exists (LibraryProjectObjPath), Is.False, "#1b");
RunTarget (LibraryProject, TargetName.Build);
RunTarget (LibraryProject, TargetName.Clean);
- Assert.IsEmpty (Directory.GetFiles (LibraryProjectBinPath, "*.*", SearchOption.AllDirectories), "#2a");
- Assert.IsFalse (Directory.Exists (LibraryProjectObjPath), "#2b");
+ Assert.That (Directory.GetFiles (LibraryProjectBinPath, "*.*", SearchOption.AllDirectories), Is.Empty, "#2a");
+ Assert.That (Directory.Exists (LibraryProjectObjPath), Is.False, "#2b");
}
[Test]
@@ -87,11 +87,11 @@ void OptimizePngs_Core (bool shouldBeDifferent)
RunTarget (MonoTouchProject, TargetName.Build);
- Assert.IsTrue (File.Exists (optimisedFile), "#1");
+ Assert.That (File.Exists (optimisedFile), Is.True, "#1");
if (shouldBeDifferent)
- CollectionAssert.AreNotEqual (File.ReadAllBytes (originalFile), File.ReadAllBytes (optimisedFile), "#2a");
+ Assert.That (File.ReadAllBytes (optimisedFile), Is.Not.EqualTo (File.ReadAllBytes (originalFile)), "#2a");
else
- CollectionAssert.AreEqual (File.ReadAllBytes (originalFile), File.ReadAllBytes (optimisedFile), "#2b");
+ Assert.That (File.ReadAllBytes (optimisedFile), Is.EqualTo (File.ReadAllBytes (originalFile)), "#2b");
}
}
}
diff --git a/tests/msbuild/Xamarin.MacDev.Tests/TestHelpers/TestBase.cs b/tests/msbuild/Xamarin.MacDev.Tests/TestHelpers/TestBase.cs
index 10d689c6ab71..b00511b546c3 100644
--- a/tests/msbuild/Xamarin.MacDev.Tests/TestHelpers/TestBase.cs
+++ b/tests/msbuild/Xamarin.MacDev.Tests/TestHelpers/TestBase.cs
@@ -119,13 +119,13 @@ public bool IsTVOS {
public void TestFilesDoNotExist (string baseDir, IEnumerable files)
{
foreach (var v in files.Select (s => Path.Combine (baseDir, s)))
- Assert.IsFalse (File.Exists (v) || Directory.Exists (v), "Unexpected file: {0} exists", v);
+ Assert.That (File.Exists (v) || Directory.Exists (v), Is.False, $"Unexpected file: {v} exists");
}
public void TestFilesExists (string baseDir, string [] files)
{
foreach (var v in files.Select (s => Path.Combine (baseDir, s)))
- Assert.IsTrue (File.Exists (v) || Directory.Exists (v), "Expected file: {0} does not exist", v);
+ Assert.That (File.Exists (v) || Directory.Exists (v), Is.True, $"Expected file: {v} does not exist");
}
public void TestFilesExists (string [] baseDirs, string [] files)
@@ -134,14 +134,14 @@ public void TestFilesExists (string [] baseDirs, string [] files)
TestFilesExists (baseDirs [0], files);
} else {
foreach (var file in files)
- Assert.IsTrue (baseDirs.Select (s => File.Exists (Path.Combine (s, file))).Any (v => v), $"Expected file: {file} does not exist in any of the directories: {string.Join (", ", baseDirs)}");
+ Assert.That (baseDirs.Select (s => File.Exists (Path.Combine (s, file))).Any (v => v), Is.True, $"Expected file: {file} does not exist in any of the directories: {string.Join (", ", baseDirs)}");
}
}
public void TestStoryboardC (string path)
{
- Assert.IsTrue (Directory.Exists (path), "Storyboard {0} does not exist", path);
- Assert.IsTrue (File.Exists (Path.Combine (path, "Info.plist")));
+ Assert.That (Directory.Exists (path), Is.True, $"Storyboard {path} does not exist");
+ Assert.That (File.Exists (Path.Combine (path, "Info.plist")), Is.True);
TestPList (path, new string [] { "CFBundleVersion", "CFBundleExecutable" });
}
@@ -149,15 +149,15 @@ public void TestPList (string path, string [] keys)
{
var plist = PDictionary.FromFile (Path.Combine (path, "Info.plist"));
if (plist is null) {
- Assert.Fail ("Could not load Info.plist from {0}", path);
+ Assert.Fail ($"Could not load Info.plist from {path}");
return;
}
foreach (var x in keys) {
- Assert.IsTrue (plist.ContainsKey (x), "Key {0} is not present in {1} Info.plist", x, path);
+ Assert.That (plist.ContainsKey (x), Is.True, $"Key {x} is not present in {path} Info.plist");
if (plist [x] is PString pstring)
- Assert.IsNotEmpty (pstring.Value, "Key {0} is empty in {1} Info.plist", x, path);
+ Assert.That (pstring.Value, Is.Not.Empty, $"Key {x} is empty in {path} Info.plist");
else
- Assert.Fail ("Key {0} is not a PString in {1} Info.plist", x, path);
+ Assert.Fail ($"Key {x} is not a PString in {path} Info.plist");
}
}
@@ -175,7 +175,7 @@ protected DateTime GetLastModified (string file)
file = Path.Combine (file, "runtime.nib");
if (!File.Exists (file))
- Assert.Fail ("Expected file '{0}' did not exist", file);
+ Assert.Fail ($"Expected file '{file}' did not exist");
return File.GetLastWriteTimeUtc (file);
}
@@ -183,7 +183,7 @@ protected DateTime GetLastModified (string file)
protected void Touch (string file)
{
if (!File.Exists (file))
- Assert.Fail ("Expected file '{0}' did not exist", file);
+ Assert.Fail ($"Expected file '{file}' did not exist");
EnsureFilestampChange ();
File.SetLastWriteTimeUtc (file, DateTime.UtcNow);
EnsureFilestampChange ();
@@ -217,12 +217,12 @@ public void RunTarget (ProjectPaths paths, string target, int expectedErrorCount
if (expectedErrorCount != Engine.ErrorEvents.Count) {
foreach (var e in Engine.ErrorEvents)
Console.WriteLine (e.ToString ());
- Assert.AreEqual (expectedErrorCount, Engine.ErrorEvents.Count, $"Unexpected number of errors when executing target '{target}'");
+ Assert.That (Engine.ErrorEvents.Count, Is.EqualTo (expectedErrorCount), $"Unexpected number of errors when executing target '{target}'");
}
if (expectedErrorCount > 0) {
- Assert.AreEqual (1, rv.ExitCode, "ExitCode (failure)");
+ Assert.That (rv.ExitCode, Is.EqualTo (1), "ExitCode (failure)");
} else {
- Assert.AreEqual (0, rv.ExitCode, "ExitCode (success)");
+ Assert.That (rv.ExitCode, Is.EqualTo (0), "ExitCode (success)");
}
}
diff --git a/tests/msbuild/Xamarin.MacDev.Tests/Xamarin.MacDev.Tests.csproj b/tests/msbuild/Xamarin.MacDev.Tests/Xamarin.MacDev.Tests.csproj
index 116834eab6cc..acf08ef3a59e 100644
--- a/tests/msbuild/Xamarin.MacDev.Tests/Xamarin.MacDev.Tests.csproj
+++ b/tests/msbuild/Xamarin.MacDev.Tests/Xamarin.MacDev.Tests.csproj
@@ -8,9 +8,9 @@
../../../product.snk
-
-
-
+
+
+
From 66ef21c14ef997b337570fd50588f563c68e06c9 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Mon, 18 May 2026 13:55:51 +0200
Subject: [PATCH 061/156] [ObjCRuntime] Improve super calls - Fixes #25362
(#25376)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
## Summary
Introduces a stack-allocated `ObjCSuper` struct to replace the use of `NSObject.SuperHandle` for `objc_msgSendSuper` calls. This eliminates the need to allocate and manage unmanaged memory for the `objc_super` struct on every super call.
## Changes
- **New `ObjCSuper` readonly ref struct** (`src/ObjCRuntime/ObjCSuper.cs`): A `[StructLayout(LayoutKind.Sequential)]` struct with `Receiver` and `ClassHandle` fields matching the native `objc_super` layout.
- **Updated bgen code generation**: P/Invoke declarations for `objc_msgSendSuper` variants now take `ObjCSuper*` instead of `IntPtr` as the first parameter. Generated call sites create a stack-allocated `ObjCSuper` and pass `&__objc_super__` instead of `this.SuperHandle`.
- **Updated handwritten super calls** in 11 source files (CIFilter, CIVector, CALayer, UIPasteboard, NSInputStream, NSUuid, NSThread, NSHttpCookie, GCMouse, NSOpenGLPixelFormat, NSBitmapImageRep) plus NSObject2.cs.
- `NSObject.SuperHandle` is preserved for backward compatibility (can be simplified/removed in XAMCORE_5_0).
Fixes https://github.com/dotnet/macios/issues/25362
🤖 Pull request created by Copilot
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
src/AppKit/NSBitmapImageRep.cs | 6 +-
src/AppKit/NSOpenGLPixelFormat.cs | 8 +-
src/CoreAnimation/CALayer.cs | 7 +-
src/CoreImage/CIFilter.cs | 17 ++++-
src/CoreImage/CIVector.cs | 6 +-
src/Foundation/NSHttpCookie.cs | 6 +-
src/Foundation/NSInputStream.cs | 9 ++-
src/Foundation/NSObject2.cs | 24 ++++--
src/Foundation/NSThread.cs | 11 ++-
src/Foundation/NSUuid.cs | 4 +-
src/GameController/GCMouse.cs | 14 +++-
src/ObjCRuntime/ObjCSuper.cs | 45 +++++++++++
src/UIKit/UIPasteboard.cs | 12 ++-
src/bgen/Filters.cs | 8 +-
src/bgen/Generator.cs | 74 ++++++++++++++-----
src/frameworks.sources | 1 +
tests/bgen/ProtocolTests.cs | 24 +++---
.../tests/ExpectedXmlDocs.MacCatalyst.xml | 30 ++++++--
tests/bgen/tests/ExpectedXmlDocs.iOS.xml | 36 +++++++--
tests/bgen/tests/ExpectedXmlDocs.macOS.xml | 30 ++++++--
tests/bgen/tests/ExpectedXmlDocs.tvOS.xml | 30 ++++++--
...alyst-MonoVM-interpreter-preservedapis.txt | 31 ++++----
.../MacCatalyst-MonoVM-interpreter-size.txt | 6 +-
.../MacCatalyst-MonoVM-preservedapis.txt | 17 +++--
.../expected/MacCatalyst-MonoVM-size.txt | 8 +-
...atalyst-NativeAOT-TrimmableStatic-size.txt | 6 +-
.../expected/MacCatalyst-NativeAOT-size.txt | 4 +-
...reCLR-Interpreter-TrimmableStatic-size.txt | 10 +--
.../MacOSX-CoreCLR-Interpreter-size.txt | 10 +--
.../MacOSX-NativeAOT-TrimmableStatic-size.txt | 6 +-
.../expected/MacOSX-NativeAOT-size.txt | 6 +-
.../TVOS-MonoVM-interpreter-preservedapis.txt | 31 ++++----
.../expected/TVOS-MonoVM-interpreter-size.txt | 6 +-
.../expected/TVOS-MonoVM-preservedapis.txt | 17 +++--
.../UnitTests/expected/TVOS-MonoVM-size.txt | 8 +-
.../TVOS-NativeAOT-TrimmableStatic-size.txt | 6 +-
.../expected/TVOS-NativeAOT-size.txt | 4 +-
.../iOS-MonoVM-interpreter-preservedapis.txt | 31 ++++----
.../expected/iOS-MonoVM-interpreter-size.txt | 6 +-
.../expected/iOS-MonoVM-preservedapis.txt | 17 +++--
.../UnitTests/expected/iOS-MonoVM-size.txt | 6 +-
.../iOS-NativeAOT-TrimmableStatic-size.txt | 6 +-
.../UnitTests/expected/iOS-NativeAOT-size.txt | 4 +-
43 files changed, 450 insertions(+), 198 deletions(-)
create mode 100644 src/ObjCRuntime/ObjCSuper.cs
diff --git a/src/AppKit/NSBitmapImageRep.cs b/src/AppKit/NSBitmapImageRep.cs
index 7da4bef511a9..3fdc05555bab 100644
--- a/src/AppKit/NSBitmapImageRep.cs
+++ b/src/AppKit/NSBitmapImageRep.cs
@@ -39,7 +39,11 @@ private NSBitmapImageRep (NSObjectFlag a, NSObjectFlag b) : base (a)
if (IsDirectBinding) {
InitializeHandle (ObjCRuntime.Messaging.IntPtr_objc_msgSend (this.Handle, Selector.GetHandle (selInitForIncrementalLoad)), selInitForIncrementalLoad);
} else {
- InitializeHandle (ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper (this.SuperHandle, Selector.GetHandle (selInitForIncrementalLoad)), selInitForIncrementalLoad);
+ unsafe {
+ var __objc_super__ = new global::ObjCRuntime.ObjCSuper (this);
+ InitializeHandle (ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper (&__objc_super__, Selector.GetHandle (selInitForIncrementalLoad)), selInitForIncrementalLoad);
+ GC.KeepAlive (this);
+ }
}
}
diff --git a/src/AppKit/NSOpenGLPixelFormat.cs b/src/AppKit/NSOpenGLPixelFormat.cs
index 86899dc34e16..e873cddce3a6 100644
--- a/src/AppKit/NSOpenGLPixelFormat.cs
+++ b/src/AppKit/NSOpenGLPixelFormat.cs
@@ -50,7 +50,9 @@ public NSOpenGLPixelFormat (NSOpenGLPixelFormatAttribute [] attribs)
if (IsDirectBinding) {
InitializeHandle (ObjCRuntime.Messaging.IntPtr_objc_msgSend_IntPtr (this.Handle, selInitWithAttributes, new IntPtr ((void*) pArray)), "initWithAttributes:");
} else {
- InitializeHandle (ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_IntPtr (this.SuperHandle, selInitWithAttributes, new IntPtr ((void*) pArray)), "initWithAttributes:");
+ var __objc_super__ = new global::ObjCRuntime.ObjCSuper (this);
+ InitializeHandle (ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_IntPtr (&__objc_super__, selInitWithAttributes, new IntPtr ((void*) pArray)), "initWithAttributes:");
+ GC.KeepAlive (this);
}
}
@@ -73,7 +75,9 @@ public NSOpenGLPixelFormat (uint [] attribs)
if (IsDirectBinding) {
InitializeHandle (ObjCRuntime.Messaging.IntPtr_objc_msgSend_IntPtr (this.Handle, selInitWithAttributes, new IntPtr ((void*) pArray)), "initWithAttributes:");
} else {
- InitializeHandle (ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_IntPtr (this.SuperHandle, selInitWithAttributes, new IntPtr ((void*) pArray)), "initWithAttributes:");
+ var __objc_super__ = new global::ObjCRuntime.ObjCSuper (this);
+ InitializeHandle (ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_IntPtr (&__objc_super__, selInitWithAttributes, new IntPtr ((void*) pArray)), "initWithAttributes:");
+ GC.KeepAlive (this);
}
}
diff --git a/src/CoreAnimation/CALayer.cs b/src/CoreAnimation/CALayer.cs
index 8af4b7110e68..8df9a5041ab3 100644
--- a/src/CoreAnimation/CALayer.cs
+++ b/src/CoreAnimation/CALayer.cs
@@ -54,7 +54,12 @@ public CALayer (CALayer other)
Messaging.IntPtr_objc_msgSend_IntPtr (Handle, Selector.GetHandle (selInitWithLayer), other.Handle);
GC.KeepAlive (other);
} else {
- Messaging.IntPtr_objc_msgSendSuper_IntPtr (SuperHandle, Selector.GetHandle (selInitWithLayer), other.Handle);
+ unsafe {
+ var __objc_super__ = new global::ObjCRuntime.ObjCSuper (this);
+ Messaging.IntPtr_objc_msgSendSuper_IntPtr (&__objc_super__, Selector.GetHandle (selInitWithLayer), other.Handle);
+ GC.KeepAlive (this);
+ GC.KeepAlive (other);
+ }
Clone (other);
}
MarkDirtyIfDerived ();
diff --git a/src/CoreImage/CIFilter.cs b/src/CoreImage/CIFilter.cs
index 6441ce736d2c..ee0f450c60d2 100644
--- a/src/CoreImage/CIFilter.cs
+++ b/src/CoreImage/CIFilter.cs
@@ -270,8 +270,12 @@ internal void SetHandle (string key, IntPtr handle)
Messaging.void_objc_msgSend_IntPtr_IntPtr (
this.Handle, Selector.GetHandle ("setValue:forKey:"), handle, nsname);
} else {
- Messaging.void_objc_msgSendSuper_IntPtr_IntPtr (
- this.SuperHandle, Selector.GetHandle ("setValue:forKey:"), handle, nsname);
+ unsafe {
+ var __objc_super__ = new global::ObjCRuntime.ObjCSuper (this);
+ Messaging.void_objc_msgSendSuper_IntPtr_IntPtr (
+ &__objc_super__, Selector.GetHandle ("setValue:forKey:"), handle, nsname);
+ GC.KeepAlive (this);
+ }
}
CFString.ReleaseNative (nsname);
}
@@ -283,8 +287,13 @@ internal IntPtr GetHandle (string key)
if (IsDirectBinding)
ret = Messaging.IntPtr_objc_msgSend_IntPtr (Handle, Selector.GetHandle ("valueForKey:"), nsname);
- else
- ret = Messaging.IntPtr_objc_msgSendSuper_IntPtr (SuperHandle, Selector.GetHandle ("valueForKey:"), nsname);
+ else {
+ unsafe {
+ var __objc_super__ = new global::ObjCRuntime.ObjCSuper (this);
+ ret = Messaging.IntPtr_objc_msgSendSuper_IntPtr (&__objc_super__, Selector.GetHandle ("valueForKey:"), nsname);
+ GC.KeepAlive (this);
+ }
+ }
CFString.ReleaseNative (nsname);
return ret;
diff --git a/src/CoreImage/CIVector.cs b/src/CoreImage/CIVector.cs
index 8270b1ecb85b..86ff2f54a7d3 100644
--- a/src/CoreImage/CIVector.cs
+++ b/src/CoreImage/CIVector.cs
@@ -63,7 +63,11 @@ public unsafe CIVector (nfloat [] values, nint count) : base (NSObjectFlag.Empty
if (IsDirectBinding) {
handle = Messaging.IntPtr_objc_msgSend_IntPtr_IntPtr (Handle, Selector.GetHandle ("initWithValues:count:"), (IntPtr) ptr, (IntPtr) count);
} else {
- handle = Messaging.IntPtr_objc_msgSendSuper_IntPtr_IntPtr (SuperHandle, Selector.GetHandle ("initWithValues:count:"), (IntPtr) ptr, (IntPtr) count);
+ unsafe {
+ var __objc_super__ = new global::ObjCRuntime.ObjCSuper (this);
+ handle = Messaging.IntPtr_objc_msgSendSuper_IntPtr_IntPtr (&__objc_super__, Selector.GetHandle ("initWithValues:count:"), (IntPtr) ptr, (IntPtr) count);
+ GC.KeepAlive (this);
+ }
}
InitializeHandle (handle, "initWithValues:count:");
}
diff --git a/src/Foundation/NSHttpCookie.cs b/src/Foundation/NSHttpCookie.cs
index ec2862dcb7fe..e79656e71503 100644
--- a/src/Foundation/NSHttpCookie.cs
+++ b/src/Foundation/NSHttpCookie.cs
@@ -123,7 +123,11 @@ void CreateCookie (string name, string value, string? path, string? domain, stri
if (IsDirectBinding) {
InitializeHandle (Messaging.IntPtr_objc_msgSend_IntPtr (this.Handle, Selector.GetHandle ("initWithProperties:"), properties.Handle), "initWithProperties:", throwOnInitFailure);
} else {
- InitializeHandle (Messaging.IntPtr_objc_msgSendSuper_IntPtr (this.SuperHandle, Selector.GetHandle ("initWithProperties:"), properties.Handle), "initWithProperties:", throwOnInitFailure);
+ unsafe {
+ var __objc_super__ = new global::ObjCRuntime.ObjCSuper (this);
+ InitializeHandle (Messaging.IntPtr_objc_msgSendSuper_IntPtr (&__objc_super__, Selector.GetHandle ("initWithProperties:"), properties.Handle), "initWithProperties:", throwOnInitFailure);
+ GC.KeepAlive (this);
+ }
}
}
}
diff --git a/src/Foundation/NSInputStream.cs b/src/Foundation/NSInputStream.cs
index e65843332aeb..14dc85346cd0 100644
--- a/src/Foundation/NSInputStream.cs
+++ b/src/Foundation/NSInputStream.cs
@@ -63,10 +63,10 @@ public unsafe nint Read (byte [] buffer, int offset, nuint len)
static extern nint objc_msgSend (IntPtr handle, IntPtr sel, IntPtr buffer, nuint len);
[DllImport (Messaging.LIBOBJC_DYLIB)]
- static extern nint objc_msgSendSuper (IntPtr handle, IntPtr sel, IntPtr buffer, nuint len);
+ static extern unsafe nint objc_msgSendSuper (global::ObjCRuntime.ObjCSuper* handle, IntPtr sel, IntPtr buffer, nuint len);
[Export ("read:maxLength:")]
- public virtual nint Read (IntPtr buffer, nuint len)
+ public virtual unsafe nint Read (IntPtr buffer, nuint len)
{
if (buffer == IntPtr.Zero)
throw new ArgumentNullException ("buffer");
@@ -74,7 +74,10 @@ public virtual nint Read (IntPtr buffer, nuint len)
if (IsDirectBinding) {
return objc_msgSend (this.Handle, Selector.GetHandle (selReadMaxLength), buffer, len);
} else {
- return objc_msgSendSuper (this.SuperHandle, Selector.GetHandle (selReadMaxLength), buffer, len);
+ var __objc_super__ = new global::ObjCRuntime.ObjCSuper (this);
+ var __result__ = objc_msgSendSuper (&__objc_super__, Selector.GetHandle (selReadMaxLength), buffer, len);
+ GC.KeepAlive (this);
+ return __result__;
}
}
diff --git a/src/Foundation/NSObject2.cs b/src/Foundation/NSObject2.cs
index 00a5bdb5ac64..7f1a5adb7e8e 100644
--- a/src/Foundation/NSObject2.cs
+++ b/src/Foundation/NSObject2.cs
@@ -77,7 +77,11 @@ namespace Foundation {
/// if (IsDirectBinding) {
/// Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
/// } else {
- /// Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ /// unsafe {
+ /// var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ /// Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ /// }
+ /// GC.KeepAlive (this);
/// }
/// }
/// ]]>
@@ -586,13 +590,19 @@ public virtual bool ConformsToProtocol (NativeHandle protocol)
if (is_wrapper) {
does = Messaging.bool_objc_msgSend_IntPtr (this.Handle, selConformsToProtocolHandle, protocol) != 0;
} else {
- does = Messaging.bool_objc_msgSendSuper_IntPtr (this.SuperHandle, selConformsToProtocolHandle, protocol) != 0;
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ does = Messaging.bool_objc_msgSendSuper_IntPtr (&__objc_super__, selConformsToProtocolHandle, protocol) != 0;
+ }
}
#else
if (is_wrapper) {
does = Messaging.bool_objc_msgSend_IntPtr (this.Handle, Selector.GetHandle (selConformsToProtocol), protocol) != 0;
} else {
- does = Messaging.bool_objc_msgSendSuper_IntPtr (this.SuperHandle, Selector.GetHandle (selConformsToProtocol), protocol) != 0;
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ does = Messaging.bool_objc_msgSendSuper_IntPtr (&__objc_super__, Selector.GetHandle (selConformsToProtocol), protocol) != 0;
+ }
}
#endif
@@ -993,8 +1003,12 @@ public void SetValueForKeyPath (NativeHandle handle, NSString keyPath)
ObjCRuntime.Messaging.void_objc_msgSend_NativeHandle_NativeHandle (this.Handle, Selector.GetHandle ("setValue:forKeyPath:"), handle, keyPath.Handle);
GC.KeepAlive (keyPath);
} else {
- ObjCRuntime.Messaging.void_objc_msgSendSuper_NativeHandle_NativeHandle (this.SuperHandle, Selector.GetHandle ("setValue:forKeyPath:"), handle, keyPath.Handle);
- GC.KeepAlive (keyPath);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ ObjCRuntime.Messaging.void_objc_msgSendSuper_NativeHandle_NativeHandle (&__objc_super__, Selector.GetHandle ("setValue:forKeyPath:"), handle, keyPath.Handle);
+ GC.KeepAlive (this);
+ GC.KeepAlive (keyPath);
+ }
}
}
diff --git a/src/Foundation/NSThread.cs b/src/Foundation/NSThread.cs
index 02105c44692c..7e82d5ef2f2b 100644
--- a/src/Foundation/NSThread.cs
+++ b/src/Foundation/NSThread.cs
@@ -37,14 +37,21 @@ public static double Priority {
[DllImport ("__Internal")]
static extern NativeHandle xamarin_init_nsthread (IntPtr handle, byte is_direct_binding, IntPtr target, IntPtr selector, IntPtr argument);
- NativeHandle InitNSThread (NSObject target, Selector selector, NSObject? argument)
+ unsafe NativeHandle InitNSThread (NSObject target, Selector selector, NSObject? argument)
{
if (target is null)
ThrowHelper.ThrowArgumentNullException (nameof (target));
if (selector is null)
ThrowHelper.ThrowArgumentNullException (nameof (selector));
- IntPtr result = xamarin_init_nsthread (IsDirectBinding ? this.Handle : this.SuperHandle, IsDirectBinding.AsByte (), target.Handle, selector.Handle, argument.GetHandle ());
+ IntPtr result;
+ if (IsDirectBinding) {
+ result = xamarin_init_nsthread (this.Handle, IsDirectBinding.AsByte (), target.Handle, selector.Handle, argument.GetHandle ());
+ } else {
+ var __objc_super__ = new global::ObjCRuntime.ObjCSuper (this);
+ result = xamarin_init_nsthread ((IntPtr) (&__objc_super__), IsDirectBinding.AsByte (), target.Handle, selector.Handle, argument.GetHandle ());
+ GC.KeepAlive (this);
+ }
GC.KeepAlive (target);
GC.KeepAlive (selector);
GC.KeepAlive (argument);
diff --git a/src/Foundation/NSUuid.cs b/src/Foundation/NSUuid.cs
index e21c0c9a93fc..ef3ef77e8cca 100644
--- a/src/Foundation/NSUuid.cs
+++ b/src/Foundation/NSUuid.cs
@@ -26,7 +26,9 @@ public NSUuid (byte [] bytes) : base (NSObjectFlag.Empty)
if (IsDirectBinding) {
InitializeHandle (Messaging.IntPtr_objc_msgSend_IntPtr (this.Handle, Selector.GetHandle ("initWithUUIDBytes:"), ptr), "initWithUUIDBytes:");
} else {
- InitializeHandle (Messaging.IntPtr_objc_msgSendSuper_IntPtr (this.SuperHandle, Selector.GetHandle ("initWithUUIDBytes:"), ptr), "initWithUUIDBytes:");
+ var __objc_super__ = new global::ObjCRuntime.ObjCSuper (this);
+ InitializeHandle (Messaging.IntPtr_objc_msgSendSuper_IntPtr (&__objc_super__, Selector.GetHandle ("initWithUUIDBytes:"), ptr), "initWithUUIDBytes:");
+ GC.KeepAlive (this);
}
}
}
diff --git a/src/GameController/GCMouse.cs b/src/GameController/GCMouse.cs
index 1238b59171b5..47ac65fb8ca6 100644
--- a/src/GameController/GCMouse.cs
+++ b/src/GameController/GCMouse.cs
@@ -16,8 +16,12 @@ public GCMouse (NSCoder coder) : base (NSObjectFlag.Empty)
InitializeHandle (global::ObjCRuntime.Messaging.IntPtr_objc_msgSend_IntPtr (this.Handle, Selector.GetHandle ("initWithCoder:"), coder.Handle), "initWithCoder:");
GC.KeepAlive (coder);
} else {
- InitializeHandle (global::ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_IntPtr (this.SuperHandle, Selector.GetHandle ("initWithCoder:"), coder.Handle), "initWithCoder:");
- GC.KeepAlive (coder);
+ unsafe {
+ var __objc_super__ = new global::ObjCRuntime.ObjCSuper (this);
+ InitializeHandle (global::ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_IntPtr (&__objc_super__, Selector.GetHandle ("initWithCoder:"), coder.Handle), "initWithCoder:");
+ GC.KeepAlive (coder);
+ GC.KeepAlive (this);
+ }
}
}
@@ -33,7 +37,11 @@ public virtual void EncodeTo (NSCoder encoder)
if (IsDirectBinding) {
global::ObjCRuntime.Messaging.void_objc_msgSend_NativeHandle (this.Handle, Selector.GetHandle ("encodeWithCoder:"), encoder__handle__);
} else {
- global::ObjCRuntime.Messaging.void_objc_msgSendSuper_NativeHandle (this.SuperHandle, Selector.GetHandle ("encodeWithCoder:"), encoder__handle__);
+ unsafe {
+ var __objc_super__ = new global::ObjCRuntime.ObjCSuper (this);
+ global::ObjCRuntime.Messaging.void_objc_msgSendSuper_NativeHandle (&__objc_super__, Selector.GetHandle ("encodeWithCoder:"), encoder__handle__);
+ GC.KeepAlive (this);
+ }
}
GC.KeepAlive (encoder);
}
diff --git a/src/ObjCRuntime/ObjCSuper.cs b/src/ObjCRuntime/ObjCSuper.cs
new file mode 100644
index 000000000000..563e45479a9f
--- /dev/null
+++ b/src/ObjCRuntime/ObjCSuper.cs
@@ -0,0 +1,45 @@
+// Copyright (c) Microsoft Corporation.
+// Licensed under the MIT License.
+
+using System;
+using System.ComponentModel;
+using System.Runtime.InteropServices;
+
+using Foundation;
+
+#nullable enable
+
+namespace ObjCRuntime {
+
+ ///
+ /// Represents the Objective-C objc_super structure used for super message sends.
+ ///
+ ///
+ ///
+ /// This struct is intended to be stack-allocated and passed by pointer to
+ /// objc_msgSendSuper variants. The second field (classHandle)
+ /// must be the receiver's class (i.e. ), not the
+ /// superclass, because the Objective-C runtime resolves the superclass internally.
+ ///
+ ///
+ [StructLayout (LayoutKind.Sequential)]
+ [EditorBrowsable (EditorBrowsableState.Never)]
+ public readonly ref struct ObjCSuper {
+ readonly NativeHandle receiver;
+ readonly NativeHandle classHandle;
+
+ /// Creates a new for the specified object.
+ /// The object to create the super struct for.
+ public ObjCSuper (NSObject obj)
+ {
+ ArgumentNullException.ThrowIfNull (obj);
+#if COREBUILD
+ receiver = NativeHandle.Zero;
+ classHandle = NativeHandle.Zero;
+#else
+ receiver = obj.Handle;
+ classHandle = obj.ClassHandle;
+#endif
+ }
+ }
+}
diff --git a/src/UIKit/UIPasteboard.cs b/src/UIKit/UIPasteboard.cs
index 779369c395e4..66720b0cd0cb 100644
--- a/src/UIKit/UIPasteboard.cs
+++ b/src/UIKit/UIPasteboard.cs
@@ -44,7 +44,11 @@ public virtual UIImage [] Images {
if (IsDirectBinding) {
ret = GetImageArray (ObjCRuntime.Messaging.IntPtr_objc_msgSend (this.Handle, Selector.GetHandle (selImages)));
} else {
- ret = GetImageArray (ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper (this.SuperHandle, Selector.GetHandle (selImages)));
+ unsafe {
+ var __objc_super__ = new global::ObjCRuntime.ObjCSuper (this);
+ ret = GetImageArray (ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper (&__objc_super__, Selector.GetHandle (selImages)));
+ GC.KeepAlive (this);
+ }
}
return ret;
}
@@ -58,7 +62,11 @@ public virtual UIImage [] Images {
if (IsDirectBinding) {
ObjCRuntime.Messaging.void_objc_msgSend_IntPtr (this.Handle, Selector.GetHandle (selSetImages_), nsa_valueHandle);
} else {
- ObjCRuntime.Messaging.void_objc_msgSendSuper_IntPtr (this.SuperHandle, Selector.GetHandle (selSetImages_), nsa_valueHandle);
+ unsafe {
+ var __objc_super__ = new global::ObjCRuntime.ObjCSuper (this);
+ ObjCRuntime.Messaging.void_objc_msgSendSuper_IntPtr (&__objc_super__, Selector.GetHandle (selSetImages_), nsa_valueHandle);
+ GC.KeepAlive (this);
+ }
}
nsa_value.Dispose ();
diff --git a/src/bgen/Filters.cs b/src/bgen/Filters.cs
index 2a1d3ecd83e4..efcc58e90dc4 100644
--- a/src/bgen/Filters.cs
+++ b/src/bgen/Filters.cs
@@ -119,7 +119,13 @@ public void GenerateFilter (Type type)
indent--;
print ("} else {");
indent++;
- print ("h = global::ObjCRuntime.Messaging.{0}_objc_msgSendSuper_{0} (this.SuperHandle, Selector.GetHandle (\"initWithCoder:\"), coder.Handle);", NativeHandleType);
+ print ("unsafe {");
+ indent++;
+ print ("var __objc_super__ = new global::ObjCRuntime.ObjCSuper (this);");
+ print ("h = global::ObjCRuntime.Messaging.{0}_objc_msgSendSuper_{0} (&__objc_super__, Selector.GetHandle (\"initWithCoder:\"), coder.Handle);", NativeHandleType);
+ print ("GC.KeepAlive (this);");
+ indent--;
+ print ("}");
indent--;
print ("}");
print ("InitializeHandle (h, \"initWithCoder:\");");
diff --git a/src/bgen/Generator.cs b/src/bgen/Generator.cs
index 86ea641986a4..cf581d75be9b 100644
--- a/src/bgen/Generator.cs
+++ b/src/bgen/Generator.cs
@@ -1092,9 +1092,11 @@ void RegisterMethod (bool need_stret, MethodInfo mi, string method_name, bool al
else if (returnType == "char")
returnType = "ushort";
- print (m, "\t\tpublic unsafe extern static {0} {1} ({3}IntPtr receiver, IntPtr selector{2});",
+ var receiverType = method_name.IndexOf ("objc_msgSendSuper", StringComparison.Ordinal) != -1 ? "ObjCSuper*" : "IntPtr";
+ print (m, "\t\tpublic unsafe extern static {0} {1} ({3}{4} receiver, IntPtr selector{2});",
returnType, method_name, b.ToString (),
- (need_stret && aligned) ? "IntPtr* retval, " : "");
+ (need_stret && aligned) ? "IntPtr* retval, " : "",
+ receiverType);
}
bool IsNativeEnum (Type type)
@@ -1338,14 +1340,14 @@ public void Go ()
print (m, "\t\tpublic extern static IntPtr IntPtr_objc_msgSend (IntPtr receiever, IntPtr selector);");
send_methods ["IntPtr_objc_msgSend"] = "IntPtr_objc_msgSend";
print (m, "\t\t[DllImport (LIBOBJC_DYLIB, EntryPoint=\"objc_msgSendSuper\")]");
- print (m, "\t\tpublic extern static IntPtr IntPtr_objc_msgSendSuper (IntPtr receiever, IntPtr selector);");
+ print (m, "\t\tpublic unsafe extern static IntPtr IntPtr_objc_msgSendSuper (ObjCSuper* receiever, IntPtr selector);");
send_methods ["IntPtr_objc_msgSendSuper"] = "IntPtr_objc_msgSendSuper";
// IntPtr_objc_msgSendSuper_IntPtr: for initWithCoder:
print (m, "\t\t[DllImport (LIBOBJC_DYLIB, EntryPoint=\"objc_msgSend\")]");
print (m, "\t\tpublic extern static IntPtr IntPtr_objc_msgSend_IntPtr (IntPtr receiever, IntPtr selector, IntPtr arg1);");
send_methods ["IntPtr_objc_msgSend_IntPtr"] = "IntPtr_objc_msgSend_IntPtr";
print (m, "\t\t[DllImport (LIBOBJC_DYLIB, EntryPoint=\"objc_msgSendSuper\")]");
- print (m, "\t\tpublic extern static IntPtr IntPtr_objc_msgSendSuper_IntPtr (IntPtr receiever, IntPtr selector, IntPtr arg1);");
+ print (m, "\t\tpublic unsafe extern static IntPtr IntPtr_objc_msgSendSuper_IntPtr (ObjCSuper* receiever, IntPtr selector, IntPtr arg1);");
send_methods ["IntPtr_objc_msgSendSuper_IntPtr"] = "IntPtr_objc_msgSendSuper_IntPtr";
}
@@ -2344,7 +2346,7 @@ static void WriteIsDirectBindingCondition (StreamWriter? sw, ref int tabs, bool?
if (is_direct_binding != false) {
var code = trueCode ();
if (!string.IsNullOrEmpty (code))
- sw!.Write ('\t', tabs).WriteLine (code);
+ WriteIsDirectBindingCode (sw!, code, tabs);
}
if (!is_direct_binding.HasValue)
@@ -2354,7 +2356,7 @@ static void WriteIsDirectBindingCondition (StreamWriter? sw, ref int tabs, bool?
if (is_direct_binding != true) {
var code = falseCode ();
if (!string.IsNullOrEmpty (code))
- sw!.Write ('\t', tabs).WriteLine (code);
+ WriteIsDirectBindingCode (sw!, code, tabs);
}
if (!is_direct_binding.HasValue) {
@@ -2363,6 +2365,15 @@ static void WriteIsDirectBindingCondition (StreamWriter? sw, ref int tabs, bool?
}
}
+ static void WriteIsDirectBindingCode (StreamWriter sw, string code, int tabs)
+ {
+ var lines = code.Split ('\n');
+ foreach (var line in lines) {
+ if (!string.IsNullOrEmpty (line))
+ sw.Write ('\t', tabs).WriteLine (line);
+ }
+ }
+
public void print_generated_code (bool optimizable = true)
{
GeneratedCode (sw, indent, optimizable);
@@ -3063,7 +3074,18 @@ void GenerateInvoke (bool stret, bool supercall, MethodInfo mi, MemberInformatio
var isInstanceMethod = category_type is null && !minfo.is_extension_method &&
!minfo.is_protocol_implementation_method;
string? target_name = isInstanceMethod ? "this" : "This";
- string handle = supercall ? ".SuperHandle" : ".Handle";
+ string handle = supercall ? "" : ".Handle";
+ string receiver;
+
+ // For super calls on instance methods, emit a stack-allocated ObjCSuper and pass its address.
+ if (supercall && !minfo.is_static) {
+ print ("unsafe {");
+ indent++;
+ print ("var __objc_super__ = new global::ObjCRuntime.ObjCSuper ({0});", target_name);
+ receiver = "&__objc_super__";
+ } else {
+ receiver = "";
+ }
// If we have supercall == false, we can be a Bind method that has a [Target]
if (supercall == false && !minfo.is_static) {
@@ -3110,8 +3132,10 @@ void GenerateInvoke (bool stret, bool supercall, MethodInfo mi, MemberInformatio
var ret_val = "(IntPtr*) aligned_ret";
if (minfo.is_static)
print ("{0} ({5}, class_ptr, {3}{4});", sig, "/*unusued*/", "/*unusued*/", selector_field, args, ret_val);
- else
- print ("{0} ({5}, {1}{2}, {3}{4});", sig, target_name, handle, selector_field, args, ret_val);
+ else {
+ var rcv = receiver.Length > 0 ? receiver : target_name + handle;
+ print ("{0} ({3}, {1}, {2}{4});", sig, rcv, selector_field, ret_val, args);
+ }
print ("aligned_assigned = true;");
} else if (minfo.is_protocol_member && mi.Name == "Constructor") {
@@ -3138,12 +3162,13 @@ void GenerateInvoke (bool stret, bool supercall, MethodInfo mi, MemberInformatio
cast_a, sig, target_name,
"/*unusued3*/", //supercall ? "Super" : "",
selector_field, args, cast_b);
- else
- print ("{0}{1}{2} ({3}{4}, {5}{6}){7};",
+ else {
+ var rcv = receiver.Length > 0 ? receiver : target_name + handle;
+ print ("{0}{1}{2} ({3}, {4}{5}){6};",
returns ? "ret = " : "",
- cast_a, sig, target_name,
- handle,
+ cast_a, sig, rcv,
selector_field, args, cast_b);
+ }
if (postproc.Length > 0)
print (postproc.ToString ());
@@ -3153,6 +3178,10 @@ void GenerateInvoke (bool stret, bool supercall, MethodInfo mi, MemberInformatio
// if this is a extension of any kind, ensure that we keep alive the this parameter
// so that it is not collected before the msg send call has completed.
print ("GC.KeepAlive (This);");
+ } else if (supercall) {
+ print ("GC.KeepAlive ({0});", target_name);
+ indent--;
+ print ("}"); // close unsafe block
}
}
@@ -6105,7 +6134,7 @@ public void Generate (Type type)
var indentation = 3;
WriteIsDirectBindingCondition (sw, ref indentation, is_direct_binding, is_direct_binding_value,
() => string.Format ("InitializeHandle (global::{1}.IntPtr_objc_msgSend (this.Handle, global::ObjCRuntime.{0}), \"init\");", initSelector, NamespaceCache.Messaging),
- () => string.Format ("InitializeHandle (global::{1}.IntPtr_objc_msgSendSuper (this.SuperHandle, global::ObjCRuntime.{0}), \"init\");", initSelector, NamespaceCache.Messaging));
+ () => string.Format ("unsafe {{\nvar __objc_super__ = new global::ObjCRuntime.ObjCSuper (this);\nInitializeHandle (global::{1}.IntPtr_objc_msgSendSuper (&__objc_super__, global::ObjCRuntime.{0}), \"init\");\nGC.KeepAlive (this);\n}}", initSelector, NamespaceCache.Messaging));
WriteMarkDirtyIfDerived (sw, type);
sw.WriteLine ("\t\t}");
@@ -6138,7 +6167,7 @@ public void Generate (Type type)
var indentation = 3;
WriteIsDirectBindingCondition (sw, ref indentation, is_direct_binding, is_direct_binding_value,
() => string.Format ("InitializeHandle (global::{1}.IntPtr_objc_msgSend_IntPtr (this.Handle, {0}, coder.Handle), \"initWithCoder:\");", initWithCoderSelector, NamespaceCache.Messaging),
- () => string.Format ("InitializeHandle (global::{1}.IntPtr_objc_msgSendSuper_IntPtr (this.SuperHandle, {0}, coder.Handle), \"initWithCoder:\");", initWithCoderSelector, NamespaceCache.Messaging));
+ () => string.Format ("unsafe {{\nvar __objc_super__ = new global::ObjCRuntime.ObjCSuper (this);\nInitializeHandle (global::{1}.IntPtr_objc_msgSendSuper_IntPtr (&__objc_super__, {0}, coder.Handle), \"initWithCoder:\");\nGC.KeepAlive (this);\n}}", initWithCoderSelector, NamespaceCache.Messaging));
WriteMarkDirtyIfDerived (sw, type);
sw.WriteLine ("\t\t\tGC.KeepAlive (coder);");
} else {
@@ -6189,7 +6218,11 @@ public void Generate (Type type)
sw.WriteLine ("\t\t/// if (IsDirectBinding) {");
sw.WriteLine ("\t\t/// Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);");
sw.WriteLine ("\t\t/// } else {");
- sw.WriteLine ("\t\t/// Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);");
+ sw.WriteLine ("\t\t/// unsafe {");
+ sw.WriteLine ("\t\t/// var __objc_super__ = new ObjCRuntime.ObjCSuper (this);");
+ sw.WriteLine ("\t\t/// Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);");
+ sw.WriteLine ("\t\t/// }");
+ sw.WriteLine ("\t\t/// GC.KeepAlive (this);");
sw.WriteLine ("\t\t/// }");
sw.WriteLine ("\t\t/// }");
sw.WriteLine ("\t\t/// ]]>");
@@ -6976,7 +7009,12 @@ public void Generate (Type type)
print ("return {0} is not null;", mi.Name.PascalCase ());
--indent;
}
- print ("return global::" + NamespaceCache.Messaging + ".bool_objc_msgSendSuper_IntPtr (SuperHandle, " + selRespondsToSelector + ", selHandle) != 0;");
+ print ("unsafe {");
+ indent++;
+ print ("var __objc_super__ = new global::ObjCRuntime.ObjCSuper (this);");
+ print ("return global::" + NamespaceCache.Messaging + ".bool_objc_msgSendSuper_IntPtr (&__objc_super__, " + selRespondsToSelector + ", selHandle) != 0;");
+ indent--;
+ print ("}");
--indent;
print ("}");
@@ -6984,7 +7022,7 @@ public void Generate (Type type)
// bool_objc_msgSendSuper_IntPtr: for respondsToSelector:
if (!send_methods.ContainsKey ("bool_objc_msgSendSuper_IntPtr")) {
print (m, "[DllImport (LIBOBJC_DYLIB, EntryPoint=\"objc_msgSendSuper\")]");
- print (m, "public extern static byte bool_objc_msgSendSuper_IntPtr (IntPtr receiever, IntPtr selector, IntPtr arg1);");
+ print (m, "public unsafe extern static byte bool_objc_msgSendSuper_IntPtr (ObjCSuper* receiever, IntPtr selector, IntPtr arg1);");
RegisterMethodName ("bool_objc_msgSendSuper_IntPtr");
}
}
diff --git a/src/frameworks.sources b/src/frameworks.sources
index 249277f15102..accf45f75e36 100644
--- a/src/frameworks.sources
+++ b/src/frameworks.sources
@@ -1908,6 +1908,7 @@ SHARED_CORE_SOURCES = \
ObjCRuntime/TransientCFString.cs \
ObjCRuntime/TransientString.cs \
ObjCRuntime/NFloat.cs \
+ ObjCRuntime/ObjCSuper.cs \
ObjCRuntime/ObjectiveCFrameworkAttribute.cs \
ObjCRuntime/ObsoleteConstants.cs \
ObjCRuntime/Protocol.cs \
diff --git a/tests/bgen/ProtocolTests.cs b/tests/bgen/ProtocolTests.cs
index 6dad62853715..fa26326de7b1 100644
--- a/tests/bgen/ProtocolTests.cs
+++ b/tests/bgen/ProtocolTests.cs
@@ -97,23 +97,23 @@ public void Members (Profile profile)
"ObjCRuntime.NativeHandle api0.Messaging::NativeHandle_objc_msgSend_NativeHandle(System.IntPtr,System.IntPtr,ObjCRuntime.NativeHandle)",
"ObjCRuntime.NativeHandle api0.Messaging::NativeHandle_objc_msgSend_ref_NativeHandle(System.IntPtr,System.IntPtr,ObjCRuntime.NativeHandle*)",
"ObjCRuntime.NativeHandle api0.Messaging::NativeHandle_objc_msgSend(System.IntPtr,System.IntPtr)",
- "ObjCRuntime.NativeHandle api0.Messaging::NativeHandle_objc_msgSendSuper_NativeHandle(System.IntPtr,System.IntPtr,ObjCRuntime.NativeHandle)",
- "ObjCRuntime.NativeHandle api0.Messaging::NativeHandle_objc_msgSendSuper_ref_NativeHandle(System.IntPtr,System.IntPtr,ObjCRuntime.NativeHandle*)",
- "ObjCRuntime.NativeHandle api0.Messaging::NativeHandle_objc_msgSendSuper(System.IntPtr,System.IntPtr)",
+ "ObjCRuntime.NativeHandle api0.Messaging::NativeHandle_objc_msgSendSuper_NativeHandle(ObjCRuntime.ObjCSuper*,System.IntPtr,ObjCRuntime.NativeHandle)",
+ "ObjCRuntime.NativeHandle api0.Messaging::NativeHandle_objc_msgSendSuper_ref_NativeHandle(ObjCRuntime.ObjCSuper*,System.IntPtr,ObjCRuntime.NativeHandle*)",
+ "ObjCRuntime.NativeHandle api0.Messaging::NativeHandle_objc_msgSendSuper(ObjCRuntime.ObjCSuper*,System.IntPtr)",
"ObjCRuntime.NativeHandle Protocols.IProtocolWithStaticMembers::Method()",
"ObjCRuntime.NativeHandle Protocols.MyObject::get_ClassHandle()",
"ObjCRuntime.NativeHandle Protocols.MyObject2::get_ClassHandle()",
"System.Action ObjCRuntime.Trampolines/NIDAction::Create(System.IntPtr)",
"System.Boolean Protocols.IProtocolWithStaticMembers::GetProperty()",
"System.Byte api0.Messaging::bool_objc_msgSend(System.IntPtr,System.IntPtr)",
- "System.Byte api0.Messaging::bool_objc_msgSendSuper(System.IntPtr,System.IntPtr)",
+ "System.Byte api0.Messaging::bool_objc_msgSendSuper(ObjCRuntime.ObjCSuper*,System.IntPtr)",
"System.IAsyncResult ObjCRuntime.Trampolines/DAction::BeginInvoke(System.IntPtr,System.AsyncCallback,System.Object)",
"System.Int32 api0.Messaging::int_objc_msgSend_int_out_Byte_ref_Int16(System.IntPtr,System.IntPtr,System.Int32,System.Byte*,System.Int16*)",
"System.Int32 api0.Messaging::int_objc_msgSend_NativeHandle(System.IntPtr,System.IntPtr,ObjCRuntime.NativeHandle)",
"System.Int32 api0.Messaging::int_objc_msgSend(System.IntPtr,System.IntPtr)",
- "System.Int32 api0.Messaging::int_objc_msgSendSuper_int_out_Byte_ref_Int16(System.IntPtr,System.IntPtr,System.Int32,System.Byte*,System.Int16*)",
- "System.Int32 api0.Messaging::int_objc_msgSendSuper_NativeHandle(System.IntPtr,System.IntPtr,ObjCRuntime.NativeHandle)",
- "System.Int32 api0.Messaging::int_objc_msgSendSuper(System.IntPtr,System.IntPtr)",
+ "System.Int32 api0.Messaging::int_objc_msgSendSuper_int_out_Byte_ref_Int16(ObjCRuntime.ObjCSuper*,System.IntPtr,System.Int32,System.Byte*,System.Int16*)",
+ "System.Int32 api0.Messaging::int_objc_msgSendSuper_NativeHandle(ObjCRuntime.ObjCSuper*,System.IntPtr,ObjCRuntime.NativeHandle)",
+ "System.Int32 api0.Messaging::int_objc_msgSendSuper(ObjCRuntime.ObjCSuper*,System.IntPtr)",
"System.Int32 Protocols.IOptionalProtocol::_GetInternalOptionalProperty(Protocols.IOptionalProtocol)",
"System.Int32 Protocols.IOptionalProtocol::_GetOptionalProperty(Protocols.IOptionalProtocol)",
"System.Int32 Protocols.IOptionalProtocol::_InternalOptionalMethod(Protocols.IOptionalProtocol,System.Int32,System.Byte&,System.Int16&)",
@@ -211,8 +211,8 @@ public void Members (Profile profile)
"System.Int32 Protocols.RequiredProtocolWrapper::RequiredMethod(System.Int32,System.Byte&,System.Int16&)",
"System.IntPtr api0.Messaging::IntPtr_objc_msgSend_IntPtr(System.IntPtr,System.IntPtr,System.IntPtr)",
"System.IntPtr api0.Messaging::IntPtr_objc_msgSend(System.IntPtr,System.IntPtr)",
- "System.IntPtr api0.Messaging::IntPtr_objc_msgSendSuper_IntPtr(System.IntPtr,System.IntPtr,System.IntPtr)",
- "System.IntPtr api0.Messaging::IntPtr_objc_msgSendSuper(System.IntPtr,System.IntPtr)",
+ "System.IntPtr api0.Messaging::IntPtr_objc_msgSendSuper_IntPtr(ObjCRuntime.ObjCSuper*,System.IntPtr,System.IntPtr)",
+ "System.IntPtr api0.Messaging::IntPtr_objc_msgSendSuper(ObjCRuntime.ObjCSuper*,System.IntPtr)",
"System.String Protocols.IOptionalProtocol::_GetNullableOptionalProperty(Protocols.IOptionalProtocol)",
"System.String Protocols.IOptionalProtocol::get_NullableOptionalProperty()",
"System.String Protocols.IOptionalProtocol::GetNullableStaticOptionalProperty()",
@@ -238,9 +238,9 @@ public void Members (Profile profile)
"System.Void api0.Messaging::void_objc_msgSend_bool(System.IntPtr,System.IntPtr,System.Byte)",
"System.Void api0.Messaging::void_objc_msgSend_int(System.IntPtr,System.IntPtr,System.Int32)",
"System.Void api0.Messaging::void_objc_msgSend_NativeHandle(System.IntPtr,System.IntPtr,ObjCRuntime.NativeHandle)",
- "System.Void api0.Messaging::void_objc_msgSendSuper_bool(System.IntPtr,System.IntPtr,System.Byte)",
- "System.Void api0.Messaging::void_objc_msgSendSuper_int(System.IntPtr,System.IntPtr,System.Int32)",
- "System.Void api0.Messaging::void_objc_msgSendSuper_NativeHandle(System.IntPtr,System.IntPtr,ObjCRuntime.NativeHandle)",
+ "System.Void api0.Messaging::void_objc_msgSendSuper_bool(ObjCRuntime.ObjCSuper*,System.IntPtr,System.Byte)",
+ "System.Void api0.Messaging::void_objc_msgSendSuper_int(ObjCRuntime.ObjCSuper*,System.IntPtr,System.Int32)",
+ "System.Void api0.Messaging::void_objc_msgSendSuper_NativeHandle(ObjCRuntime.ObjCSuper*,System.IntPtr,ObjCRuntime.NativeHandle)",
"System.Void ObjCRuntime.Trampolines/DAction::.ctor(System.Object,System.IntPtr)",
"System.Void ObjCRuntime.Trampolines/DAction::EndInvoke(System.IAsyncResult)",
"System.Void ObjCRuntime.Trampolines/DAction::Invoke(System.IntPtr)",
diff --git a/tests/bgen/tests/ExpectedXmlDocs.MacCatalyst.xml b/tests/bgen/tests/ExpectedXmlDocs.MacCatalyst.xml
index 57467f2576c7..05163498b7fd 100644
--- a/tests/bgen/tests/ExpectedXmlDocs.MacCatalyst.xml
+++ b/tests/bgen/tests/ExpectedXmlDocs.MacCatalyst.xml
@@ -158,7 +158,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
@@ -383,7 +387,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
@@ -578,7 +586,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
@@ -688,7 +700,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
@@ -768,7 +784,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
diff --git a/tests/bgen/tests/ExpectedXmlDocs.iOS.xml b/tests/bgen/tests/ExpectedXmlDocs.iOS.xml
index ca171d315bba..03904bb8b865 100644
--- a/tests/bgen/tests/ExpectedXmlDocs.iOS.xml
+++ b/tests/bgen/tests/ExpectedXmlDocs.iOS.xml
@@ -158,7 +158,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
@@ -383,7 +387,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
@@ -578,7 +586,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
@@ -688,7 +700,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
@@ -768,7 +784,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
@@ -858,7 +878,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
diff --git a/tests/bgen/tests/ExpectedXmlDocs.macOS.xml b/tests/bgen/tests/ExpectedXmlDocs.macOS.xml
index 57467f2576c7..05163498b7fd 100644
--- a/tests/bgen/tests/ExpectedXmlDocs.macOS.xml
+++ b/tests/bgen/tests/ExpectedXmlDocs.macOS.xml
@@ -158,7 +158,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
@@ -383,7 +387,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
@@ -578,7 +586,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
@@ -688,7 +700,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
@@ -768,7 +784,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
diff --git a/tests/bgen/tests/ExpectedXmlDocs.tvOS.xml b/tests/bgen/tests/ExpectedXmlDocs.tvOS.xml
index 57467f2576c7..05163498b7fd 100644
--- a/tests/bgen/tests/ExpectedXmlDocs.tvOS.xml
+++ b/tests/bgen/tests/ExpectedXmlDocs.tvOS.xml
@@ -158,7 +158,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
@@ -383,7 +387,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
@@ -578,7 +586,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
@@ -688,7 +700,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
@@ -768,7 +784,11 @@
if (IsDirectBinding) {
Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSend_CGRect (this.Handle, initWithFrame, frame);
} else {
- Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (this.SuperHandle, initWithFrame, frame);
+ unsafe {
+ var __objc_super__ = new ObjCRuntime.ObjCSuper (this);
+ Handle = ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_CGRect (&__objc_super__, initWithFrame, frame);
+ }
+ GC.KeepAlive (this);
}
}
]]>
diff --git a/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-preservedapis.txt b/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-preservedapis.txt
index a8fb5747d13e..6ec14abe043b 100644
--- a/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-preservedapis.txt
+++ b/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-preservedapis.txt
@@ -147,11 +147,9 @@ Microsoft.MacCatalyst.dll:Foundation.NSObject.get_Handle()
Microsoft.MacCatalyst.dll:Foundation.NSObject.get_InFinalizerQueue()
Microsoft.MacCatalyst.dll:Foundation.NSObject.get_IsDirectBinding()
Microsoft.MacCatalyst.dll:Foundation.NSObject.get_IsRegisteredToggleRef()
-Microsoft.MacCatalyst.dll:Foundation.NSObject.get_SuperHandle()
Microsoft.MacCatalyst.dll:Foundation.NSObject.GetData()
Microsoft.MacCatalyst.dll:Foundation.NSObject.GetHashCode()
Microsoft.MacCatalyst.dll:Foundation.NSObject.GetNativeHash()
-Microsoft.MacCatalyst.dll:Foundation.NSObject.GetSuper()
Microsoft.MacCatalyst.dll:Foundation.NSObject.Initialize()
Microsoft.MacCatalyst.dll:Foundation.NSObject.InitializeHandle(ObjCRuntime.NativeHandle, System.String, System.Boolean)
Microsoft.MacCatalyst.dll:Foundation.NSObject.InitializeHandle(ObjCRuntime.NativeHandle, System.String)
@@ -440,29 +438,29 @@ Microsoft.MacCatalyst.dll:ObjCRuntime.MarshalObjectiveCExceptionMode ObjCRuntime
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.bool_objc_msgSend_IntPtr(System.IntPtr, System.IntPtr, System.IntPtr)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.bool_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
-Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_IntPtr(System.IntPtr, System.IntPtr, System.IntPtr)
-Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
+Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_IntPtr(ObjCRuntime.ObjCSuper*, System.IntPtr, System.IntPtr)
+Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_NativeHandle(ObjCRuntime.ObjCSuper*, System.IntPtr, ObjCRuntime.NativeHandle)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.CGRect_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.CGRect_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.CGRect_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
-Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_NativeHandle(ObjCRuntime.ObjCSuper*, System.IntPtr, ObjCRuntime.NativeHandle)
+Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSend_CGRect(System.IntPtr, System.IntPtr, CoreGraphics.CGRect)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper_CGRect(System.IntPtr, System.IntPtr, CoreGraphics.CGRect)
-Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
-Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper_CGRect(ObjCRuntime.ObjCSuper*, System.IntPtr, CoreGraphics.CGRect)
+Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper_NativeHandle(ObjCRuntime.ObjCSuper*, System.IntPtr, ObjCRuntime.NativeHandle)
+Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.UIntPtr_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.UIntPtr_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.UIntPtr_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.void_objc_msgSend_NativeHandle_NativeHandle_bool(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle, ObjCRuntime.NativeHandle, System.Byte)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.void_objc_msgSend_NativeHandle_UIntPtr(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle, System.UIntPtr)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.void_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.void_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.void_objc_msgSendSuper_NativeHandle_UIntPtr(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle, System.UIntPtr)
-Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.void_objc_msgSendSuper_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
-Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.void_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.void_objc_msgSendSuper_NativeHandle_UIntPtr(ObjCRuntime.ObjCSuper*, System.IntPtr, ObjCRuntime.NativeHandle, System.UIntPtr)
+Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.void_objc_msgSendSuper_NativeHandle(ObjCRuntime.ObjCSuper*, System.IntPtr, ObjCRuntime.NativeHandle)
+Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.void_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.MacCatalyst.dll:ObjCRuntime.Method
Microsoft.MacCatalyst.dll:ObjCRuntime.Method.get_ConstructorTrampoline()
Microsoft.MacCatalyst.dll:ObjCRuntime.Method.get_DoubleTrampoline()
@@ -497,7 +495,6 @@ Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle Foundation.NSObject::class_pt
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle Foundation.NSObject::ClassHandle()
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle Foundation.NSObject::handle()
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle Foundation.NSObject::Handle()
-Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle Foundation.NSObject::SuperHandle()
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle Foundation.NSObjectData::classHandle
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle Foundation.NSObjectData::handle
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle Foundation.NSString::class_ptr
@@ -508,6 +505,8 @@ Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle ObjCRuntime.DisposableObject:
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle ObjCRuntime.DisposableObject::Handle()
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle ObjCRuntime.INativeObject::Handle()
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle ObjCRuntime.NativeHandle::Zero
+Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle ObjCRuntime.ObjCSuper::classHandle
+Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle ObjCRuntime.ObjCSuper::receiver
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle ObjCRuntime.Protocol::handle
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle ObjCRuntime.Protocol::Handle()
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle ObjCRuntime.Runtime/ClassHandles::unused
@@ -553,6 +552,8 @@ Microsoft.MacCatalyst.dll:ObjCRuntime.ObjCException.get_Name()
Microsoft.MacCatalyst.dll:ObjCRuntime.ObjCException.get_NSException()
Microsoft.MacCatalyst.dll:ObjCRuntime.ObjCException.get_Reason()
Microsoft.MacCatalyst.dll:ObjCRuntime.ObjCException.ToString()
+Microsoft.MacCatalyst.dll:ObjCRuntime.ObjCSuper
+Microsoft.MacCatalyst.dll:ObjCRuntime.ObjCSuper..ctor(Foundation.NSObject)
Microsoft.MacCatalyst.dll:ObjCRuntime.Protocol
Microsoft.MacCatalyst.dll:ObjCRuntime.Protocol._Xamarin_ConstructINativeObject(ObjCRuntime.NativeHandle, System.Boolean)
Microsoft.MacCatalyst.dll:ObjCRuntime.Protocol..cctor()
diff --git a/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-size.txt b/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-size.txt
index acd310b0378a..78ee37f1f790 100644
--- a/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-interpreter-size.txt
@@ -1,8 +1,8 @@
-AppBundleSize: 5,792,339 bytes (5,656.6 KB = 5.5 MB)
+AppBundleSize: 5,787,160 bytes (5,651.5 KB = 5.5 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 3,310 bytes (3.2 KB = 0.0 MB)
-Contents/Info.plist: 1,112 bytes (1.1 KB = 0.0 MB)
-Contents/MacOS/SizeTestApp: 4,568,704 bytes (4,461.6 KB = 4.4 MB)
+Contents/Info.plist: 1,101 bytes (1.1 KB = 0.0 MB)
+Contents/MacOS/SizeTestApp: 4,563,536 bytes (4,456.6 KB = 4.4 MB)
Contents/MonoBundle/Microsoft.MacCatalyst.dll: 157,184 bytes (153.5 KB = 0.1 MB)
Contents/MonoBundle/runtimeconfig.bin: 1,405 bytes (1.4 KB = 0.0 MB)
Contents/MonoBundle/SizeTestApp.dll: 7,680 bytes (7.5 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-preservedapis.txt b/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-preservedapis.txt
index 36ed14ba4f7c..0043aa3bcc3b 100644
--- a/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-preservedapis.txt
+++ b/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-preservedapis.txt
@@ -132,11 +132,9 @@ Microsoft.MacCatalyst.dll:Foundation.NSObject.get_Handle()
Microsoft.MacCatalyst.dll:Foundation.NSObject.get_InFinalizerQueue()
Microsoft.MacCatalyst.dll:Foundation.NSObject.get_IsDirectBinding()
Microsoft.MacCatalyst.dll:Foundation.NSObject.get_IsRegisteredToggleRef()
-Microsoft.MacCatalyst.dll:Foundation.NSObject.get_SuperHandle()
Microsoft.MacCatalyst.dll:Foundation.NSObject.GetData()
Microsoft.MacCatalyst.dll:Foundation.NSObject.GetHashCode()
Microsoft.MacCatalyst.dll:Foundation.NSObject.GetNativeHash()
-Microsoft.MacCatalyst.dll:Foundation.NSObject.GetSuper()
Microsoft.MacCatalyst.dll:Foundation.NSObject.Initialize()
Microsoft.MacCatalyst.dll:Foundation.NSObject.InitializeHandle(ObjCRuntime.NativeHandle, System.String, System.Boolean)
Microsoft.MacCatalyst.dll:Foundation.NSObject.InitializeHandle(ObjCRuntime.NativeHandle, System.String)
@@ -348,17 +346,17 @@ Microsoft.MacCatalyst.dll:ObjCRuntime.MarshalObjectiveCExceptionMode ObjCRuntime
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.bool_objc_msgSend_IntPtr(System.IntPtr, System.IntPtr, System.IntPtr)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.bool_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
-Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_IntPtr(System.IntPtr, System.IntPtr, System.IntPtr)
-Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
+Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_IntPtr(ObjCRuntime.ObjCSuper*, System.IntPtr, System.IntPtr)
+Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_NativeHandle(ObjCRuntime.ObjCSuper*, System.IntPtr, ObjCRuntime.NativeHandle)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.CGRect_objc_msgSend(System.IntPtr, System.IntPtr)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSend_CGRect(System.IntPtr, System.IntPtr, CoreGraphics.CGRect)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.UIntPtr_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.UIntPtr_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.UIntPtr_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.void_objc_msgSend_NativeHandle_NativeHandle_bool(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle, ObjCRuntime.NativeHandle, System.Byte)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.void_objc_msgSend_NativeHandle_UIntPtr(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle, System.UIntPtr)
Microsoft.MacCatalyst.dll:ObjCRuntime.Messaging.void_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
@@ -377,7 +375,6 @@ Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle Foundation.NSObject::class_pt
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle Foundation.NSObject::ClassHandle()
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle Foundation.NSObject::handle()
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle Foundation.NSObject::Handle()
-Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle Foundation.NSObject::SuperHandle()
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle Foundation.NSObjectData::classHandle
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle Foundation.NSObjectData::handle
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle ObjCRuntime.Class::handle
@@ -386,6 +383,8 @@ Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle ObjCRuntime.DisposableObject:
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle ObjCRuntime.DisposableObject::Handle()
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle ObjCRuntime.INativeObject::Handle()
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle ObjCRuntime.NativeHandle::Zero
+Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle ObjCRuntime.ObjCSuper::classHandle
+Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle ObjCRuntime.ObjCSuper::receiver
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle ObjCRuntime.Runtime/ClassHandles::unused
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle ObjCRuntime.Selector::handle
Microsoft.MacCatalyst.dll:ObjCRuntime.NativeHandle ObjCRuntime.Selector::Handle()
@@ -428,6 +427,8 @@ Microsoft.MacCatalyst.dll:ObjCRuntime.ObjCException.get_Name()
Microsoft.MacCatalyst.dll:ObjCRuntime.ObjCException.get_NSException()
Microsoft.MacCatalyst.dll:ObjCRuntime.ObjCException.get_Reason()
Microsoft.MacCatalyst.dll:ObjCRuntime.ObjCException.ToString()
+Microsoft.MacCatalyst.dll:ObjCRuntime.ObjCSuper
+Microsoft.MacCatalyst.dll:ObjCRuntime.ObjCSuper..ctor(Foundation.NSObject)
Microsoft.MacCatalyst.dll:ObjCRuntime.RegistrarHelper
Microsoft.MacCatalyst.dll:ObjCRuntime.RegistrarHelper.ConstructINativeObject`1(System.Type, ObjCRuntime.NativeHandle, System.Boolean)
Microsoft.MacCatalyst.dll:ObjCRuntime.RegistrarHelper.ConstructNSObject`1(System.Type, ObjCRuntime.NativeHandle)
diff --git a/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-size.txt b/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-size.txt
index 7512634ffdcc..67e1e583c978 100644
--- a/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacCatalyst-MonoVM-size.txt
@@ -1,10 +1,10 @@
-AppBundleSize: 16,328,311 bytes (15,945.6 KB = 15.6 MB)
+AppBundleSize: 16,323,580 bytes (15,941.0 KB = 15.6 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 4,134 bytes (4.0 KB = 0.0 MB)
-Contents/Info.plist: 1,112 bytes (1.1 KB = 0.0 MB)
-Contents/MacOS/SizeTestApp: 13,817,152 bytes (13,493.3 KB = 13.2 MB)
+Contents/Info.plist: 1,101 bytes (1.1 KB = 0.0 MB)
+Contents/MacOS/SizeTestApp: 13,812,384 bytes (13,488.7 KB = 13.2 MB)
Contents/MonoBundle/aot-instances.aotdata.arm64: 1,045,032 bytes (1,020.5 KB = 1.0 MB)
-Contents/MonoBundle/Microsoft.MacCatalyst.aotdata.arm64: 36,320 bytes (35.5 KB = 0.0 MB)
+Contents/MonoBundle/Microsoft.MacCatalyst.aotdata.arm64: 36,368 bytes (35.5 KB = 0.0 MB)
Contents/MonoBundle/Microsoft.MacCatalyst.dll: 50,688 bytes (49.5 KB = 0.0 MB)
Contents/MonoBundle/runtimeconfig.bin: 1,481 bytes (1.4 KB = 0.0 MB)
Contents/MonoBundle/SizeTestApp.aotdata.arm64: 1,552 bytes (1.5 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-TrimmableStatic-size.txt b/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-TrimmableStatic-size.txt
index ffb9f2f06ec5..59ab57bf44ef 100644
--- a/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-TrimmableStatic-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-TrimmableStatic-size.txt
@@ -1,7 +1,7 @@
-AppBundleSize: 8,742,942 bytes (8,538.0 KB = 8.3 MB)
+AppBundleSize: 8,792,419 bytes (8,586.3 KB = 8.4 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 2,358 bytes (2.3 KB = 0.0 MB)
-Contents/Info.plist: 1,112 bytes (1.1 KB = 0.0 MB)
-Contents/MacOS/SizeTestApp: 8,737,568 bytes (8,532.8 KB = 8.3 MB)
+Contents/Info.plist: 1,101 bytes (1.1 KB = 0.0 MB)
+Contents/MacOS/SizeTestApp: 8,787,056 bytes (8,581.1 KB = 8.4 MB)
Contents/MonoBundle/runtimeconfig.bin: 1,896 bytes (1.9 KB = 0.0 MB)
Contents/PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-size.txt b/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-size.txt
index e8c5a0324ea1..8a8b69daa88a 100644
--- a/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacCatalyst-NativeAOT-size.txt
@@ -1,7 +1,7 @@
-AppBundleSize: 2,781,142 bytes (2,716.0 KB = 2.7 MB)
+AppBundleSize: 2,781,131 bytes (2,715.9 KB = 2.7 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 2,358 bytes (2.3 KB = 0.0 MB)
-Contents/Info.plist: 1,112 bytes (1.1 KB = 0.0 MB)
+Contents/Info.plist: 1,101 bytes (1.1 KB = 0.0 MB)
Contents/MacOS/SizeTestApp: 2,775,856 bytes (2,710.8 KB = 2.6 MB)
Contents/MonoBundle/runtimeconfig.bin: 1,808 bytes (1.8 KB = 0.0 MB)
Contents/PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-TrimmableStatic-size.txt b/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-TrimmableStatic-size.txt
index 643cf28d6c9d..067f24eb504d 100644
--- a/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-TrimmableStatic-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-TrimmableStatic-size.txt
@@ -1,12 +1,12 @@
-AppBundleSize: 259,379,553 bytes (253,300.3 KB = 247.4 MB)
+AppBundleSize: 260,130,342 bytes (254,033.5 KB = 248.1 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 67,868 bytes (66.3 KB = 0.1 MB)
-Contents/Info.plist: 743 bytes (0.7 KB = 0.0 MB)
-Contents/MacOS/SizeTestApp: 7,432,080 bytes (7,257.9 KB = 7.1 MB)
+Contents/Info.plist: 732 bytes (0.7 KB = 0.0 MB)
+Contents/MacOS/SizeTestApp: 7,431,264 bytes (7,257.1 KB = 7.1 MB)
Contents/MonoBundle/.xamarin/osx-arm64/_Microsoft.macOS.TypeMap.dll: 4,847,616 bytes (4,734.0 KB = 4.6 MB)
Contents/MonoBundle/.xamarin/osx-arm64/_SizeTestApp.TypeMap.dll: 3,072 bytes (3.0 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.CSharp.dll: 893,192 bytes (872.3 KB = 0.9 MB)
-Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.macOS.dll: 38,148,096 bytes (37,254.0 KB = 36.4 MB)
+Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.macOS.dll: 38,523,904 bytes (37,621.0 KB = 36.7 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.VisualBasic.Core.dll: 1,335,096 bytes (1,303.8 KB = 1.3 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.VisualBasic.dll: 17,680 bytes (17.3 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.Win32.Primitives.dll: 16,144 bytes (15.8 KB = 0.0 MB)
@@ -182,7 +182,7 @@ Contents/MonoBundle/.xamarin/osx-arm64/WindowsBase.dll: 16,688 bytes (16.3 KB =
Contents/MonoBundle/.xamarin/osx-x64/_Microsoft.macOS.TypeMap.dll: 4,847,616 bytes (4,734.0 KB = 4.6 MB)
Contents/MonoBundle/.xamarin/osx-x64/_SizeTestApp.TypeMap.dll: 3,072 bytes (3.0 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.CSharp.dll: 796,432 bytes (777.8 KB = 0.8 MB)
-Contents/MonoBundle/.xamarin/osx-x64/Microsoft.macOS.dll: 38,148,096 bytes (37,254.0 KB = 36.4 MB)
+Contents/MonoBundle/.xamarin/osx-x64/Microsoft.macOS.dll: 38,523,904 bytes (37,621.0 KB = 36.7 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.VisualBasic.Core.dll: 1,166,648 bytes (1,139.3 KB = 1.1 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.VisualBasic.dll: 17,680 bytes (17.3 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.Win32.Primitives.dll: 16,176 bytes (15.8 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-size.txt b/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-size.txt
index 2ac55e068fe2..83d57f54803e 100644
--- a/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacOSX-CoreCLR-Interpreter-size.txt
@@ -1,10 +1,10 @@
-AppBundleSize: 247,542,219 bytes (241,740.4 KB = 236.1 MB)
+AppBundleSize: 248,292,016 bytes (242,472.7 KB = 236.8 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 67,160 bytes (65.6 KB = 0.1 MB)
-Contents/Info.plist: 743 bytes (0.7 KB = 0.0 MB)
-Contents/MacOS/SizeTestApp: 8,088,336 bytes (7,898.8 KB = 7.7 MB)
+Contents/Info.plist: 732 bytes (0.7 KB = 0.0 MB)
+Contents/MacOS/SizeTestApp: 8,087,552 bytes (7,898.0 KB = 7.7 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.CSharp.dll: 893,192 bytes (872.3 KB = 0.9 MB)
-Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.macOS.dll: 36,751,872 bytes (35,890.5 KB = 35.0 MB)
+Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.macOS.dll: 37,127,168 bytes (36,257.0 KB = 35.4 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.VisualBasic.Core.dll: 1,335,096 bytes (1,303.8 KB = 1.3 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.VisualBasic.dll: 17,680 bytes (17.3 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-arm64/Microsoft.Win32.Primitives.dll: 16,144 bytes (15.8 KB = 0.0 MB)
@@ -178,7 +178,7 @@ Contents/MonoBundle/.xamarin/osx-arm64/System.Xml.XPath.dll: 16,144 bytes (15.8
Contents/MonoBundle/.xamarin/osx-arm64/System.Xml.XPath.XDocument.dll: 17,672 bytes (17.3 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-arm64/WindowsBase.dll: 16,688 bytes (16.3 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.CSharp.dll: 796,432 bytes (777.8 KB = 0.8 MB)
-Contents/MonoBundle/.xamarin/osx-x64/Microsoft.macOS.dll: 36,751,872 bytes (35,890.5 KB = 35.0 MB)
+Contents/MonoBundle/.xamarin/osx-x64/Microsoft.macOS.dll: 37,127,168 bytes (36,257.0 KB = 35.4 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.VisualBasic.Core.dll: 1,166,648 bytes (1,139.3 KB = 1.1 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.VisualBasic.dll: 17,680 bytes (17.3 KB = 0.0 MB)
Contents/MonoBundle/.xamarin/osx-x64/Microsoft.Win32.Primitives.dll: 16,176 bytes (15.8 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-TrimmableStatic-size.txt b/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-TrimmableStatic-size.txt
index 5ca361d42edc..9a45e4dcfb44 100644
--- a/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-TrimmableStatic-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-TrimmableStatic-size.txt
@@ -1,8 +1,8 @@
-AppBundleSize: 21,449,705 bytes (20,947.0 KB = 20.5 MB)
+AppBundleSize: 21,531,678 bytes (21,027.0 KB = 20.5 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 3,489 bytes (3.4 KB = 0.0 MB)
-Contents/Info.plist: 743 bytes (0.7 KB = 0.0 MB)
-Contents/MacOS/SizeTestApp: 18,456,032 bytes (18,023.5 KB = 17.6 MB)
+Contents/Info.plist: 732 bytes (0.7 KB = 0.0 MB)
+Contents/MacOS/SizeTestApp: 18,538,016 bytes (18,103.5 KB = 17.7 MB)
Contents/MonoBundle/libSystem.Globalization.Native.dylib: 252,176 bytes (246.3 KB = 0.2 MB)
Contents/MonoBundle/libSystem.IO.Compression.Native.dylib: 2,005,440 bytes (1,958.4 KB = 1.9 MB)
Contents/MonoBundle/libSystem.Native.dylib: 292,176 bytes (285.3 KB = 0.3 MB)
diff --git a/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-size.txt b/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-size.txt
index e8b63372eb52..40ce560ec153 100644
--- a/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-size.txt
+++ b/tests/dotnet/UnitTests/expected/MacOSX-NativeAOT-size.txt
@@ -1,8 +1,8 @@
-AppBundleSize: 8,818,823 bytes (8,612.1 KB = 8.4 MB)
+AppBundleSize: 8,835,196 bytes (8,628.1 KB = 8.4 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
Contents/_CodeSignature/CodeResources: 3,489 bytes (3.4 KB = 0.0 MB)
-Contents/Info.plist: 743 bytes (0.7 KB = 0.0 MB)
-Contents/MacOS/SizeTestApp: 5,825,232 bytes (5,688.7 KB = 5.6 MB)
+Contents/Info.plist: 732 bytes (0.7 KB = 0.0 MB)
+Contents/MacOS/SizeTestApp: 5,841,616 bytes (5,704.7 KB = 5.6 MB)
Contents/MonoBundle/libSystem.Globalization.Native.dylib: 252,176 bytes (246.3 KB = 0.2 MB)
Contents/MonoBundle/libSystem.IO.Compression.Native.dylib: 2,005,440 bytes (1,958.4 KB = 1.9 MB)
Contents/MonoBundle/libSystem.Native.dylib: 292,176 bytes (285.3 KB = 0.3 MB)
diff --git a/tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-preservedapis.txt b/tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-preservedapis.txt
index 69dd2bddea06..9dc7e411bbb3 100644
--- a/tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-preservedapis.txt
+++ b/tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-preservedapis.txt
@@ -139,11 +139,9 @@ Microsoft.tvOS.dll:Foundation.NSObject.get_Handle()
Microsoft.tvOS.dll:Foundation.NSObject.get_InFinalizerQueue()
Microsoft.tvOS.dll:Foundation.NSObject.get_IsDirectBinding()
Microsoft.tvOS.dll:Foundation.NSObject.get_IsRegisteredToggleRef()
-Microsoft.tvOS.dll:Foundation.NSObject.get_SuperHandle()
Microsoft.tvOS.dll:Foundation.NSObject.GetData()
Microsoft.tvOS.dll:Foundation.NSObject.GetHashCode()
Microsoft.tvOS.dll:Foundation.NSObject.GetNativeHash()
-Microsoft.tvOS.dll:Foundation.NSObject.GetSuper()
Microsoft.tvOS.dll:Foundation.NSObject.Initialize()
Microsoft.tvOS.dll:Foundation.NSObject.InitializeHandle(ObjCRuntime.NativeHandle, System.String, System.Boolean)
Microsoft.tvOS.dll:Foundation.NSObject.InitializeHandle(ObjCRuntime.NativeHandle, System.String)
@@ -435,29 +433,29 @@ Microsoft.tvOS.dll:ObjCRuntime.MarshalObjectiveCExceptionMode ObjCRuntime.Runtim
Microsoft.tvOS.dll:ObjCRuntime.Messaging
Microsoft.tvOS.dll:ObjCRuntime.Messaging.bool_objc_msgSend_IntPtr(System.IntPtr, System.IntPtr, System.IntPtr)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.bool_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
-Microsoft.tvOS.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_IntPtr(System.IntPtr, System.IntPtr, System.IntPtr)
-Microsoft.tvOS.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
+Microsoft.tvOS.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_IntPtr(ObjCRuntime.ObjCSuper*, System.IntPtr, System.IntPtr)
+Microsoft.tvOS.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_NativeHandle(ObjCRuntime.ObjCSuper*, System.IntPtr, ObjCRuntime.NativeHandle)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.CGRect_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.tvOS.dll:ObjCRuntime.Messaging.CGRect_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.tvOS.dll:ObjCRuntime.Messaging.CGRect_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.tvOS.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
-Microsoft.tvOS.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.tvOS.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_NativeHandle(ObjCRuntime.ObjCSuper*, System.IntPtr, ObjCRuntime.NativeHandle)
+Microsoft.tvOS.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSend_CGRect(System.IntPtr, System.IntPtr, CoreGraphics.CGRect)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.tvOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper_CGRect(System.IntPtr, System.IntPtr, CoreGraphics.CGRect)
-Microsoft.tvOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
-Microsoft.tvOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.tvOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper_CGRect(ObjCRuntime.ObjCSuper*, System.IntPtr, CoreGraphics.CGRect)
+Microsoft.tvOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper_NativeHandle(ObjCRuntime.ObjCSuper*, System.IntPtr, ObjCRuntime.NativeHandle)
+Microsoft.tvOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.UIntPtr_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.tvOS.dll:ObjCRuntime.Messaging.UIntPtr_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.tvOS.dll:ObjCRuntime.Messaging.UIntPtr_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.void_objc_msgSend_NativeHandle_NativeHandle_bool(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle, ObjCRuntime.NativeHandle, System.Byte)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.void_objc_msgSend_NativeHandle_UIntPtr(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle, System.UIntPtr)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.void_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.void_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.tvOS.dll:ObjCRuntime.Messaging.void_objc_msgSendSuper_NativeHandle_UIntPtr(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle, System.UIntPtr)
-Microsoft.tvOS.dll:ObjCRuntime.Messaging.void_objc_msgSendSuper_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
-Microsoft.tvOS.dll:ObjCRuntime.Messaging.void_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.tvOS.dll:ObjCRuntime.Messaging.void_objc_msgSendSuper_NativeHandle_UIntPtr(ObjCRuntime.ObjCSuper*, System.IntPtr, ObjCRuntime.NativeHandle, System.UIntPtr)
+Microsoft.tvOS.dll:ObjCRuntime.Messaging.void_objc_msgSendSuper_NativeHandle(ObjCRuntime.ObjCSuper*, System.IntPtr, ObjCRuntime.NativeHandle)
+Microsoft.tvOS.dll:ObjCRuntime.Messaging.void_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.tvOS.dll:ObjCRuntime.Method
Microsoft.tvOS.dll:ObjCRuntime.Method.get_ConstructorTrampoline()
Microsoft.tvOS.dll:ObjCRuntime.Method.get_DoubleTrampoline()
@@ -492,7 +490,6 @@ Microsoft.tvOS.dll:ObjCRuntime.NativeHandle Foundation.NSObject::class_ptr
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle Foundation.NSObject::ClassHandle()
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle Foundation.NSObject::handle()
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle Foundation.NSObject::Handle()
-Microsoft.tvOS.dll:ObjCRuntime.NativeHandle Foundation.NSObject::SuperHandle()
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle Foundation.NSObjectData::classHandle
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle Foundation.NSObjectData::handle
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle Foundation.NSString::class_ptr
@@ -503,6 +500,8 @@ Microsoft.tvOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.DisposableObject::handle
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.DisposableObject::Handle()
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.INativeObject::Handle()
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.NativeHandle::Zero
+Microsoft.tvOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.ObjCSuper::classHandle
+Microsoft.tvOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.ObjCSuper::receiver
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.Protocol::handle
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.Protocol::Handle()
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.Runtime/ClassHandles::unused
@@ -548,6 +547,8 @@ Microsoft.tvOS.dll:ObjCRuntime.ObjCException.get_Name()
Microsoft.tvOS.dll:ObjCRuntime.ObjCException.get_NSException()
Microsoft.tvOS.dll:ObjCRuntime.ObjCException.get_Reason()
Microsoft.tvOS.dll:ObjCRuntime.ObjCException.ToString()
+Microsoft.tvOS.dll:ObjCRuntime.ObjCSuper
+Microsoft.tvOS.dll:ObjCRuntime.ObjCSuper..ctor(Foundation.NSObject)
Microsoft.tvOS.dll:ObjCRuntime.Protocol
Microsoft.tvOS.dll:ObjCRuntime.Protocol._Xamarin_ConstructINativeObject(ObjCRuntime.NativeHandle, System.Boolean)
Microsoft.tvOS.dll:ObjCRuntime.Protocol..cctor()
diff --git a/tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-size.txt b/tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-size.txt
index 690044239400..50aaf0f31b2f 100644
--- a/tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-size.txt
+++ b/tests/dotnet/UnitTests/expected/TVOS-MonoVM-interpreter-size.txt
@@ -1,9 +1,9 @@
-AppBundleSize: 3,615,919 bytes (3,531.2 KB = 3.4 MB)
+AppBundleSize: 3,616,420 bytes (3,531.7 KB = 3.4 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 3,999 bytes (3.9 KB = 0.0 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,131 bytes (1.1 KB = 0.0 MB)
-Microsoft.tvOS.dll: 154,112 bytes (150.5 KB = 0.1 MB)
+Info.plist: 1,120 bytes (1.1 KB = 0.0 MB)
+Microsoft.tvOS.dll: 154,624 bytes (151.0 KB = 0.1 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,405 bytes (1.4 KB = 0.0 MB)
SizeTestApp: 2,404,416 bytes (2,348.1 KB = 2.3 MB)
diff --git a/tests/dotnet/UnitTests/expected/TVOS-MonoVM-preservedapis.txt b/tests/dotnet/UnitTests/expected/TVOS-MonoVM-preservedapis.txt
index 39615d782921..897cc8c3871e 100644
--- a/tests/dotnet/UnitTests/expected/TVOS-MonoVM-preservedapis.txt
+++ b/tests/dotnet/UnitTests/expected/TVOS-MonoVM-preservedapis.txt
@@ -124,11 +124,9 @@ Microsoft.tvOS.dll:Foundation.NSObject.get_Handle()
Microsoft.tvOS.dll:Foundation.NSObject.get_InFinalizerQueue()
Microsoft.tvOS.dll:Foundation.NSObject.get_IsDirectBinding()
Microsoft.tvOS.dll:Foundation.NSObject.get_IsRegisteredToggleRef()
-Microsoft.tvOS.dll:Foundation.NSObject.get_SuperHandle()
Microsoft.tvOS.dll:Foundation.NSObject.GetData()
Microsoft.tvOS.dll:Foundation.NSObject.GetHashCode()
Microsoft.tvOS.dll:Foundation.NSObject.GetNativeHash()
-Microsoft.tvOS.dll:Foundation.NSObject.GetSuper()
Microsoft.tvOS.dll:Foundation.NSObject.Initialize()
Microsoft.tvOS.dll:Foundation.NSObject.InitializeHandle(ObjCRuntime.NativeHandle, System.String, System.Boolean)
Microsoft.tvOS.dll:Foundation.NSObject.InitializeHandle(ObjCRuntime.NativeHandle, System.String)
@@ -343,17 +341,17 @@ Microsoft.tvOS.dll:ObjCRuntime.MarshalObjectiveCExceptionMode ObjCRuntime.Runtim
Microsoft.tvOS.dll:ObjCRuntime.Messaging
Microsoft.tvOS.dll:ObjCRuntime.Messaging.bool_objc_msgSend_IntPtr(System.IntPtr, System.IntPtr, System.IntPtr)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.bool_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
-Microsoft.tvOS.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_IntPtr(System.IntPtr, System.IntPtr, System.IntPtr)
-Microsoft.tvOS.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
+Microsoft.tvOS.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_IntPtr(ObjCRuntime.ObjCSuper*, System.IntPtr, System.IntPtr)
+Microsoft.tvOS.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_NativeHandle(ObjCRuntime.ObjCSuper*, System.IntPtr, ObjCRuntime.NativeHandle)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.CGRect_objc_msgSend(System.IntPtr, System.IntPtr)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.tvOS.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.tvOS.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSend_CGRect(System.IntPtr, System.IntPtr, CoreGraphics.CGRect)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.tvOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.tvOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.UIntPtr_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.tvOS.dll:ObjCRuntime.Messaging.UIntPtr_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.tvOS.dll:ObjCRuntime.Messaging.UIntPtr_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.void_objc_msgSend_NativeHandle_NativeHandle_bool(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle, ObjCRuntime.NativeHandle, System.Byte)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.void_objc_msgSend_NativeHandle_UIntPtr(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle, System.UIntPtr)
Microsoft.tvOS.dll:ObjCRuntime.Messaging.void_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
@@ -372,7 +370,6 @@ Microsoft.tvOS.dll:ObjCRuntime.NativeHandle Foundation.NSObject::class_ptr
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle Foundation.NSObject::ClassHandle()
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle Foundation.NSObject::handle()
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle Foundation.NSObject::Handle()
-Microsoft.tvOS.dll:ObjCRuntime.NativeHandle Foundation.NSObject::SuperHandle()
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle Foundation.NSObjectData::classHandle
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle Foundation.NSObjectData::handle
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.Class::handle
@@ -381,6 +378,8 @@ Microsoft.tvOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.DisposableObject::handle
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.DisposableObject::Handle()
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.INativeObject::Handle()
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.NativeHandle::Zero
+Microsoft.tvOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.ObjCSuper::classHandle
+Microsoft.tvOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.ObjCSuper::receiver
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.Runtime/ClassHandles::unused
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.Selector::handle
Microsoft.tvOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.Selector::Handle()
@@ -423,6 +422,8 @@ Microsoft.tvOS.dll:ObjCRuntime.ObjCException.get_Name()
Microsoft.tvOS.dll:ObjCRuntime.ObjCException.get_NSException()
Microsoft.tvOS.dll:ObjCRuntime.ObjCException.get_Reason()
Microsoft.tvOS.dll:ObjCRuntime.ObjCException.ToString()
+Microsoft.tvOS.dll:ObjCRuntime.ObjCSuper
+Microsoft.tvOS.dll:ObjCRuntime.ObjCSuper..ctor(Foundation.NSObject)
Microsoft.tvOS.dll:ObjCRuntime.RegistrarHelper
Microsoft.tvOS.dll:ObjCRuntime.RegistrarHelper.ConstructINativeObject`1(System.Type, ObjCRuntime.NativeHandle, System.Boolean)
Microsoft.tvOS.dll:ObjCRuntime.RegistrarHelper.ConstructNSObject`1(System.Type, ObjCRuntime.NativeHandle)
diff --git a/tests/dotnet/UnitTests/expected/TVOS-MonoVM-size.txt b/tests/dotnet/UnitTests/expected/TVOS-MonoVM-size.txt
index 5e627a186b79..756f7510197e 100644
--- a/tests/dotnet/UnitTests/expected/TVOS-MonoVM-size.txt
+++ b/tests/dotnet/UnitTests/expected/TVOS-MonoVM-size.txt
@@ -1,14 +1,14 @@
-AppBundleSize: 9,364,125 bytes (9,144.7 KB = 8.9 MB)
+AppBundleSize: 9,364,234 bytes (9,144.8 KB = 8.9 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 5,233 bytes (5.1 KB = 0.0 MB)
aot-instances.aotdata.arm64: 827,592 bytes (808.2 KB = 0.8 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,131 bytes (1.1 KB = 0.0 MB)
-Microsoft.tvOS.aotdata.arm64: 22,880 bytes (22.3 KB = 0.0 MB)
+Info.plist: 1,120 bytes (1.1 KB = 0.0 MB)
+Microsoft.tvOS.aotdata.arm64: 22,984 bytes (22.4 KB = 0.0 MB)
Microsoft.tvOS.dll: 48,640 bytes (47.5 KB = 0.0 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,481 bytes (1.4 KB = 0.0 MB)
-SizeTestApp: 7,261,136 bytes (7,091.0 KB = 6.9 MB)
+SizeTestApp: 7,261,152 bytes (7,091.0 KB = 6.9 MB)
SizeTestApp.aotdata.arm64: 1,464 bytes (1.4 KB = 0.0 MB)
SizeTestApp.dll: 7,680 bytes (7.5 KB = 0.0 MB)
System.Private.CoreLib.aotdata.arm64: 640,656 bytes (625.6 KB = 0.6 MB)
diff --git a/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-TrimmableStatic-size.txt b/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-TrimmableStatic-size.txt
index dfd9e745144b..ce409263e277 100644
--- a/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-TrimmableStatic-size.txt
+++ b/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-TrimmableStatic-size.txt
@@ -1,8 +1,8 @@
-AppBundleSize: 7,888,849 bytes (7,704.0 KB = 7.5 MB)
+AppBundleSize: 7,922,022 bytes (7,736.3 KB = 7.6 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 2,589 bytes (2.5 KB = 0.0 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,131 bytes (1.1 KB = 0.0 MB)
+Info.plist: 1,120 bytes (1.1 KB = 0.0 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,889 bytes (1.8 KB = 0.0 MB)
-SizeTestApp: 7,882,848 bytes (7,698.1 KB = 7.5 MB)
+SizeTestApp: 7,916,032 bytes (7,730.5 KB = 7.5 MB)
diff --git a/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-size.txt b/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-size.txt
index e31f38da129e..7ede3e0bb7e8 100644
--- a/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-size.txt
+++ b/tests/dotnet/UnitTests/expected/TVOS-NativeAOT-size.txt
@@ -1,8 +1,8 @@
-AppBundleSize: 2,783,136 bytes (2,717.9 KB = 2.7 MB)
+AppBundleSize: 2,783,125 bytes (2,717.9 KB = 2.7 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 2,589 bytes (2.5 KB = 0.0 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,131 bytes (1.1 KB = 0.0 MB)
+Info.plist: 1,120 bytes (1.1 KB = 0.0 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,808 bytes (1.8 KB = 0.0 MB)
SizeTestApp: 2,777,216 bytes (2,712.1 KB = 2.6 MB)
diff --git a/tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-preservedapis.txt b/tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-preservedapis.txt
index 4f60ff683f87..c2062123e2fc 100644
--- a/tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-preservedapis.txt
+++ b/tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-preservedapis.txt
@@ -139,11 +139,9 @@ Microsoft.iOS.dll:Foundation.NSObject.get_Handle()
Microsoft.iOS.dll:Foundation.NSObject.get_InFinalizerQueue()
Microsoft.iOS.dll:Foundation.NSObject.get_IsDirectBinding()
Microsoft.iOS.dll:Foundation.NSObject.get_IsRegisteredToggleRef()
-Microsoft.iOS.dll:Foundation.NSObject.get_SuperHandle()
Microsoft.iOS.dll:Foundation.NSObject.GetData()
Microsoft.iOS.dll:Foundation.NSObject.GetHashCode()
Microsoft.iOS.dll:Foundation.NSObject.GetNativeHash()
-Microsoft.iOS.dll:Foundation.NSObject.GetSuper()
Microsoft.iOS.dll:Foundation.NSObject.Initialize()
Microsoft.iOS.dll:Foundation.NSObject.InitializeHandle(ObjCRuntime.NativeHandle, System.String, System.Boolean)
Microsoft.iOS.dll:Foundation.NSObject.InitializeHandle(ObjCRuntime.NativeHandle, System.String)
@@ -435,29 +433,29 @@ Microsoft.iOS.dll:ObjCRuntime.MarshalObjectiveCExceptionMode ObjCRuntime.Runtime
Microsoft.iOS.dll:ObjCRuntime.Messaging
Microsoft.iOS.dll:ObjCRuntime.Messaging.bool_objc_msgSend_IntPtr(System.IntPtr, System.IntPtr, System.IntPtr)
Microsoft.iOS.dll:ObjCRuntime.Messaging.bool_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
-Microsoft.iOS.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_IntPtr(System.IntPtr, System.IntPtr, System.IntPtr)
-Microsoft.iOS.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
+Microsoft.iOS.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_IntPtr(ObjCRuntime.ObjCSuper*, System.IntPtr, System.IntPtr)
+Microsoft.iOS.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_NativeHandle(ObjCRuntime.ObjCSuper*, System.IntPtr, ObjCRuntime.NativeHandle)
Microsoft.iOS.dll:ObjCRuntime.Messaging.CGRect_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.iOS.dll:ObjCRuntime.Messaging.CGRect_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.iOS.dll:ObjCRuntime.Messaging.CGRect_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.iOS.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
Microsoft.iOS.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.iOS.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
-Microsoft.iOS.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.iOS.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper_NativeHandle(ObjCRuntime.ObjCSuper*, System.IntPtr, ObjCRuntime.NativeHandle)
+Microsoft.iOS.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.iOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSend_CGRect(System.IntPtr, System.IntPtr, CoreGraphics.CGRect)
Microsoft.iOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
Microsoft.iOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.iOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper_CGRect(System.IntPtr, System.IntPtr, CoreGraphics.CGRect)
-Microsoft.iOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
-Microsoft.iOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.iOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper_CGRect(ObjCRuntime.ObjCSuper*, System.IntPtr, CoreGraphics.CGRect)
+Microsoft.iOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper_NativeHandle(ObjCRuntime.ObjCSuper*, System.IntPtr, ObjCRuntime.NativeHandle)
+Microsoft.iOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.iOS.dll:ObjCRuntime.Messaging.UIntPtr_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.iOS.dll:ObjCRuntime.Messaging.UIntPtr_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.iOS.dll:ObjCRuntime.Messaging.UIntPtr_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.iOS.dll:ObjCRuntime.Messaging.void_objc_msgSend_NativeHandle_NativeHandle_bool(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle, ObjCRuntime.NativeHandle, System.Byte)
Microsoft.iOS.dll:ObjCRuntime.Messaging.void_objc_msgSend_NativeHandle_UIntPtr(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle, System.UIntPtr)
Microsoft.iOS.dll:ObjCRuntime.Messaging.void_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
Microsoft.iOS.dll:ObjCRuntime.Messaging.void_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.iOS.dll:ObjCRuntime.Messaging.void_objc_msgSendSuper_NativeHandle_UIntPtr(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle, System.UIntPtr)
-Microsoft.iOS.dll:ObjCRuntime.Messaging.void_objc_msgSendSuper_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
-Microsoft.iOS.dll:ObjCRuntime.Messaging.void_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.iOS.dll:ObjCRuntime.Messaging.void_objc_msgSendSuper_NativeHandle_UIntPtr(ObjCRuntime.ObjCSuper*, System.IntPtr, ObjCRuntime.NativeHandle, System.UIntPtr)
+Microsoft.iOS.dll:ObjCRuntime.Messaging.void_objc_msgSendSuper_NativeHandle(ObjCRuntime.ObjCSuper*, System.IntPtr, ObjCRuntime.NativeHandle)
+Microsoft.iOS.dll:ObjCRuntime.Messaging.void_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.iOS.dll:ObjCRuntime.Method
Microsoft.iOS.dll:ObjCRuntime.Method.get_ConstructorTrampoline()
Microsoft.iOS.dll:ObjCRuntime.Method.get_DoubleTrampoline()
@@ -492,7 +490,6 @@ Microsoft.iOS.dll:ObjCRuntime.NativeHandle Foundation.NSObject::class_ptr
Microsoft.iOS.dll:ObjCRuntime.NativeHandle Foundation.NSObject::ClassHandle()
Microsoft.iOS.dll:ObjCRuntime.NativeHandle Foundation.NSObject::handle()
Microsoft.iOS.dll:ObjCRuntime.NativeHandle Foundation.NSObject::Handle()
-Microsoft.iOS.dll:ObjCRuntime.NativeHandle Foundation.NSObject::SuperHandle()
Microsoft.iOS.dll:ObjCRuntime.NativeHandle Foundation.NSObjectData::classHandle
Microsoft.iOS.dll:ObjCRuntime.NativeHandle Foundation.NSObjectData::handle
Microsoft.iOS.dll:ObjCRuntime.NativeHandle Foundation.NSString::class_ptr
@@ -503,6 +500,8 @@ Microsoft.iOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.DisposableObject::handle
Microsoft.iOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.DisposableObject::Handle()
Microsoft.iOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.INativeObject::Handle()
Microsoft.iOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.NativeHandle::Zero
+Microsoft.iOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.ObjCSuper::classHandle
+Microsoft.iOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.ObjCSuper::receiver
Microsoft.iOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.Protocol::handle
Microsoft.iOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.Protocol::Handle()
Microsoft.iOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.Runtime/ClassHandles::unused
@@ -548,6 +547,8 @@ Microsoft.iOS.dll:ObjCRuntime.ObjCException.get_Name()
Microsoft.iOS.dll:ObjCRuntime.ObjCException.get_NSException()
Microsoft.iOS.dll:ObjCRuntime.ObjCException.get_Reason()
Microsoft.iOS.dll:ObjCRuntime.ObjCException.ToString()
+Microsoft.iOS.dll:ObjCRuntime.ObjCSuper
+Microsoft.iOS.dll:ObjCRuntime.ObjCSuper..ctor(Foundation.NSObject)
Microsoft.iOS.dll:ObjCRuntime.Protocol
Microsoft.iOS.dll:ObjCRuntime.Protocol._Xamarin_ConstructINativeObject(ObjCRuntime.NativeHandle, System.Boolean)
Microsoft.iOS.dll:ObjCRuntime.Protocol..cctor()
diff --git a/tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-size.txt b/tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-size.txt
index a8a3f09e5f33..0c9c253439b5 100644
--- a/tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-size.txt
+++ b/tests/dotnet/UnitTests/expected/iOS-MonoVM-interpreter-size.txt
@@ -1,9 +1,9 @@
-AppBundleSize: 3,602,372 bytes (3,517.9 KB = 3.4 MB)
+AppBundleSize: 3,602,873 bytes (3,518.4 KB = 3.4 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 3,997 bytes (3.9 KB = 0.0 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,154 bytes (1.1 KB = 0.0 MB)
-Microsoft.iOS.dll: 154,112 bytes (150.5 KB = 0.1 MB)
+Info.plist: 1,143 bytes (1.1 KB = 0.0 MB)
+Microsoft.iOS.dll: 154,624 bytes (151.0 KB = 0.1 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,405 bytes (1.4 KB = 0.0 MB)
SizeTestApp: 2,390,848 bytes (2,334.8 KB = 2.3 MB)
diff --git a/tests/dotnet/UnitTests/expected/iOS-MonoVM-preservedapis.txt b/tests/dotnet/UnitTests/expected/iOS-MonoVM-preservedapis.txt
index 9636d8f67412..0b5ab2d71783 100644
--- a/tests/dotnet/UnitTests/expected/iOS-MonoVM-preservedapis.txt
+++ b/tests/dotnet/UnitTests/expected/iOS-MonoVM-preservedapis.txt
@@ -124,11 +124,9 @@ Microsoft.iOS.dll:Foundation.NSObject.get_Handle()
Microsoft.iOS.dll:Foundation.NSObject.get_InFinalizerQueue()
Microsoft.iOS.dll:Foundation.NSObject.get_IsDirectBinding()
Microsoft.iOS.dll:Foundation.NSObject.get_IsRegisteredToggleRef()
-Microsoft.iOS.dll:Foundation.NSObject.get_SuperHandle()
Microsoft.iOS.dll:Foundation.NSObject.GetData()
Microsoft.iOS.dll:Foundation.NSObject.GetHashCode()
Microsoft.iOS.dll:Foundation.NSObject.GetNativeHash()
-Microsoft.iOS.dll:Foundation.NSObject.GetSuper()
Microsoft.iOS.dll:Foundation.NSObject.Initialize()
Microsoft.iOS.dll:Foundation.NSObject.InitializeHandle(ObjCRuntime.NativeHandle, System.String, System.Boolean)
Microsoft.iOS.dll:Foundation.NSObject.InitializeHandle(ObjCRuntime.NativeHandle, System.String)
@@ -343,17 +341,17 @@ Microsoft.iOS.dll:ObjCRuntime.MarshalObjectiveCExceptionMode ObjCRuntime.Runtime
Microsoft.iOS.dll:ObjCRuntime.Messaging
Microsoft.iOS.dll:ObjCRuntime.Messaging.bool_objc_msgSend_IntPtr(System.IntPtr, System.IntPtr, System.IntPtr)
Microsoft.iOS.dll:ObjCRuntime.Messaging.bool_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
-Microsoft.iOS.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_IntPtr(System.IntPtr, System.IntPtr, System.IntPtr)
-Microsoft.iOS.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
+Microsoft.iOS.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_IntPtr(ObjCRuntime.ObjCSuper*, System.IntPtr, System.IntPtr)
+Microsoft.iOS.dll:ObjCRuntime.Messaging.bool_objc_msgSendSuper_NativeHandle(ObjCRuntime.ObjCSuper*, System.IntPtr, ObjCRuntime.NativeHandle)
Microsoft.iOS.dll:ObjCRuntime.Messaging.CGRect_objc_msgSend(System.IntPtr, System.IntPtr)
Microsoft.iOS.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.iOS.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.iOS.dll:ObjCRuntime.Messaging.IntPtr_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.iOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSend_CGRect(System.IntPtr, System.IntPtr, CoreGraphics.CGRect)
Microsoft.iOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
Microsoft.iOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.iOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.iOS.dll:ObjCRuntime.Messaging.NativeHandle_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.iOS.dll:ObjCRuntime.Messaging.UIntPtr_objc_msgSend(System.IntPtr, System.IntPtr)
-Microsoft.iOS.dll:ObjCRuntime.Messaging.UIntPtr_objc_msgSendSuper(System.IntPtr, System.IntPtr)
+Microsoft.iOS.dll:ObjCRuntime.Messaging.UIntPtr_objc_msgSendSuper(ObjCRuntime.ObjCSuper*, System.IntPtr)
Microsoft.iOS.dll:ObjCRuntime.Messaging.void_objc_msgSend_NativeHandle_NativeHandle_bool(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle, ObjCRuntime.NativeHandle, System.Byte)
Microsoft.iOS.dll:ObjCRuntime.Messaging.void_objc_msgSend_NativeHandle_UIntPtr(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle, System.UIntPtr)
Microsoft.iOS.dll:ObjCRuntime.Messaging.void_objc_msgSend_NativeHandle(System.IntPtr, System.IntPtr, ObjCRuntime.NativeHandle)
@@ -372,7 +370,6 @@ Microsoft.iOS.dll:ObjCRuntime.NativeHandle Foundation.NSObject::class_ptr
Microsoft.iOS.dll:ObjCRuntime.NativeHandle Foundation.NSObject::ClassHandle()
Microsoft.iOS.dll:ObjCRuntime.NativeHandle Foundation.NSObject::handle()
Microsoft.iOS.dll:ObjCRuntime.NativeHandle Foundation.NSObject::Handle()
-Microsoft.iOS.dll:ObjCRuntime.NativeHandle Foundation.NSObject::SuperHandle()
Microsoft.iOS.dll:ObjCRuntime.NativeHandle Foundation.NSObjectData::classHandle
Microsoft.iOS.dll:ObjCRuntime.NativeHandle Foundation.NSObjectData::handle
Microsoft.iOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.Class::handle
@@ -381,6 +378,8 @@ Microsoft.iOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.DisposableObject::handle
Microsoft.iOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.DisposableObject::Handle()
Microsoft.iOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.INativeObject::Handle()
Microsoft.iOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.NativeHandle::Zero
+Microsoft.iOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.ObjCSuper::classHandle
+Microsoft.iOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.ObjCSuper::receiver
Microsoft.iOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.Runtime/ClassHandles::unused
Microsoft.iOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.Selector::handle
Microsoft.iOS.dll:ObjCRuntime.NativeHandle ObjCRuntime.Selector::Handle()
@@ -423,6 +422,8 @@ Microsoft.iOS.dll:ObjCRuntime.ObjCException.get_Name()
Microsoft.iOS.dll:ObjCRuntime.ObjCException.get_NSException()
Microsoft.iOS.dll:ObjCRuntime.ObjCException.get_Reason()
Microsoft.iOS.dll:ObjCRuntime.ObjCException.ToString()
+Microsoft.iOS.dll:ObjCRuntime.ObjCSuper
+Microsoft.iOS.dll:ObjCRuntime.ObjCSuper..ctor(Foundation.NSObject)
Microsoft.iOS.dll:ObjCRuntime.RegistrarHelper
Microsoft.iOS.dll:ObjCRuntime.RegistrarHelper.ConstructINativeObject`1(System.Type, ObjCRuntime.NativeHandle, System.Boolean)
Microsoft.iOS.dll:ObjCRuntime.RegistrarHelper.ConstructNSObject`1(System.Type, ObjCRuntime.NativeHandle)
diff --git a/tests/dotnet/UnitTests/expected/iOS-MonoVM-size.txt b/tests/dotnet/UnitTests/expected/iOS-MonoVM-size.txt
index 34257d903055..12ad8c361f6a 100644
--- a/tests/dotnet/UnitTests/expected/iOS-MonoVM-size.txt
+++ b/tests/dotnet/UnitTests/expected/iOS-MonoVM-size.txt
@@ -1,10 +1,10 @@
-AppBundleSize: 9,338,488 bytes (9,119.6 KB = 8.9 MB)
+AppBundleSize: 9,338,573 bytes (9,119.7 KB = 8.9 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 5,229 bytes (5.1 KB = 0.0 MB)
aot-instances.aotdata.arm64: 827,592 bytes (808.2 KB = 0.8 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,154 bytes (1.1 KB = 0.0 MB)
-Microsoft.iOS.aotdata.arm64: 23,240 bytes (22.7 KB = 0.0 MB)
+Info.plist: 1,143 bytes (1.1 KB = 0.0 MB)
+Microsoft.iOS.aotdata.arm64: 23,336 bytes (22.8 KB = 0.0 MB)
Microsoft.iOS.dll: 48,640 bytes (47.5 KB = 0.0 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,481 bytes (1.4 KB = 0.0 MB)
diff --git a/tests/dotnet/UnitTests/expected/iOS-NativeAOT-TrimmableStatic-size.txt b/tests/dotnet/UnitTests/expected/iOS-NativeAOT-TrimmableStatic-size.txt
index 21809140aee4..c3b634481f8f 100644
--- a/tests/dotnet/UnitTests/expected/iOS-NativeAOT-TrimmableStatic-size.txt
+++ b/tests/dotnet/UnitTests/expected/iOS-NativeAOT-TrimmableStatic-size.txt
@@ -1,8 +1,8 @@
-AppBundleSize: 9,022,567 bytes (8,811.1 KB = 8.6 MB)
+AppBundleSize: 9,072,044 bytes (8,859.4 KB = 8.7 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 2,589 bytes (2.5 KB = 0.0 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,154 bytes (1.1 KB = 0.0 MB)
+Info.plist: 1,143 bytes (1.1 KB = 0.0 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,888 bytes (1.8 KB = 0.0 MB)
-SizeTestApp: 9,016,544 bytes (8,805.2 KB = 8.6 MB)
+SizeTestApp: 9,066,032 bytes (8,853.5 KB = 8.6 MB)
diff --git a/tests/dotnet/UnitTests/expected/iOS-NativeAOT-size.txt b/tests/dotnet/UnitTests/expected/iOS-NativeAOT-size.txt
index 8b40666ad139..12ee378aba96 100644
--- a/tests/dotnet/UnitTests/expected/iOS-NativeAOT-size.txt
+++ b/tests/dotnet/UnitTests/expected/iOS-NativeAOT-size.txt
@@ -1,8 +1,8 @@
-AppBundleSize: 2,783,879 bytes (2,718.6 KB = 2.7 MB)
+AppBundleSize: 2,783,868 bytes (2,718.6 KB = 2.7 MB)
# The following list of files and their sizes is just informational / for review, and isn't used in the test:
_CodeSignature/CodeResources: 2,589 bytes (2.5 KB = 0.0 MB)
archived-expanded-entitlements.xcent: 384 bytes (0.4 KB = 0.0 MB)
-Info.plist: 1,154 bytes (1.1 KB = 0.0 MB)
+Info.plist: 1,143 bytes (1.1 KB = 0.0 MB)
PkgInfo: 8 bytes (0.0 KB = 0.0 MB)
runtimeconfig.bin: 1,808 bytes (1.8 KB = 0.0 MB)
SizeTestApp: 2,777,936 bytes (2,712.8 KB = 2.6 MB)
From 1d20309ee75612368b21451f770e5ec0318e6829 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Mon, 18 May 2026 14:11:56 +0200
Subject: [PATCH 062/156] [docs] Fix broken link in native-library-interop.md
(#25439)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
## Summary
Line 22 of `docs/native-library-interop.md` contained a broken internal link pointing to `build-apps/build-items.md`. The directory `docs/build-apps/` does not exist in the repository; the correct path is `docs/building-apps/build-items.md`.
## Changes
- Fixed the link target on line 22: `build-apps/build-items.md` → `building-apps/build-items.md`
## Verification
- `docs/building-apps/build-items.md` exists in the repo ✅
- The corrected line reads `[build-items](building-apps/build-items.md)` ✅
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
docs/native-library-interop.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/native-library-interop.md b/docs/native-library-interop.md
index dec4a772645c..50d7481a56ee 100644
--- a/docs/native-library-interop.md
+++ b/docs/native-library-interop.md
@@ -19,7 +19,7 @@ the build process will attempt to create an XCFramework from the specified Xcode
output will be added as a `@(NativeReference)` to the .NET project so that it can be bound and have its
API surfaced via an [API definition][0] file.
-Please see the [build-items](build-apps/build-items.md) docs for more information about
+Please see the [build-items](building-apps/build-items.md) docs for more information about
the `@(XcodeProject)` build action.
Additional documentation and references can be found below:
From c91db64125940b2fe14f0e2a2ec62226b88e8207 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Mon, 18 May 2026 14:12:18 +0200
Subject: [PATCH 063/156] [tests] Upgrade tests/introspection to NUnit v4
Assert.That syntax (#25442)
Convert classic NUnit assertions to NUnit v4's constraint-based
Assert.That syntax in the introspection test project.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
tests/introspection/ApiBaseTest.cs | 2 +-
tests/introspection/ApiCMAttachmentTest.cs | 10 +++++-----
tests/introspection/ApiClassPtrTest.cs | 4 ++--
tests/introspection/ApiCoreImageFiltersTest.cs | 8 ++++----
tests/introspection/ApiCtorInitTest.cs | 8 ++++----
tests/introspection/ApiFieldTest.cs | 6 +++---
tests/introspection/ApiPInvokeTest.cs | 4 ++--
tests/introspection/ApiProtocolTest.cs | 14 +++++++-------
tests/introspection/ApiSelectorTest.cs | 6 +++---
tests/introspection/ApiSignatureTest.cs | 2 +-
tests/introspection/ApiStructTest.cs | 4 +---
tests/introspection/ApiTypoTest.cs | 11 ++++++-----
tests/introspection/ApiWeakPropertyTest.cs | 2 +-
13 files changed, 40 insertions(+), 41 deletions(-)
diff --git a/tests/introspection/ApiBaseTest.cs b/tests/introspection/ApiBaseTest.cs
index 66122f4b2326..2c59f52b1ae3 100644
--- a/tests/introspection/ApiBaseTest.cs
+++ b/tests/introspection/ApiBaseTest.cs
@@ -109,7 +109,7 @@ protected TextWriter Writer {
protected void ReportError (string s, params object? [] parameters)
{
if (!ContinueOnFailure)
- Assert.Fail (s, parameters);
+ Assert.Fail (string.Format (s, parameters));
else {
Writer.Write ("[FAIL] ");
Writer.WriteLine (s, parameters);
diff --git a/tests/introspection/ApiCMAttachmentTest.cs b/tests/introspection/ApiCMAttachmentTest.cs
index a375ad550856..b8d243321409 100644
--- a/tests/introspection/ApiCMAttachmentTest.cs
+++ b/tests/introspection/ApiCMAttachmentTest.cs
@@ -548,9 +548,9 @@ public void CheckAttachments ()
obj.SetAttachment ("key", attch, CMAttachmentMode.ShouldNotPropagate);
using (var otherAttch = obj.GetAttachment ("key", out otherMode)!) {
obj.RemoveAllAttachments ();
- Assert.AreEqual (mode, otherMode);
- Assert.IsNotNull (otherAttch, "For type {0}", t.Name);
- Assert.AreEqual (attch.ToString (), otherAttch.ToString (), "For type {0}", t.Name);
+ Assert.That (otherMode, Is.EqualTo (mode));
+ Assert.That (otherAttch, Is.Not.Null, $"For type {t.Name}");
+ Assert.That (otherAttch.ToString (), Is.EqualTo (attch.ToString ()), "For type {0}", t.Name);
}
}
if (obj is IDisposable disp) {
@@ -575,7 +575,7 @@ public void CheckFailAttachments ()
continue;
var n = GetINativeInstance (t);
if (n is null)
- Assert.Fail ("Could not create instance of '{0}'.", t);
+ Assert.Fail ($"Could not create instance of '{t}'.");
var obj = new AttachableNativeObject (n!);
Assert.That (obj.Handle, Is.Not.EqualTo (IntPtr.Zero), t.Name + ".Handle");
using (var attch = new CFString ("myAttch")) {
@@ -583,7 +583,7 @@ public void CheckFailAttachments ()
obj.SetAttachment ("key", attch, CMAttachmentMode.ShouldNotPropagate);
using (var otherAttch = obj.GetAttachment ("key", out otherMode)) {
obj.RemoveAllAttachments ();
- Assert.Null (otherAttch, "For type {0}", t.Name);
+ Assert.That (otherAttch, Is.Null, $"For type {t.Name}");
}
}
if (t is IDisposable disp) {
diff --git a/tests/introspection/ApiClassPtrTest.cs b/tests/introspection/ApiClassPtrTest.cs
index bace683cfc92..2a718408526d 100644
--- a/tests/introspection/ApiClassPtrTest.cs
+++ b/tests/introspection/ApiClassPtrTest.cs
@@ -81,7 +81,7 @@ public void VerifyClassPtr ()
IntPtr class_ptr = (IntPtr) (NativeHandle) fi.GetValue (null)!;
IntPtr register_class_ptr = GetClassPtrFromRegister (t);
- Assert.AreEqual (class_ptr, register_class_ptr, "class_ptr and RegisterAttribute are different: " + t.Name);
+ Assert.That (register_class_ptr, Is.EqualTo (class_ptr), "class_ptr and RegisterAttribute are different: " + t.Name);
}
}
@@ -104,7 +104,7 @@ public void VerifyClassPtrCategories ()
else
extended_class_ptr = GetClassPtrFromRegister (extendedType);
- Assert.AreEqual (class_ptr, extended_class_ptr, "class_ptr and RegisterAttribute from extended class are different: " + t.Name);
+ Assert.That (extended_class_ptr, Is.EqualTo (class_ptr), "class_ptr and RegisterAttribute from extended class are different: " + t.Name);
}
}
}
diff --git a/tests/introspection/ApiCoreImageFiltersTest.cs b/tests/introspection/ApiCoreImageFiltersTest.cs
index 0915d646eabf..a7f7114ff9fe 100644
--- a/tests/introspection/ApiCoreImageFiltersTest.cs
+++ b/tests/introspection/ApiCoreImageFiltersTest.cs
@@ -98,7 +98,7 @@ public void CheckNativeFilters ()
}
n++;
}
- Assert.That (filters.Count, Is.EqualTo (0), "{0} native filters missing: {1}", filters.Count, String.Join (", ", filters));
+ Assert.That (filters.Count, Is.EqualTo (0), $"{filters.Count} native filters missing: {String.Join (", ", filters)}");
}
[Test]
@@ -149,7 +149,7 @@ public void CheckManagedFilters ()
if (Skip (filters [i]))
filters.RemoveAt (i);
}
- Assert.That (filters.Count, Is.EqualTo (0), "Managed filters not found for {0}", String.Join (", ", filters));
+ Assert.That (filters.Count, Is.EqualTo (0), $"Managed filters not found for {String.Join (", ", filters)}");
}
static void GenerateBinding (NSObject filter, TextWriter writer)
@@ -366,7 +366,7 @@ public void Protocols ()
if (to_confirm_manually.Length > 0) {
Console.WriteLine (to_confirm_manually);
}
- Assert.AreEqual (0, Errors, "{0} potential errors found{1}", Errors, Errors == 0 ? string.Empty : ":\n" + ErrorData.ToString () + "\n");
+ Assert.That (Errors, Is.EqualTo (0), $"{Errors} potential errors found:\n{ErrorData}\n");
}
[Test]
@@ -535,7 +535,7 @@ public void Keys ()
ReportError ($"{t.Name}: Property `{po.Name}` should NOT have a setter.");
}
}
- Assert.AreEqual (0, Errors, "{0} potential errors found{1}", Errors, Errors == 0 ? string.Empty : ":\n" + ErrorData.ToString () + "\n");
+ Assert.That (Errors, Is.EqualTo (0), $"{Errors} potential errors found:\n{ErrorData}\n");
}
}
}
diff --git a/tests/introspection/ApiCtorInitTest.cs b/tests/introspection/ApiCtorInitTest.cs
index bbfe6aef1e44..2d218ec6ae11 100644
--- a/tests/introspection/ApiCtorInitTest.cs
+++ b/tests/introspection/ApiCtorInitTest.cs
@@ -319,7 +319,7 @@ public void DefaultCtorAllowed ()
}
n++;
}
- Assert.AreEqual (0, Errors, "{0} potential errors found in {1} default ctor validated{2}", Errors, n, Errors == 0 ? string.Empty : ":\n" + ErrorData.ToString () + "\n");
+ Assert.That (Errors, Is.EqualTo (0), $"{Errors} potential errors found in {n} default ctor validated:\n{ErrorData}\n");
}
// .NET constructors are not virtual, so we need to re-expose the base class .ctor when a subclass is created.
@@ -371,7 +371,7 @@ public void DesignatedInitializer ()
n++;
}
}
- Assert.AreEqual (0, Errors, "{0} potential errors found in {1} designated initializer validated", Errors, n);
+ Assert.That (Errors, Is.EqualTo (0), $"{Errors} potential errors found in {n} designated initializer validated");
}
protected virtual bool Match (ConstructorInfo ctor, Type type)
@@ -639,7 +639,7 @@ public void ShouldNotExposeDefaultCtorTest ()
}
n++;
}
- Assert.AreEqual (0, Errors, $"{Errors} potential errors found in {n} BaseType empty ctor validated: \n{ErrorData}\n{(genObjCTestCode ? $"\n\n{objCCode}\n" : string.Empty)}");
+ Assert.That (Errors, Is.EqualTo (0), $"{Errors} potential errors found in {n} BaseType empty ctor validated: \n{ErrorData}\n{(genObjCTestCode ? $"\n\n{objCCode}\n" : string.Empty)}");
}
protected virtual bool SkipCheckShouldNotExposeDefaultCtor (Type type)
@@ -681,7 +681,7 @@ public void ARAnchorCopyingCtorTest ()
ReportError ("{0} should re-expose IARAnchorCopying::.ctor(ARAnchor)", t);
}
- Assert.AreEqual (0, Errors, "{0} potential errors found when validating if subclasses of 'ARAnchor' re-expose 'IARAnchorCopying' constructor", Errors);
+ Assert.That (Errors, Is.EqualTo (0), $"{Errors} potential errors found when validating if subclasses of 'ARAnchor' re-expose 'IARAnchorCopying' constructor");
}
#endif
}
diff --git a/tests/introspection/ApiFieldTest.cs b/tests/introspection/ApiFieldTest.cs
index d850e49a0669..1c2ffebdc05d 100644
--- a/tests/introspection/ApiFieldTest.cs
+++ b/tests/introspection/ApiFieldTest.cs
@@ -200,7 +200,7 @@ public void Notifications ()
}
n++;
}
- Assert.AreEqual (0, Errors, "{0} errors found in {1} fields validated: {2}", Errors, n, string.Join (", ", failed_fields));
+ Assert.That (Errors, Is.EqualTo (0), $"{Errors} errors found in {n} fields validated: {string.Join (", ", failed_fields)}");
}
[Test]
@@ -225,7 +225,7 @@ public void NonNullNSStringFields ()
}
n++;
}
- Assert.AreEqual (0, Errors, "{0} errors found in {1} fields validated: {2}", Errors, n, string.Join (", ", failed_fields));
+ Assert.That (Errors, Is.EqualTo (0), $"{Errors} errors found in {n} fields validated: {string.Join (", ", failed_fields)}");
}
[Test]
@@ -264,7 +264,7 @@ public void FieldExists ()
Dlfcn.dlclose (lib);
n++;
}
- Assert.AreEqual (0, Errors, "{0} errors found in {1} fields validated: {2}", Errors, n, string.Join (", ", failed_fields));
+ Assert.That (Errors, Is.EqualTo (0), $"{Errors} errors found in {n} fields validated: {string.Join (", ", failed_fields)}");
}
}
}
diff --git a/tests/introspection/ApiPInvokeTest.cs b/tests/introspection/ApiPInvokeTest.cs
index 9407f80b3fb8..65d216667185 100644
--- a/tests/introspection/ApiPInvokeTest.cs
+++ b/tests/introspection/ApiPInvokeTest.cs
@@ -176,7 +176,7 @@ public void SymbolExists ()
Dlfcn.dlclose (lib);
n++;
}
- Assert.AreEqual (0, Errors, "{0} errors found in {1} functions validated: {2}", Errors, n, string.Join (", ", failed_api));
+ Assert.That (Errors, Is.EqualTo (0), $"{Errors} errors found in {n} functions validated: {string.Join (", ", failed_api)}");
}
bool SkipDueToDeviceCapabilities (Type type)
@@ -282,7 +282,7 @@ protected void Check (Assembly a)
n++;
}
}
- Assert.AreEqual (0, Errors, "{0} errors found in {1} symbol lookups{2}", Errors, n, Errors == 0 ? string.Empty : ":\n" + ErrorData.ToString () + "\n");
+ Assert.That (Errors, Is.EqualTo (0), $"{Errors} errors found in {n} symbol lookups:\n{ErrorData}\n");
}
protected string ResolveLibrarySymlinks (string path)
diff --git a/tests/introspection/ApiProtocolTest.cs b/tests/introspection/ApiProtocolTest.cs
index e4b65416d49f..e556f72676a2 100644
--- a/tests/introspection/ApiProtocolTest.cs
+++ b/tests/introspection/ApiProtocolTest.cs
@@ -846,7 +846,7 @@ protected virtual bool Skip (Type type, string protocolName)
void CheckProtocol (string protocolName, Action action)
{
IntPtr protocol = Runtime.GetProtocol (protocolName);
- Assert.AreNotEqual (protocol, IntPtr.Zero, protocolName);
+ Assert.That (IntPtr.Zero, Is.Not.EqualTo (protocol), protocolName);
int n = 0;
foreach (Type t in Assembly.GetTypes ()) {
@@ -881,7 +881,7 @@ public void Coding ()
// FIXME: and implement the .ctor(NSCoder)
}
});
- Assert.AreEqual (Errors, 0, "{0} types conforms to NSCoding but does not implement INSCoding: {1}", Errors, String.Join ('\n', list));
+ Assert.That (0, Is.EqualTo (Errors), $"{Errors} types conforms to NSCoding but does not implement INSCoding: {String.Join ('\n', list)}");
}
// [Test] -> iOS 6.0+ and Mountain Lion (10.8) +
@@ -898,7 +898,7 @@ public virtual void SecureCoding ()
}
}
});
- Assert.AreEqual (Errors, 0, "{0} types conforms to NSSecureCoding but does not implement INSSecureCoding: {1}", Errors, String.Join ('\n', list));
+ Assert.That (0, Is.EqualTo (Errors), $"{Errors} types conforms to NSSecureCoding but does not implement INSSecureCoding: {String.Join ('\n', list)}");
}
bool SupportsSecureCoding (Type type)
@@ -941,11 +941,11 @@ public virtual void SupportsSecureCoding ()
} else if (type.IsPublic && supports) {
// there are internal types, e.g. DataWrapper : NSData, that subclass NSSecureCoding-types without
// [re-]declaring their allegiance - but we can live with those small betrayals
- Assert.IsFalse (NSSecureCoding.SupportsSecureCoding (type), "{0} !SupportsSecureCoding", type.Name);
+ Assert.That (NSSecureCoding.SupportsSecureCoding (type), Is.False, $"{type.Name} !SupportsSecureCoding");
ReportError ("SupportsSecureCoding returns true but {0} does not conforms to NSSecureCoding", type.Name);
}
});
- Assert.AreEqual (Errors, 0, "{0} types conforms to NSCoding but does not implement INSSecureCoding", Errors);
+ Assert.That (0, Is.EqualTo (Errors), $"{Errors} types conforms to NSCoding but does not implement INSSecureCoding");
}
[Test]
@@ -964,7 +964,7 @@ public void Copying ()
}
}
});
- Assert.AreEqual (Errors, 0, "{0} types conforms to NSCopying but does not implement INSCopying: {1}", Errors, String.Join ('\n', list));
+ Assert.That (0, Is.EqualTo (Errors), $"{Errors} types conforms to NSCopying but does not implement INSCopying: {String.Join ('\n', list)}");
}
[Test]
@@ -983,7 +983,7 @@ public void MutableCopying ()
}
}
});
- Assert.AreEqual (Errors, 0, "{0} types conforms to NSMutableCopying but does not implement INSMutableCopying: {1}", Errors, String.Join ('\n', list));
+ Assert.That (0, Is.EqualTo (Errors), $"{Errors} types conforms to NSMutableCopying but does not implement INSMutableCopying: {String.Join ('\n', list)}");
}
[Test]
diff --git a/tests/introspection/ApiSelectorTest.cs b/tests/introspection/ApiSelectorTest.cs
index 2f089ffa2ad3..d22c7b8829d2 100644
--- a/tests/introspection/ApiSelectorTest.cs
+++ b/tests/introspection/ApiSelectorTest.cs
@@ -1398,7 +1398,7 @@ public void Protocols ()
}
}
}
- Assert.AreEqual (0, Errors, "{0} errors found in {1} protocol selectors validated", Errors, n);
+ Assert.That (Errors, Is.EqualTo (0), $"{Errors} errors found in {n} protocol selectors validated");
}
void ProcessProtocolMember (Type t, MethodBase m, ref int n)
@@ -1465,7 +1465,7 @@ public void InstanceMethods ()
Process (class_ptr, t, m, ref n);
}
}
- Assert.AreEqual (0, Errors, "{0} errors found in {1} instance selector validated{2}", Errors, n, Errors == 0 ? string.Empty : ":\n" + ErrorData.ToString () + "\n");
+ Assert.That (Errors, Is.EqualTo (0), $"{Errors} errors found in {n} instance selector validated:\n{ErrorData}\n");
}
void Process (IntPtr class_ptr, Type t, MethodBase m, ref int n)
@@ -1573,7 +1573,7 @@ public void StaticMethods ()
}
}
}
- Assert.AreEqual (0, Errors, "{0} errors found in {1} static selector validated{2}", Errors, n, Errors == 0 ? string.Empty : ":\n" + ErrorData.ToString () + "\n");
+ Assert.That (Errors, Is.EqualTo (0), $"{Errors} errors found in {n} static selector validated:\n{ErrorData}\n");
}
}
}
diff --git a/tests/introspection/ApiSignatureTest.cs b/tests/introspection/ApiSignatureTest.cs
index 4d88583eb5cf..d9c1fa6bd2b5 100644
--- a/tests/introspection/ApiSignatureTest.cs
+++ b/tests/introspection/ApiSignatureTest.cs
@@ -57,7 +57,7 @@ public abstract class ApiSignatureTest : ApiBaseTest {
if (encoded [end] != '@' || encoded [end + 1] != '0' || encoded [end + 2] != ':') {
if (!ContinueOnFailure)
- Assert.Fail ("Unexpected format, missing '@0:', inside '{0}'", encoded);
+ Assert.Fail ($"Unexpected format, missing '@0:', inside '{encoded}'");
return null;
}
diff --git a/tests/introspection/ApiStructTest.cs b/tests/introspection/ApiStructTest.cs
index cc71f137b548..5106fe6ebd68 100644
--- a/tests/introspection/ApiStructTest.cs
+++ b/tests/introspection/ApiStructTest.cs
@@ -44,9 +44,7 @@ public void Structs ()
}
}
- Assert.AreEqual (0, totalErrors,
- "{0} errors found in {1} structures validated",
- totalErrors, totalStructs);
+ Assert.That (totalErrors, Is.EqualTo (0), $"{totalErrors} errors found in {totalStructs} structures validated");
}
protected virtual bool CheckStruct (Type type)
diff --git a/tests/introspection/ApiTypoTest.cs b/tests/introspection/ApiTypoTest.cs
index a42f62aa4141..8bbd6384e879 100644
--- a/tests/introspection/ApiTypoTest.cs
+++ b/tests/introspection/ApiTypoTest.cs
@@ -579,6 +579,7 @@ public virtual bool Skip (MemberInfo methodName, string typo)
{ "Polylines", All },
{ "Popularimeter", All },
{ "Postback", ApplePlatform.iOS | ApplePlatform.MacCatalyst },
+ { "Ppd", ApplePlatform.MacOSX }, // PostScript Printer Description
{ "Ppk", All },
{ "Preauthentication", ApplePlatform.MacOSX },
{ "Preds", All },
@@ -843,7 +844,7 @@ public virtual void AttributeTypoTest ()
foreach (Type t in types)
AttributeTypo (t, ref totalErrors);
- Assert.AreEqual (0, totalErrors, "Attributes have typos!");
+ Assert.That (totalErrors, Is.EqualTo (0), "Attributes have typos!");
}
void AttributeTypo (Type t, ref int totalErrors)
@@ -951,7 +952,7 @@ public virtual void TypoTest ()
ReportError ($"Unnecessary allowed typo \"{typo}\" is not present in any API name");
totalErrors++;
}
- Assert.AreEqual (0, totalErrors, "Typos!");
+ Assert.That (totalErrors, Is.EqualTo (0), "Typos!");
}
string? GetMessage (object attribute)
@@ -1137,7 +1138,7 @@ public void ConstantsCheck ()
switch (fi.Name) {
case "Version":
case "SdkVersion":
- Assert.True (Version.TryParse (s, out _), fi.Name);
+ Assert.That (Version.TryParse (s, out _), Is.True, fi.Name);
break;
#if !XAMCORE_5_0
case "AssetsLibraryLibrary":
@@ -1151,7 +1152,7 @@ public void ConstantsCheck ()
case "MLComputeLibrary":
// Xcode 12 beta 2 does not ship these framework/headers for the simulators
if (TestRuntime.IsDevice)
- Assert.True (CheckLibrary (s), fi.Name);
+ Assert.That (CheckLibrary (s), Is.True, fi.Name);
break;
#endif
#if __TVOS__
@@ -1190,7 +1191,7 @@ public void ConstantsCheck ()
if (fi.Name == "AutomaticAssessmentConfigurationLibrary" && !TestRuntime.CheckXcodeVersion (11, 4))
continue;
#endif
- Assert.True (CheckLibrary (s), fi.Name);
+ Assert.That (CheckLibrary (s), Is.True, fi.Name);
} else {
Assert.Fail ($"Unknown '{fi.Name}' field cannot be verified - please fix me!");
}
diff --git a/tests/introspection/ApiWeakPropertyTest.cs b/tests/introspection/ApiWeakPropertyTest.cs
index e11770ba8dbb..da5e64d5025b 100644
--- a/tests/introspection/ApiWeakPropertyTest.cs
+++ b/tests/introspection/ApiWeakPropertyTest.cs
@@ -102,7 +102,7 @@ public void WeakPropertiesHaveArgumentSemantic ()
n++;
}
}
- Assert.AreEqual (0, Errors, "{0} errors found in {1} fields validated: {2}", Errors, n, string.Join (", ", failed_properties));
+ Assert.That (Errors, Is.EqualTo (0), $"{Errors} errors found in {n} fields validated: {string.Join (", ", failed_properties)}");
}
bool CheckArgumentSemantic (MethodInfo meth, [NotNullWhen (true)] out string? error)
From 1ac68e47b96640807c449d45bc9b19113cc26295 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Mon, 18 May 2026 15:11:36 +0200
Subject: [PATCH 064/156] Delete old NuGet.config feeds. (#25449)
---
NuGet.config | 12 ------------
1 file changed, 12 deletions(-)
diff --git a/NuGet.config b/NuGet.config
index d9588597df42..039e15e88514 100644
--- a/NuGet.config
+++ b/NuGet.config
@@ -34,18 +34,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
From 78aab6d3e09b621d79fa686fe956ab2a61a9ed84 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Mon, 18 May 2026 18:29:17 +0200
Subject: [PATCH 065/156] Fix docs/bindas.md links pointing to personal fork
instead of dotnet/macios (#25441)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
All 11 numbered code reference links in `docs/bindas.md` (links [1]–[7], [9]–[12]) pointed to a personal fork (`rolfbjarne/xamarin-macios`) at a specific commit SHA. These links are not guaranteed to remain accessible. Link [8] (a PR link) was already correct.
This PR updates all 11 links to use canonical `dotnet/macios` permalinks with the current main branch SHA (`18a22fd`), with corrected line numbers matching the current state of the codebase.
### Changes
- **Base URL**: `rolfbjarne/xamarin-macios/blob/b38c114f…` → `dotnet/macios/blob/18a22fd0…`
- **Links [11]/[12]**: path corrected from `src/generator.cs` → `src/bgen/Generator.cs` (file was renamed)
- **All line numbers**: updated to match the current tree (e.g., `testgenerator.cs#L100` → `#L125`, `Registrar.cs#L687` → `#L794`)
### Verification
All 11 updated URLs return HTTP 200. This is a documentation-only change with no code impact.
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
docs/bindas.md | 34 +++++++++++++++++-----------------
1 file changed, 17 insertions(+), 17 deletions(-)
diff --git a/docs/bindas.md b/docs/bindas.md
index 27c7a5ef8130..6ef355d08bd7 100644
--- a/docs/bindas.md
+++ b/docs/bindas.md
@@ -23,16 +23,16 @@ The sample code is to support a new type for NSValue, the exact code locations w
code this is the two functions to convert between NSValue and
NSDirectionalEdgeInsets:
- `xamarin_nsdirectionaledgeinsets_to_nsvalue`: [trampolines.h#151][2], [trampolines.m#889][3]
- `xamarin_nsvalue_to_nsdirectionaledgeinsets`: [trampolines.h#116][4], [trampolines.m#799][5]
+ `xamarin_nsdirectionaledgeinsets_to_nsvalue`: [trampolines.h#197][2], [trampolines.m#1252][3]
+ `xamarin_nsvalue_to_nsdirectionaledgeinsets`: [trampolines.h#161][4], [trampolines.m#1192][5]
-3. Add a switch entry to [trampolines.m#1007][6] to use the two new conversion functions.
+3. Add a switch entry to [trampolines.m#1601][6] to use the two new conversion functions.
-4. The registrar also needs to know ([Registrar.cs#687][7]).
+4. The registrar also needs to know ([Registrar.cs#794][7]).
-5. And the static registrar needs to know too, so that it can call the right native conversion function ([StaticRegistrar.cs#3796][9], [StaticRegistrar.cs#3830][10]).
+5. And the static registrar needs to know too, so that it can call the right native conversion function ([StaticRegistrar.cs#4896][9], [StaticRegistrar.cs#4925][10]).
-6. Now there's just the generator support left ([generator.cs#1223][11], [generator.cs#1369][12]).
+6. Now there's just the generator support left ([Generator.cs#390][11], [Generator.cs#470][12]).
7. Finally run the following tests (at least)
@@ -40,15 +40,15 @@ The sample code is to support a new type for NSValue, the exact code locations w
* link all on both simulator and device.
-[1]: https://github.com/rolfbjarne/xamarin-macios/blob/b38c114fbe8c9d229ec41a312dc36802cb4f027e/tests/test-libraries/testgenerator.cs#L100
-[2]: https://github.com/rolfbjarne/xamarin-macios/blob/b38c114fbe8c9d229ec41a312dc36802cb4f027e/runtime/xamarin/trampolines.h#L151
-[3]: https://github.com/rolfbjarne/xamarin-macios/blob/b38c114fbe8c9d229ec41a312dc36802cb4f027e/runtime/trampolines.m#L889
-[4]: https://github.com/rolfbjarne/xamarin-macios/blob/b38c114fbe8c9d229ec41a312dc36802cb4f027e/runtime/xamarin/trampolines.h#L116
-[5]: https://github.com/rolfbjarne/xamarin-macios/blob/b38c114fbe8c9d229ec41a312dc36802cb4f027e/runtime/trampolines.m#L799
-[6]: https://github.com/rolfbjarne/xamarin-macios/blob/b38c114fbe8c9d229ec41a312dc36802cb4f027e/runtime/trampolines.m#L1007-L1008
-[7]: https://github.com/rolfbjarne/xamarin-macios/blob/b38c114fbe8c9d229ec41a312dc36802cb4f027e/src/ObjCRuntime/Registrar.cs#L687
+[1]: https://github.com/dotnet/macios/blob/18a22fd0812016cfdc8397d9b70981a1fc365fed/tests/test-libraries/testgenerator.cs#L125
+[2]: https://github.com/dotnet/macios/blob/18a22fd0812016cfdc8397d9b70981a1fc365fed/runtime/xamarin/trampolines.h#L197
+[3]: https://github.com/dotnet/macios/blob/18a22fd0812016cfdc8397d9b70981a1fc365fed/runtime/trampolines.m#L1252
+[4]: https://github.com/dotnet/macios/blob/18a22fd0812016cfdc8397d9b70981a1fc365fed/runtime/xamarin/trampolines.h#L161
+[5]: https://github.com/dotnet/macios/blob/18a22fd0812016cfdc8397d9b70981a1fc365fed/runtime/trampolines.m#L1192
+[6]: https://github.com/dotnet/macios/blob/18a22fd0812016cfdc8397d9b70981a1fc365fed/runtime/trampolines.m#L1601-L1602
+[7]: https://github.com/dotnet/macios/blob/18a22fd0812016cfdc8397d9b70981a1fc365fed/src/ObjCRuntime/Registrar.cs#L794
[8]: https://github.com/dotnet/macios/pull/2288/commits/b38c114fbe8c9d229ec41a312dc36802cb4f027e
-[9]: https://github.com/rolfbjarne/xamarin-macios/blob/b38c114fbe8c9d229ec41a312dc36802cb4f027e/tools/common/StaticRegistrar.cs#L3796
-[10]: https://github.com/rolfbjarne/xamarin-macios/blob/b38c114fbe8c9d229ec41a312dc36802cb4f027e/tools/common/StaticRegistrar.cs#L3830
-[11]: https://github.com/rolfbjarne/xamarin-macios/blob/b38c114fbe8c9d229ec41a312dc36802cb4f027e/src/generator.cs#L1223
-[12]: https://github.com/rolfbjarne/xamarin-macios/blob/b38c114fbe8c9d229ec41a312dc36802cb4f027e/src/generator.cs#L1369
+[9]: https://github.com/dotnet/macios/blob/18a22fd0812016cfdc8397d9b70981a1fc365fed/tools/common/StaticRegistrar.cs#L4896
+[10]: https://github.com/dotnet/macios/blob/18a22fd0812016cfdc8397d9b70981a1fc365fed/tools/common/StaticRegistrar.cs#L4925
+[11]: https://github.com/dotnet/macios/blob/18a22fd0812016cfdc8397d9b70981a1fc365fed/src/bgen/Generator.cs#L390
+[12]: https://github.com/dotnet/macios/blob/18a22fd0812016cfdc8397d9b70981a1fc365fed/src/bgen/Generator.cs#L470
From 3d651416d3bc96260fe9b288f76ca8b60fbd775f Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Mon, 18 May 2026 18:40:54 +0200
Subject: [PATCH 066/156] [tests] Fix flaky
NSPasteboardTests.DetectMetadataTests on macOS (#25450)
The DetectMetadata tests were flaky because the macOS pasteboard subsystem may not have fully analyzed content metadata by the time DetectMetadata is called immediately after SetStringForType. The callback would be invoked but return an empty dictionary.
Fix by:
- Adding retry logic (up to 5 attempts with 500ms delays) for the '#2' detection case where we expect results after writing content
- Increasing WaitOne timeouts from 1s to 10s for CI under load
Fixes https://github.com/dotnet/macios/issues/25446
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Rolf Bjarne Kvinge
---
tests/monotouch-test/AppKit/NSPasteboard.cs | 69 ++++++++++++++-------
1 file changed, 45 insertions(+), 24 deletions(-)
diff --git a/tests/monotouch-test/AppKit/NSPasteboard.cs b/tests/monotouch-test/AppKit/NSPasteboard.cs
index 1e8bcc02bf39..cdfe371a71eb 100644
--- a/tests/monotouch-test/AppKit/NSPasteboard.cs
+++ b/tests/monotouch-test/AppKit/NSPasteboard.cs
@@ -349,19 +349,26 @@ public void DetectMetadataTests_WeaklyTyped ()
detected = null;
error = null;
pasteboard.DetectMetadata (hashSet, callback);
- Assert.That (evt.WaitOne (TimeSpan.FromSeconds (1)), "WeaklyTyped DetectMetadata #1 wait");
+ Assert.That (evt.WaitOne (TimeSpan.FromSeconds (10)), "WeaklyTyped DetectMetadata #1 wait");
Assert.That (detected, Is.Not.Null, "WeaklyTyped DetectMetadata #1 patterns");
Assert.That ((int) detected.Count, Is.EqualTo (0), "WeaklyTyped DetectMetadata #1 count");
Assert.That (error, Is.Null, "WeaklyTyped DetectMetadata #1 error");
pasteboard.ClearContents ();
pasteboard.SetStringForType ("file:///this/is/some/file.html", NSPasteboardType.FileUrl.GetConstant ());
- evt.Reset ();
- detected = null;
- error = null;
- pasteboard.DetectMetadata (hashSet, callback);
- Assert.That (evt.WaitOne (TimeSpan.FromSeconds (1)), "WeaklyTyped DetectMetadata #2 wait");
- Assert.That (detected, Is.Not.Null, "WeaklyTyped DetectMetadata #2 patterns");
+ // The pasteboard subsystem may need time to analyze content metadata,
+ // so retry detection if it returns empty results.
+ for (int attempt = 0; attempt < 5; attempt++) {
+ evt.Reset ();
+ detected = null;
+ error = null;
+ pasteboard.DetectMetadata (hashSet, callback);
+ Assert.That (evt.WaitOne (TimeSpan.FromSeconds (10)), "WeaklyTyped DetectMetadata #2 wait");
+ Assert.That (detected, Is.Not.Null, "WeaklyTyped DetectMetadata #2 patterns");
+ if ((int) detected.Count > 0)
+ break;
+ Thread.Sleep (500);
+ }
Assert.That ((int) detected.Count, Is.EqualTo (1), "WeaklyTyped DetectMetadata #2 count");
Assert.That (detected.Keys.First ().ToString (), Does.Contain (NSPasteboardMetadataType.ContentType.GetConstant ().ToString ()), "WeaklyTyped DetectMetadata #2 email");
Assert.That (detected.Values.First ().ToString (), Does.Contain ("public.html"), "WeaklyTyped DetectMetadata #2 value");
@@ -375,7 +382,7 @@ public void DetectMetadataTests_WeaklyTyped ()
detected = null;
error = null;
pasteboard.DetectMetadata (hashSet, callback);
- Assert.That (evt.WaitOne (TimeSpan.FromSeconds (1)), "WeaklyTyped DetectMetadata #3 wait");
+ Assert.That (evt.WaitOne (TimeSpan.FromSeconds (10)), "WeaklyTyped DetectMetadata #3 wait");
Assert.That (detected, Is.Not.Null, "WeaklyTyped DetectMetadata #3 patterns");
Assert.That ((int) detected.Count, Is.EqualTo (0), "WeaklyTyped DetectMetadata #3 count");
Assert.That (error, Is.Not.Null, "WeaklyTyped DetectMetadata #3 error");
@@ -406,19 +413,26 @@ public void DetectMetadataTests_SomewhatStronglyTyped ()
detected = null;
error = null;
pasteboard.DetectMetadata (hashSet, callback);
- Assert.That (evt.WaitOne (TimeSpan.FromSeconds (1)), "SomewhatStronglyTyped DetectMetadata #1 wait");
+ Assert.That (evt.WaitOne (TimeSpan.FromSeconds (10)), "SomewhatStronglyTyped DetectMetadata #1 wait");
Assert.That (detected, Is.Not.Null, "SomewhatStronglyTyped DetectMetadata #1 patterns");
Assert.That ((int) detected.Count, Is.EqualTo (0), "SomewhatStronglyTyped DetectMetadata #1 count");
Assert.That (error, Is.Null, "SomewhatStronglyTyped DetectMetadata #1 error");
pasteboard.ClearContents ();
pasteboard.SetStringForType ("file:///this/is/some/file.html", NSPasteboardType.FileUrl.GetConstant ());
- evt.Reset ();
- detected = null;
- error = null;
- pasteboard.DetectMetadata (hashSet, callback);
- Assert.That (evt.WaitOne (TimeSpan.FromSeconds (1)), "SomewhatStronglyTyped DetectMetadata #2 wait");
- Assert.That (detected, Is.Not.Null, "SomewhatStronglyTyped DetectMetadata #2 patterns");
+ // The pasteboard subsystem may need time to analyze content metadata,
+ // so retry detection if it returns empty results.
+ for (int attempt = 0; attempt < 5; attempt++) {
+ evt.Reset ();
+ detected = null;
+ error = null;
+ pasteboard.DetectMetadata (hashSet, callback);
+ Assert.That (evt.WaitOne (TimeSpan.FromSeconds (10)), "SomewhatStronglyTyped DetectMetadata #2 wait");
+ Assert.That (detected, Is.Not.Null, "SomewhatStronglyTyped DetectMetadata #2 patterns");
+ if ((int) detected.Count > 0)
+ break;
+ Thread.Sleep (500);
+ }
Assert.That ((int) detected.Count, Is.EqualTo (1), "SomewhatStronglyTyped DetectMetadata #2 count");
Assert.That (detected.Keys.First ().ToString (), Does.Contain (NSPasteboardMetadataType.ContentType.GetConstant ().ToString ()), "SomewhatStronglyTyped DetectMetadata #2 contenttype");
Assert.That (detected.Values.First ().ToString (), Does.Contain ("public.html"), "SomewhatStronglyTyped DetectMetadata #2 value");
@@ -432,7 +446,7 @@ public void DetectMetadataTests_SomewhatStronglyTyped ()
detected = null;
error = null;
pasteboard.DetectMetadata (hashSet, callback);
- Assert.That (evt.WaitOne (TimeSpan.FromSeconds (1)), "SomewhatStronglyTyped DetectMetadata #3 wait");
+ Assert.That (evt.WaitOne (TimeSpan.FromSeconds (10)), "SomewhatStronglyTyped DetectMetadata #3 wait");
Assert.That (detected, Is.Not.Null, "SomewhatStronglyTyped DetectMetadata #3 patterns");
Assert.That ((int) detected.Count, Is.EqualTo (0), "SomewhatStronglyTyped DetectMetadata #3 count");
Assert.That (error, Is.Not.Null, "SomewhatStronglyTyped DetectMetadata #3 error");
@@ -463,19 +477,26 @@ public void DetectMetadataTests_StronglyTyped ()
detected = null;
error = null;
pasteboard.DetectMetadata (hashSet, callback);
- Assert.That (evt.WaitOne (TimeSpan.FromSeconds (1)), "StronglyTyped DetectMetadata #1 wait");
+ Assert.That (evt.WaitOne (TimeSpan.FromSeconds (10)), "StronglyTyped DetectMetadata #1 wait");
Assert.That (detected, Is.Not.Null, "StronglyTyped DetectMetadata #1 patterns");
Assert.That ((int) detected.Count, Is.EqualTo (0), "StronglyTyped DetectMetadata #1 count");
Assert.That (error, Is.Null, "StronglyTyped DetectMetadata #1 error");
pasteboard.ClearContents ();
pasteboard.SetStringForType ("file:///this/is/some/file.html", NSPasteboardType.FileUrl.GetConstant ());
- evt.Reset ();
- detected = null;
- error = null;
- pasteboard.DetectMetadata (hashSet, callback);
- Assert.That (evt.WaitOne (TimeSpan.FromSeconds (1)), "StronglyTyped DetectMetadata #2 wait");
- Assert.That (detected, Is.Not.Null, "StronglyTyped DetectMetadata #2 patterns");
+ // The pasteboard subsystem may need time to analyze content metadata,
+ // so retry detection if it returns empty results.
+ for (int attempt = 0; attempt < 5; attempt++) {
+ evt.Reset ();
+ detected = null;
+ error = null;
+ pasteboard.DetectMetadata (hashSet, callback);
+ Assert.That (evt.WaitOne (TimeSpan.FromSeconds (10)), "StronglyTyped DetectMetadata #2 wait");
+ Assert.That (detected, Is.Not.Null, "StronglyTyped DetectMetadata #2 patterns");
+ if ((int) detected.Count > 0)
+ break;
+ Thread.Sleep (500);
+ }
Assert.That ((int) detected.Count, Is.EqualTo (1), "StronglyTyped DetectMetadata #2 count");
Assert.That (detected.Keys.First (), Is.EqualTo (NSPasteboardMetadataType.ContentType), "StronglyTyped DetectMetadata #2 contenttype");
Assert.That (detected.Values.First ().ToString (), Does.Contain ("public.html"), "StronglyTyped DetectMetadata #2 value");
@@ -489,7 +510,7 @@ public void DetectMetadataTests_StronglyTyped ()
detected = null;
error = null;
pasteboard.DetectMetadata (hashSet, callback);
- Assert.That (evt.WaitOne (TimeSpan.FromSeconds (1)), "StronglyTyped DetectMetadata #3 wait");
+ Assert.That (evt.WaitOne (TimeSpan.FromSeconds (10)), "StronglyTyped DetectMetadata #3 wait");
Assert.That (detected, Is.Not.Null, "StronglyTyped DetectMetadata #3 patterns");
Assert.That ((int) detected.Count, Is.EqualTo (0), "StronglyTyped DetectMetadata #3 count");
Assert.That (error, Is.Not.Null, "StronglyTyped DetectMetadata #3 error");
From 8302f79a1b46f22ecd65ef4dbaca200801a61159 Mon Sep 17 00:00:00 2001
From: "dotnet-maestro[bot]"
<42748379+dotnet-maestro[bot]@users.noreply.github.com>
Date: Tue, 19 May 2026 07:28:39 +0000
Subject: [PATCH 067/156] [main] Update dependencies from dotnet/macios
(#25460)
This pull request updates the following dependencies
## From https://github.com/dotnet/macios
- **Subscription**: [c0371266-dd6f-4959-822b-decc72d2d668](https://maestro.dot.net/subscriptions?search=c0371266-dd6f-4959-822b-decc72d2d668)
- **Build**: [20260518.1](https://dev.azure.com/devdiv/DevDiv/_build/results?buildId=14122183) ([314711](https://maestro.dot.net/channel/3884/github:dotnet:macios/build/314711))
- **Date Produced**: May 18, 2026 8:31:49 AM UTC
- **Commit**: [7075bb3cf977326a4e0a01108b748478ce08091e](https://github.com/dotnet/macios/commit/7075bb3cf977326a4e0a01108b748478ce08091e)
- **Branch**: [release/9.0.1xx](https://github.com/dotnet/macios/tree/release/9.0.1xx)
- **Dependency Updates**:
- From [26.5.9001 to 26.5.9002][1]
- Microsoft.iOS.Sdk.net9.0_26.5
- Microsoft.MacCatalyst.Sdk.net9.0_26.5
- Microsoft.macOS.Sdk.net9.0_26.5
- Microsoft.tvOS.Sdk.net9.0_26.5
[1]: https://github.com/dotnet/macios/compare/1e1deb87ce...7075bb3cf9
---
NuGet.config | 3 +--
eng/Version.Details.props | 8 ++++----
eng/Version.Details.xml | 16 ++++++++--------
3 files changed, 13 insertions(+), 14 deletions(-)
diff --git a/NuGet.config b/NuGet.config
index 039e15e88514..bf6f3a85bfa3 100644
--- a/NuGet.config
+++ b/NuGet.config
@@ -12,8 +12,7 @@
-
-
+
diff --git a/eng/Version.Details.props b/eng/Version.Details.props
index 13e094bf3616..d74d5d3ff7b5 100644
--- a/eng/Version.Details.props
+++ b/eng/Version.Details.props
@@ -19,16 +19,16 @@ This file should be imported by eng/Versions.props
26.0.11017
18.5.9227
- 26.5.9001
+ 26.5.9002
26.0.11017
18.5.9227
- 26.5.9001
+ 26.5.9002
26.0.11017
15.5.9227
- 26.5.9001
+ 26.5.9002
26.0.11017
18.5.9227
- 26.5.9001
+ 26.5.9002
11.0.0-prerelease.26264.1
diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml
index f19d57393d5b..755ad37b2897 100644
--- a/eng/Version.Details.xml
+++ b/eng/Version.Details.xml
@@ -60,21 +60,21 @@
797d30720e5e629d23eb146935da94cb1b61047e
-
+
https://github.com/dotnet/macios
- 1e1deb87ce9428d975d718366a2e01c61624fe55
+ 7075bb3cf977326a4e0a01108b748478ce08091e
-
+
https://github.com/dotnet/macios
- 1e1deb87ce9428d975d718366a2e01c61624fe55
+ 7075bb3cf977326a4e0a01108b748478ce08091e
-
+
https://github.com/dotnet/macios
- 1e1deb87ce9428d975d718366a2e01c61624fe55
+ 7075bb3cf977326a4e0a01108b748478ce08091e
-
+
https://github.com/dotnet/macios
- 1e1deb87ce9428d975d718366a2e01c61624fe55
+ 7075bb3cf977326a4e0a01108b748478ce08091e
From 7015f6ab4fdbc48742e77ccd18def03cc1852e59 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 19 May 2026 14:12:35 +0200
Subject: [PATCH 068/156] [msbuild/tools] Add netstandard2.0 helper string
functions. (#25375)
* Add a 'StringUtils.IsNullOrEmpty' with proper nullability attributes, because the netstandard2.0 version doesn't have it.
* Add a 'string.EndsWith(char)' overload.
---------
Co-authored-by: Rolf Bjarne Kvinge
---
.../Tasks/CompileAppManifest.cs | 6 +----
tools/common/Application.cs | 5 +++-
tools/common/Assembly.cs | 10 +++----
tools/common/StaticRegistrar.cs | 4 +--
tools/common/StringUtils.cs | 27 ++++++++++++-------
tools/dotnet-linker/LinkerConfiguration.cs | 2 +-
6 files changed, 31 insertions(+), 23 deletions(-)
diff --git a/msbuild/Xamarin.MacDev.Tasks/Tasks/CompileAppManifest.cs b/msbuild/Xamarin.MacDev.Tasks/Tasks/CompileAppManifest.cs
index 4ba5f04dc0de..daa70e268ed0 100644
--- a/msbuild/Xamarin.MacDev.Tasks/Tasks/CompileAppManifest.cs
+++ b/msbuild/Xamarin.MacDev.Tasks/Tasks/CompileAppManifest.cs
@@ -258,11 +258,7 @@ bool SetMinimumOSVersion (PDictionary plist)
}
}
-#if NET
- if (string.IsNullOrEmpty (minimumOSVersionInManifest)) {
-#else
- if (string.IsNullOrEmpty (minimumOSVersionInManifest) || minimumOSVersionInManifest is null) {
-#endif
+ if (StringUtils.IsNullOrEmpty (minimumOSVersionInManifest)) {
// Nothing is specified in the Info.plist - use SupportedOSPlatformVersion, and if that's not set, then use the sdkVersion
if (!string.IsNullOrEmpty (convertedSupportedOSPlatformVersion)) {
minimumOSVersion = convertedSupportedOSPlatformVersion;
diff --git a/tools/common/Application.cs b/tools/common/Application.cs
index 87fba1263280..bbb980051b3e 100644
--- a/tools/common/Application.cs
+++ b/tools/common/Application.cs
@@ -228,7 +228,7 @@ public bool IsDeviceBuild {
public bool IsSimulatorBuild {
get {
- if (!string.IsNullOrEmpty (RuntimeIdentifier))
+ if (!StringUtils.IsNullOrEmpty (RuntimeIdentifier))
return RuntimeIdentifier.IndexOf ("simulator", StringComparison.OrdinalIgnoreCase) >= 0;
switch (Platform) {
@@ -686,6 +686,9 @@ public void ParseAbi (string abi)
#if !LEGACY_TOOLS
public void ParseRegistrar (string v)
{
+ if (StringUtils.IsNullOrEmpty (v))
+ return;
+
var split = v.Split ('=');
var name = split [0];
var value = split.Length > 1 ? split [1] : string.Empty;
diff --git a/tools/common/Assembly.cs b/tools/common/Assembly.cs
index 28f4d9a98f7b..fc34425292b1 100644
--- a/tools/common/Assembly.cs
+++ b/tools/common/Assembly.cs
@@ -242,12 +242,12 @@ void ProcessLinkWithAttributes (AssemblyDefinition assembly)
continue;
// Remove the resource from the assembly at a later stage.
- if (!string.IsNullOrEmpty (metadata.LibraryName))
+ if (!StringUtils.IsNullOrEmpty (metadata.LibraryName))
AddResourceToBeRemoved (metadata.LibraryName);
ProcessNativeReferenceOptions (metadata);
- if (!string.IsNullOrEmpty (linkWith.LibraryName)) {
+ if (!StringUtils.IsNullOrEmpty (linkWith.LibraryName)) {
switch (Path.GetExtension (linkWith.LibraryName).ToLowerInvariant ()) {
case ".framework": {
// TryExtractFramework prints a error/warning if something goes wrong, so no need for us to have an error handling path.
@@ -282,7 +282,7 @@ void ProcessNativeReferenceOptions (NativeReferenceMetadata metadata)
if (metadata.ForceLoad && !(metadata.SmartLink && (App.Registrar == RegistrarMode.Static || App.Registrar == RegistrarMode.ManagedStatic || App.Registrar == RegistrarMode.TrimmableStatic)))
ForceLoad = true;
- if (!string.IsNullOrEmpty (metadata.LinkerFlags)) {
+ if (!StringUtils.IsNullOrEmpty (metadata.LinkerFlags)) {
if (LinkerFlags is null)
LinkerFlags = new List ();
if (!StringUtils.TryParseArguments (metadata.LinkerFlags, out var args, out var ex))
@@ -290,7 +290,7 @@ void ProcessNativeReferenceOptions (NativeReferenceMetadata metadata)
LinkerFlags.AddRange (args);
}
- if (!string.IsNullOrEmpty (metadata.Frameworks)) {
+ if (!StringUtils.IsNullOrEmpty (metadata.Frameworks)) {
foreach (var f in metadata.Frameworks.Split (new char [] { ' ' })) {
if (Frameworks is null)
Frameworks = new HashSet ();
@@ -298,7 +298,7 @@ void ProcessNativeReferenceOptions (NativeReferenceMetadata metadata)
}
}
- if (!string.IsNullOrEmpty (metadata.WeakFrameworks)) {
+ if (!StringUtils.IsNullOrEmpty (metadata.WeakFrameworks)) {
foreach (var f in metadata.WeakFrameworks.Split (new char [] { ' ' })) {
if (WeakFrameworks is null)
WeakFrameworks = new HashSet ();
diff --git a/tools/common/StaticRegistrar.cs b/tools/common/StaticRegistrar.cs
index ad3102cb77fa..c544e6f83340 100644
--- a/tools/common/StaticRegistrar.cs
+++ b/tools/common/StaticRegistrar.cs
@@ -2674,7 +2674,7 @@ public List SkippedTypes {
public string GetInitializationMethodName (string? single_assembly)
{
- if (!string.IsNullOrEmpty (single_assembly)) {
+ if (!StringUtils.IsNullOrEmpty (single_assembly)) {
return "xamarin_create_classes_" + single_assembly.Replace ('.', '_').Replace ('-', '_');
} else {
return "xamarin_create_classes";
@@ -2816,7 +2816,7 @@ void Specialize (AutoIndentStringBuilder sb, out string initialization_method)
// Select the types that needs to be registered.
var allTypes = GetAllTypes (exceptions);
- if (string.IsNullOrEmpty (single_assembly)) {
+ if (StringUtils.IsNullOrEmpty (single_assembly)) {
foreach (var assembly in GetAssemblies ())
registered_assemblies.Add (new (assembly, GetAssemblyName (assembly)));
} else {
diff --git a/tools/common/StringUtils.cs b/tools/common/StringUtils.cs
index 6b770607321c..01dadf374af7 100644
--- a/tools/common/StringUtils.cs
+++ b/tools/common/StringUtils.cs
@@ -283,11 +283,7 @@ public static bool TryParseFormattedMessage (string? line, out string? fileName,
code = 0;
message = null;
-#if NET
- if (string.IsNullOrEmpty (line))
-#else
- if (string.IsNullOrEmpty (line) || line is null)
-#endif
+ if (IsNullOrEmpty (line))
return false;
var origin = string.Empty;
@@ -362,11 +358,7 @@ static bool IndexOfAny (string line, out int start, out int end, params string [
static string RemovePathAtEnd (string line)
{
-#if NET
if (line.TrimEnd ().EndsWith (']')) {
-#else
- if (line.TrimEnd ().EndsWith ("]")) {
-#endif
var start = line.LastIndexOf ('[');
if (start >= 0) {
// we want to get the space before `[` too.
@@ -380,6 +372,14 @@ static string RemovePathAtEnd (string line)
return line;
}
+
+ // This function only exists because netstandard2.0's version doesn't have the [NotNullWhen] attribute,
+ // which makes nullability analysis somewhat annoying. This function can be removed and callsites updated
+ // to call string.IsNullOrEmpty directly once we stop targeting netstandard2.0.
+ public static bool IsNullOrEmpty ([NotNullWhen (false)] string? s)
+ {
+ return string.IsNullOrEmpty (s);
+ }
}
static class StringExtensions {
@@ -397,5 +397,14 @@ internal static T [] CopyAndAdd (this T [] array, T value)
tmpArray [tmpArray.Length - 1] = value;
return tmpArray;
}
+
+#if !NET
+ public static bool EndsWith (this string s, char value)
+ {
+ if (s.Length == 0)
+ return false;
+ return s [s.Length - 1] == value;
+ }
+#endif
}
}
diff --git a/tools/dotnet-linker/LinkerConfiguration.cs b/tools/dotnet-linker/LinkerConfiguration.cs
index 5de07dbced9d..8458b9030239 100644
--- a/tools/dotnet-linker/LinkerConfiguration.cs
+++ b/tools/dotnet-linker/LinkerConfiguration.cs
@@ -424,7 +424,7 @@ public static LinkerConfiguration GetInstance (LinkContext context)
ErrorHelper.Platform = Platform;
// Optimizations.Parse can only be called after setting ErrorHelper.Platform
- if (!string.IsNullOrEmpty (user_optimize_flags)) {
+ if (!StringUtils.IsNullOrEmpty (user_optimize_flags)) {
var messages = new List ();
Application.Optimizations.Parse (Application.Platform, user_optimize_flags, messages);
ErrorHelper.Show (messages);
From a2e5df81c8959fb4a5e9563463808da6fe2583a7 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 19 May 2026 14:25:52 +0200
Subject: [PATCH 069/156] Add option to build (partially) without Xcode.
(#25429)
Useful when:
* Building on Linux.
* Building on older macOS versions, that can't install the required Xcode version.
Refactor the existing IS_LINUX variable to use NO_XCODE instead.
---
Make.config | 20 ++++++++++++++------
Makefile | 6 +++---
configure | 7 +++++++
msbuild/Makefile | 4 ++--
src/Makefile | 6 +++---
system-dependencies.sh | 24 ++++++++++++++++++------
tests/Makefile | 4 ++--
tools/Makefile | 2 +-
tools/mtouch/Makefile | 2 +-
9 files changed, 51 insertions(+), 24 deletions(-)
diff --git a/Make.config b/Make.config
index dc72572619be..23ad1a546caf 100644
--- a/Make.config
+++ b/Make.config
@@ -1,9 +1,9 @@
include $(TOP)/mk/subdirs.mk
-# Detect if we're building on Linux
+# Detect if we're building on Linux (which means there's no Xcode)
UNAME_S:=$(shell uname -s)
ifeq ($(UNAME_S),Linux)
-IS_LINUX=1
+NO_XCODE=1
endif
# Common cURL command:
@@ -209,9 +209,18 @@ MACCATALYST_NUGET_VERSION_FULL=$(MACCATALYST_NUGET_VERSION_NO_METADATA)$(NUGET_B
# Xcode version should have both a major and a minor version (even if the minor version is 0)
XCODE_VERSION=26.5
XCODE_URL=https://bosstoragemirror.blob.core.windows.net/internal-files/xcodes/Xcode_26.5.xip
-ifndef IS_LINUX
+ifndef NO_XCODE
XCODE_DEVELOPER_ROOT=/Applications/Xcode_26.5.0.app/Contents/Developer
-XCODE_PRODUCT_BUILD_VERSION:=$(shell /usr/libexec/PlistBuddy -c 'Print :ProductBuildVersion' $(XCODE_DEVELOPER_ROOT)/../version.plist 2>/dev/null || echo " $(shell tput setaf 1 2>/dev/null)The required Xcode ($(XCODE_VERSION)) is not installed in $(basename $(basename $(XCODE_DEVELOPER_ROOT)))$(shell tput sgr0 2>/dev/null)" >&2)
+ifneq (OK,$(shell test -d $(abspath $(XCODE_DEVELOPER_ROOT)) && echo OK))
+NO_XCODE=1
+$(warning The required Xcode ($(XCODE_VERSION)) is not installed in $(XCODE_DEVELOPER_ROOT) - this directory does not exist. Any parts of the build that require Xcode will be disabled.)
+else
+XCODE_PRODUCT_BUILD_VERSION:=$(shell /usr/libexec/PlistBuddy -c 'Print :ProductBuildVersion' $(XCODE_DEVELOPER_ROOT)/../version.plist 2>/dev/null)
+ifeq (,$(XCODE_PRODUCT_BUILD_VERSION))
+NO_XCODE=1
+$(warning The required Xcode ($(XCODE_VERSION)) is not installed in $(XCODE_DEVELOPER_ROOT) - directory exists, but no version found. Any parts of the build that require Xcode will be disabled.)
+endif
+endif
# We define stable Xcode as the Xcode app being named like "Xcode_#.#[.#].app"
# and any other naming is deemed to be a beta. This is the safer approach: any
@@ -232,8 +241,7 @@ endif
export DEVELOPER_DIR=$(XCODE_DEVELOPER_ROOT)
export MD_APPLE_SDK_ROOT=$(abspath $(XCODE_DEVELOPER_ROOT)/../..)
else
-# On Linux, set placeholder Xcode values but honor XCODE_CHANNEL so we configure bots correctly
-XCODE_PRODUCT_BUILD_VERSION=
+# Without Xcode, set placeholder Xcode values but honor XCODE_CHANNEL so we configure bots correctly
ifeq ($(XCODE_CHANNEL),Beta)
XCODE_IS_STABLE=false
XCODE_IS_PREVIEW=true
diff --git a/Makefile b/Makefile
index f60d19b26180..4f8bfa47322b 100644
--- a/Makefile
+++ b/Makefile
@@ -3,8 +3,8 @@ SUBDIRS=builds
include $(TOP)/Make.config
include $(TOP)/mk/versions.mk
-# On Linux, skip directories that require native compilation or macOS platform
-ifndef IS_LINUX
+# Without Xcode, skip directories that require native compilation or macOS platform
+ifndef NO_XCODE
SUBDIRS += runtime
endif
@@ -16,7 +16,7 @@ endif
SUBDIRS += tools
-ifndef IS_LINUX
+ifndef NO_XCODE
SUBDIRS += dotnet
endif
diff --git a/configure b/configure
index 4a126a2a5bd1..a040e46460bb 100755
--- a/configure
+++ b/configure
@@ -30,6 +30,8 @@ Usage: configure [options]
--custom-dotnet=[dotnet/runtime] Use a locally built version of dotnet/runtime. Pass the path to an already build checkout of dotnet/runtime. See docs/CORECLR.md for detailed instructions about how to build dotnet/runtime from source.
--ignore-unknown-params alters the default behavior to not return an non-zero exit code when an unknown parameter is provided.
+
+ --no-xcode Only do things that don't require Xcode. This won't produce anything useful, but might come in handy once in a blue moon when testing something that doesn't require Xcode somewhere Xcode can't be installed (Linux, older macOS devices, etc.)
EOL
}
@@ -149,6 +151,11 @@ while test "x$1" != x; do
IGNORE_UNKNOWN_PARAMS=true
shift
;;
+ --no-xcode)
+ echo "Ignoring Xcode requirement"
+ echo "NO_XCODE=1" >> "$CONFIGURED_FILE"
+ shift
+ ;;
--help|-h)
show_help
exit 0
diff --git a/msbuild/Makefile b/msbuild/Makefile
index c676c92ca83a..49c7db013c83 100644
--- a/msbuild/Makefile
+++ b/msbuild/Makefile
@@ -119,7 +119,7 @@ DOTNET_IOS_WINDOWS_FILES += Messaging/Xamarin.Messaging.Build/obj/$(CONFIG)/Buil
.dotnet-windows: .build-stamp .copy-windows-files
-ifndef IS_LINUX
+ifndef NO_XCODE
all-local:: .dotnet-windows
dotnet:: .dotnet-windows
endif
@@ -130,7 +130,7 @@ endif
# we must install locally during 'make all', because the F# build depends on the msbuild targets/assemblies.
all-local:: $(MSBUILD_PRODUCTS)
-ifndef IS_LINUX
+ifndef NO_XCODE
all-local:: .stamp-test-xml
endif
diff --git a/src/Makefile b/src/Makefile
index 8fb8a3f67808..703dc110204c 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -346,17 +346,17 @@ $(DOTNET_DESTDIR)/$($(2)_NUGET_REF_NAME)/ref/$(DOTNET_TFM)/Microsoft.$(1).dll: $
$(DOTNET_DESTDIR)/$($(2)_NUGET_REF_NAME)/ref/$(DOTNET_TFM)/Microsoft.$(1).xml: $($(2)_DOTNET_BUILD_DIR)/doc/Microsoft.$(1).xml | $(DOTNET_DESTDIR)/$($(2)_NUGET_REF_NAME)/ref/$(DOTNET_TFM)
$$(Q) $(CP) $$< $$@
-ifndef IS_LINUX
+ifndef NO_XCODE
$($(2)_DOTNET_BUILD_DIR)/doc/Microsoft.$(1).xml: $($(2)_DOTNET_BUILD_DIR)/ref/Microsoft.$(1).xml $($(2)_DOTNET_BUILD_DIR)/ref/Microsoft.$(1).dll build/.build-adr-stamp | $($(2)_DOTNET_BUILD_DIR)/doc
$$(Q_GEN) $(TOP)/packages/appledocreader.$(ADR_RUNTIME_IDENTIFIER)/$(ADR_NUGET_VERSION)/tools/any/$(ADR_RUNTIME_IDENTIFIER)/AppleDocReader inject docs --assembly="$(abspath $($(2)_DOTNET_BUILD_DIR)/ref/Microsoft.$(1).dll)" --input="$(abspath $($(2)_DOTNET_BUILD_DIR)/ref/Microsoft.$(1).xml)" --output="$(abspath $$@)" --xcode="$(DEVELOPER_DIR)/../.." --runtimeDll="$(DOTNET_BCL_DIR)/System.Runtime.dll" -f
else
-# On Linux, skip AppleDocReader (macOS-only tool) and just copy the XML
+# Without Xcode, skip AppleDocReader and just copy the XML
$($(2)_DOTNET_BUILD_DIR)/doc/Microsoft.$(1).xml: $($(2)_DOTNET_BUILD_DIR)/ref/Microsoft.$(1).xml | $($(2)_DOTNET_BUILD_DIR)/doc
$(Q) $(CP) $$< $$@
endif
endef
-ifndef IS_LINUX
+ifndef NO_XCODE
build/.build-adr-stamp:
$(MAKE) -C $(TOP)/tools/adr
$(Q) touch $@
diff --git a/system-dependencies.sh b/system-dependencies.sh
index 292a7c8c12eb..c5cc85e0ad29 100755
--- a/system-dependencies.sh
+++ b/system-dependencies.sh
@@ -6,7 +6,7 @@ cd $(dirname $0)
# Detect if we're running on Linux
if [[ "$(uname -s)" == "Linux" ]]; then
- IS_LINUX=1
+ NO_XCODE=1
# On Linux, ignore all macOS-specific dependencies
IGNORE_OSX=1
IGNORE_XCODE=1
@@ -20,7 +20,7 @@ if [[ "$(uname -s)" == "Linux" ]]; then
IGNORE_YAMLLINT=1
IGNORE_PYTHON3=1
else
- IS_LINUX=
+ NO_XCODE=
fi
FAIL=
@@ -31,6 +31,18 @@ VERBOSE=
OPTIONAL_SIMULATORS=1
OPTIONAL_OLD_SIMULATORS=1
+if test -f configure.inc; then
+ source configure.inc
+
+ if test -n "$NO_XCODE"; then
+ IGNORE_OSX=1
+ IGNORE_XCODE=1
+ IGNORE_SIMULATORS=1
+ IGNORE_OLD_SIMULATORS=1
+ IGNORE_XCODE_COMPONENTS=1
+ fi
+fi
+
# parse command-line arguments
while ! test -z $1; do
case $1 in
@@ -848,8 +860,8 @@ function check_osx_version () {
}
function check_checkout_dir () {
- # Skip on Linux - this check is macOS-specific
- if test -n "$IS_LINUX"; then
+ # Skip without Xcode - this check is macOS-specific
+ if test -n "$NO_XCODE"; then
return
fi
@@ -964,8 +976,8 @@ function check_old_simulators ()
echo "Checking system..."
-if test -n "$IS_LINUX"; then
- ok "Running on ${COLOR_BLUE}Linux${COLOR_CLEAR} - skipping macOS-specific checks"
+if test -n "$NO_XCODE"; then
+ ok "No Xcode available - skipping Xcode-specific checks"
ok "Only .NET download and managed code builds will be available"
fi
diff --git a/tests/Makefile b/tests/Makefile
index 5313dfde1142..6a0802b2f561 100644
--- a/tests/Makefile
+++ b/tests/Makefile
@@ -2,9 +2,9 @@ TOP = ..
include $(TOP)/Make.config
-# Skip test-libraries on Linux (requires native compilation with Xcode/clang)
+# Skip test-libraries without Xcode (requires native compilation with Xcode/clang)
ifndef ONLY_SHARPIE
-ifndef IS_LINUX
+ifndef NO_XCODE
SUBDIRS=test-libraries
endif
endif
diff --git a/tools/Makefile b/tools/Makefile
index ee73e7c5ba3e..00d896286809 100644
--- a/tools/Makefile
+++ b/tools/Makefile
@@ -2,7 +2,7 @@ TOP=..
include $(TOP)/Make.config
-ifndef IS_LINUX
+ifndef NO_XCODE
SUBDIRS += sharpie
endif
diff --git a/tools/mtouch/Makefile b/tools/mtouch/Makefile
index 40fab8c5dd39..0ad70dd239a7 100644
--- a/tools/mtouch/Makefile
+++ b/tools/mtouch/Makefile
@@ -86,7 +86,7 @@ endef
$(foreach platform,$(DOTNET_PLATFORMS_MTOUCH),$(foreach rid,$(DOTNET_$(platform)_RUNTIME_IDENTIFIERS),$(eval $(call InstallRegistrar,$(platform),$(rid)))))
-ifndef IS_LINUX
+ifndef NO_XCODE
dotnet: $(TARGETS_DOTNET)
install-local:: $(TARGETS_DOTNET)
all-local:: $(TARGETS_DOTNET)
From ca36f53f3653ca23cf549c572c9602c3ff33a4ac Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 19 May 2026 15:32:18 +0200
Subject: [PATCH 070/156] [tests] Fix transient TLS/network failures in
MessageHandlerTest tests (#25452)
Expand IgnoreInCIIfSshConnectionError to also detect 'A TLS error
caused the secure connection to fail' messages and
CFNetworkErrors.SecureConnectionFailed NSError codes by walking the
entire exception chain.
Add IgnoreInCIIfBadNetwork(ex) calls to tests that were only checking
HTTP status codes but not exceptions:
- GHIssue8342
- SupportsDigestAuthentication
- GHIssue16339
- AcceptSslCertificatesServicePointManager
Fixes https://github.com/dotnet/macios/issues/25444
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Rolf Bjarne Kvinge
---
tests/common/TestRuntime.cs | 16 +++++++++++++---
.../System.Net.Http/MessageHandlers.cs | 4 ++++
2 files changed, 17 insertions(+), 3 deletions(-)
diff --git a/tests/common/TestRuntime.cs b/tests/common/TestRuntime.cs
index 7c4f957c0c70..68ab6699c66b 100644
--- a/tests/common/TestRuntime.cs
+++ b/tests/common/TestRuntime.cs
@@ -1732,9 +1732,19 @@ public static void IgnoreInCIIfNoNetworkConnection (NSError error)
public static void IgnoreInCIIfSshConnectionError (Exception ex)
{
- var msg = ex.Message;
- if (msg.Contains ("The SSL connection could not be established")) {
- IgnoreInCI ($"Ignored due to network error: {ex}");
+ // Check all exceptions in the chain for TLS/SSL error messages
+ var current = ex;
+ while (current is not null) {
+ var msg = current.Message;
+ if (msg.Contains ("The SSL connection could not be established") ||
+ msg.Contains ("A TLS error caused the secure connection to fail")) {
+ IgnoreInCI ($"Ignored due to network error: {ex}");
+ }
+ if (current is NSErrorException nex) {
+ // CFNetworkErrors.SecureConnectionFailed = -1200
+ IgnoreNetworkError (nex.Error, CFNetworkErrors.SecureConnectionFailed);
+ }
+ current = current.InnerException;
}
}
diff --git a/tests/monotouch-test/System.Net.Http/MessageHandlers.cs b/tests/monotouch-test/System.Net.Http/MessageHandlers.cs
index 949a29ecfe3f..6e28a1ca9fb5 100644
--- a/tests/monotouch-test/System.Net.Http/MessageHandlers.cs
+++ b/tests/monotouch-test/System.Net.Http/MessageHandlers.cs
@@ -594,6 +594,7 @@ public void AcceptSslCertificatesServicePointManager (Type handlerType)
Assert.AreNotEqual (ex.InnerException.Message, "Error: TrustFailure");
}
}
+ TestRuntime.IgnoreInCIIfBadNetwork (ex);
Assert.IsNull (ex);
// Assert.IsTrue (servicePointManagerCbWasExcuted, "Executed");
}
@@ -902,6 +903,7 @@ public void GHIssue8342 (HttpStatusCode expectedStatus, string validUsername, st
if (!done) { // timeouts happen in the bots due to dns issues, connection issues etc.. we do not want to fail
Assert.Inconclusive ("Request timedout.");
} else {
+ TestRuntime.IgnoreInCIIfBadNetwork (ex);
TestRuntime.IgnoreInCIIfBadNetwork (httpStatus);
Assert.IsNull (ex, "Exception not null");
Assert.AreEqual (expectedStatus, httpStatus, "Status not ok");
@@ -928,6 +930,7 @@ public void SupportsDigestAuthentication (HttpStatusCode expectedStatus, string
if (!done) {
Assert.Inconclusive ("Request timedout.");
} else {
+ TestRuntime.IgnoreInCIIfBadNetwork (ex);
TestRuntime.IgnoreInCIIfBadNetwork (httpStatus);
Assert.IsNull (ex, "Exception not null");
Assert.AreEqual (expectedStatus, httpStatus, "Status not ok");
@@ -1039,6 +1042,7 @@ public void GHIssue16339 ()
if (!done) { // timeouts happen in the bots due to dns issues, connection issues etc.. we do not want to fail
Assert.Inconclusive ("Request timedout.");
} else {
+ TestRuntime.IgnoreInCIIfBadNetwork (ex);
Assert.IsNull (ex, "Exception");
for (var i = 0; i < iterations; i++) {
From 881aad6575a8e67374e76ea6d5e0bd6a5c5a6ece Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 19 May 2026 15:36:27 +0200
Subject: [PATCH 071/156] [tools] Fix marking generated block code when not
using any of the static registrars (#25434)
* Fix an issue where the new style of generated block supporting code wasn't properly handled by the trimmer when using the dynamic registrar.
* Add a 'link sdk' + 'link all' test variation for all platforms for monotouch-test.
* Update a few tests to cope with the additional trimming variations for monotouch-test.
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Rolf Bjarne Kvinge
---
tests/bindings-test/ProtocolTest.cs | 19 ++++-
.../monotouch-test/AppKit/DerivedEventTest.cs | 2 +-
tests/monotouch-test/AppKit/NSView.cs | 2 +-
.../ObjCRuntime/EveryFrameworkSmokeTest.cs | 4 +-
.../xharness/Jenkins/TestVariationsFactory.cs | 4 +
.../Steps/PreserveBlockCodeStep.cs | 80 +++++++++++++++++--
6 files changed, 98 insertions(+), 13 deletions(-)
diff --git a/tests/bindings-test/ProtocolTest.cs b/tests/bindings-test/ProtocolTest.cs
index 5667a8d478a2..b9d2ae0495e9 100644
--- a/tests/bindings-test/ProtocolTest.cs
+++ b/tests/bindings-test/ProtocolTest.cs
@@ -10,12 +10,17 @@ public class ProtocolTest {
bool HasProtocolAttributes {
get {
if (TestRuntime.IsLinkAll) {
-#if OPTIMIZEALL && __MACOS__
- return false;
+#if OPTIMIZEALL
+ var registeredProtocols = true;
+#elif __MACOS__
+ var registeredProtocols = false;
#else
- if (!Runtime.DynamicRegistrationSupported)
- return false;
+ var registeredProtocols = true;
#endif
+ if (!registeredProtocols)
+ return Runtime.DynamicRegistrationSupported;
+
+ return !IsStaticRegistrar;
}
@@ -23,6 +28,12 @@ bool HasProtocolAttributes {
}
}
+ bool IsStaticRegistrar {
+ get {
+ return global::XamarinTests.ObjCRuntime.Registrar.IsStaticRegistrar;
+ }
+ }
+
bool IsTrimmableStaticRegistrar {
get {
return global::XamarinTests.ObjCRuntime.Registrar.IsTrimmableStaticRegistrar;
diff --git a/tests/monotouch-test/AppKit/DerivedEventTest.cs b/tests/monotouch-test/AppKit/DerivedEventTest.cs
index 8a8776cf1f2e..e018cc1ebd5b 100644
--- a/tests/monotouch-test/AppKit/DerivedEventTest.cs
+++ b/tests/monotouch-test/AppKit/DerivedEventTest.cs
@@ -39,7 +39,7 @@ void TestDelegates (NSComboBox b)
public void DerivedEvents_OverwriteThrows ()
{
#if RELEASE
- var checkTrimmedAway = TestRuntime.IsLinkAll;
+ var checkTrimmedAway = TestRuntime.IsLinkAny;
#else
var checkTrimmedAway = false;
#endif
diff --git a/tests/monotouch-test/AppKit/NSView.cs b/tests/monotouch-test/AppKit/NSView.cs
index 830c77187bb5..345a31c1fa37 100644
--- a/tests/monotouch-test/AppKit/NSView.cs
+++ b/tests/monotouch-test/AppKit/NSView.cs
@@ -64,7 +64,7 @@ public void AllItemsWithNSMenuShouldAllowNull ()
foreach (var ctor in types) {
var o = ctor ();
var prop = o.GetType ().GetProperty ("Menu", BindingFlags.Public | BindingFlags.Instance);
- if (prop is null && TestRuntime.IsLinkAll)
+ if (prop is null && TestRuntime.IsLinkAny)
continue; // the property was linked away.
prop.SetValue (o, null, null);
}
diff --git a/tests/monotouch-test/ObjCRuntime/EveryFrameworkSmokeTest.cs b/tests/monotouch-test/ObjCRuntime/EveryFrameworkSmokeTest.cs
index 33cfce365583..5b9c61d7341b 100644
--- a/tests/monotouch-test/ObjCRuntime/EveryFrameworkSmokeTest.cs
+++ b/tests/monotouch-test/ObjCRuntime/EveryFrameworkSmokeTest.cs
@@ -85,8 +85,8 @@ LoadStatus CheckLoadFailure (string libraryName, string path)
[Test]
public void ExpectedLibrariesAreLoaded ()
{
- if (TestRuntime.IsLinkAll)
- Assert.Ignore ("This test will fail when all assemblies are linked, since we won't link with all frameworks in that case.");
+ if (TestRuntime.IsLinkAny)
+ Assert.Ignore ("This test will fail when assemblies are linked, since we won't link with all frameworks in that case.");
List failures = new List ();
diff --git a/tests/xharness/Jenkins/TestVariationsFactory.cs b/tests/xharness/Jenkins/TestVariationsFactory.cs
index 72984f51eeb9..812e53156a69 100644
--- a/tests/xharness/Jenkins/TestVariationsFactory.cs
+++ b/tests/xharness/Jenkins/TestVariationsFactory.cs
@@ -59,6 +59,10 @@ IEnumerable GetTestData (RunTestTask test)
yield return new TestData { Variation = "Debug (don't bundle original resources)", TestVariation = "do-not-bundle-original-resources" };
}
break;
+ case "monotouch-test":
+ yield return new TestData { Variation = "Release (link sdk)", TestVariation = "release|linksdk", Ignored = ignore };
+ yield return new TestData { Variation = "Release (link all)", TestVariation = "release|linkall", Ignored = ignore };
+ break;
}
switch (test.ProjectPlatform) {
diff --git a/tools/dotnet-linker/Steps/PreserveBlockCodeStep.cs b/tools/dotnet-linker/Steps/PreserveBlockCodeStep.cs
index 6b22aaade307..5a25a54ca27d 100644
--- a/tools/dotnet-linker/Steps/PreserveBlockCodeStep.cs
+++ b/tools/dotnet-linker/Steps/PreserveBlockCodeStep.cs
@@ -33,12 +33,16 @@ protected override bool IsActiveFor (AssemblyDefinition assembly)
protected override bool ProcessType (TypeDefinition type)
{
- if (!GetMembersToPreserve (type, out var field, out var method))
- return false;
-
var modified = false;
- modified |= abr.AddDynamicDependencyAttributeToStaticConstructor (type, field);
- modified |= abr.AddDynamicDependencyAttributeToStaticConstructor (type, method);
+
+ if (GetMembersToPreserve (type, out var field, out var method)) {
+ modified |= abr.AddDynamicDependencyAttributeToStaticConstructor (type, field);
+ modified |= abr.AddDynamicDependencyAttributeToStaticConstructor (type, method);
+ }
+
+ if (GetNewStyleMethodToPreserve (type, out var invokeMethod))
+ modified |= abr.AddDynamicDependencyAttributeToStaticConstructor (type, invokeMethod);
+
return modified;
}
@@ -103,5 +107,71 @@ static internal void Invoke (IntPtr block, int magic_number)
// The type was used, so preserve the method and field
return true;
}
+
+ // New-style block proxy types use [UnmanagedCallersOnly] on the Invoke method
+ // and don't have a Handler field. They are generated when the bgen tool emits
+ // function pointer-based block trampolines. We need to preserve the Invoke method
+ // because the runtime looks it up via reflection in Blocks.GetBlockForDelegate.
+ public static bool GetNewStyleMethodToPreserve (TypeDefinition type, [NotNullWhen (true)] out MethodDefinition? method)
+ {
+ method = null;
+
+ /* For the following class:
+
+ static internal class SDRegistrarTestBlock {
+ [UnmanagedCallersOnly]
+ [UserDelegateType (typeof (RegistrarTestBlock))]
+ internal static unsafe uint Invoke (IntPtr block, uint magic)
+ {
+ }
+ internal static unsafe BlockLiteral CreateBlock (RegistrarTestBlock callback)
+ {
+ delegate* unmanaged trampoline = &Invoke;
+ return new BlockLiteral (trampoline, callback, typeof (SDRegistrarTestBlock), nameof (Invoke));
+ }
+ }
+
+ * We need to make sure the linker doesn't remove the Invoke method.
+ */
+
+ // The type must be abstract, sealed (static class) and nested
+ if (!type.IsAbstract || !type.IsSealed || !type.IsNested)
+ return false;
+
+ // The type must not have fields (old-style types have a Handler field and are handled by GetMembersToPreserve)
+ if (type.HasFields)
+ return false;
+
+ // The type is nested inside ObjCRuntime.Trampolines class
+ var nestingType = type.DeclaringType;
+ if (!nestingType.Is ("ObjCRuntime", "Trampolines"))
+ return false;
+
+ if (!type.HasMethods)
+ return false;
+
+ // The class has an 'Invoke' method with [UnmanagedCallersOnly] and [UserDelegateType] attributes
+ method = type.Methods.SingleOrDefault (v => {
+ if (v.Name != "Invoke")
+ return false;
+ if (!v.HasParameters)
+ return false;
+ if (!v.HasCustomAttributes)
+ return false;
+ var hasUnmanagedCallersOnly = false;
+ var hasUserDelegateType = false;
+ foreach (var attr in v.CustomAttributes) {
+ if (attr.AttributeType.Name == "UnmanagedCallersOnlyAttribute")
+ hasUnmanagedCallersOnly = true;
+ else if (attr.AttributeType.Name == "UserDelegateTypeAttribute")
+ hasUserDelegateType = true;
+ if (hasUnmanagedCallersOnly && hasUserDelegateType)
+ break;
+ }
+ return hasUnmanagedCallersOnly && hasUserDelegateType;
+ });
+
+ return method is not null;
+ }
}
}
From 6f67cf9aeda698ea7be078392fbe4fbe707caa07 Mon Sep 17 00:00:00 2001
From: Alex Soto
Date: Tue, 19 May 2026 10:18:11 -0400
Subject: [PATCH 072/156] [apidiff] Update reference/stable versions to latest
.NET 10 / Xcode 26.5 (#25457)
---
Make.config | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/Make.config b/Make.config
index 23ad1a546caf..37e7563a336d 100644
--- a/Make.config
+++ b/Make.config
@@ -50,10 +50,10 @@ include $(TOP)/Make.versions
# The value is taken from the name + version of the Ref pack.
# Example: given the Ref pack "Microsoft.iOS.Ref.net8.0_17.5" with the version "17.5.8030", the value
# to write here would be the part after "Microsoft.iOS.Ref." + "/" + version: "net8.0_17.5/17.5.8030"
-STABLE_NUGET_VERSION_iOS=net10.0_26.4/26.4.10259
-STABLE_NUGET_VERSION_tvOS=net10.0_26.4/26.4.10259
-STABLE_NUGET_VERSION_MacCatalyst=net10.0_26.4/26.4.10259
-STABLE_NUGET_VERSION_macOS=net10.0_26.4/26.4.10259
+STABLE_NUGET_VERSION_iOS=net10.0_26.5/26.5.10280
+STABLE_NUGET_VERSION_tvOS=net10.0_26.5/26.5.10280
+STABLE_NUGET_VERSION_MacCatalyst=net10.0_26.5/26.5.10280
+STABLE_NUGET_VERSION_macOS=net10.0_26.5/26.5.10280
PACKAGE_HEAD_REV=$(shell git rev-parse HEAD)
From f5b5402ef91ce5b6b91525a77e9738dc24f5725f Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 19 May 2026 17:42:19 +0200
Subject: [PATCH 073/156] [github] Simplify the yaml lint action to not post a
comment. (#25467)
The red checkmark should be enough, and this way we don't require write permissions to the pull request.
---
.github/workflows/yamllint.yml | 25 ++-----------------------
1 file changed, 2 insertions(+), 23 deletions(-)
diff --git a/.github/workflows/yamllint.yml b/.github/workflows/yamllint.yml
index 4a6ab347b175..d2fa268c38a3 100644
--- a/.github/workflows/yamllint.yml
+++ b/.github/workflows/yamllint.yml
@@ -4,7 +4,7 @@ on: pull_request
permissions:
contents: read
- pull-requests: write
+ pull-requests: read
jobs:
rebase:
@@ -22,27 +22,6 @@ jobs:
run: pip install yamllint
- name: Lint YAML pipeline files
- id: lint-pipeline
working-directory: ./tools/devops/automation
run: |
- RESULT=$(yamllint . -f github)
- if [ -n "$RESULT" ]; then
- echo "YAML Lint found issues"
- echo "$RESULT"
- echo "::set-output name=result::$RESULT"
- exit 1
- fi
-
- # only post a comment if the linting fails
- - name: Post comment
- uses: unsplash/comment-on-pr@v1.3.1
- if: failure()
- env:
- GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- with:
- msg: |
- [yaml-lint] YamlLint found issues in the pipeline files.
- ${{ steps.lint-pipeline.outputs.result }}
- check_for_duplicate_msg: true
- delete_prev_regex_msg: "YamlLint found issues in the pipeline files."
- duplicate_msg_pattern: "YamlLint found issues in the pipeline files."
+ yamllint . -f github
From 2b66dc0bb4856ee2977d6e413721463e986d2297 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Tue, 19 May 2026 17:42:45 +0200
Subject: [PATCH 074/156] [github] Remove unused workflows. (#25466)
These are all already disabled, and have been for a while, so just remove them.
---
.github/workflows/label-checker.yml | 30 -----------------
.github/workflows/localization-update.yml | 30 -----------------
.../workflows/localization_branch_sync.yml | 32 -------------------
.github/workflows/pwsh-ci.yml | 22 -------------
4 files changed, 114 deletions(-)
delete mode 100644 .github/workflows/label-checker.yml
delete mode 100644 .github/workflows/localization-update.yml
delete mode 100644 .github/workflows/localization_branch_sync.yml
delete mode 100644 .github/workflows/pwsh-ci.yml
diff --git a/.github/workflows/label-checker.yml b/.github/workflows/label-checker.yml
deleted file mode 100644
index 58a7169aa78d..000000000000
--- a/.github/workflows/label-checker.yml
+++ /dev/null
@@ -1,30 +0,0 @@
-name: Labels verification
-on:
- pull_request:
- types: [opened, reopened, labeled, unlabeled, synchronize]
-
-permissions:
- contents: read
-
-jobs:
- labels-check:
- permissions:
- contents: none
- runs-on: ubuntu-latest
- name: Labels verification
-
- steps:
- - run: exit 0
- name: 'Monojenkins PR'
- # always happy if monojenkins
- if: github.actor == 'vs-mobiletools-engineering-service2' || github.actor == 'github-actions[bot]' || github.actor == 'dotnet-maestro[bot]'
-
- - run: exit 1
- name: 'User PR with no labels'
- # failure if not monojenkins and not dotnet-maestro and no labels
- if: github.actor != 'vs-mobiletools-engineering-service2' && github.actor != 'dotnet-maestro[bot]' && join(github.event.pull_request.labels, ',') == ''
-
- - run: exit 0
- name: 'User PR with labels'
- # success if not monojenkins but labels
- if: github.actor != 'vs-mobiletools-engineering-service2' && github.actor != 'dotnet-maestro[bot]' && join(github.event.pull_request.labels, ',') != ''
diff --git a/.github/workflows/localization-update.yml b/.github/workflows/localization-update.yml
deleted file mode 100644
index 4e7c3b47a0ce..000000000000
--- a/.github/workflows/localization-update.yml
+++ /dev/null
@@ -1,30 +0,0 @@
-name: Get Localization Translations
-on:
- push:
- branches:
- - "lego/*"
-
-permissions:
- contents: read
-
-jobs:
- pull-request:
- permissions:
- contents: read # for actions/checkout to fetch code
- pull-requests: write # for repo-sync/pull-request to create pull requests
- name: '[Localization PR to main]'
- runs-on: ubuntu-latest
- steps:
- - uses: actions/checkout@v6
- name: checkout
-
- - uses: repo-sync/pull-request@v2
- name: pull-request
- with:
- destination_branch: "main"
- pr_title: "[Localization] Pulling New Localization Translations $GITHUB_RUN_ID"
- pr_body: "Automated PR. Bring new translated changes in the lcl files for OneLocBuild to create translated resx files."
- pr_label: "localization_bot,not-notes-worthy"
- pr_milestone: "Future"
- pr_allow_empty: false
- github_token: ${{ secrets.GITHUB_TOKEN }}
diff --git a/.github/workflows/localization_branch_sync.yml b/.github/workflows/localization_branch_sync.yml
deleted file mode 100644
index 93f6ad852dc0..000000000000
--- a/.github/workflows/localization_branch_sync.yml
+++ /dev/null
@@ -1,32 +0,0 @@
-# Disabling this action since we do something similar already in the CI
-
-name: Sync Localization Branch
-on:
- pull_request:
- branches:
- - 'main'
- types: [closed]
-
-concurrency:
- group: 'Localization-Sync'
- cancel-in-progress: false
-
-jobs:
- replaceLocalizationBranch:
- name: 'Replace Localization Branch'
- runs-on: ubuntu-latest
- if: ${{ github.event.pull_request.merged == true && github.event.pull_request.user.login == 'github-actions[bot]' && contains(github.event.pull_request.labels.*.name, 'localization_bot') }}
- steps:
- - uses: dawidd6/action-delete-branch@v3
- name: 'delete'
- with:
- github_token: ${{ secrets.GITHUB_TOKEN }}
- branches: Localization
- soft_fail: true
-
- - uses: peterjgrainger/action-create-branch@v4.0.0
- name: 'Create Localization Branch'
- env:
- GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- with:
- branch: 'Localization'
diff --git a/.github/workflows/pwsh-ci.yml b/.github/workflows/pwsh-ci.yml
deleted file mode 100644
index dc06a8786d0a..000000000000
--- a/.github/workflows/pwsh-ci.yml
+++ /dev/null
@@ -1,22 +0,0 @@
-name: CI for pwsh
-on:
- push:
- branches: [ main ]
- pull_request:
-permissions:
- contents: read
-
-jobs:
- test-pwsh:
- runs-on: ubuntu-latest
- steps:
- - uses: actions/checkout@v6
- - name: Run Pester tests
- run: |
- Set-PSRepository psgallery -InstallationPolicy trusted
- Install-Module -Name Pester -Confirm:$false -Force
-
- Invoke-Pester -Path *.Tests.ps1
- if ($Error[0].Fullyqualifiederrorid -eq 'PesterAssertionFailed') {exit 1}
- working-directory: ./tools/devops/automation/scripts
- shell: pwsh
From 49f6b83022209b38976d07a1bd70cb1fbbce6bfb Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Wed, 20 May 2026 01:19:20 +0200
Subject: [PATCH 075/156] [github] Use/require fewer permissions in the 'Bump
global.json' workflow. (#25469)
'zizmor' reports no issues for this workflow now.
---
.github/workflows/bump-global-json.yml | 18 +++++++++++++-----
1 file changed, 13 insertions(+), 5 deletions(-)
diff --git a/.github/workflows/bump-global-json.yml b/.github/workflows/bump-global-json.yml
index f66a3a0b7eb7..0644a2c53429 100644
--- a/.github/workflows/bump-global-json.yml
+++ b/.github/workflows/bump-global-json.yml
@@ -1,5 +1,10 @@
name: Bump global.json for dotnet/sdk bumps
-on: pull_request_target
+
+on:
+ pull_request:
+ types: [opened, synchronize]
+
+permissions: {}
jobs:
bump-global-json:
@@ -10,14 +15,18 @@ jobs:
# https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs
permissions:
contents: write
- if: contains(github.event.pull_request.title, 'Update dependencies from dotnet/') && github.actor == 'dotnet-maestro[bot]'
+ # We'll never need to run this workflow for PRs from forks, so explicitly avoid that to limit potential exposure
+ if: github.event.pull_request.head.repo.full_name == github.repository &&
+ github.event.pull_request.user.login == 'dotnet-maestro[bot]' &&
+ contains(github.event.pull_request.title, 'Update dependencies from dotnet/')
steps:
- name: 'Checkout repo'
- uses: actions/checkout@v6
+ uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
with:
fetch-depth: 0
repository: ${{ github.event.pull_request.head.repo.full_name }}
- ref: ${{ github.event.pull_request.head.sha }}
+ ref: ${{ github.head_ref }}
+ persist-credentials: true # we need the credentials to push code
- name: 'Update global.json'
env:
@@ -34,6 +43,5 @@ jobs:
git add -- global.json
git config --global user.email "github-actions@xamarin.com"
git config --global user.name "GitHub Actions"
- git checkout "$GITHUB_HEAD_REF"
git commit -m "Re-generate global.json for PR #$PR_NUMBER: $PR_TITLE"
git push
From e70475bd75822305d7dcf152c3743d2e5500e78c Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Wed, 20 May 2026 01:19:40 +0200
Subject: [PATCH 076/156] [github] Enable cooldown for dependabot. (#25470)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
This makes us less susceptible to supply-chain attacks.
It also makes zizmor happy:
$ zizmor .github/dependabot.yml
INFO zizmor: 🌈 zizmor v1.25.2
INFO audit: zizmor: 🌈 completed .github/dependabot.yml
No findings to report. Good job!
References:
* https://blog.yossarian.net/2025/11/21/We-should-all-be-using-dependency-cooldowns#fnref:apt
* https://mattsch.com/blog/2026/03/28/harden-your-github-actions-workflows-with-zizmor-dependency-pinning-and-dependency-cooldowns/
---
.github/dependabot.yml | 2 ++
1 file changed, 2 insertions(+)
diff --git a/.github/dependabot.yml b/.github/dependabot.yml
index 5ace4600a1f2..6cc00712d1c7 100644
--- a/.github/dependabot.yml
+++ b/.github/dependabot.yml
@@ -4,3 +4,5 @@ updates:
directory: "/"
schedule:
interval: "weekly"
+ cooldown:
+ default-days: 7
From cdb7987f0afd359c222d65aa269e1447faa1e4d2 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Wed, 20 May 2026 01:20:08 +0200
Subject: [PATCH 077/156] [github] Remove the backport trigger workflow.
(#25471)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
It's not working, and I'm not sure how much work it would be to make it work
again, so just remove it for now. Arcade might have something we could (re)use
if we wanted to.
zizmor isn't quite happy about it, but I think it's fine anyway:
$ zizmor .github/workflows/backport-trigger.yml
INFO zizmor: 🌈 zizmor v1.25.2
fatal: no audit was performed
invalid input: .github/workflows/backport-trigger.yml
---
.github/workflows/backport-trigger.yml | 56 --------------------------
1 file changed, 56 deletions(-)
delete mode 100644 .github/workflows/backport-trigger.yml
diff --git a/.github/workflows/backport-trigger.yml b/.github/workflows/backport-trigger.yml
deleted file mode 100644
index 0cc0f263e5f6..000000000000
--- a/.github/workflows/backport-trigger.yml
+++ /dev/null
@@ -1,56 +0,0 @@
-name: Backport Trigger
-
-on:
- issue_comment:
- types: [created]
-
-jobs:
- setupBackport:
- runs-on: ubuntu-latest
- # GITHUB_TOKEN change from read-write to read-only on 2024-02-01 requires permissions block
- # https://docs.opensource.microsoft.com/github/apps/permission-changes/
- # https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs
- permissions:
- actions: write
- contents: read
- security-events: write
- if: github.event.issue.pull_request != '' && startswith(github.event.comment.body, '/sudo backport')
- outputs:
- target_branch: ${{ steps.parse_comment.outputs.target_branch }}
- steps:
- - name: Parse Comment
- id: parse_comment
- shell: pwsh
- run: |
- Write-Host "Parsing $env:COMMENT"
- ($botName, $backport, $backportTargetBranch) = [System.Text.RegularExpressions.Regex]::Split("$env:COMMENT", "\s+")
- Write-Host "GITHUB_OUTPUT: ${env:GITHUB_OUTPUT}"
- [IO.File]::AppendAllText($env:GITHUB_OUTPUT, "target_branch=${backportTargetBranch}$([Environment]::NewLine)") # Equivalent to the deprecated ::set-output command: https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idoutputs
- env:
- COMMENT: "${{ github.event.comment.body }}"
-
- launchBackportBuild:
- needs: setupBackport
- uses: xamarin/backport-bot-action/.github/workflows/backport-action.yml@v2.0
- # GITHUB_TOKEN change from read-write to read-only on 2024-02-01 requiring permissions block
- # https://docs.opensource.microsoft.com/github/apps/permission-changes/
- # https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs
- permissions:
- actions: none
- contents: read
- security-events: none
- id-token: write # The backport-action template being invoked requires this permission
- with:
- pull_request_url: ${{ github.event.issue.pull_request.url }}
- target_branch: ${{ needs.setupBackport.outputs.target_branch }}
- comment_author: ${{ github.actor }}
- github_repository: ${{ github.repository }}
- use_fork: false
- secrets:
- azure_tenant_id: ${{ secrets.BACKPORT_AZURE_TENANT_ID }}
- azure_subscription_id: ${{ secrets.BACKPORT_AZURE_SUBSCRIPTION_ID }}
- azure_client_id: ${{ secrets.BACKPORT_AZURE_CLIENT_ID }}
- ado_organization: ${{ secrets.ADO_PROJECTCOLLECTION }}
- ado_project: ${{ secrets.ADO_PROJECT }}
- backport_pipeline_id: ${{ secrets.BACKPORT_PIPELINEID }}
- github_account_pat: ${{ secrets.SERVICEACCOUNT_PAT }}
From b973ea4c475f974ac01f06ed29a4a21eda4f81a8 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Wed, 20 May 2026 01:20:44 +0200
Subject: [PATCH 078/156] [github] Harden 'Maestro changelog' workflow
permissions and pin actions (#25472)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
- Remove unnecessary 'issues: write' permission (pull-requests: write
is sufficient for PR comments).
- Add top-level 'permissions: {}' for least privilege.
- Use github.event.pull_request.user.login instead of github.actor
(actor can differ on workflow re-runs).
- Pin actions/setup-dotnet and actions/github-script to commit SHAs.
zizmor is happy:
$ zizmor .github/workflows/maestro-changelog.yml
INFO zizmor: 🌈 zizmor v1.25.2
INFO audit: zizmor: 🌈 completed .github/workflows/maestro-changelog.yml
No findings to report. Good job! (1 suppressed)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
.github/workflows/maestro-changelog.yml | 12 +++++++-----
1 file changed, 7 insertions(+), 5 deletions(-)
diff --git a/.github/workflows/maestro-changelog.yml b/.github/workflows/maestro-changelog.yml
index d69b1124d873..e390cd2d872c 100644
--- a/.github/workflows/maestro-changelog.yml
+++ b/.github/workflows/maestro-changelog.yml
@@ -1,6 +1,9 @@
name: Add changelog for Maestro bump
+
on: pull_request
+permissions: {}
+
jobs:
add-changelog:
name: Add changelog
@@ -9,13 +12,12 @@ jobs:
# https://docs.opensource.microsoft.com/github/apps/permission-changes/
# https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs
permissions:
- issues: write
- pull-requests: write
+ pull-requests: write # will add/edit comments
contents: read
- if: github.actor == 'dotnet-maestro[bot]'
+ if: github.event.pull_request.user.login == 'dotnet-maestro[bot]'
steps:
- - uses: actions/setup-dotnet@v5
+ - uses: actions/setup-dotnet@c2fa09f4bde5ebb9d1777cf28262a3eb3db3ced7 # v5
with:
dotnet-version: '9'
@@ -28,7 +30,7 @@ jobs:
./bin/Debug/net9.0/changelog https://github.com/$GITHUB_REPOSITORY/pull/${GITHUB_REF_NAME/\/*/} > /tmp/changelog.txt 2>&1
- name: 'Add changelog'
- uses: actions/github-script@v9.0.0
+ uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
From 3fbea17f7c684afab44dfd699aa5793792d05b45 Mon Sep 17 00:00:00 2001
From: Rolf Bjarne Kvinge
Date: Wed, 20 May 2026 12:10:39 +0200
Subject: [PATCH 079/156] [tests] Fix actool warnings in test icon asset
catalogs (#25475)
Replace legacy multi-size app icon sets with modern single-size
(1024x1024) format. The old format had:
- Case mismatch: Icon-app-60@3x.png vs icon-app-60@3x.png
- Deprecated 57x57 and 72x72 icon sizes
- Deprecated 76x76@1x (non-retina iPad) icon size
The modern format uses a single universal 1024x1024 icon with
platform "ios", which works for all platform builds (iOS, tvOS,
macOS, Mac Catalyst) without warnings.
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---
.../AppIcons.appiconset/Contents.json | 209 +----------------
.../AppIcons.appiconset/icon-1024.png | Bin 0 -> 113000 bytes
.../AppIcons.appiconset/icon-app-57.png | Bin 1618 -> 0 bytes
.../AppIcons.appiconset/icon-app-57@2x.png | Bin 3206 -> 0 bytes
.../AppIcons.appiconset/icon-app-60@2x.png | Bin 3357 -> 0 bytes
.../AppIcons.appiconset/icon-app-72.png | Bin 1820 -> 0 bytes
.../AppIcons.appiconset/icon-app-72@2x.png | Bin 4093 -> 0 bytes
.../AppIcons.appiconset/icon-app-76.png | Bin 2082 -> 0 bytes
.../AppIcons.appiconset/icon-app-76@2x.png | Bin 4395 -> 0 bytes
.../AppIcons.appiconset/icon-app-83.5@2x.png | Bin 8968 -> 0 bytes
tests/introspection/dotnet/shared.csproj | 10 +-
.../AppIcons.appiconset/Contents.json | 222 +-----------------
.../AppIcons.appiconset/Icon-app-60@3x.png | Bin 5100 -> 0 bytes
.../AppIcons.appiconset/icon-1024.png | Bin 0 -> 113000 bytes
.../AppIcons.appiconset/icon-app-57.png | Bin 1618 -> 0 bytes
.../AppIcons.appiconset/icon-app-57@2x.png | Bin 3206 -> 0 bytes
.../AppIcons.appiconset/icon-app-60@2x.png | Bin 3357 -> 0 bytes
.../AppIcons.appiconset/icon-app-72.png | Bin 1820 -> 0 bytes
.../AppIcons.appiconset/icon-app-72@2x.png | Bin 4093 -> 0 bytes
.../AppIcons.appiconset/icon-app-76.png | Bin 2082 -> 0 bytes
.../AppIcons.appiconset/icon-app-76@2x.png | Bin 4395 -> 0 bytes
.../AppIcons.appiconset/icon-app-83.5@2x.png | Bin 8968 -> 0 bytes
tests/linker/dont link/dotnet/shared.csproj | 10 +-
.../AppIcons.appiconset/Contents.json | 222 +-----------------
.../AppIcons.appiconset/Icon-app-60@3x.png | Bin 5100 -> 0 bytes
.../AppIcons.appiconset/icon-1024.png | Bin 0 -> 113000 bytes
.../AppIcons.appiconset/icon-app-57.png | Bin 1618 -> 0 bytes
.../AppIcons.appiconset/icon-app-57@2x.png | Bin 3206 -> 0 bytes
.../AppIcons.appiconset/icon-app-60@2x.png | Bin 3357 -> 0 bytes
.../AppIcons.appiconset/icon-app-72.png | Bin 1820 -> 0 bytes
.../AppIcons.appiconset/icon-app-72@2x.png | Bin 4093 -> 0 bytes
.../AppIcons.appiconset/icon-app-76.png | Bin 2082 -> 0 bytes
.../AppIcons.appiconset/icon-app-76@2x.png | Bin 4395 -> 0 bytes
.../AppIcons.appiconset/icon-app-83.5@2x.png | Bin 8968 -> 0 bytes
tests/linker/link all/dotnet/shared.csproj | 10 +-
.../AppIcons.appiconset/Contents.json | 222 +-----------------
.../AppIcons.appiconset/Icon-app-60@3x.png | Bin 5100 -> 0 bytes
.../AppIcons.appiconset/icon-1024.png | Bin 0 -> 113000 bytes
.../AppIcons.appiconset/icon-app-57.png | Bin 1618 -> 0 bytes
.../AppIcons.appiconset/icon-app-57@2x.png | Bin 3206 -> 0 bytes
.../AppIcons.appiconset/icon-app-60@2x.png | Bin 3357 -> 0 bytes
.../AppIcons.appiconset/icon-app-72.png | Bin 1820 -> 0 bytes
.../AppIcons.appiconset/icon-app-72@2x.png | Bin 4093 -> 0 bytes
.../AppIcons.appiconset/icon-app-76.png | Bin 2082 -> 0 bytes
.../AppIcons.appiconset/icon-app-76@2x.png | Bin 4395 -> 0 bytes
.../AppIcons.appiconset/icon-app-83.5@2x.png | Bin 8968 -> 0 bytes
tests/linker/link sdk/dotnet/shared.csproj | 10 +-
.../linker/trimmode copy/dotnet/shared.csproj | 10 +-
.../linker/trimmode link/dotnet/shared.csproj | 10 +-
.../AppIcons.appiconset/Contents.json | 222 +-----------------
.../AppIcons.appiconset/Icon-app-60@3x.png | Bin 5100 -> 0 bytes
.../AppIcons.appiconset/icon-1024.png | Bin 0 -> 113000 bytes
.../AppIcons.appiconset/icon-app-57.png | Bin 1618 -> 0 bytes
.../AppIcons.appiconset/icon-app-57@2x.png | Bin 3206 -> 0 bytes
.../AppIcons.appiconset/icon-app-60@2x.png | Bin 3357 -> 0 bytes
.../AppIcons.appiconset/icon-app-72.png | Bin 1820 -> 0 bytes
.../AppIcons.appiconset/icon-app-72@2x.png | Bin 4093 -> 0 bytes
.../AppIcons.appiconset/icon-app-76.png | Bin 2082 -> 0 bytes
.../AppIcons.appiconset/icon-app-76@2x.png | Bin 4395 -> 0 bytes
.../AppIcons.appiconset/icon-app-83.5@2x.png | Bin 8968 -> 0 bytes
60 files changed, 46 insertions(+), 1111 deletions(-)
create mode 100644 tests/introspection/Assets.xcassets/AppIcons.appiconset/icon-1024.png
delete mode 100644 tests/introspection/Assets.xcassets/AppIcons.appiconset/icon-app-57.png
delete mode 100644 tests/introspection/Assets.xcassets/AppIcons.appiconset/icon-app-57@2x.png
delete mode 100644 tests/introspection/Assets.xcassets/AppIcons.appiconset/icon-app-60@2x.png
delete mode 100644 tests/introspection/Assets.xcassets/AppIcons.appiconset/icon-app-72.png
delete mode 100644 tests/introspection/Assets.xcassets/AppIcons.appiconset/icon-app-72@2x.png
delete mode 100644 tests/introspection/Assets.xcassets/AppIcons.appiconset/icon-app-76.png
delete mode 100644 tests/introspection/Assets.xcassets/AppIcons.appiconset/icon-app-76@2x.png
delete mode 100644 tests/introspection/Assets.xcassets/AppIcons.appiconset/icon-app-83.5@2x.png
delete mode 100644 tests/linker/dont link/Assets.xcassets/AppIcons.appiconset/Icon-app-60@3x.png
create mode 100644 tests/linker/dont link/Assets.xcassets/AppIcons.appiconset/icon-1024.png
delete mode 100644 tests/linker/dont link/Assets.xcassets/AppIcons.appiconset/icon-app-57.png
delete mode 100644 tests/linker/dont link/Assets.xcassets/AppIcons.appiconset/icon-app-57@2x.png
delete mode 100644 tests/linker/dont link/Assets.xcassets/AppIcons.appiconset/icon-app-60@2x.png
delete mode 100644 tests/linker/dont link/Assets.xcassets/AppIcons.appiconset/icon-app-72.png
delete mode 100644 tests/linker/dont link/Assets.xcassets/AppIcons.appiconset/icon-app-72@2x.png
delete mode 100644 tests/linker/dont link/Assets.xcassets/AppIcons.appiconset/icon-app-76.png
delete mode 100644 tests/linker/dont link/Assets.xcassets/AppIcons.appiconset/icon-app-76@2x.png
delete mode 100644 tests/linker/dont link/Assets.xcassets/AppIcons.appiconset/icon-app-83.5@2x.png
delete mode 100644 tests/linker/link all/Assets.xcassets/AppIcons.appiconset/Icon-app-60@3x.png
create mode 100644 tests/linker/link all/Assets.xcassets/AppIcons.appiconset/icon-1024.png
delete mode 100644 tests/linker/link all/Assets.xcassets/AppIcons.appiconset/icon-app-57.png
delete mode 100644 tests/linker/link all/Assets.xcassets/AppIcons.appiconset/icon-app-57@2x.png
delete mode 100644 tests/linker/link all/Assets.xcassets/AppIcons.appiconset/icon-app-60@2x.png
delete mode 100644 tests/linker/link all/Assets.xcassets/AppIcons.appiconset/icon-app-72.png
delete mode 100644 tests/linker/link all/Assets.xcassets/AppIcons.appiconset/icon-app-72@2x.png
delete mode 100644 tests/linker/link all/Assets.xcassets/AppIcons.appiconset/icon-app-76.png
delete mode 100644 tests/linker/link all/Assets.xcassets/AppIcons.appiconset/icon-app-76@2x.png
delete mode 100644 tests/linker/link all/Assets.xcassets/AppIcons.appiconset/icon-app-83.5@2x.png
delete mode 100644 tests/linker/link sdk/Assets.xcassets/AppIcons.appiconset/Icon-app-60@3x.png
create mode 100644 tests/linker/link sdk/Assets.xcassets/AppIcons.appiconset/icon-1024.png
delete mode 100644 tests/linker/link sdk/Assets.xcassets/AppIcons.appiconset/icon-app-57.png
delete mode 100644 tests/linker/link sdk/Assets.xcassets/AppIcons.appiconset/icon-app-57@2x.png
delete mode 100644 tests/linker/link sdk/Assets.xcassets/AppIcons.appiconset/icon-app-60@2x.png
delete mode 100644 tests/linker/link sdk/Assets.xcassets/AppIcons.appiconset/icon-app-72.png
delete mode 100644 tests/linker/link sdk/Assets.xcassets/AppIcons.appiconset/icon-app-72@2x.png
delete mode 100644 tests/linker/link sdk/Assets.xcassets/AppIcons.appiconset/icon-app-76.png
delete mode 100644 tests/linker/link sdk/Assets.xcassets/AppIcons.appiconset/icon-app-76@2x.png
delete mode 100644 tests/linker/link sdk/Assets.xcassets/AppIcons.appiconset/icon-app-83.5@2x.png
delete mode 100644 tests/monotouch-test/Assets.xcassets/AppIcons.appiconset/Icon-app-60@3x.png
create mode 100644 tests/monotouch-test/Assets.xcassets/AppIcons.appiconset/icon-1024.png
delete mode 100644 tests/monotouch-test/Assets.xcassets/AppIcons.appiconset/icon-app-57.png
delete mode 100644 tests/monotouch-test/Assets.xcassets/AppIcons.appiconset/icon-app-57@2x.png
delete mode 100644 tests/monotouch-test/Assets.xcassets/AppIcons.appiconset/icon-app-60@2x.png
delete mode 100644 tests/monotouch-test/Assets.xcassets/AppIcons.appiconset/icon-app-72.png
delete mode 100644 tests/monotouch-test/Assets.xcassets/AppIcons.appiconset/icon-app-72@2x.png
delete mode 100644 tests/monotouch-test/Assets.xcassets/AppIcons.appiconset/icon-app-76.png
delete mode 100644 tests/monotouch-test/Assets.xcassets/AppIcons.appiconset/icon-app-76@2x.png
delete mode 100644 tests/monotouch-test/Assets.xcassets/AppIcons.appiconset/icon-app-83.5@2x.png
diff --git a/tests/introspection/Assets.xcassets/AppIcons.appiconset/Contents.json b/tests/introspection/Assets.xcassets/AppIcons.appiconset/Contents.json
index 284e15f9906c..0e65c18b41c3 100644
--- a/tests/introspection/Assets.xcassets/AppIcons.appiconset/Contents.json
+++ b/tests/introspection/Assets.xcassets/AppIcons.appiconset/Contents.json
@@ -1,208 +1,15 @@
{
"images": [
{
- "size": "29x29",
- "scale": "1x",
- "idiom": "iphone"
- },
- {
- "size": "29x29",
- "scale": "2x",
- "idiom": "iphone"
- },
- {
- "size": "29x29",
- "scale": "3x",
- "idiom": "iphone"
- },
- {
- "size": "40x40",
- "scale": "2x",
- "idiom": "iphone"
- },
- {
- "size": "40x40",
- "scale": "3x",
- "idiom": "iphone"
- },
- {
- "filename": "icon-app-57.png",
- "size": "57x57",
- "scale": "1x",
- "idiom": "iphone"
- },
- {
- "filename": "icon-app-57@2x.png",
- "size": "57x57",
- "scale": "2x",
- "idiom": "iphone"
- },
- {
- "filename": "icon-app-60@2x.png",
- "size": "60x60",
- "scale": "2x",
- "idiom": "iphone"
- },
- {
- "size": "29x29",
- "scale": "1x",
- "idiom": "ipad"
- },
- {
- "size": "29x29",
- "scale": "2x",
- "idiom": "ipad"
- },
- {
- "size": "40x40",
- "scale": "1x",
- "idiom": "ipad"
- },
- {
- "size": "40x40",
- "scale": "2x",
- "idiom": "ipad"
- },
- {
- "size": "50x50",
- "scale": "1x",
- "idiom": "ipad"
- },
- {
- "size": "50x50",
- "scale": "2x",
- "idiom": "ipad"
- },
- {
- "filename": "icon-app-83.5@2x.png",
- "size": "83.5x83.5",
- "scale": "2x",
- "idiom": "ipad"
- },
- {
- "filename": "icon-app-72.png",
- "size": "72x72",
- "scale": "1x",
- "idiom": "ipad"
- },
- {
- "filename": "icon-app-72@2x.png",
- "size": "72x72",
- "scale": "2x",
- "idiom": "ipad"
- },
- {
- "filename": "icon-app-76.png",
- "size": "76x76",
- "scale": "1x",
- "idiom": "ipad"
- },
- {
- "filename": "icon-app-76@2x.png",
- "size": "76x76",
- "scale": "2x",
- "idiom": "ipad"
- },
- {
- "role": "notificationCenter",
- "size": "24x24",
- "subtype": "38mm",
- "scale": "2x",
- "idiom": "watch"
- },
- {
- "role": "notificationCenter",
- "size": "27.5x27.5",
- "subtype": "42mm",
- "scale": "2x",
- "idiom": "watch"
- },
- {
- "role": "companionSettings",
- "size": "29x29",
- "scale": "2x",
- "idiom": "watch"
- },
- {
- "role": "companionSettings",
- "size": "29x29",
- "scale": "3x",
- "idiom": "watch"
- },
- {
- "role": "appLauncher",
- "size": "40x40",
- "subtype": "38mm",
- "scale": "2x",
- "idiom": "watch"
- },
- {
- "role": "quickLook",
- "size": "86x86",
- "subtype": "38mm",
- "scale": "2x",
- "idiom": "watch"
- },
- {
- "role": "quickLook",
- "size": "98x98",
- "subtype": "42mm",
- "scale": "2x",
- "idiom": "watch"
- },
- {
- "size": "16x16",
- "scale": "1x",
- "idiom": "mac"
- },
- {
- "size": "16x16",
- "scale": "2x",
- "idiom": "mac"
- },
- {
- "size": "32x32",
- "scale": "1x",
- "idiom": "mac"
- },
- {
- "size": "32x32",
- "scale": "2x",
- "idiom": "mac"
- },
- {
- "size": "128x128",
- "scale": "1x",
- "idiom": "mac"
- },
- {
- "size": "128x128",
- "scale": "2x",
- "idiom": "mac"
- },
- {
- "size": "256x256",
- "scale": "1x",
- "idiom": "mac"
- },
- {
- "size": "256x256",
- "scale": "2x",
- "idiom": "mac"
- },
- {
- "size": "512x512",
- "scale": "1x",
- "idiom": "mac"
- },
- {
- "size": "512x512",
- "scale": "2x",
- "idiom": "mac"
+ "filename": "icon-1024.png",
+ "idiom": "universal",
+ "platform": "ios",
+ "size": "1024x1024"
}
],
"info": {
- "version": 1,
- "author": "xcode"
+ "author": "xcode",
+ "version": 1
}
-}
\ No newline at end of file
+}
+
diff --git a/tests/introspection/Assets.xcassets/AppIcons.appiconset/icon-1024.png b/tests/introspection/Assets.xcassets/AppIcons.appiconset/icon-1024.png
new file mode 100644
index 0000000000000000000000000000000000000000..1e62561f25b7d14cb7fbea5e7366c0463e58591e
GIT binary patch
literal 113000
zcmeEu2Uk;T(C$tMO;MUs6zNTrjsntxD4>88rFW4cMS3p@h#-Q1ihy)QML>!I(u5#Y
ziUg#K^xk_3B-wWd&-uQ4?)e9Io#k>FOtSa;&O7rwGtbN>O6Qi^iDPGu0RV8~hWa%<
z06;)55dakh^bhLXg@>e{?3J~Y0pL^IalAD-^fRZ8x}FvQ1n>g@IvfBFp#MV81Aw;}
z04!Poz?EbGV0KHZ(v^qaxMpi~!%j;J5Q1J)0kFvXN7sizKb?X80svVS3?PI4g+YIS
zEcoB=B7iKi|9wsRV9&_nIRHQcH?Aq)@q;bbEcmcVe|eDFaWA{MZ#nOm_bx7Q49x9h
z_5JNp>3rkMpsmWNs|e!xw^QfapR4n;GU|B&+!A6i?tYW`lZ8`uSE$vIaE5p^f|nEa
z_e%?@P+at_^r#pA_}`-sWKlT)#hm~C3O^D_R)>%n;=TE=t4RSy6#v)7|9Z*DnFX_g
zzj9{a```Qi_0}2SBH915B3{l=YPv2!EL8Jy)W6<>od6R5XYK!Ur#b|*)MO-o>b1YO
z^*?W+DS-BWZ_NshkODM0UueDgzisj7OJr!;At6pu^HbYo34ngUII@AHj>e=Qd}2Acnlfn>7(j^TeDo8-Cw
zMZ@0#{~sv*1IhjarN1HhKW_LZ*ZfD(e?#bh6#dWi>c33sZwUP_Vf{yz`(MKPH-!FI
zH~g~>`LBHY8$$mp-~P_T|Iq7yRrFsF`k$EbcP9Qv*Z5D&_!~n16EptK#Q)Iie`3bp
z5c>azm~m1dUiC=+93P^q=uEXRx3o|FA;VE!B?5-;p#!JNs)uXUYGo%;@hi3KsmU2P
zkZ{qbNWzMJ%ZA7RftDdVbI;FP!OtU^F`KZayQn^>?6b8jGXQ;zA-*mIl8B2raO0*>
zG%<3!W&V7s^aRxRNj=Ad9CwQ^+1G}Hq6
zj_4EQ`Kjgo2CTcG?An0fuHbsbs$t9W&4oCnHUfV9fRP8-sPO$J89~|m%rpI{FpxhF
z>22Ci#yFDDi1(_%t3#1TXO$9Ar@)!MKIgK^DqDo$BSqgg_#%%_+#YNLEHD#4|Cf{6
zw6HhJXJEg~A1+(&o!l#Z7)Y%?PR>|S5QEA~^W{57j>?FBNONkXP0?C#M}bDOCCW=G
z)6fi0y|%$r$%*HjV1Y+~qRE9fNDBSBJS24cvE!yqA?;lh4Yc{XboW`
z#VZv`m&E1o^iv^O8sJr%s4ulC>4hd7KnzUbtJ2vfl=-k&g4Mo4y}Pi*t)CuASu54s
z>rYBYxH^|0)qU<(7V&v1yM^!`e#5nTj+WTCaExeue(wjJPFrxj&Z0O?*7npWd#BTq
zDw=)tC0HIAJ+wm~f$l$x4)h&4XHl*DHIanzp=;_;gTOa@A)6H6cy^e{^ui=2-??W~
zJD=#E09uL~miQ(uU1@PmFWzzc8WTF+;Gqzx!~#^TPLv*O1<}CU8||mQhP+^&`g+ch
z>YH+*7>^g`3fHJ`j$g>}NM;7V_Xv}vAg3Km8dN`dO+&z57F76y$>Nde9OQss2?JOWO>}+Sha6)Gb#v5Nq+=k0&
zM}wm6+jJF110!Zr+J3}=3RD2X%);`A$Q0K91rR?yAz|!@RFEZRd
zJgTXx03urVw+eDY2|$Icdi28s>9qc>>RrDNxI7mqnNu_
zk*Dz1)iKuN+@3%hAB}Iu61&gKoa|+RiUbr5b=s5~3k96b_bwpwoef|cev$Gli~IMl
zOUlH=BxWe;N_gDpn$j?KUY-eF5fm?BoCEuew^)XCI|mH6hORtOoU=hSAMRC6|FDjE
znrmN7X=d4?^zz0@{q7yyjmN{~2e0kbI+;mMvi_O0P-EPEN6267ZvrE1T$S3pExaLA
zU4nZtGopM-14;D7*zB?%IiMvRt-!vQ2;*#tPBY`RSc4&r2+iwqXA9?HVk{H^Mhafl
zD#BeP^aw?6?|%c3?MmkzTNLRzCp!8qDZ-Z9WRe520{|N9zP8M^unL)&g!XIlPsBe7
z6))cE3bB82<-_9J#_W*pe*=qXc%6BeNQg64!@KWl4zp|n4L7^v!272Hs&*{9ep=Rh
zufe)vYYYL%WOe|;yK3kSeo8AkgnD#FS`QC7z!(Lqq9W9F8*gG9r$tTQ1&8~|XVTa6
zU+ZNNvu+LX{!|u9e3B}*jejV$RkZ#%dnYsC7*G8b;?lk+mVX48x4x#$7jWKM%&2M2
zuflczmBi(XpZl#W6|xQo8bzqcxAD{y_hSSIUPA^xfW{vu+6cyrxnTTmS
z1|bMLlRc~r6|#6$0dP!1A>5mHME(2Md0Z+nc8EFvy=f`zD|=FR@w-2!^M2)O`O;Ve
z$sa}IkYM%N`LiHlPb{`ZMEU$0aVw3D7ybIW%woYAI9{?VmhB-rRo&;tpoF={*cTWNq{Wyn_`z)@1iA@G~$T^wI)|PGKp=3ZN(BY}CJ{
zUcc5IbEA%~D-eEXyf{Bu_+W6@^N6YUZ$eGMT86Z8(owK5A{}Bs%G>;2s*qE3H(3gC
z8Uh#Y${sG<)i1z@zy6)Xpq(GG`mPT{10=anA#bk^8<}{8Od6D%gj|eWa@@e$O3RyF
zPZNEpjF%Cx8(Vy@hxZ@5Y*o$*7rIxv#31dvyQN#4LyAFeG2(^UqB8{BlS(g{Vq}tEL{6%;{auDH-b#@7mI95QX-h-v<6~|1b
zLCI)Yrdabz_8=xs3=gIY+k5a&7I20^6nqLZy@X%6&11#6
zT$t(JsQQ@x(k+UzP3yLQcgnIuld5|!)F-wikLy{ZDP-g|%t1Q^H
z)@&>vbo|70AdJ1nK;fxF)D2p+FMW)=W_;6IRKXn5sT*V|AlgXbN2|11VinF_4KyVi
zZ;o4E6|y*3*;GvPl~&A=T|-knv>KW6gSxmDilKSOH_Md@8E>w!%gf}5@TlS*h8LSz
zvCW4>``x7(uflJ3WT#~Z7a9rE;Ms;;N$h6^EXBP{~!
zsZo|iQuxaje|q@)mr0)YG}BiD^1KQy&M={?D?S>6PBv@>-Sz5v_1MU1pQJH@w%9c|gWnB=;@+ONQQj-PUDtR1
zAEK!m#KY0-Hwh^wkE4i2cJV}Vf$pt1o29R}$RES3UW&!QYra&)h-YEl!*m(58|FqY
zeEVxBmp9fi+dkOH_n{aQl@f5*$q&GwjD5
zUdc-$guJI(XhQGyy|^xgicmMVD0>MoLyf!frl@~oEnr288!iA_yvb&{ouo)VK&y2bvWn)7Ir6J36Y4+@;Y=}hSppB
zq#vXabhZnhEmhHiI7~r*$zHoYD}n`#13Er}X_FH=mayI)oogtS5Cmfr}+~tQM6|fm4D+0omHN
zXNO{MB$AMlPfpTq{*jCZ7fmqIu6sB
zXg<6QUza%cI2SsIj2P%t1XR{&A=naqgiO*X@(2slUQ(n$OTgd8U4TQEky1`#0uf2s
zd>_jrT>P)yTotx6RnjIgh&&lwaATyb%6(Z8)@eeLp)7$B8x<;22ETNvx#BrLoh1?YrMc&2_)AMB-
zpc0Q?eC?;Vt@)93)Mw!}C!0>1c-ujzqo~me6G6?(8#b|X-X>t715`kO_9+T@QLV}18
z=pL)~Hjhcm)7yR~O@Bpqb>aE1r@*-KDFqE_utamUWrO?YMRSmqqDy)*$Jc2jt~jty
z05?VCubFjryR|-W7gf0Nijty~QliP)bnm&)ZRF>nqRkH1yO$m;Bq@G6go6-WK8z8
zZ);D+GPpi-jC)5MW$Uyr8i?+FL0N*aztOiRkSd6y%nf8N*|E0dEISW2Dj7E##p{zv
z!B5@vC7Du@bjJ1@EYOK-rUN#+y1VyrYB&@Jd1k+0^ZQAb%qMTK&LD<&IjMbSdBpM3
zVR5GfdV?n>*_m&D_U#^goEXp+OFj;SzS261CRs*xh20xkOqlnZ5O@t^K9s>H)eLRPd#u#E{}F{L~nh_Ac2t^VDAzZy>}H6_hcf
zq%~d%)f>&8@7WwnIM7OGRJ;syJ#V4|5)YR~K-t9SnH64pIV*V)fZ%JNuj~-mQqx!D
z(%aBzRTbHs7=PSpVX8%uT*8)L+Z3O&!d;W==uy{r){7_sm|0?b4zRa#@B4?{Izl}~
zHOLlo^DGdhXl4K^z@Wo=(I9}k{kWVtY(R>FY1
zzn1-$ZwDnp(ikHv3gjHC$7-N(faDKxc&=)>s^Q|W#w@kEFRYm$Y0McL1ryJ^oBRW`
zQ|qezHC{o=RorNyW$&T8P2mj5?4i{r@j6@d7qiEtXHaz4l5`K;OYsBAARE12OW3?Q
zHb3?EpYpE;kwSgxX0T>1i@tcVMCP$2_{Ecjj+Mv=3QD-5&?q1oRzq6E!1)BD0kd
z8mh!`a{>_LXmHj~7ycZ5i8^)IuDQAAUiOOc#VqM3Hu&PwzzHCn>urB>zm!Iw5!gS6
zAzVwpko>?uked|hC*f25CS}Gg1n7n5Yn-xp%nlNKZ;a&=!)%BT@H85)k#(0g(`fG_kwfHs~Xb+
zJFwR1$EbOs-Q4|W^`GQV+kl4meXc~0MfO!C!g*yz-KUs9AH`j+2$Fx*-J^~Pym5lA
zaI(A;cU`D^Z^3wH3g_YTrOg9%e?!T*lt)(~gK)jcsD
zJH|>LCL%Ac@0Hl9P3om1KTdRtQU
z<%17iS_I*qJD$$7p_i5Wc75rQ)pWn&hLJ~{pbo$Z|C^SoYhd
z;6>>6XQ;O32-LOA*zG!*yuDR2A%@7pXRnuBJM9Vd-UKQOWq}7fz<8|8OR)JH$^Sy-
zsC2;HD?8lYLRH^aY%xq%moqe_xf6cMgz=G?6@7ToO&H_eFp1euxBwd~;
zSz-WICUgT`9jnBgzRBU?Ah=X*LabCKSp*5sett?UTsV8Yq+tG+w#>%l
z7zI$82%aTFR@*OXYGFv0T2sj?TXc2UDLPZB;Qdhlax70xp~;AX=J%9@5X*HcK^O%jJ&JtujK#IRN=6uZ&Ld)KF1M}LOvv|i%o6~-ss53cHKlM3IUnT(Of
z|79i@L_p1x(9^-SJC%;ud+JQFHhJ@BGMeZLOrF`^1CSH;Z7<2y_-*flmHMPzTYV=1fvYPZ&gg`Ufiti`Zz
zgNUelc_lH!P=RI1}shLZjpUnn-e!MvFQO`P#q*j!f7y$p4v+>H?Si
zo=3qxq@rq#2DWa|N|#6*^T&&T(T&$}sKA73&mXd?==99|!y}YSJ_aGFE;NPgE(?UtpMZ
z8&V+&S`bd043%4IRc>gZD$cu71yT0X15Elu@|U24w>||LY*bJEW?C`;RR+w3h+0V8Lcc!fHS$Rb15H`f)0^?hO^ABLiNJWI{)W#=&M_@1qO
zIRn4V%5h?eTrX+hw}>TpWfa;iBpj0Dy}O@(hC_F@Q~|hNoPaUH+?&Et^t?kNQ$r_!
za()=w>cn1!@3K!(i}exd#n&Y93vH(WTe5D~iJhz8~U@j};G$cx~A)#Re#3e^C_g-*r3M
z{Cia>0qFJky?xWF9`WE>{aLF0Pp`l8@cM8uK$?7mCD|DwMrLnRp6dLlmdDvsS>C
zTQWy!cnM~u^*!YQ(4ykE1OM>Lf^p^cTq*`yu{=q{(QY5JgxHfk3V9w!kMKPg#$%ef
zgYo59i2!1qrG>#CR_hBdd@`5Ij<`o25o!S%)MRjE5euzNS+~ZB;ve%1nB3Sfi{$Zs
zECE9Y1lf@*Kj5aPNXfHk8d6pL&p!V_UkrW=h-KLNPtU<^2sR6%m4pfR`F^?JaubQ$
zD>*xl`M^$z>Rw~J=Ze^8#_#eek*hN)tM5J%4b3$IJ$04phxmYtE~Krpr$I&jZ9c;#
zMQ>@1(w}){zu7uOm8%=3`^!j|M0
z5}Vz3pmpxiAv@
zffcq<#rM4(R`KCejRDTU9{_!6@
zu3})Y43;5upoAlqsRWbx(T46j5Sqff?n7ymx8c9&6+>RFe;{33btL=@%0VEqE20s^
z1+6uZ9;yEJoxrB$`OSA#}g{Oc9}0&!Xb&`eco;
zqC%S1uQdb3u~)GMDnOoeo&F955~uW3H|xTo*P(rGu2!u1{zncSy^AzQO%{13*rJyi
zt8Yp5Ju3r#LbYbF<}i`FEl3NW^w^atdg%J1PXOBXEpp@`{eEJ5u&L70wyDEc=(sJ|
zA%_(e)z*4OVhli-*uaEBG;fHZzZ?Ue1fSKY%5w*`jNUq(_qaQzLv+H=k0(9+lRdM)
zLJo|{>g7n@$;Wnw!O(^HNZo1L9v*atWw0PK#mIx+;Az9%IZ{Y2pMY)>_~LXeRE@32
zBdQpb6gLC;kh6o2zUw1eQ&_~Q}3FfX-CbrXbiv#y~Vq`AK
z14G5FkTJauVE=x8`xi!Q+QoVjQ
z>_Y4jQ;I%?l7*zi?DuMr^vsY|EpSZXi9!KhbGap;+r{GpKlkU}u_3{a{7>2x3aaN_
z|f?rYwq(j%>g;?gg&!IB>w9^Su
z7OC3))kph!L)w?_(EYp6zQkcBxCLU=`d&z72Ep&k#~I>0Ir>c;&oVdR8YKMOyHQtq
zsxSD}x+u3*^!1L%5ASp3z2{1e1l}B7Neb~mXf`jq=R>BAX(oA7It~yiDze)$BEMDA
zu~hwWezOM`keG+s4G_<)QEZg&N<4n=O`YM!aGDeuQWJP3AMcNlf}P@pD%HAZ9!Ml@
zvdyJ_PAUl9m%zyOon=e=q!L=)ZQX+fdbG_&!4VJ@jo#;?K)3r9^_)oPayms^rK4D*
zqdHA5$9aVC>`8zRaQRe7?1-+Ys9sc03M!Emu4MMW4pcPh^C%KLbe1t8#+4AIT>AhX;8SPKJS_k4TEy%glM%Ta~yf}j_@!qYK-{4Y9m
zf4bL29fRrRJNt5fSatUy;Js5(`#z)ao%!wZ0Xno4K@x#}2Q!qlw1DKjHtm@96^v
z!H4k_W6DQ9tf+1E5xMlFX!xx{
zTq?iEwoQPN1S|uKHbUJAv~Awc#>briK5~s1!agu%Jx2Mm!kh`*7t`vOV@FY4>#4c!W-$dF~kIeE}@3;Q(4XydPHQIcD%ccyotfEh3c{lQdLqO45@
z5J6t*ip&EWi&kRaIwESxo>)LGQNkmZGO;*RQ!RQCy5~RXFTReMp_sCcIZPr2!CQ<$
zILyCR#%PUtZDj=iw%-BNWrPW=u;LYln;juPo;AN_`*L>TPcrBif|y^{4i0pa4i<
zolFjfuN4M|8YUi?zBSG)-c5IKcM=@*D@4mj_JeXvVg4ajK{ilgvPnuzYN@D@aBM1)
z+K+xU1wCNz_Tc^*?frokf@BYB?D6$-?F7*F%jJ_&SEuIQe#Jgga80N^Du9?(vd)7)
zzPAs8CB1|S+XH+Fo}=*Wqqq{gasPso@lo(CEu(vK9sTD%RX*Y(Tj^wC&XS}i2xG(eh)*%t?E#V10HLrc6!Ylf0AL;1aDdnUT?~5@e>mS8(O}(Ub7|%
zy7H1x%w!lx;Hntnkv!qyckfJ+s;AznSOky|WpC}dJy~t+<*IZj3
zvch?WcY^a!)S=#~e;LLG-T@$m<8+f4YpDf6!Ig`I$m~La(P4xHVq9W)F=d5w?~-k1
zpj!uDow>6Rk&dMCVP8T>J(uEHTaMt>K~y1Ck9YbEVZH%%ZfFwd@}=`uu}k}(UQT8jfS1k|$gBI?
z7(TZ)394$8KDlM~hv%3>?`-sLmd(g19}n@ZNwL3LHEei{yIAW$n3PTlm(GEP*=Ps^e_u?$x4MC=Y@lxRXtzW$b7U=!%T;R;k~AbyNyKJ_zMu
z3Xwrd5O9k6G!3t!ZPzmK`LziAZk5n3H#4_EuzdM5@dZV-CtvX)VSZs;?sHqj
zr{s5cQ619L5)?M4LcU}>9JCCD$e8pB7coU&ma_7*GG#AT`jJgi2IiEZ(q-$rz?dHV
z1wZ;@6HTX$uMJ@3kNL4ofU4lBp_%2m=)UEP15{otlny&{Y-B(U%tRD@ZU)0H|8Y&8
zNdK35Xv|PSXyT-n-U*={Zj7V8i`^>l%XDqTbQ+e#iL+#HXEp+E&v_!y(7euUMKWP$
z+HrUBN)1dE8<6N0bRR;(pClx_a;Wtcks%uTfcEikgDKF73W+GUguv)N4FpX+QU1W2
zt(+NDA{XG2fzGFTz=t3C9wtraOu$%AydrIf`4-UN5v=lgX)HcJtvnGFJk%v7sg$GY
zog{{Sd)ma;E~#wRzkWs1=7u22aDBO?3!!e6g18x_{Zlp(V1E6P-|b0!b0dn%X`7)A
zDDH?5NBcF}_Z&$`b*0q3dz{sZNi-_WOvbSB#T07Lq^Q^n?!ef}|B?T>RuG1(M@0I)
z1st1B3h0c7wHO4yMpl$n0eOxV!YCiOrkOvPtE
zBTCqu@H2H08^j9zSS>Lp_%HsDciU@hzSB|<`u-Senp$c~B4YCLDS)%`J7{_nrFe14
zsaD!q>xaPC>RC^*9;&V=Qe$Kn0zcf65A?eQ{`@Wgbnp+>F%4)Y18vkt{@M2J=k_1(
zX<+;G&6=Q0B3|ytGRS;C(fTAXxoZJyY+}(-g>^;-R$7uWc+w<*W`--FaEs
z#D*aG*{!7^`H+v?p7b`7p6zD$9vV^<(9*C5ZKy)52Q3AE4lgwtk0{`JMJh8A2-DMVN^#gacnFB-@lm2!VScRd**H%49WYVX;Y-6B18Q
z928wA0Ciif@9oqKDSt{m-gsKFF^XFLr8M{D%*P#|?;0Jt3HjjJVDxV^3@DGa&f1fo
zsyxc44oPE{inCAFcwyA1LPw8hX~Q3HVy96Ab>2=_ZTMig3__N?xPJbx4vb1x3@|jZ
zeby-gs1?q4-g(-p_Q(cg-;gOh^rb+(1hL4=>X0L!B{?$xg&=w;{zc$gV$lFoYhF1~
znheQUoxC6C)a>?t1A{0|>&NZ;_bK+I`ZUA-Qk{6ION-PsuBdd{IrA8*bVj(+Kz9=N
z6(;+h^JpzLVvb&38=|oqzATuPYe_Tn3kWMXBeVn$FoUA66c(RCuv4Ardw&_)F0fCdP}d2#Ksc9>4*0K;-G5@|qUW-va50mbb=5
zn$krGrFckKUX@@3LOPnKQB+o?_2X0mF;4vtMt#1qX=CISi>m+R-%v|X8|})Nd8T=9
zYsC7-uWZ4C{QTNubwNG}d|+&exw$CRohW?u5n%4}gX&I5cXcTP1W0v3izCiz4ZogX0%^IwFNKu1&3XuJ;G;n-MQuoJK*s%
zS&o;!`S~BV^M?+%cXEc6V*9}X-Q6*^PMgQI8HDp~ppu14+nShe?8yVG&?goV3lHT&
zavoKY*0C-_GSNwU(hP4!B;Xiyp7?OG^U_Ij3_lpH(?o~vVS%&2kxR#03a69MiTg>Z
zrM=T(OMwEGdh76lKk-qE2FCaUJ~T0nL;%-vEzQd|h`(dGtWM9MUaW%K@H&Sd>t&be
z$C>eH-J^6GMp7SvkxU4l75Q``(0;yTfLa1hD`-B9wMMB1{%abg2@IY98i(JSzvH*e
zJ9L?&rTEhg3*reSnokDy%)V_kyq~-tr&a`|6Prpju#b8wY?Hf(wHtFa=A0
zjw@bwnJ{fC7r2aG*^8ze2)Y#Ysk3=eDxU>Dm3ysVK+d$k(+flLB
z0%_~x?lOlLpxd4dboh6AD`$-|^K9H=u|6^iYp#EyM!SM;Tk3*v}tS=?Vof_Y-x
zM+l4G{>)k<;bWn|7*nm>l5^S~b*YTVlzZ~pPut72`u003XYNi1_9uYG{Kw^!)9<}Q
z0m(<}>LiC{a6qX-4$D>d`DSUtI9+mxd7(YV3~G7m?u*0ensNU1
z>nKzuG!zg6YL~Z#dvkqMdS(lzBtMe!b}L8PMr*Xp{P}e>K2*QoJ?5aXvsE+<@^#o$
zD_e7)dqs=BKtYLTY664#srP5@n!As(*$w?_dSgHhshb&CdkAVWfHY~}lDFgI6C{bF
z?jb4N8-Gk7abXf5e7+Pv&Oc(cJCVU
zxjoH%BE!T*!)JLNMbrG(XsjMwZY*y1rBDrK2N_*IR(p9R)RyY|>Xosa7k$dXMIo`>
z2UnOL8s1+)o#O#C5bW=A!JUb(irU+7ql5{l*NDv>NveIlK?=1XNhs9DV!9|H$3!In
zSM|Mc9-3KqRDd^lRLp0rf7v!|OV56fM%E6ERsFmE(rYG13fdo5*Rcl}+K^^HWYAMr>juOzl1bAvnvz*hTO}1XQ7ncatP3
zsa|3{1ao{kaGe)us3a5I@7q)=B_`2Zt=pUiCcE>(rlr2$8g6m-NE$1kB0X0^0?FFv
z$lws4)$6`k`#hQ+mK>+6!R$B3
zV?9h|=e083^;ZH`FI`&AU<)E$vsB~5z4a!vmtzK3T7SqCZy`mGN?|b)fzb@MXjm;G
z=sZ(Cc&dc0g2P+@wTrL-ecGGtwFe7YvKT^5{E%=eg|Zc|;T$*ea%48I#grr7uI%Z6Z0zl#0!CR`}2JKdRL9!
z$nnjwAo7;Lt`xoJed`~uEO-2tKe_p*NatPGLF|9&&OV{CYg<*4{%-h8G+tN|28>m`
zV8dm6I#YMO9+y#2G%SIRtQ1f#|DBdWRvttW@OjsRp>6Kh$_GQj7aiPuNDWscLeQOb
zV!&|Gz!ok(QH*^Dj@rJ$fMy>Z8#32N^}>KA2DCh-a#Vjpb$E6)ev$I;OrVxBR4(R+
z7A{U)j^hJVz6lJAn|ud1)R^dtF<$hvpg^ZtCWU)NR>fKQM7lM*9%)3-d5m2f&q(yYa%h7KCd%5{ljY$6Pbsf3kjhh2=N>ty){LoU3Vk!gI9NdeQKqK9{ECW%bz_V^)e
z4P@N$hhA&ZqKmDiNh|2z}e3R!7J-B7t;=3p@a)@*5K924WHrW&p+8PNgv9PDA<8NO6vUy@nU0b@|
zU28}w`A22p@jehf1ubEJ6=A~hc8zGn@n_ubsF?e^AgoiQhblqEnTR#+P-b=X^|(Cp
zdkza(eBn+eif&8WG*<6XU;2E=(fN)90elKm!svnPL#jWG65e8I#IK(rG^WG%axwa~
zw}a;P&3^RMWKIBT_a9`>D4qLlk`Jywn(Ex;bBW7DUSO*|H`%4*ABs=g5y#3%j&>++L+I5=9`&0TEiS9#N863v)c3o`v
z0J}U}8DwzPXSrBit0?O%JJ7WOcA!9zG4|t!{MwI!R0bicm4u)IKdTkl_fz}0(iFkz
zJcdfO^tstv*6=8pd${;F%d^LgKlk)Itk<6>mH4FKUPUyU$Tu&(wO@MqLLy-9@$1xg
zF1XoGW}K@Z0;t5ETG3DpiMx+0-J&f&}6fj|dFy&=B$2k^)^C
z1Wloo#x%xli2&lB67G-N6&?zDZ56Mu-i?3L#S|%UbPmOah+opq_ki!i6Or_2S4-jO
zcAfHXKnSZXD0my(vb7;cH!S~Z1H|FezeFwSNMyZs3(7}))fOS8JXCQNsx@_YmF$c$
z(HGYSnh!0pot`0=sgU8;G)S4N>UpQ*9gZy&cB&1Gj7>E#X2~sidQ5q2rHu~z2D2kF
zhQ}J_K5Uj>4Zx@3*xo6fQgs=UuC)y+8{GdQE@ky{g}V*BUyI@>nHVg2y_~(zF&EAb
zu)s}3fx@WVqh198B8L5ti^0!HV=`HnIBYX#2&2LSC8%^L=QVZ7>wCzAiU7>$&abM}
zN2&aFhaNA{^<__pTy5NpR4_e>?{vXlUr@eD{9Voe+ha@4Utwch^dN9wK{fNjLyYg*
z9u0WQBpW4ZnRvctS*ncqeuh1yJ(-;8JTptp*qrI!TC{DgxA5#zQ_${#TZS!}sW#9l
zJ)q{Tpp=}nnMp{h3IB9Nnp_ahTT-<-Kp~jKXqAXEk=NO#_al0LNvo;8cVb$QI3xxy
zp19RRHck+-uC$n|YJBr)z0Kcz&t_zH)s#BxL*2_Ma}nZj{Ndzp@3Gta&tj>1hiGkQ
zGLk-ccxfk(GN9}1+X4s*LHu}w=!3aQ1*wIJwbvoD84{@YJ)1|TWA~~8S8Jq+jbxnE
zo#MKSZ*3JFKT>qj0I4j1L7(JFvm%LkkXIFedO~wsLz%Hm_X(NU(OJK=Rk!0+jrvWh
z&LpOT#&V#O-bDJ^tZ%l#Z7qV%&-aE*4;P
zL+O~Z4R>6C1;dKb+u&Zyy%yeL4n)L3o`qdd?V*oK`)c7{w#8P6xj$yf+_&LiC%bmK
z9WU~BucZx>+Yc{^bII0I$Ab)DbO#PylKeIEc?n|xX$kzubkXFVtJB)
zJX>%E7j{wfY^+XANeLj*@3DmwA#^2?H;dcT}}w-UXMSv#02K3pJ2cgs<@
zD|)#vm%m@5VdRW)wF##5{F+auHgcp3)Jc;x+!O0x_2IYqyBe7h3H-I&PRU|KjLWOR
zwG@}-frc|Rmk*V&EK1gG_b`epHax8&KaOea>BTyC$oy#Ku3p_+NCRASn^(@Ryq3Co
zWr!}B{`29bwGMyZx6`}cv>P(E@PuG9!in`gar{#+C3rxZzx-Uo7;-Pa&iz{+`dQ0-
zg1uttl2VI%Q0H1~k;b5d99)y3j2?W+`h}^=ko@pGnfGA6fHU+$0$(8d$IW7G(*~gSyax(q(K1tF2QoK$J)|c58cxQepL+Vy;d@0
z%?~qsPdD)hd*k9vxFr3!gjx*TS?0-^p>LnjEO~7+XHZATpmY^N29DRZW{~2F&`cmW
zDj$o}`^v3pprMDSzuWmHCjB~Vpl@YL4R#Z?R&or0@=q?BOB(`Vj+2tg;}v{2JI0~_
z2IBYb6;S5vO;E{_EkDfzIKjd
z;EM31i@Jn?SfV;+0>&H@=)FXdP7AH2ic_^n(h99Lr@
zvN&&m+KaZ^H)BtWqRgs`YF~V&3|L~`AAIe+o$v{HUSUMc2W2+17+`K2vkpBw^7dp%
ziBWON!m_JCWQnDvi%@6Z4ma*+#N7=e8f_M5T0O%lF$x-R>DQ6@L`n6ph9K+Fm_OdqIaRh^z~
zN<@Adwir?5qOoS2pnn9SYOV-<+XQhF_jWBG>TO-QdCPTY`6g{hK~o8JW_jkpx}m;-
z-n^ji)b^*Zys=Y7=S{)A?Yp~+UWr@&xCw0y`)#75x5|oT(-Y)?3A#l6G
zxGjD+!;H9>c^sR*8|8T6ubmvnY%?&Y`|XrEcW9vp7{O`RSyYqNkqfpI24#Mz%{!2u
zN$s~;{B3!Aum8CR)Sx9}d4VOI;Y+{>IGWPfE#b|x{0dhI`7AkITUh#vA|hIPtfRz<
zCLsprs(oLfz$6_%8y}(t(Yi?7rq)P@#XIMj#7&-noonYG-cA)o3+VJdIB+Sm|D!(z
zA|9YBLqxw!{3Fr)qu0o5z;^+^#GzRYjq&r;U1x?(68w&v7_$!eJuC37wxgMn4N)my
z+A5WJItODZhsc2Xp#^YB<1qM#fcC53%-h4IOx>H;nC$~#T|zqpQw>97Ju}-{CI<@<
zH_PXskyDP1`Pmo_>$sUOwr@@9955WWHsRr)(s)<7ZI|>-u4wn%-Q^m2b^hTEUpICMX?Zg%9c7Xsf;hx*$
zk26?b383{)|3u-U{I%GS0%lZ6u#FwuqklG1fgr$jHlD>-Je@*s?T;v+WL
zJt5P=TzGLUtXu_Wd4jQZ;|z@{XL>LBTinLjHoetykM>)29s5f!Y$fetU%j}bmOC9=
zQg*{Tx8c{`wouDP5MS@3vX$EhLCjF@Fhr^&mOpneCqlpf0-5#gx?=9eyS}zlt>HXZ
zHK`@cvSVfjXDJ;fRysG>t-XR)a07HKJj=MAOcj>1$CRB`I<|FNllt2*9}y3Q%w
zy$Kv9;28TkgLc6^y4}H8ujxw~RO~sqG%VEZ7YsC57qavdZ=4)({<_TRp1qv#hOsE^
z@*{hEam%d)Ot~~dX9#B~nV;jfornq`yW^i{lZv2w$kGO8Zb^5aM#YfX?7dY0HY3C6
z#|4>0XYU!?ou~P=r%R0c>G=Dc0-3tKG)4bdc!Tpi-hm?3!tU1OxY$d{fK60IOXe7W0{kIn#+caxeNL)*Ny
zEy?#Nc62~Q
ztli@`dw>E(+hg5Di&Xu(OQyJ}L^%(_B5+-1SbkWS^_hv2l5JEJF^>|M
z8)7+jJ8oi@i0+o$TaoH};3Ql-^}U**Ffa)2YuyreCHX#3KGsVElZlxN;{wjR_FB@o
zy~#nIh`NcdcKY0+{Q?6Or}Cnty3H^I_l3dF18)A|?F@(7o?f%i|Do%x;@WPaZs8C@
z2~yl0f)0KB
z0d0S?M-yfGZOF}I*D>q&$2KgguEDQs6BW`5y+m>WabYLt_A4T<0G>%4ASw&HeV$mF
z`BNV@n_HpV96*jbPiNAyqixiFqC6h-fG?)?T2qhQ@6wlY??0}|NDltkro?k)gXrY|
z2xdnERd{zZOE6B{+Pb{6g&@CkGoa`b+m^QclcbwTZ`XVfkEiK-
zbJ-!3J4#(YeRV(7A^6;^-AdMvrHZv9`^U3R1QZpQ_36uD4d)Adwwd?7_>Q-rd-={;
zQ90q67uZOleO!}%xe9%*Y47()PJ8GzOef1PA*+HtXGENr5hHRKHd8Rxm{E5VT@yrl
zl6^*2p>UMr`Jc7sFu=nLZbOpPU5JwC!3QQG@1u{HeSD)Y%{a
ztrtxSz=IB;92N;sWI=9p@P1P|8J+=cAEXs+jwjz4^4KQ-h4uu7+PXuQ*VrJ9ciT!A
z&5kja4P9A%lZh!W@&i`4*^G&jmck{U42xS|(wnAq13R?ph}0Hle$|cj`6QfBXogX
zMxALQ=M7=!l4rY~gR2tm2Mp(S5)yy#&{_yTs-vr3fs8u|$bM+0&NiXC-v5ts?-7mz
zJPAY0WQ^NEC*M%88C7esl$=f*u9jl=Mt(!#9Bcy-(s;hplx@!^7^5+z7CNR3?@?b7
zGN68#HI$NquJ7p8TEyReUL4U$GRGD+9H)_aZi(;sFj6SY&e3sq`(`!r146;s_n41^
zY9ZjE#-|n(2CJ&~#hEXAF7F=go3fuDpN!ooUUR6{W05d*j0NIEy9AM99Os{kFnt&5
z-WJBmUAd|X38#g%BjgfNe!TuGBsKzDuaD}3!7&`z_y8zX;Xzv}aAmOYYhQ&SfSgN7j$SXNh_J@+)v*Y^cEvH8IC|t9_pS+cG5rXY^+@(|h
zZWkwzA%^R#481J^BL$ox@Mr%gAsgW%mIo$4{A7AU4yDIczi|L_cecwrO!1(2l`~|@
z1x~I=QSV|^U&2QYW?ZFhKD!={Deb~S`U|q-ART&8|C9BaoSRm?Pwl`#J!)DAc-y*7
zGF9q*G1~F@_c7%jmypp#rA7(j_OZ2`2hY?F!VkHm2#nl~87`|M6Jv|8DJ(y9x_fFl
zf~rba_S@G|esJFoqo>=|W49+tqstThL%4d9zlXu~J;-m(t??}7oGEFZD~WK=`*V2c
zcD9>V%70XcH}*d)A!tYjjwQVI4~u5h2?V%sn{k>EF5kgb*Nny$WGD6(
z!C#QjHPJ0%s1avvmy
z_;oTi==Sn4rek8U#V(O^_U%W@hGac%p4WfN^B9?;D)-g~hUtfMzf-HklK&lyjsCnU
zPc?~GqPFPOxhM1WufZJ?<|iTqomaJ%FB8~^03oUN?Iy6ESR0ChLur6>S
z8307>H9H($|9ILl8334O(1rMendhd{!9{nsX1(oOHBv}r&rUm#`yiLmTy*+=y#Z@+
zZR^DSHIk3Ld#-v85neZ|=bb)>r%OqKF_oL+N5AbORgI_AkkH17^6Pg}(Xs=#9Yt@w
zQLZi~(Ir&R)L${~>EF`LJrEr_>vWy+7n23o;tk;$9{lB@w$sZ`+ST=XR$NsYVqk-P
zQC6VRRpE~(7y9$S(e7E{EwiB8fhW@0(xj@|A2(>RZ*D)+qj|4r@RB*=tQ-kfxxvi?
z;434l7S@EXOcaIs>m!>)b-}7O;R{@=f(o#=14roj1IhqCbzeed1iuQ=gJEqyrH3K$63uU#dsHQLG~brpu@vN
z3oYc_Q7xNeOd3=7BI+Bo*hdAw_X_jcX~ptTMNnG(s#n|D$sOl!qYT>m*Z3xefD_UM
zo$b#jUbgPqQ%4aH=-`u&x;8gI^B&Rt12*j8QJF@C#V$Y#hmUPJGqxs2pojhGc1W4$
zfa0J~^T6N@{qO<(G7Z9~tF2arpwBe@b)!u3s#7UF?<+P-#P?R542%r8FRSCe8
zNmdX%IZ5Q367V=ENrm5h>V7dvR@)u5`0zT?xjt?s(z`z>Hd3AWaFeU_E@TaytR
zT#nCE&s#-aG{7C!S0way=4DJFfG3Z-D6F>9&_F>g4i6mEK
zLZD_~QbA7z?>Kem2O5QSp=qU;$?4b+k%p9sdtFv;FkU8HqSpO~*n-gpm%jD-?@LBF
zdzw)QiKHP>Uv|s77~C5>+9zhnn1Tgms|fQ}rp?d_SnP&ig79CwXF8o;T1HVjY;T}J
zAC~T<78sZE=&>POcx)3Uyj8QN&RZ+Nwl42Uqe^HJb@Wq{F_Z|j$k=fj@4mwxa}oVv
zgKM>!<0E!T{YW_@OYCqt!(CcS@IUJc4mgfytP1ayPUt3)#(t3pihX(f72S7lK!{*2
zBC)sbqYim54P-K`v@sMrk(n-9tV=RhXm520trA_S=>SUT<2`#)Aa!+Yn(V6Ywjr+w
zU%X%4#wFUFy%|(39niC*FT(1(n!9xRwQwQtojucX9C&lKQ|-%tXHc?Hf9+y0n7otx
zM2peo!f#@&Y=6$MYSt3Xdvo=)3|47bIR`yG+{j94JQ=?6VvCLyI*LI)r27Yk{_m)3
zv4Zi+Gt8_#c6wU50-EzFj4kw2qu7RZ_#Nx&FXfq(M2GMn$N&=qmJi_5E!3Cx66(o;
zmy%$n`&;U-^2KCh+CyDq&6hRbT%J
z+5P;fc8Ga?1(QF!@Y55&Vje8(38o%%1*K&L{m=5kbxq_&Dbu0epC4~isDUZkmpgy+L(nGG
zBPm!K?^}|TL*}8}?xC$IIH^4F>oqeDRcD6}+ES_9pa8HjCa@_AsJPszB2mZ)s(Dgu33iCh*IQFW=qveAncpLQiyN6gg?pe<uWyLY
zANy7z-B29mSOx}BVN;@f`7dJ#-=1L9yBnHZ#Nve2RX{9=YV~D`~e46cL5{2s15Jr4U?5GVvrt~xv5)UP+Tqx%S_9MuB@nW3|(8#fMcG|Wle9a5(czV6i2PJB&cSQtLjVioIODgNH
zzF-m6?4)xxiNu72(L25EcR8!(a2ux3!&8RFvlPr>=232AFzm2?
zZItE4g;NTW?ZZ39=hBlb2=!aS&xg>H*C#lR=gbgMC2QgWJ9q6Top*r2Y|fcMroJKo
z{fWUu`LB~~e1wa*Do=!+AhxNh{w_sy8Pj&vuv#tvoncq(+1^e$%URnF}1C;QK<3jPyJMeL^rLmel-QpyWEq+_n8^J6+W0gZyq35YJ3Y{&<07oKM}
zFDL&b0#Wb^f~eyhO7ZhELJ8;pFm!4sI};G3witW2jU|J}gWBKlTayA4Xm))O
zh71>RW3()vxDs-0$HoU$(3SGd&-os=(+q~`Bzjr)No|te0$L-c0^>*3{J-E2s`z0S
zI%bXdpsa+PYEK(IEqkl2#XFj5f29-|IB#GzeWE^XK^4*R=c{I3|9sR?wC+27SElTx
zq`R$L`#jbhKj3lo^l2Y^cfB1o6(NN;cAa)L_B
zX67KD%8$&gAKfb7xI|Y7D)Rr6jMn}WME(=hD@2MCqCeD?WLLv}Jc%hEbkvLij4%9+*@!51bzxtBRvWafGXRI`^>|3C
zJFt=aOYQAV8`t1fa!nh%nrQoG==YNEwZ{nsWcAncKFNwlq*VGb1Y?--@&4*vUZD&wI@%L}CazMh#(P#Gs1**t^eEjrRzx
zp$^kyIvh{O8)eIAz@5*`3CF+Woefy?`SX@x%oiftFS^(PC@>uca_QgQXFoxHJ6;*c
zxdAs0(hE-Q0o<5q(2Ulq{FKX?*_jgJg#L2Ypp>Z?FPwq($3=jO`(UgHboB+7Dx>{8
z)X>8_!5MsBp#W;FyjTw5k1K%+d`!f)PJnY=T_GLyXFK+ajbY`anA<
z&G9MSR2pA&HoHNbXS&9Hg`_c~H5p?9Q4L0d9o*?{$`?17!UATW_#%?SVhQzf<$Lr>
z26`v-KJW}sko6N4Q9^n$7!|KTo9QNy#~n3RxNqVJ`-t01yZ+qax%qSjZEvF}sESnE+Mg+H%
z7Ko}p-uH*~-z+F5Hz*Lp?2?=M&e~+E6Bf({@n1bIcWx8?(=xNC!I|BZ%#LEkf3wxv
zR^E)qutr8|eHyYY9r1_v@;|52gD!4!7-1rH$zQ77Q{ria#pn;^3dpDx*67|Q=gX#^
zOo3Ne7n>+3cX%UMv`4|hTIu=9vz5~fmApP}O2j%vNr@B)Io0nJO{aa^TMiWqRyI?g
zpY8jMKYA@ME)MwDc1j6YTn#2(w%G6p>+KG#cxS!VN<5rjOTN?>uO1e#a*bZ!a04Bm
z9G^epST|hrB87MtH^F(V5WgpOv-t{-eDII4n-s=d=p*d67w$l_vxT1ay!jxpm-1dG
z47R=|)KS70$ng5czzAPH-)iH}$G@f55E2LMa_hMCu0{+FN8+W81uxx*sy?&CB6JfQ8^Xa&bd2xu}I5FS8~
zPJFr@gT1JBUt6nJ+MGYyHhHUydr6aERbFG!A5f3BOW?ZkBM1hY>JV9Q^D|TQdV?gy
ztGc&6X${y)=SaZj07?h?;ls@y%MDZ@lTrW#87P={a~`M~4fv^1zrX>+fhaKoQZZ@?
z!s6|JF#&Lb`f|Tm#Gogi`lNqbyj0KQ*NW49sg7@
zIaRmd_-$sd2r59rD-npB$wovi*&53PAi1|95oH4Wa#kS2f$6pL?`o
zbM^=CwV2URU?Y#JItYDuSgU=vnZi*IGjv@yY&4xbz`=j}GI&{Spa#KG07QwlvC;O>
z?qiLHc&84ev87V_1hOm91P|iTwB=N7Q-Q*!SPk@&;v
zyyM0_$|~ylW!Q^p(93fJFO2|rXb(_D#j84*3on;r5C2nKPIAn;M4we1wyL9Z$LZG$b|cl0RM{MSz@PoZz{P4`?H~JDxH|D5G8{?KW;-TXJpA8+3qNR4RG$ekJ*ZkHxNG2@qJ;w&
z^6LRik^tXmTBSEt4%Fm9WcBw!^FKYE?oj^Z+c=iVG630m~&stDt5PP
zqGXhNCE_&=2u+rZg|`1?TAnj=7I~a{`baP#94p8v)+y{>Z-fQZ^)E_9@BF(PzL
z4>U!f`Jl$B=!FmXIqIySyXT1VH${&KfpjECB7j)Q^BJC_x2(My`5)}TyPs};SN6vz
z16GBFa2}jEz?19qnJ-e9SQe0|_BaBXXrK{(aiTbF{>jX%MPfjcknbhs#90rR$bVb3
z8`W>yV}h*+8w@h0N_#Z03qAo*yWpa3eGFq@^$zGep5zL5oVpOw7-HwU@5n1pi*N-gh_Xf1FeF-
z=ofKG%^({qu*#}VUCxwGC10^;sE$J}Kr}8;EYxXBwgq$UvtIPDu#T(hH7kn?$xy67
zxS6L`R)ZATb+XriqZRuvk*7ki3h(gwMlngBV{WNJ%KDeiO~$ZVw>HiGl9TQIpJLmx
zI+-}>&dytb@KZvLg&z_!EW$t(GASmSi5Nfv0a=Vs^!jq3Q13HWYe`xm*$^P0BPi>K
zG)o#qU%f(%e=qI=d6F<_@f|OLN5UyV4+26!aG}nVbAGM8m!f)mh9x}Z@Z8kkfDkJ`
zaX(BDd~|FST^Tc9VMOF<`Jrz;d;Re*L9a!>$4qX7hmOH#2TvXls^O0qopt}?al^xB
z&Z596-!-f1h-xHQ4hH?$!$5_9Gaz?6>O??PlN6#zWTtNW+xjBz`Odn~#+pvPu4@|m!?+6rFuw=-mFupCZit62$
zQ+Utu_&evUz0>r2P+tDVnovzrl&bW&MxUtrFMgH7078C4U?K#FF(}IKUqE;N?;k!V
z&?f|^4fe%;ZlFC#3(`SCepmRTkQm`%+p=>_{^PC=xm0$MKx!Vv#boCr@tm=Wk3+QqjdE7D5U9?;yLB$@llhIoFs=
zp9Q3JGzDE4{1nkS>ek=w?l1iGF8nR>Xcha4QmM)P=KhOQITvSsM3O?f*7{)f!7XoO
z&-L?rso%C34(^q1dL8@8&n9f`Ox{2I{T_-A+~0gJHZ~rQ`VA92zP&wdaMnREzEJQf
z%C5g&XZNf*Eh$+142cx!1B-ax~;^mZ5@&R=%2v#Sx50X
z=#16i7PLM5SWtvl55bh7o1lvGiPXIj1A8r0t>t28rmCj=fmkz==sD+InNCI!uSfnX
z&e@RxSb6)Ib90!0n2>-r)Qycf^=3BJy?$l5OnD_?9?+Ko-)lY$P$hsb=JrU9#9vg@
z+a&c0vgnNy=m*^BT4?AYWJ0t>D8um-9*Q|DSV{Wy8vB)1{LvDspSd7kuRhN>-zj_;
zhdeb!i@eA0Dj|p|h#pk2C~tsH7r+^G7F+v0`}6l9Ne9DYf^7S*Ce=u~9+JG?)nBK^;G&*C2EVwkrE&MjDO~mqLq&T5WV>738z7(jSNyv6}
z{9+)NUv%)==O*ppNQYM49?_!Yd+v;-54tZK0cg~iG8(>XPXBi8jPPiS*q;XoW{v`L
z)KDVC+7S)1n^I9mdAuRpv_ilwySnA$`-WjpdVWlMzDq&fEvO_PrvcQr&5g6aAR-q-
z;UI*xeYbl1&gz?Ltk~T`^zwo9dL#yA6o>3@EUa}Il_37?^<5=^dJ?8I@dS|&{SOX-
zvfkvbH>D1L@`?#RP=N?H$?X6#wO^UFwcc1XU3@e#$?L87d*6{4StPe9=YcE}^q9Gw
z<#S7?mK*j?z^QUq>;Vf)6TwPAn%JoXcz8vP&==VL$dM-g5DYlwTJzp3QmZP%`J7ez
zg1COkJQrTpZZm(I2YWL@G(DbNV2wUoQTpnAEcm}l%Ku*_b)Ie@1NjC%iyrJ@%m;}g
zU@gmpe-`}~Xj2+o2xfSV4n#+e@#-+o&WrrzYjhdooX42&`}P_He^tc9nSkI>t=_Kj
zmbqA&*}cHwV3r_RJ~=?pKoQ8NSxDbHG1_zs%#i)%fw$rNw)-%%AJNEORv#O{Q(9ef
za%s2@MDetUjJWOX}ai>(30ozC$5B73BIHdpoia61woT<@x;Hoq5toc
zSKJTdiT$g<`(8P{O-`%CxA51Lr7rTBE|Nkj|A007*{q#
z&J?qslxr=gR|F!f>&QrIBX*V>a75j6vqcLTI9ROw>{QZI7uUL7=O>Er%1n{3!YZNq
z1Rk1tM%EaLNE`96IXIr2JbjXC;2MItSIJjBaiD)Ypl+
zJfSAI06#is$#O91LPXeYrBgZ5HR7%hBLZG=8iLx#Kje2{*p=O4$kFHZAH6>r;EDCg
z9=@u(eNvd8?1owF_BLjqA8i7vpJk({i9HhF@0Fu~8pxPCK~;YN5l_rQ
z4V8r>q32WiiAsvCd3-C@I8oLd%AQZjqO$M>^L*mm%b61=LS^F1|79A%^6e!z9ffeK;O
zCyP}TBY2fpdkU}eYEK;}?|FfGSbo@kD2#vV;)814pbP_Qf1bTBPT!X3g}?Du^3X3a
zCPZhP2=DTYcovt+P5ou>%Nc&h_=@U4J}tvEKg)8OqiH!6nUz*lVKL=(8%pA%uLG=;aT
zKf5$iMn9z(t$TmeoU5_FE?%$NC0ef>`2@R1oPM5V&{+*YVQ=Q?i@h)<@6A5ey{0eLQJM%w(!B_z9xq9=
z@n_k47J@}QBjJNOylEG-evMM>9B}_O52k})hKKid`2mh&ktf-c>}SrT2{Ee@PX?={
zgChmBmpLW;%9{y6x|m~_3a~NfGCIfSoH3|b$6XvhG|qQP{i;jx*{p7!`FchhwM+9o
z^OHCu;_OqtFiyS88@u8#b73+BVB0UpHx~B;>PFV|+)W78e_Qsu2J2CcD}H$~JT@w|yuw@32eF+BD%yvAY%9MH@8;aNZ267+u3
zBjT8brLpSFu@@vtb`K7RTr&4R^Jfg+RHj4&H?(S3QA69lF@aQjRBu&QiUlwVo3W@e
zZZJ0v25ABRpBI3?^cv|YX|NFL(nLAC_*@?Q5T~kBZ@Jg);dV*uE6#e+)P>nf*Tw5%~wV6{hFD+Q$u6DU0ggNRf&i#KE!C
z$nnmW%i|tGi%Ydv&
zJ(s7k;;WVMaO^33SN_t9*LJn5V?VXV=FlW*SD@RjDV}8~Ff4}KuFVG|!Tm0onT~2K1pTQ$#{ORj~
z+!qi0UvvVVpzONtLunk2;#bF=7I_mw
zn5O2EFDEL4Llo4_PB)N7Q-=cwLUd`iQ~`cy&5MabQfay|862$_`KE;^6_*hWUHJaq
zy!@deYq4swF-D3A-;O8)gpx@(dzpgAm{Itn?!*rtGj8(%y$@2e@ul(tvv__Z{WNsjlwD07kx(?X}kjX4Je~`;jG5fc{Uj)N@FcV*9aXuL-hdEH_Y6@tmsVa8YTC
z0sG#0owiKD*fF;1nxPI6owem!!6L4m&+p-l1KbRc8DL298J3UjAq=`RP6;Ho)~~#(
zaC&lS15*J>K0lK(gyag}+;6s=!MxckV9Ld88a`Al9DW>edHS|AYIkG7fHYna9OUw<
z;_U%4V&&q-gWZUZ9e*L3;a3SOhW6P2AjwE0@h!F(99S&UYTlG+Zj;!dz6jRdM2kSzYR7uzB;Z;6(pdibUP+s}cDl
zgQ=YU>UC|Zd5rKEam3ZWBDo?I{|0H|K$bNn-XPgI$@uC|JSnj(r~@j0rGY>!X^UI1
z*`_2B5-KVBQ^WMndbYG2dBJ#`%O%q>!_D6NQA5GsA4*wn7kT_#(f&%kv6=bOTf_G#
z5(C(d2j9IzqMG>dmGy2=&=v#@f;9vEzFaHuozj&V?9w>=?!=nz{U|R?pqB@-UeaZn
zXGA`Zdu(p1ktj_maxKnAK+p`N3i3PvLp4v&ZE(323CnEgg39EoR+d6qEKt9RHJ@N4Oa>g`bf>>cMA-_PLoBf8
zSTnPEFQ&39Y*2G$CBXYE1e$LxIqUWQLvlR0Ls>rM%kom@wKC&AoZgToe}KW3)X3DG
z2V#^I%_=!l?#jB|w)Zj|c<>kne>p^2m?d3NLrxACCHCtuD4vEt_<~|XZu!Bg19Bri
zkCW9g_XZtDQX8i<#z@`klB0j4MJKQ~%;1B`58a{nrJxs65;KZ2zR@%?2+VuwytM>d
zd+XCBK;Dm=*#8|+*J}RHaLX3SrSi3GCfx;RuWlN1Lg&f@)7SaErKBd2z1UEosD;?w
z_sFjpy7XF;6e0DH60|-NfWK7UENfj24AuX@wHwDIXiEM7*F~h@xyb+`>|7|j^0=y}
z3c>1bmmtDG0zA8-yyW#2u{)A&GR`%>&wrFLqT~e5#yXI1>P^sgsV&9(dG-sinK3#3
zT~AemuP-m;-9nZYf<|rpbjN?KBOb{5kpBPDvcvoLjc)8(q;CH%W5Ux`EMtAfQJBT_
zptZ=djDel2n^ZKBrfC!GkUrBR?5q|TM%|JeV^jcWeiW>JxD+a~(2$*DlDd(dXv8_d
zuTY$@kP?{5o-QHb5=fdTWw~a7TRQo8^1bQj&ea+l@yjL~B7_)6#ne5(NUJzvHGh6d
zJ>FB;t+@X!&f0bzJoUEUId%*NeWIIw?vp80>drbI83(;7fJNOkY>D*Q!mvy1wt7+h
zQs%|Wo7HEkmvk#tp#YMd?nC)h=w?wGZZAau>38bY=~a0J(ZzJ&
z3*&*Ps@}vR`=6BGaU^g=G$cZibBfH<*G7?3aJqG9Yl0fIaYnJC)@`9T(8wWgx;!Gf
z9@;2{g*(Y-G2Nv1?IyOcOiKww@%r@v6|?)YH&z7p9PlEiHXN;UnJm5KgdjF>7iik&MsP@@Cfh)h@h+*!{t6
z8#L)0IZ6Le+5W}7YcVy)prD>5>b9mK_+Z`T?2l4!hE}enl1+v&lL_0Sz|X|*J$NO#
z{3!g_KbF)^^5cL8QS)z(G$OvCF-iFTNPAuVWgR%6tKinrcbkWG7xUX)uhwzfZGX?d
z!`Spku=|V#;Cs$5RMCa+Xm|)%!+tHO(3-b>ieE6>{iBYN<-Wsaon@G2uX?WLRDwpj
zG)ddy3LIZ(k)|neMtvpg=#cz71yg7TGj9~Z=$=`{_Wpdml$C;xDtCK
zkU|dN9L$km^e+BNm(o)z?(Wymx4oiV2hh(9oJs|swvYnqzDsW`-gSSTdaVabo`}Kq
zuQWSm0`LzDscU|y>^~CGO4SlmXwWr|@C=;;$kCsyGl+3cX#u}un?;=siG9QZE}FNJ
zMG^9^B5Z!Ki0J&CdsDV3IAM1q+}65Y2Er~jq)PN-FG$i!7yXWQKx|X$b>DJ%gyY0l
zULZLrAZ>P#EDvPK)qERQ3ytiqiRGvCO_gRrz!1SU
zB=k(%e|pLbILQqDFjx}7Yp3&gv2#LO*)^LMnKD`8D@HQ5KnMnkE<9i&;pGwIPW|9N
z8y{)n)-+)@Vwf!7fg4C|4h5-<@3yl3#dk0RH8?cN&sJBc_;TdYgDe1PpR20qDXSHrR=S@usZ~
z=IvpphtwCphehsbSxQ89@WMXIphW`ojSJt_uGB6*F`(Mz?2)1QYiG2h-5_O`qo-cQ
z22r9tMk9UPDCc-m14xkc&mF*4ty-W~Eqh>Hh2Wv)?)^6!s5+Gvschnpxp24u
z3`Tb!AYwp%b9}>p#l;b8edElLevHYxx1z>&GDGdX8tKRdgcABYJa3Y`O7N5-N0(9~
z{NzZm42m!dG6`}Ha#?Gh$NmN)=M=JJ9O4R~my4ts&M;xBjloa(bHEVzRT@F%vZW{V
zQNeCAk5vZ14tdx`o#DF0On?;wO&($)thd*3v*>EF^dca(CE#m`pxg;2`USov6dQ2G
z-(nq30}1`3
zfrLC{$MdlP2*N-3h@?^n)1;zuNj}iT2<6u_8sk+w)$dbYKI&9uCB6KPkH+M4H>n`K@GTzTO&(kIBx?#fYb3d9Gbv-X4%y)b@4oUQ(1O(?F(oFm1$L37Ox;~%f?8z
zUN+kzgL|e3qv+Td!i*oDfw2Ehd+I{NmE~>6t-r21n)`Pcoh$EkfeXW5`yR7)^Tcrv7620NZhCsYo
zrO>K7dHh_qD8reX8h~s>9P06j9b;GvT*}D&>b4DFoJ46f#ziufac*!V3#*xt-Ee9m
zl4IgUwIDq{(qd~-9Br1_Y;|9j$jtsA3bzLZW{&CgGz^DsOa%CT;@6S`7>`%cX0X1{
zZ+Bl4Za%b^i5CW!@-m{1OMlXv*8$G{HxFN)bb
zTFp2bRrF3un}tO0hJ6nK)O=IJGER@`<^c(~LQ1H10iyFFbL4Y_w!AuKQzzqdR;rsX
z??^E_!=QYccdM(`P9lF$ba!RYY;MPNGH2xc{C*-sYI*;?47@eN#6oT$(-+3k{8S04
zdlOpf)M1V}+yq?+3@U@*M189}O1li`)xkl=O=G)t+53z^8UeRbN=Z55zm{xS!&MpP}9+e8@el8BY4#7pP3tm>)t2n--UB>%NjN;}^
zm9jZY@U6ooyi%#yn!!cq_Y)U6<_qhGq*&%&sC`%XJCMDKEX}Ieo=W3z^S9B4gY-+p
zTsNOQzS-nA#B+Y_-%dsFS;5!fhZ+mnbFGuC!YCtn;U=;JhE$&nV$%6F%Drd6lNI_I
z#XA-zEGGPXQ=GEM6%JEtLeNt1YxE1o|E5bK_{3ZS0f^Hyz
zIWr{W=LxZ_8+-=2KE43+yHb(HERF9bZC`3U`LHqlfueHCuGWn8DnfB=iFxN5i4L|?
zo?0SREn1Sd;qZWEh39H(|4ntsq!q|G-x;hQMYPKH8HCaR#RG7paw3VM??!{zrM^|m
zGH9ybHF{f7d6e8EpkERq@ZeK;kvP||j>JZ;decN4I*pDE
zX)n4v-I+AlKXjFf$p9al5&>ih3KavOVK>KT?x&XltQf%@&pEW6#`=ZkGE-Sub4`L!d9;_gpTg(h$
zZv*+q#S6wHI0fu)|L=~y#t$X-r+{=L6D6n#kE{4rk`Abu)OoT~I{7SyLk!*k4`#?)
zkY;>pV);f}hQQwJz>KC+6GlD%%<|#jv)E}AB)kYFP$u52jQ?bcFGq?%k&=~+#O+OO
zRa=m5rAyRgdVn2j8Qcr5&8gB$^!=ftooshQZP~^fDf;8+4nIX4cC&avfgU)Kc69I+F%VBi7$C+
zDr>sbvpy#MWN3=I2G(_r!_ReZu|pH#cR;D!7WfJ$m$kQ}i2W5oTjCY$tdu4}#rTL!
zA=n6LgcUEmqjWY`l#~Y#I*!6q+EN=|vHYm}f{P;F7%>89cQSLGwireh{_0y^f`u8&
zu)-)#(~c(%K(}AXOnlT
zsEK7tPC*qBpyuPp2UI*CR@W{?I?*ze(o?N0$0d-B96x~%-=<4p&EA)sIp6Au=x%k0
zsL#(HK@LB-ZA5%T72n?u>zq0F^X15N;N*&Q>c4Y)f#gn<|Gzl=FaJ3FeaFRJK}Jxj
z;{t_dkrVf8!n`6(G=PGv>lpviqmINukH_qX4_m!gc>W}^rsg72yqXMVpcMRqq&*XE
zB)`^^eUaPd@GGBU#uTowiTADqh<%d$=`LJ7HyRfG0=d)b#R85gX|+5}+e@3FP86v&
z=Fa8z0OepsT|nkQlT+fvFEhdf;pD7a2}*;4+a&3SO^ea8`7Pgi=Q10;z6t#77-7K@
zH%<}31pwa;uhIVEDIsunJ!C=!+CR%mfI|^pLzHEWpxz`ozwt?V6ID1+jxzcSfZZ<4p`4oLTt*pbPEnxw@2E_EVTuN1P1Sq#HMO;DdhZVvQDVndady^u3$qx;RcB|9iIX8+@7;4QwZAp;Xu
z)w&I%#q~?sBkzS>3jwOCUSqKul{-@EC3+K)hJ`9-x&U_YE5FVFEaEGZ9PHfA9=k~q
zb?r^M#c(rWIZ216iGDuY;^x!Y=1hUzZ1mrI(}Jf`8y@iO+3;9vl5b}KpJB5ils|vS
zk{2~)TT2rDMc8uL19fanNe%m)DiZ|5s_rv4l$$p0vJu|!{)JDwv_XTS^2;}>Qqt0A
zpALBZQIoi^z3f2JC&-^H{N49N0P&?LBrH`Oo$~gW+7o7Pf=90$
z$~X6$J)%>^&_=fpe-oHX)jw@jU%k{^t*OpWv%|i25Is5nv`p(`g=Bk8p-?{=m7Nj;i4UhZFS#beH{JWo%1sXM$3o+`0&!n$cVL!6VU>~cO%$k&!Xx}D_T{exQ#5N)5
zvqHC`@3bIiF7PyR=A!eM64mVv0c@xKc|6oJ-4wwCJP<+Q3|A=e!?Pv*CR3VB&};bH
z2@?tb+xI2buCF}WQHao`4*Bcn&KJ5IV*jr2ZmHejhY${Kb)TpF_Hfa@&XXA_Cwo9rLpOnoUEx`X6C&Gq`h?l@+eD^RqM<#J!q1Vfvi(u__}n?-uH+{p%H~rLkKQCu99O
z_~Tzw@PS0byr!T*l+^c8f3B$Bx05B(t9YSy>!Cb?33WnicPZ5o#*6T5V_$CTI=0AD
z#5YNjDWf(j@-GeTUZX#lSJpe}Ac@+Li=M8%7e_M3OZLsg{@6>YLixetn=JAX1USp9
zxmx;j$V!H~!jJ12+OGjfgEb7GNTh4HksFHOBVF}?$ryoJ0J8l^*E$Sb|2w`4>!>Sk
zIzajm+_m4|2n8&8M)P`a#f%HsA?nv2DvF2p{Ff{a(}Zv&5kfko#(lH%1W*}*!D0|k-Hu=^=)r%jS4R(}nFp4Z8T5
zIZ6ve3c%Iq6-oC9FlHwH@X>CUl2|gL!v`)#i}kx3$gPZI!b&;|iB;k4*hb$Kt&YGD
zA->l3{p{8Ed95?1JDa?omJ#3*jhKj_Bc#!Z{ZitBEBit{`NlxWuUmi$9~rM~dg0Pj
zYm{M3DG6H=92maQyA@UvU2#qGPtxK#kzl#QM4^?WAzU*1n4}IUxUW3w>MnCO{!Uj=
zmD~2l_j*@V4F7^6Aw|6RUlCGMaG9$5c31Gu=rnX
za-F_AxOPr72aYf2PB;#J6%+v7h0uUFKjNkTAG-cBAjJq^ZTFYeclh}eB}PX+;Lrd@3r`|`*n
zc*Jf0$-;!+B^s?w*>+Wea=V#>dN~+2gNFW!WKQxWsRxnFQK19_U5X(R`ry+YO*hMWfvrercLQy{bJHz-evKFopG4+
zQb>2>;@i-qSVsBAi>-j0zkWf%dLeWHke76mn=*)>dWkhm_HJp9b4#h&_a~a&Or{_j
zv4irG;7VyJ*=l{O&R{4Z4mZ-N%u|5qh}n;B{`pIuR-#Fy
zODsU5V3qQE=0uzkS398gAmp^V9FLu56QBIbETJAK<)+9)S-?dJj;l=_(9iaH*mT%v
zpEXTM;e?>Z6VXTwW;694eeVSNMQ|qq21u+AhA0gO)Qk$KCf=pC$TnvWt`Wa&8qtdX
zMR!uM3MVU}yrP>qbrnv=BizG*#<+E)IrzqBbp^YR%gUXleP8;6eHiaAQfRsE^OCh(
z$NAXbyK){Qza-MNu6W?@Q>Vh?M%a5exG2~4h&UYwv6t(Lt%7_f%$P&-crj#vy@Wh!
zJVC(N+0#)wEGsAEp)l2zYqFbvO~fs>{zorG;apQsT-ALSLfdS6^z(u
z3X65YhF)jfz86%Y&%}c-Gs602Q-jnZxQQOcD*pNiO?gKswSb}zgGR}2$!b`x+l2t6
ztlFS$MPp4^p6?%Ye@9{d6tkq@(0zUIQJp8w`{v(DAi6Dq~50XAOVnYS0@uYIBjQN+Dd4B$_#t-AZeXYX`)5^=?-zQEG^HwIGX%bOf*4
zk>RR_^>MRdqU#G{q;|HN&;V$W--9yVJQAVIMxWzHjrOp2IkE)9h;w
z2%oF}FvI}ueqqf(zMHJq%=D0yxTF4LRKmBZLH%#?pcotISOjvr+
zN$Vf?dBjt*u7g7vO`>X#5fxSsyD7S=Z2DNic-?yj@~gXcPBz*KR{5krlCTt2sF;y1TK+n^fQ0Y7T=Rb7=IaNTqAvP#JT{Kzt7~wtoX`6utwR{Y0|lpu$7$osHu{deDv%-=FU`k03)x+BMg
z_8z`Se0i}h^$I>y*jm7GU&3zKYU?mqJ3HW$@o!_@ksRDvj+vREyR_*ho0>Qx!
zR`gNF|MYCuJ4izG#@5lagvDT=n+=^%Fq43X)VL@sKqphdK;f>{1Xs^)yJqB1mbx1J
zD%3qCN6QXbhQQdb)s|Wxu8VbF`w$^pX>c=+?kbjLG51N^pxPbbmykL
z9&AbT9vE(v(E=Dzlk4`1oMVU
zn^SW<8L%-LNv*o3$A&q8_?iE*-MA8X57GiJ)T872LF^(^HNc8LOo-Fr(fO*&a}79sKzE
z?61%wLyScFdqR-@J87nd4xF5m3K{Kp39$F?!1dF-dj{j*KKqADV~>YU1iFMZ&aXYY
z#tXTZd}s5i7hh^X)Y0Qp2MCkn?#Hmqbt68?`||@B%6w?144Ve>nt}1rB$|*@Jy^+c
zxvbog$>o~Qz#&{o)?g)5^F(wg&A$x6d3=JaKI_`XeyRSj*Yp~%s!tHAgNZ~CH(T(F
z0#KXKu$AjT-$ZdSAyyk6rS6s@bNV8G;8KNP~$xLG!-V`1GCTkyQ0bDS`-
z=@pcDRk*1T9R8E_n~&S_ejYw8CQ9XejL9YSQC0oH=Q@?Ml?7%H%NYD?+HQ2!BHG7RE1@n?wrV`Tu?V>zI25=bHu;eViVEK}xr_j9hpm=1t|}VO
z&HK%rCc1Mn4HRVP{?$hNJb{)*2Kq|4oWWB=ODjEyw&ec86fL3wBXUi*N{OruY!YL%WB
zvcwWqJ8?A+`3XkPEFtr#+i~DZY$`%#T`L_!+J$zSSCwd@EHBMDH4!hao=%cQy_ueU
z6y+=X!f+blI(}e)4#PyVbL~p!yU{aqrBcJPyw-q&uJd!|9r%rFLJJ@>yN)PgZrgDG7
zX$xUuhtSD`{_*Mn*f#eaGm!7y~8wa@e~_LhxQTd#SNn#gL=J^J(1maPFOBwu%O^?<fr&
zG0=2!zzPnFQWS=Kdba5$%Y2O|lF(^4;so$Cv=U%5qTrH6-OMn}ykQb^Vj3J!sP>Y9
zUsFL-ZTzbfGl?4(Ir^G^W}ji6E>;`Vr&f$dHA|i;y{wvP9l1=Owf`EpJ4CByv3dg{
zpgC3V95Gimq{6j^e};W#up#)fP{*4A4BGQrPCEz=X+ext}0_YD;sVbAa9=c5}s2C
z(eO|Sx2a8R8q)nTX$_CI#)mXMTT^`@=sM{=9$i;O==O3hv5t!Fd&7xEUmc_o@^jC@
zl${R~zVDd>UA5aS3mWMYl5y34)K}QG&DS)=;vd>@JaaB=B@6WL{jqN<^ZSMLyk)A#
z67OGe5Ky}?ffWbELkBAcM^S!U1tT12t#bjV!*3{h3o2Y+W?Eh1+}1)z=@B0^n4H#6
zRf}$ao{T}xDA0Bsm^=EIJu>&%s}Ib_Rt+Yc)`=0p?V_P$?`$#JOU1N)O4Q#deBUu+
zaE1bq+8J6o7CM6kfCQlS%2hNxC|$YzgeEs?Gsh%RuvdOFcW!*MJIt`B?7{>wqpp5*
z_07STscskP>)D#agy#I5p~?bGJt_0*_3vxCSL-wAM{+mHrpiKWye=0(lBVBZFZM4l
z6+U*1Xq@yv;UQ|Bj(4?xEHBm!-u<1!@s;;Q~qT+bh
zFBg{3&N*?te79!FHQh4nnp|v~MXo710(mQqh_!B-
z3<0KTTGK|PFR