peachsim 0.1.2410 → 0.1.2411

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (111) hide show
  1. package/README.md +2 -5
  2. package/cli/internal-child-contract.ts +0 -1
  3. package/cli/internal-child.ts +0 -6
  4. package/cli/outbound-endpoints.ts +0 -23
  5. package/dist-lib/agent-daemon-client.cjs +1 -1
  6. package/dist-lib/agent-events.cjs +1 -1
  7. package/dist-lib/attached-projects.cjs +1 -1
  8. package/dist-lib/auth/shared-session.cjs +1 -1
  9. package/dist-lib/backend-origin.cjs +1 -1
  10. package/dist-lib/beta.cjs +1 -1
  11. package/dist-lib/beta.mjs +1 -1
  12. package/dist-lib/bridge-constants.cjs +1 -1
  13. package/dist-lib/bridge-contract-input.cjs +1 -1
  14. package/dist-lib/bridge-contract-input.mjs +1 -1
  15. package/dist-lib/bridge-contract.cjs +1 -1
  16. package/dist-lib/bridge-contract.mjs +1 -1
  17. package/dist-lib/bundle-channel.cjs +10279 -4163
  18. package/dist-lib/capture-contract.cjs +1 -1
  19. package/dist-lib/capture-contract.mjs +1 -1
  20. package/dist-lib/cloud-contract.cjs +1 -1
  21. package/dist-lib/cloud-contract.mjs +1 -1
  22. package/dist-lib/cloud-test-args.cjs +1 -1
  23. package/dist-lib/cloud-test-args.mjs +1 -1
  24. package/dist-lib/cloud.cjs +1 -1
  25. package/dist-lib/cloud.mjs +1 -1
  26. package/dist-lib/config.cjs +1 -1
  27. package/dist-lib/config.mjs +1 -1
  28. package/dist-lib/detox/index.cjs +1 -1
  29. package/dist-lib/dev-bundle-resolution.cjs +1 -1
  30. package/dist-lib/expo-swift-bundle.cjs +11551 -5435
  31. package/dist-lib/expo-swift-metadata.cjs +1 -1
  32. package/dist-lib/expo-swift-metadata.mjs +1 -1
  33. package/dist-lib/home-paths.cjs +1 -1
  34. package/dist-lib/host/bridge-host.cjs +12798 -6682
  35. package/dist-lib/host/fetch-proxy-handler.cjs +924 -150
  36. package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
  37. package/dist-lib/host/fetch-proxy-overrides.mjs +1 -1
  38. package/dist-lib/host/replacement-module-handler.cjs +1 -1
  39. package/dist-lib/host/websocket-proxy.cjs +1 -1
  40. package/dist-lib/index.cjs +1011 -237
  41. package/dist-lib/jump-to-source-babel.cjs +1 -1
  42. package/dist-lib/jump-to-source-native.cjs +1 -1
  43. package/dist-lib/kotlin-host.cjs +1 -1
  44. package/dist-lib/menu.cjs +1 -1
  45. package/dist-lib/menu.mjs +1 -1
  46. package/dist-lib/metro-fingerprint-registry.cjs +1 -1
  47. package/dist-lib/metro-fingerprint-registry.mjs +1 -1
  48. package/dist-lib/metro-production-bundle.cjs +1 -1
  49. package/dist-lib/metro-production-bundle.mjs +1 -1
  50. package/dist-lib/metro.cjs +927 -153
  51. package/dist-lib/native-app-identity-project.cjs +2 -2
  52. package/dist-lib/native-app-identity-project.mjs +2 -2
  53. package/dist-lib/native-app-identity.cjs +1 -1
  54. package/dist-lib/native-app-identity.mjs +1 -1
  55. package/dist-lib/native-firebase-metadata.cjs +1 -1
  56. package/dist-lib/native-firebase-metadata.mjs +1 -1
  57. package/dist-lib/pdfium-raster.cjs +1 -1
  58. package/dist-lib/pdfium-raster.mjs +1 -1
  59. package/dist-lib/plist.cjs +1 -1
  60. package/dist-lib/plist.mjs +1 -1
  61. package/dist-lib/profiles.cjs +1 -1
  62. package/dist-lib/public-brand.cjs +1 -1
  63. package/dist-lib/public-origins-lib-esm.json +24 -24
  64. package/dist-lib/public-origins-lib.json +124 -104
  65. package/dist-lib/react-native-host-modules.cjs +1 -1
  66. package/dist-lib/react-native-host-modules.mjs +1 -1
  67. package/dist-lib/reap-browser.cjs +1 -1
  68. package/dist-lib/scripts/dev-server-scanner.cjs +1 -1
  69. package/dist-lib/sdk.cjs +1 -1
  70. package/dist-lib/sdk.mjs +1 -1
  71. package/dist-lib/skills.cjs +13905 -7789
  72. package/dist-lib/swift-compile.cjs +62 -14
  73. package/dist-lib/swift-compile.mjs +62 -13
  74. package/dist-lib/swift-package.cjs +1 -1
  75. package/dist-lib/swift-package.mjs +1 -1
  76. package/dist-lib/swift-submit.cjs +1 -1
  77. package/dist-lib/swift-submit.mjs +1 -1
  78. package/dist-lib/swift-toolchain.cjs +1 -1
  79. package/dist-lib/swift.cjs +1 -1
  80. package/dist-lib/vite-swift.cjs +76 -19
  81. package/dist-lib/vite.cjs +3100 -2326
  82. package/dist-lib/worklet-executable.cjs +1 -1
  83. package/dist-lib/worklet-executable.mjs +1 -1
  84. package/kotlin/sdk.tar.gz +0 -0
  85. package/package.json +3 -3
  86. package/sdk/ios/System/Library/Frameworks/AuthenticationServices.framework/Headers/ASWebAuthenticationSession.h +1 -1
  87. package/sdk/ios/System/Library/Frameworks/Photos.framework/Headers/PHAsset.h +1 -1
  88. package/sdk/ios/System/Library/Frameworks/Photos.framework/Headers/PHAssetResource.h +1 -1
  89. package/sdk/ios/System/Library/Frameworks/Photos.framework/Headers/PHChange.h +1 -1
  90. package/sdk/ios/System/Library/Frameworks/Photos.framework/Headers/PHFetchOptions.h +1 -1
  91. package/sdk/ios/System/Library/Frameworks/Photos.framework/Headers/PHFetchResult.h +1 -1
  92. package/sdk/ios/System/Library/Frameworks/Photos.framework/Headers/PHImageManager.h +2 -2
  93. package/sdk/ios/System/Library/Frameworks/Photos.framework/Headers/PHObject.h +1 -1
  94. package/sdk/ios/System/Library/Frameworks/Photos.framework/Headers/PHPhotoLibrary.h +2 -2
  95. package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIDevice.h +1 -1
  96. package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIVibrancyEffect.h +1 -1
  97. package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIVisualEffectView.h +1 -1
  98. package/sdk/ios/System/Library/Frameworks/UIKitActivity.framework/Headers/UIKitActivity.h +1 -1
  99. package/src/nitro-adapter.lock.json +262 -262
  100. package/src/nitro-superset.lock.json +4 -4
  101. package/src/podspec-cocoapods.ts +934 -0
  102. package/src/podspec-prism.ts +66 -0
  103. package/src/podspec-ruby-stdlib.ts +1121 -0
  104. package/src/podspec-ruby.ts +5175 -0
  105. package/src/podspec-sources.ts +25 -112
  106. package/src/swift-compile.ts +70 -12
  107. package/src/swift-distribution.lock.json +9 -8
  108. package/src/swift-host.ts +14 -4
  109. package/src/turbo-runtime.lock.json +19 -19
  110. package/cli/drivers/linux-cocoapods.lock.json +0 -303
  111. package/cli/drivers/linux-cocoapods.ts +0 -99
@@ -1,4 +1,4 @@
1
- /*! peach v0.1.2410 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.2411 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
2
2
  let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -85,7 +85,6 @@ __export(swift_compile_exports, {
85
85
  swiftSystemLibraryExclusions: () => swiftSystemLibraryExclusions,
86
86
  swiftSystemLibrarySurface: () => swiftSystemLibrarySurface,
87
87
  swiftTargetDependencies: () => swiftTargetDependencies,
88
- swiftTargetsOnWasmArch: () => swiftTargetsOnWasmArch,
89
88
  swiftTypedApplicationEntry: () => swiftTypedApplicationEntry,
90
89
  syncSwiftTree: () => syncSwiftTree,
91
90
  withNativeSourceGlue: () => withNativeSourceGlue,
@@ -13866,7 +13865,7 @@ var darwinRecordsRegion = (quoted2) => quoted2.length ? ["-Wl,--start-lib", ...q
13866
13865
  var REACTOR_FLAG = '"-Xclang-linker", "-mexec-model=reactor",\n';
13867
13866
  var MULTI_MANIFEST_VERSION = 71;
13868
13867
  var SWIFT_HEADER_PRODUCTS_TARGET = "PeachHeaderProducts";
13869
- var compilerSourceDigest = true ? "d287f3ad479477c70004707c1336f37c9baeb81aef1880544a5ca236e088ca16" : swiftCompilerSourceDigest(__sootsim_import_meta_dirname);
13868
+ var compilerSourceDigest = true ? "5bdda04d424b3a504c042269bf0bebf701fc0435974970611138a79db9b959cd" : swiftCompilerSourceDigest(__sootsim_import_meta_dirname);
13870
13869
  function swiftArtifactHash(input, release, moduleRoot) {
13871
13870
  const hash = (0, import_node_crypto14.createHash)("sha256");
13872
13871
  hash.update(`swift-compile
@@ -14386,6 +14385,8 @@ var ARCH_ARM64 = /\barch\(\s*arm64\s*\)/g;
14386
14385
  var NOT_ON_IOS = /\b(?:os\(\s*WASI\s*\)|canImport\(\s*FoundationNetworking\s*\))/g;
14387
14386
  var DELEGATE_CLASS = /^class\s+[A-Za-z_]\w*\s*(?:<[^>{]*>)?\s*:[^{]*\b(?:UIApplicationDelegate|UISceneDelegate|UIWindowSceneDelegate)\b[^{]*\{/;
14388
14387
  var ARM64_MACRO = /^__(?:aarch64|arm64|AARCH64|ARM)/;
14388
+ var WASM_MACRO = /\b__(?:wasm(?:32|64)?|wasi)__\b/;
14389
+ var ARCH_WASM32 = /\barch\(\s*wasm32\s*\)/;
14389
14390
  var C_WORDS = new Set(
14390
14391
  "auto bool break case char const continue default do double else enum extern false float for goto if inline int long register restrict return short signed sizeof static struct switch true typedef union unsigned void volatile while YES NO NULL nil Nil id self super instancetype".split(
14391
14392
  " "
@@ -14403,18 +14404,28 @@ function headerNamesByArch(headers) {
14403
14404
  }
14404
14405
  };
14405
14406
  })();
14406
- const names = { arm64: /* @__PURE__ */ new Set(), wasm: /* @__PURE__ */ new Set() };
14407
+ const names = {
14408
+ arm64: /* @__PURE__ */ new Set(),
14409
+ wasm: /* @__PURE__ */ new Set(),
14410
+ withoutWasm: /* @__PURE__ */ new Set()
14411
+ };
14412
+ const withoutWasm = { ...archEnvironments.wasm, defines: emptyMacroEnvironment.defines };
14407
14413
  for (const header of headers) {
14408
14414
  const code = stripCCode(header);
14409
14415
  const wasm = cActiveCode(code, archEnvironments.wasm).match(/[A-Za-z_]\w*/g) ?? [];
14410
14416
  for (const name2 of wasm) names.wasm.add(name2);
14417
+ if (WASM_MACRO.test(code))
14418
+ for (const match of cActiveCode(code, withoutWasm).matchAll(
14419
+ /\b([A-Za-z_]\w*)\s*\(/g
14420
+ ))
14421
+ names.withoutWasm.add(match[1]);
14411
14422
  if (!/\b__(?:aarch64|arm64|AARCH64|ARM)/.test(code)) continue;
14412
14423
  for (const name2 of cActiveCode(code, archEnvironments.arm64).match(/[A-Za-z_]\w*/g) ?? [])
14413
14424
  names.arm64.add(name2);
14414
14425
  }
14415
14426
  return names;
14416
14427
  }
14417
- function swiftTargetsOnWasmArch(targets, swiftSources, headers) {
14428
+ function swiftTargetArchitectures(targets, swiftSources, headers) {
14418
14429
  const byName = new Map(targets.map((target) => [target.name, target]));
14419
14430
  const namesByTarget = /* @__PURE__ */ new Map();
14420
14431
  const targetNames = (target) => {
@@ -14424,6 +14435,7 @@ function swiftTargetsOnWasmArch(targets, swiftSources, headers) {
14424
14435
  return names;
14425
14436
  };
14426
14437
  const onWasm = /* @__PURE__ */ new Set();
14438
+ const withoutWasm = /* @__PURE__ */ new Map();
14427
14439
  for (const [name2, sources] of swiftSources) {
14428
14440
  const target = byName.get(name2);
14429
14441
  if (!target) continue;
@@ -14435,6 +14447,12 @@ function swiftTargetsOnWasmArch(targets, swiftSources, headers) {
14435
14447
  })
14436
14448
  ].map(targetNames);
14437
14449
  const wasm = new Set(visible.flatMap((names) => [...names.wasm]));
14450
+ if (sources.some((source) => ARCH_WASM32.test(source))) {
14451
+ const unavailable = new Set(
14452
+ visible.flatMap((names) => [...names.withoutWasm]).filter((name3) => !wasm.has(name3))
14453
+ );
14454
+ if (unavailable.size) withoutWasm.set(name2, unavailable);
14455
+ }
14438
14456
  const arm64Only = [...new Set(visible.flatMap((names) => [...names.arm64]))].filter(
14439
14457
  (name3) => !wasm.has(name3) && !C_WORDS.has(name3)
14440
14458
  );
@@ -14443,7 +14461,41 @@ function swiftTargetsOnWasmArch(targets, swiftSources, headers) {
14443
14461
  if (sources.some((source) => named.test(source) && named.test(swiftCodeMask(source))))
14444
14462
  onWasm.add(name2);
14445
14463
  }
14446
- return onWasm;
14464
+ return { onWasm, withoutWasm };
14465
+ }
14466
+ function swiftWasmCallGuards(source, unavailable) {
14467
+ if (!ARCH_WASM32.test(source)) return source;
14468
+ const code = swiftCodeMask(source);
14469
+ const clauses = /^[ \t]*#(if|elseif|else|endif)\b([^\n]*)/gm;
14470
+ const stack = [];
14471
+ const edits = [];
14472
+ for (const directive of code.matchAll(clauses)) {
14473
+ const kind = directive[1];
14474
+ if (kind !== "if") {
14475
+ const previous = stack.pop();
14476
+ if (previous) {
14477
+ const body = code.slice(previous.body, directive.index);
14478
+ for (const match of body.matchAll(/\b([A-Za-z_]\w*)\s*\(/g)) {
14479
+ if (!unavailable.has(match[1])) continue;
14480
+ const condition = ARCH_WASM32.exec(code.slice(previous.start, previous.body));
14481
+ edits.push([
14482
+ previous.start + condition.index,
14483
+ condition[0].length,
14484
+ "true".padEnd(condition[0].length)
14485
+ ]);
14486
+ break;
14487
+ }
14488
+ }
14489
+ }
14490
+ if (kind !== "endif")
14491
+ stack.push(
14492
+ /^\s*!\s*arch\(\s*wasm32\s*\)\s*$/.test(directive[2]) ? { start: directive.index, body: directive.index + directive[0].length } : void 0
14493
+ );
14494
+ }
14495
+ let out = source;
14496
+ for (const [at, width, replacement] of edits.sort((a, b) => b[0] - a[0]))
14497
+ out = out.slice(0, at) + replacement + out.slice(at + width);
14498
+ return out;
14447
14499
  }
14448
14500
  function compiledSwiftSources(files, targets, overlayFrameworks, headers, nativeSourceGlue = false) {
14449
14501
  const ordered = [...targets].sort((a, b) => b.path.length - a.path.length);
@@ -14464,7 +14516,7 @@ function compiledSwiftSources(files, targets, overlayFrameworks, headers, native
14464
14516
  for (const { source, owner } of owners.values())
14465
14517
  if (owner)
14466
14518
  swiftSources.set(owner.name, [...swiftSources.get(owner.name) ?? [], source]);
14467
- const wasmArch = swiftTargetsOnWasmArch(targets, swiftSources, headers);
14519
+ const { onWasm, withoutWasm } = swiftTargetArchitectures(targets, swiftSources, headers);
14468
14520
  return new Map(
14469
14521
  [...owners].map(([file, { source, owner }]) => {
14470
14522
  if (nativeSourceGlue && import_node_path26.default.posix.basename(file) === "OneNativeSource.generated.swift")
@@ -14472,11 +14524,12 @@ function compiledSwiftSources(files, targets, overlayFrameworks, headers, native
14472
14524
  const manifest = /(?:^|\/)Package(?:@swift-[\d.]+)?\.swift$/.test(file);
14473
14525
  if (manifest && (!owner || /^Package(?:@swift-[\d.]+)?\.swift$/.test(file)))
14474
14526
  return [file, source];
14527
+ const unavailable = owner && withoutWasm.get(owner.name);
14475
14528
  const ios = swiftSourceAsIOS(
14476
- source,
14529
+ unavailable ? swiftWasmCallGuards(source, unavailable) : source,
14477
14530
  overlayFrameworks,
14478
14531
  owner?.defines?.includes(SWIFT_XCODE_BUILD_CONDITION) && !owner.defines.includes("SWIFT_PACKAGE") ? false : void 0,
14479
- !owner || !wasmArch.has(owner.name)
14532
+ !owner || !onWasm.has(owner.name)
14480
14533
  );
14481
14534
  return [file, withPreconcurrencyFoundationModules(ios)];
14482
14535
  })
@@ -14618,7 +14671,6 @@ var FOUNDATION_OVERLAY_TYPES = /* @__PURE__ */ new Set([
14618
14671
  "NSAssertionHandler",
14619
14672
  "NSAttributedStringFormattingContextKey",
14620
14673
  "NSBundleResourceRequest",
14621
- "NSCollectionChangeType",
14622
14674
  "NSConditionLock",
14623
14675
  "NSException",
14624
14676
  "NSExtensionItem",
@@ -14656,9 +14708,6 @@ var FOUNDATION_OVERLAY_TYPES = /* @__PURE__ */ new Set([
14656
14708
  "NSMetadataQueryAttributeValueTuple",
14657
14709
  "NSMetadataQueryDelegate",
14658
14710
  "NSMetadataQueryResultGroup",
14659
- "NSOrderedCollectionChange",
14660
- "NSOrderedCollectionDifference",
14661
- "NSOrderedCollectionDifferenceCalculationOptions",
14662
14711
  "NSPointerArray",
14663
14712
  "NSPredicateValidating",
14664
14713
  "NSProxy",
@@ -18683,7 +18732,6 @@ function compileSwiftProjectOnce(input, options) {
18683
18732
  swiftSystemLibraryExclusions,
18684
18733
  swiftSystemLibrarySurface,
18685
18734
  swiftTargetDependencies,
18686
- swiftTargetsOnWasmArch,
18687
18735
  swiftTypedApplicationEntry,
18688
18736
  syncSwiftTree,
18689
18737
  withNativeSourceGlue,
@@ -1,4 +1,4 @@
1
- /*! peach v0.1.2410 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.2411 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
2
2
  var __defProp = Object.defineProperty;
3
3
  var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
4
4
  var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
@@ -13854,7 +13854,7 @@ var darwinRecordsRegion = (quoted2) => quoted2.length ? ["-Wl,--start-lib", ...q
13854
13854
  var REACTOR_FLAG = '"-Xclang-linker", "-mexec-model=reactor",\n';
13855
13855
  var MULTI_MANIFEST_VERSION = 71;
13856
13856
  var SWIFT_HEADER_PRODUCTS_TARGET = "PeachHeaderProducts";
13857
- var compilerSourceDigest = true ? "d287f3ad479477c70004707c1336f37c9baeb81aef1880544a5ca236e088ca16" : swiftCompilerSourceDigest(import.meta.dirname);
13857
+ var compilerSourceDigest = true ? "5bdda04d424b3a504c042269bf0bebf701fc0435974970611138a79db9b959cd" : swiftCompilerSourceDigest(import.meta.dirname);
13858
13858
  function swiftArtifactHash(input, release, moduleRoot) {
13859
13859
  const hash = createHash14("sha256");
13860
13860
  hash.update(`swift-compile
@@ -14374,6 +14374,8 @@ var ARCH_ARM64 = /\barch\(\s*arm64\s*\)/g;
14374
14374
  var NOT_ON_IOS = /\b(?:os\(\s*WASI\s*\)|canImport\(\s*FoundationNetworking\s*\))/g;
14375
14375
  var DELEGATE_CLASS = /^class\s+[A-Za-z_]\w*\s*(?:<[^>{]*>)?\s*:[^{]*\b(?:UIApplicationDelegate|UISceneDelegate|UIWindowSceneDelegate)\b[^{]*\{/;
14376
14376
  var ARM64_MACRO = /^__(?:aarch64|arm64|AARCH64|ARM)/;
14377
+ var WASM_MACRO = /\b__(?:wasm(?:32|64)?|wasi)__\b/;
14378
+ var ARCH_WASM32 = /\barch\(\s*wasm32\s*\)/;
14377
14379
  var C_WORDS = new Set(
14378
14380
  "auto bool break case char const continue default do double else enum extern false float for goto if inline int long register restrict return short signed sizeof static struct switch true typedef union unsigned void volatile while YES NO NULL nil Nil id self super instancetype".split(
14379
14381
  " "
@@ -14391,18 +14393,28 @@ function headerNamesByArch(headers) {
14391
14393
  }
14392
14394
  };
14393
14395
  })());
14394
- const names = { arm64: /* @__PURE__ */ new Set(), wasm: /* @__PURE__ */ new Set() };
14396
+ const names = {
14397
+ arm64: /* @__PURE__ */ new Set(),
14398
+ wasm: /* @__PURE__ */ new Set(),
14399
+ withoutWasm: /* @__PURE__ */ new Set()
14400
+ };
14401
+ const withoutWasm = { ...archEnvironments.wasm, defines: emptyMacroEnvironment.defines };
14395
14402
  for (const header of headers) {
14396
14403
  const code = stripCCode(header);
14397
14404
  const wasm = cActiveCode(code, archEnvironments.wasm).match(/[A-Za-z_]\w*/g) ?? [];
14398
14405
  for (const name2 of wasm) names.wasm.add(name2);
14406
+ if (WASM_MACRO.test(code))
14407
+ for (const match of cActiveCode(code, withoutWasm).matchAll(
14408
+ /\b([A-Za-z_]\w*)\s*\(/g
14409
+ ))
14410
+ names.withoutWasm.add(match[1]);
14399
14411
  if (!/\b__(?:aarch64|arm64|AARCH64|ARM)/.test(code)) continue;
14400
14412
  for (const name2 of cActiveCode(code, archEnvironments.arm64).match(/[A-Za-z_]\w*/g) ?? [])
14401
14413
  names.arm64.add(name2);
14402
14414
  }
14403
14415
  return names;
14404
14416
  }
14405
- function swiftTargetsOnWasmArch(targets, swiftSources, headers) {
14417
+ function swiftTargetArchitectures(targets, swiftSources, headers) {
14406
14418
  const byName = new Map(targets.map((target) => [target.name, target]));
14407
14419
  const namesByTarget = /* @__PURE__ */ new Map();
14408
14420
  const targetNames = (target) => {
@@ -14412,6 +14424,7 @@ function swiftTargetsOnWasmArch(targets, swiftSources, headers) {
14412
14424
  return names;
14413
14425
  };
14414
14426
  const onWasm = /* @__PURE__ */ new Set();
14427
+ const withoutWasm = /* @__PURE__ */ new Map();
14415
14428
  for (const [name2, sources] of swiftSources) {
14416
14429
  const target = byName.get(name2);
14417
14430
  if (!target) continue;
@@ -14423,6 +14436,12 @@ function swiftTargetsOnWasmArch(targets, swiftSources, headers) {
14423
14436
  })
14424
14437
  ].map(targetNames);
14425
14438
  const wasm = new Set(visible.flatMap((names) => [...names.wasm]));
14439
+ if (sources.some((source) => ARCH_WASM32.test(source))) {
14440
+ const unavailable = new Set(
14441
+ visible.flatMap((names) => [...names.withoutWasm]).filter((name3) => !wasm.has(name3))
14442
+ );
14443
+ if (unavailable.size) withoutWasm.set(name2, unavailable);
14444
+ }
14426
14445
  const arm64Only = [...new Set(visible.flatMap((names) => [...names.arm64]))].filter(
14427
14446
  (name3) => !wasm.has(name3) && !C_WORDS.has(name3)
14428
14447
  );
@@ -14431,7 +14450,41 @@ function swiftTargetsOnWasmArch(targets, swiftSources, headers) {
14431
14450
  if (sources.some((source) => named.test(source) && named.test(swiftCodeMask(source))))
14432
14451
  onWasm.add(name2);
14433
14452
  }
14434
- return onWasm;
14453
+ return { onWasm, withoutWasm };
14454
+ }
14455
+ function swiftWasmCallGuards(source, unavailable) {
14456
+ if (!ARCH_WASM32.test(source)) return source;
14457
+ const code = swiftCodeMask(source);
14458
+ const clauses = /^[ \t]*#(if|elseif|else|endif)\b([^\n]*)/gm;
14459
+ const stack = [];
14460
+ const edits = [];
14461
+ for (const directive of code.matchAll(clauses)) {
14462
+ const kind = directive[1];
14463
+ if (kind !== "if") {
14464
+ const previous = stack.pop();
14465
+ if (previous) {
14466
+ const body = code.slice(previous.body, directive.index);
14467
+ for (const match of body.matchAll(/\b([A-Za-z_]\w*)\s*\(/g)) {
14468
+ if (!unavailable.has(match[1])) continue;
14469
+ const condition = ARCH_WASM32.exec(code.slice(previous.start, previous.body));
14470
+ edits.push([
14471
+ previous.start + condition.index,
14472
+ condition[0].length,
14473
+ "true".padEnd(condition[0].length)
14474
+ ]);
14475
+ break;
14476
+ }
14477
+ }
14478
+ }
14479
+ if (kind !== "endif")
14480
+ stack.push(
14481
+ /^\s*!\s*arch\(\s*wasm32\s*\)\s*$/.test(directive[2]) ? { start: directive.index, body: directive.index + directive[0].length } : void 0
14482
+ );
14483
+ }
14484
+ let out = source;
14485
+ for (const [at, width, replacement] of edits.sort((a, b) => b[0] - a[0]))
14486
+ out = out.slice(0, at) + replacement + out.slice(at + width);
14487
+ return out;
14435
14488
  }
14436
14489
  function compiledSwiftSources(files, targets, overlayFrameworks, headers, nativeSourceGlue = false) {
14437
14490
  const ordered = [...targets].sort((a, b) => b.path.length - a.path.length);
@@ -14452,7 +14505,7 @@ function compiledSwiftSources(files, targets, overlayFrameworks, headers, native
14452
14505
  for (const { source, owner } of owners.values())
14453
14506
  if (owner)
14454
14507
  swiftSources.set(owner.name, [...swiftSources.get(owner.name) ?? [], source]);
14455
- const wasmArch = swiftTargetsOnWasmArch(targets, swiftSources, headers);
14508
+ const { onWasm, withoutWasm } = swiftTargetArchitectures(targets, swiftSources, headers);
14456
14509
  return new Map(
14457
14510
  [...owners].map(([file, { source, owner }]) => {
14458
14511
  if (nativeSourceGlue && path28.posix.basename(file) === "OneNativeSource.generated.swift")
@@ -14460,11 +14513,12 @@ function compiledSwiftSources(files, targets, overlayFrameworks, headers, native
14460
14513
  const manifest = /(?:^|\/)Package(?:@swift-[\d.]+)?\.swift$/.test(file);
14461
14514
  if (manifest && (!owner || /^Package(?:@swift-[\d.]+)?\.swift$/.test(file)))
14462
14515
  return [file, source];
14516
+ const unavailable = owner && withoutWasm.get(owner.name);
14463
14517
  const ios = swiftSourceAsIOS(
14464
- source,
14518
+ unavailable ? swiftWasmCallGuards(source, unavailable) : source,
14465
14519
  overlayFrameworks,
14466
14520
  owner?.defines?.includes(SWIFT_XCODE_BUILD_CONDITION) && !owner.defines.includes("SWIFT_PACKAGE") ? false : void 0,
14467
- !owner || !wasmArch.has(owner.name)
14521
+ !owner || !onWasm.has(owner.name)
14468
14522
  );
14469
14523
  return [file, withPreconcurrencyFoundationModules(ios)];
14470
14524
  })
@@ -14606,7 +14660,6 @@ var FOUNDATION_OVERLAY_TYPES = /* @__PURE__ */ new Set([
14606
14660
  "NSAssertionHandler",
14607
14661
  "NSAttributedStringFormattingContextKey",
14608
14662
  "NSBundleResourceRequest",
14609
- "NSCollectionChangeType",
14610
14663
  "NSConditionLock",
14611
14664
  "NSException",
14612
14665
  "NSExtensionItem",
@@ -14644,9 +14697,6 @@ var FOUNDATION_OVERLAY_TYPES = /* @__PURE__ */ new Set([
14644
14697
  "NSMetadataQueryAttributeValueTuple",
14645
14698
  "NSMetadataQueryDelegate",
14646
14699
  "NSMetadataQueryResultGroup",
14647
- "NSOrderedCollectionChange",
14648
- "NSOrderedCollectionDifference",
14649
- "NSOrderedCollectionDifferenceCalculationOptions",
14650
14700
  "NSPointerArray",
14651
14701
  "NSPredicateValidating",
14652
14702
  "NSProxy",
@@ -18670,7 +18720,6 @@ export {
18670
18720
  swiftSystemLibraryExclusions,
18671
18721
  swiftSystemLibrarySurface,
18672
18722
  swiftTargetDependencies,
18673
- swiftTargetsOnWasmArch,
18674
18723
  swiftTypedApplicationEntry,
18675
18724
  syncSwiftTree,
18676
18725
  withNativeSourceGlue,
@@ -1,4 +1,4 @@
1
- /*! peach v0.1.2410 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.2411 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
2
2
  let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! peach v0.1.2410 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.2411 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
2
2
 
3
3
  // src/swift-package.ts
4
4
  function swiftManifestSettings(target) {
@@ -1,4 +1,4 @@
1
- /*! peach v0.1.2410 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.2411 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
2
2
  let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! peach v0.1.2410 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.2411 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
2
2
 
3
3
  // src/is-record.ts
4
4
  function isRecord(value) {
@@ -1,4 +1,4 @@
1
- /*! peach v0.1.2410 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.2411 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
2
2
  let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -1,4 +1,4 @@
1
- /*! peach v0.1.2410 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.2411 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
2
2
  let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! peach v0.1.2410 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.2411 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
2
2
  let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -18781,7 +18781,7 @@ var darwinRecordsRegion = (quoted2) => quoted2.length ? ["-Wl,--start-lib", ...q
18781
18781
  var REACTOR_FLAG = '"-Xclang-linker", "-mexec-model=reactor",\n';
18782
18782
  var MULTI_MANIFEST_VERSION = 71;
18783
18783
  var SWIFT_HEADER_PRODUCTS_TARGET = "PeachHeaderProducts";
18784
- var compilerSourceDigest = true ? "d287f3ad479477c70004707c1336f37c9baeb81aef1880544a5ca236e088ca16" : swiftCompilerSourceDigest(__sootsim_import_meta_dirname);
18784
+ var compilerSourceDigest = true ? "5bdda04d424b3a504c042269bf0bebf701fc0435974970611138a79db9b959cd" : swiftCompilerSourceDigest(__sootsim_import_meta_dirname);
18785
18785
  function swiftArtifactHash(input, release, moduleRoot) {
18786
18786
  const hash = (0, import_node_crypto14.createHash)("sha256");
18787
18787
  hash.update(`swift-compile
@@ -19301,6 +19301,8 @@ var ARCH_ARM64 = /\barch\(\s*arm64\s*\)/g;
19301
19301
  var NOT_ON_IOS = /\b(?:os\(\s*WASI\s*\)|canImport\(\s*FoundationNetworking\s*\))/g;
19302
19302
  var DELEGATE_CLASS = /^class\s+[A-Za-z_]\w*\s*(?:<[^>{]*>)?\s*:[^{]*\b(?:UIApplicationDelegate|UISceneDelegate|UIWindowSceneDelegate)\b[^{]*\{/;
19303
19303
  var ARM64_MACRO = /^__(?:aarch64|arm64|AARCH64|ARM)/;
19304
+ var WASM_MACRO = /\b__(?:wasm(?:32|64)?|wasi)__\b/;
19305
+ var ARCH_WASM32 = /\barch\(\s*wasm32\s*\)/;
19304
19306
  var C_WORDS = new Set(
19305
19307
  "auto bool break case char const continue default do double else enum extern false float for goto if inline int long register restrict return short signed sizeof static struct switch true typedef union unsigned void volatile while YES NO NULL nil Nil id self super instancetype".split(
19306
19308
  " "
@@ -19318,18 +19320,28 @@ function headerNamesByArch(headers) {
19318
19320
  }
19319
19321
  };
19320
19322
  })();
19321
- const names = { arm64: /* @__PURE__ */ new Set(), wasm: /* @__PURE__ */ new Set() };
19323
+ const names = {
19324
+ arm64: /* @__PURE__ */ new Set(),
19325
+ wasm: /* @__PURE__ */ new Set(),
19326
+ withoutWasm: /* @__PURE__ */ new Set()
19327
+ };
19328
+ const withoutWasm = { ...archEnvironments.wasm, defines: emptyMacroEnvironment.defines };
19322
19329
  for (const header of headers) {
19323
19330
  const code = stripCCode(header);
19324
19331
  const wasm = cActiveCode(code, archEnvironments.wasm).match(/[A-Za-z_]\w*/g) ?? [];
19325
19332
  for (const name3 of wasm) names.wasm.add(name3);
19333
+ if (WASM_MACRO.test(code))
19334
+ for (const match of cActiveCode(code, withoutWasm).matchAll(
19335
+ /\b([A-Za-z_]\w*)\s*\(/g
19336
+ ))
19337
+ names.withoutWasm.add(match[1]);
19326
19338
  if (!/\b__(?:aarch64|arm64|AARCH64|ARM)/.test(code)) continue;
19327
19339
  for (const name3 of cActiveCode(code, archEnvironments.arm64).match(/[A-Za-z_]\w*/g) ?? [])
19328
19340
  names.arm64.add(name3);
19329
19341
  }
19330
19342
  return names;
19331
19343
  }
19332
- function swiftTargetsOnWasmArch(targets, swiftSources, headers) {
19344
+ function swiftTargetArchitectures(targets, swiftSources, headers) {
19333
19345
  const byName = new Map(targets.map((target) => [target.name, target]));
19334
19346
  const namesByTarget = /* @__PURE__ */ new Map();
19335
19347
  const targetNames = (target) => {
@@ -19339,6 +19351,7 @@ function swiftTargetsOnWasmArch(targets, swiftSources, headers) {
19339
19351
  return names;
19340
19352
  };
19341
19353
  const onWasm = /* @__PURE__ */ new Set();
19354
+ const withoutWasm = /* @__PURE__ */ new Map();
19342
19355
  for (const [name3, sources] of swiftSources) {
19343
19356
  const target = byName.get(name3);
19344
19357
  if (!target) continue;
@@ -19350,6 +19363,12 @@ function swiftTargetsOnWasmArch(targets, swiftSources, headers) {
19350
19363
  })
19351
19364
  ].map(targetNames);
19352
19365
  const wasm = new Set(visible.flatMap((names) => [...names.wasm]));
19366
+ if (sources.some((source) => ARCH_WASM32.test(source))) {
19367
+ const unavailable2 = new Set(
19368
+ visible.flatMap((names) => [...names.withoutWasm]).filter((name4) => !wasm.has(name4))
19369
+ );
19370
+ if (unavailable2.size) withoutWasm.set(name3, unavailable2);
19371
+ }
19353
19372
  const arm64Only = [...new Set(visible.flatMap((names) => [...names.arm64]))].filter(
19354
19373
  (name4) => !wasm.has(name4) && !C_WORDS.has(name4)
19355
19374
  );
@@ -19358,7 +19377,41 @@ function swiftTargetsOnWasmArch(targets, swiftSources, headers) {
19358
19377
  if (sources.some((source) => named.test(source) && named.test(swiftCodeMask(source))))
19359
19378
  onWasm.add(name3);
19360
19379
  }
19361
- return onWasm;
19380
+ return { onWasm, withoutWasm };
19381
+ }
19382
+ function swiftWasmCallGuards(source, unavailable2) {
19383
+ if (!ARCH_WASM32.test(source)) return source;
19384
+ const code = swiftCodeMask(source);
19385
+ const clauses = /^[ \t]*#(if|elseif|else|endif)\b([^\n]*)/gm;
19386
+ const stack = [];
19387
+ const edits = [];
19388
+ for (const directive of code.matchAll(clauses)) {
19389
+ const kind = directive[1];
19390
+ if (kind !== "if") {
19391
+ const previous = stack.pop();
19392
+ if (previous) {
19393
+ const body = code.slice(previous.body, directive.index);
19394
+ for (const match of body.matchAll(/\b([A-Za-z_]\w*)\s*\(/g)) {
19395
+ if (!unavailable2.has(match[1])) continue;
19396
+ const condition = ARCH_WASM32.exec(code.slice(previous.start, previous.body));
19397
+ edits.push([
19398
+ previous.start + condition.index,
19399
+ condition[0].length,
19400
+ "true".padEnd(condition[0].length)
19401
+ ]);
19402
+ break;
19403
+ }
19404
+ }
19405
+ }
19406
+ if (kind !== "endif")
19407
+ stack.push(
19408
+ /^\s*!\s*arch\(\s*wasm32\s*\)\s*$/.test(directive[2]) ? { start: directive.index, body: directive.index + directive[0].length } : void 0
19409
+ );
19410
+ }
19411
+ let out = source;
19412
+ for (const [at, width, replacement] of edits.sort((a, b) => b[0] - a[0]))
19413
+ out = out.slice(0, at) + replacement + out.slice(at + width);
19414
+ return out;
19362
19415
  }
19363
19416
  function compiledSwiftSources(files2, targets, overlayFrameworks, headers, nativeSourceGlue = false) {
19364
19417
  const ordered = [...targets].sort((a, b) => b.path.length - a.path.length);
@@ -19379,7 +19432,7 @@ function compiledSwiftSources(files2, targets, overlayFrameworks, headers, nativ
19379
19432
  for (const { source, owner } of owners.values())
19380
19433
  if (owner)
19381
19434
  swiftSources.set(owner.name, [...swiftSources.get(owner.name) ?? [], source]);
19382
- const wasmArch = swiftTargetsOnWasmArch(targets, swiftSources, headers);
19435
+ const { onWasm, withoutWasm } = swiftTargetArchitectures(targets, swiftSources, headers);
19383
19436
  return new Map(
19384
19437
  [...owners].map(([file, { source, owner }]) => {
19385
19438
  if (nativeSourceGlue && import_node_path28.default.posix.basename(file) === "OneNativeSource.generated.swift")
@@ -19387,11 +19440,12 @@ function compiledSwiftSources(files2, targets, overlayFrameworks, headers, nativ
19387
19440
  const manifest = /(?:^|\/)Package(?:@swift-[\d.]+)?\.swift$/.test(file);
19388
19441
  if (manifest && (!owner || /^Package(?:@swift-[\d.]+)?\.swift$/.test(file)))
19389
19442
  return [file, source];
19443
+ const unavailable2 = owner && withoutWasm.get(owner.name);
19390
19444
  const ios = swiftSourceAsIOS(
19391
- source,
19445
+ unavailable2 ? swiftWasmCallGuards(source, unavailable2) : source,
19392
19446
  overlayFrameworks,
19393
19447
  owner?.defines?.includes(SWIFT_XCODE_BUILD_CONDITION) && !owner.defines.includes("SWIFT_PACKAGE") ? false : void 0,
19394
- !owner || !wasmArch.has(owner.name)
19448
+ !owner || !onWasm.has(owner.name)
19395
19449
  );
19396
19450
  return [file, withPreconcurrencyFoundationModules(ios)];
19397
19451
  })
@@ -19533,7 +19587,6 @@ var FOUNDATION_OVERLAY_TYPES = /* @__PURE__ */ new Set([
19533
19587
  "NSAssertionHandler",
19534
19588
  "NSAttributedStringFormattingContextKey",
19535
19589
  "NSBundleResourceRequest",
19536
- "NSCollectionChangeType",
19537
19590
  "NSConditionLock",
19538
19591
  "NSException",
19539
19592
  "NSExtensionItem",
@@ -19571,9 +19624,6 @@ var FOUNDATION_OVERLAY_TYPES = /* @__PURE__ */ new Set([
19571
19624
  "NSMetadataQueryAttributeValueTuple",
19572
19625
  "NSMetadataQueryDelegate",
19573
19626
  "NSMetadataQueryResultGroup",
19574
- "NSOrderedCollectionChange",
19575
- "NSOrderedCollectionDifference",
19576
- "NSOrderedCollectionDifferenceCalculationOptions",
19577
19627
  "NSPointerArray",
19578
19628
  "NSPredicateValidating",
19579
19629
  "NSProxy",
@@ -34319,7 +34369,7 @@ function sourceClosureDigest(srcDir, entrypoints, excludedFiles) {
34319
34369
  return hash.digest("hex");
34320
34370
  }
34321
34371
  var standinSourceDigest = (srcDir = __sootsim_import_meta_dirname) => sourceClosureDigest(srcDir, STANDIN_DIGEST_ENTRYPOINTS);
34322
- var STANDIN_SOURCE_DIGEST = true ? "33613fe0a59b84be02c11350a1382f0d95184a98af5ca339e388eff115c7ac07" : standinSourceDigest();
34372
+ var STANDIN_SOURCE_DIGEST = true ? "2d765e977c08a74dad452d5ca662fba6baa967ccf18a7456e60717372076300b" : standinSourceDigest();
34323
34373
 
34324
34374
  // src/swift-standins.ts
34325
34375
  var import_node_child_process32 = require("node:child_process");
@@ -39690,8 +39740,7 @@ var RNX_INTERNAL_CHILDREN = {
39690
39740
  playwrightInstall: "playwright-install",
39691
39741
  playwrightHost: "playwright-host",
39692
39742
  syncHttp: "sync-http",
39693
- pdfRaster: "pdf-raster",
39694
- linuxCocoaPods: "linux-cocoapods"
39743
+ pdfRaster: "pdf-raster"
39695
39744
  };
39696
39745
 
39697
39746
  // cli/self-invocation.ts
@@ -41033,13 +41082,21 @@ function buildSwiftResourceTable(project, baseUrl, inputs) {
41033
41082
  return swiftResourceBundleForFile(bundles, key2)?.path ?? ".";
41034
41083
  }
41035
41084
  ).map((image) => ({ ...image, file: bundled.get(image.file) ?? image.file }));
41036
- const colors = enumerateBundleColors(catalogFiles, readContents2);
41037
- const symbols = enumerateBundleSymbols(catalogFiles, readContents2, (file) => {
41085
+ const catalogBundle = (file) => {
41038
41086
  const disk = byRelative.get(file);
41039
- if (!disk) throw new Error(`symbol source ${file} has no input file`);
41087
+ if (!disk) throw new Error(`catalog source ${file} has no input file`);
41040
41088
  const key2 = layout2 ? xcodeInputKey(layout2, disk, file) : file;
41041
41089
  return swiftResourceBundleForFile(bundles, key2)?.path ?? ".";
41042
- });
41090
+ };
41091
+ const colors = enumerateBundleColors(catalogFiles, readContents2);
41092
+ const packageCatalogs = Map.groupBy(catalogFiles, catalogBundle);
41093
+ packageCatalogs.delete(".");
41094
+ for (const [bundle, files2] of packageCatalogs)
41095
+ for (const [name3, color] of Object.entries(
41096
+ enumerateBundleColors(files2, readContents2)
41097
+ ))
41098
+ colors[`${bundle}/${name3}`] = color;
41099
+ const symbols = enumerateBundleSymbols(catalogFiles, readContents2, catalogBundle);
41043
41100
  const table = /* @__PURE__ */ Object.create(null);
41044
41101
  const images = {};
41045
41102
  const metalSources = {};