peachsim 0.1.1966 → 0.1.1968

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 (83) hide show
  1. package/dist-lib/agent-daemon-client.cjs +1 -1
  2. package/dist-lib/agent-events.cjs +1 -1
  3. package/dist-lib/attached-projects.cjs +1 -1
  4. package/dist-lib/auth/shared-session.cjs +1 -1
  5. package/dist-lib/backend-origin.cjs +1 -1
  6. package/dist-lib/beta.cjs +1 -1
  7. package/dist-lib/beta.mjs +1 -1
  8. package/dist-lib/bridge-constants.cjs +1 -1
  9. package/dist-lib/bridge-contract-input.cjs +1 -1
  10. package/dist-lib/bridge-contract-input.mjs +1 -1
  11. package/dist-lib/bridge-contract.cjs +1 -1
  12. package/dist-lib/bridge-contract.mjs +1 -1
  13. package/dist-lib/bundle-channel.cjs +92 -15
  14. package/dist-lib/capture-contract.cjs +1 -1
  15. package/dist-lib/capture-contract.mjs +1 -1
  16. package/dist-lib/cloud-contract.cjs +1 -1
  17. package/dist-lib/cloud-contract.mjs +1 -1
  18. package/dist-lib/cloud-test-args.cjs +1 -1
  19. package/dist-lib/cloud-test-args.mjs +1 -1
  20. package/dist-lib/cloud.cjs +1 -1
  21. package/dist-lib/cloud.mjs +1 -1
  22. package/dist-lib/config.cjs +1 -1
  23. package/dist-lib/config.mjs +1 -1
  24. package/dist-lib/detox/index.cjs +1 -1
  25. package/dist-lib/dev-bundle-resolution.cjs +1 -1
  26. package/dist-lib/expo-swift-bundle.cjs +90 -13
  27. package/dist-lib/expo-swift-metadata.cjs +1 -1
  28. package/dist-lib/expo-swift-metadata.mjs +1 -1
  29. package/dist-lib/home-paths.cjs +1 -1
  30. package/dist-lib/host/bridge-host.cjs +91 -14
  31. package/dist-lib/host/fetch-proxy-handler.cjs +1 -1
  32. package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
  33. package/dist-lib/host/fetch-proxy-overrides.mjs +1 -1
  34. package/dist-lib/host/replacement-module-handler.cjs +1 -1
  35. package/dist-lib/host/websocket-proxy.cjs +1 -1
  36. package/dist-lib/index.cjs +2 -2
  37. package/dist-lib/jump-to-source-babel.cjs +1 -1
  38. package/dist-lib/jump-to-source-native.cjs +1 -1
  39. package/dist-lib/kotlin-host.cjs +1 -1
  40. package/dist-lib/menu.cjs +1 -1
  41. package/dist-lib/menu.mjs +1 -1
  42. package/dist-lib/metro-fingerprint-registry.cjs +1 -1
  43. package/dist-lib/metro-fingerprint-registry.mjs +1 -1
  44. package/dist-lib/metro-production-bundle.cjs +1 -1
  45. package/dist-lib/metro-production-bundle.mjs +1 -1
  46. package/dist-lib/metro.cjs +2 -2
  47. package/dist-lib/native-app-identity-project.cjs +2 -2
  48. package/dist-lib/native-app-identity-project.mjs +2 -2
  49. package/dist-lib/native-app-identity.cjs +1 -1
  50. package/dist-lib/native-app-identity.mjs +1 -1
  51. package/dist-lib/native-firebase-metadata.cjs +1 -1
  52. package/dist-lib/native-firebase-metadata.mjs +1 -1
  53. package/dist-lib/pdfium-raster.cjs +1 -1
  54. package/dist-lib/pdfium-raster.mjs +1 -1
  55. package/dist-lib/plist.cjs +1 -1
  56. package/dist-lib/plist.mjs +1 -1
  57. package/dist-lib/profiles.cjs +1 -1
  58. package/dist-lib/public-brand.cjs +1 -1
  59. package/dist-lib/public-origins-lib-esm.json +24 -24
  60. package/dist-lib/public-origins-lib.json +53 -53
  61. package/dist-lib/react-native-host-modules.cjs +1 -1
  62. package/dist-lib/react-native-host-modules.mjs +1 -1
  63. package/dist-lib/reap-browser.cjs +1 -1
  64. package/dist-lib/scripts/dev-server-scanner.cjs +1 -1
  65. package/dist-lib/sdk.cjs +1 -1
  66. package/dist-lib/sdk.mjs +1 -1
  67. package/dist-lib/skills.cjs +92 -15
  68. package/dist-lib/swift-compile.cjs +2 -2
  69. package/dist-lib/swift-compile.mjs +2 -2
  70. package/dist-lib/swift-package.cjs +1 -1
  71. package/dist-lib/swift-package.mjs +1 -1
  72. package/dist-lib/swift-submit.cjs +1 -1
  73. package/dist-lib/swift-submit.mjs +1 -1
  74. package/dist-lib/swift-toolchain.cjs +1 -1
  75. package/dist-lib/swift.cjs +1 -1
  76. package/dist-lib/vite-swift.cjs +89 -12
  77. package/dist-lib/vite.cjs +1 -1
  78. package/dist-lib/worklet-executable.cjs +1 -1
  79. package/dist-lib/worklet-executable.mjs +1 -1
  80. package/package.json +1 -1
  81. package/src/swift-objc-standin.ts +77 -4
  82. package/src/swift-standin-emit.ts +25 -3
  83. package/src/swift-standins.ts +7 -1
@@ -1,4 +1,4 @@
1
- /*! peach v0.1.1966 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.1968 | (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;
@@ -42970,6 +42970,7 @@ function emitSwiftStandin(sourceGraphs, options) {
42970
42970
  const superclass = /* @__PURE__ */ new Map();
42971
42971
  const superId = /* @__PURE__ */ new Map();
42972
42972
  const conforms = /* @__PURE__ */ new Map();
42973
+ const conditional = [];
42973
42974
  const conformanceTargets = /* @__PURE__ */ new Map();
42974
42975
  const objectConformers = /* @__PURE__ */ new Set();
42975
42976
  const conformIds = /* @__PURE__ */ new Map();
@@ -42985,7 +42986,10 @@ function emitSwiftStandin(sourceGraphs, options) {
42985
42986
  const parts = fallback.split(".");
42986
42987
  const module2 = parts[0] === "SwiftUICore" ? "SwiftUI" : parts[0];
42987
42988
  const unqualified = parts.slice(1).join(".") || parts[0];
42988
- const name3 = family.has(parts[0]) && parts[0] !== "SwiftUICore" ? parts.join(".") : unqualified;
42989
+ const name3 = parts.length > 1 && family.has(parts[0]) && parts[0] !== "SwiftUICore" ? (
42990
+ // a module selector reaches past a class named like its module
42991
+ `${parts[0]}::${unqualified}`
42992
+ ) : unqualified;
42989
42993
  return { name: name3, module: module2, local: false };
42990
42994
  };
42991
42995
  const nsObject = nameOf("c:objc(cs)NSObject", "ObjectiveC.NSObject").name;
@@ -43000,6 +43004,7 @@ function emitSwiftStandin(sourceGraphs, options) {
43000
43004
  if (edge.sourceOrigin) origins.set(edge.source, edge.sourceOrigin.displayName);
43001
43005
  switch (edge.kind) {
43002
43006
  case "memberOf": {
43007
+ if (edge.source === edge.target) break;
43003
43008
  const parent = byId.get(edge.target);
43004
43009
  if (parent) {
43005
43010
  owner.set(edge.source, edge.target);
@@ -43030,7 +43035,15 @@ function emitSwiftStandin(sourceGraphs, options) {
43030
43035
  path: pathOf(source),
43031
43036
  reason: `unsupported Objective-C protocol parent ${edge.target}`
43032
43037
  });
43033
- if (name3) {
43038
+ if (name3 && edge.swiftConstraints?.length) {
43039
+ conditional.push({
43040
+ source,
43041
+ name: name3,
43042
+ where: edge.swiftConstraints.map(
43043
+ ({ kind, lhs, rhs }) => kind === "sameType" ? `${lhs} == ${rhs}` : `${lhs}: ${rhs}`
43044
+ ).join(", ")
43045
+ });
43046
+ } else if (name3) {
43034
43047
  conforms.set(edge.source, [...conforms.get(edge.source) ?? [], name3]);
43035
43048
  const targets = conformanceTargets.get(edge.source) ?? /* @__PURE__ */ new Map();
43036
43049
  targets.set(name3, edge.target);
@@ -43511,7 +43524,7 @@ function emitSwiftStandin(sourceGraphs, options) {
43511
43524
  if (!parentSymbol || !ownIds.has(parentSymbol.identifier.precise))
43512
43525
  list2.push(standinMarker);
43513
43526
  const open = symbol2.accessLevel === "open" && (!parentSymbol || parentSymbol.accessLevel === "open");
43514
- const objcName = /^c:objc\(cs\)(\w+)$/.exec(id)?.[1];
43527
+ const objcName = shape.generics ? void 0 : /^c:objc\(cs\)(\w+)$/.exec(id)?.[1];
43515
43528
  emit(
43516
43529
  `${indent2}${shape.attrs}${objcName ? `@objc(${objcName}) ` : ""}${shape.final}${open ? "open" : "public"} class ${shape.name}${shape.generics}${list2.length ? `: ${list2.join(", ")}` : ""}${selfConforming(shape.where)} {`
43517
43530
  );
@@ -43906,6 +43919,8 @@ function emitSwiftStandin(sourceGraphs, options) {
43906
43919
  emitWitness(witness.member, " ", witness.path);
43907
43920
  emit("}");
43908
43921
  }
43922
+ for (const { source, name: name3, where } of conditional)
43923
+ emitAt(pathOf(source), `extension ${pathOf(source)}: ${name3} where ${where} {}`);
43909
43924
  const banner = [
43910
43925
  ...options.placeholder ? [
43911
43926
  `// placeholder for ${options.module}, generated from ${options.source}: ${options.placeholder}.`,
@@ -44335,13 +44350,18 @@ function objcView(surface, toolchainBin, stdlib, cacheDir5, work, original, vend
44335
44350
  import_node_fs32.default.mkdirSync(import_node_path29.default.dirname(file), { recursive: true });
44336
44351
  import_node_fs32.default.writeFileSync(file, text6);
44337
44352
  }
44353
+ const interfaceCopies = [];
44338
44354
  if (framework) {
44339
44355
  import_node_fs32.default.mkdirSync(import_node_path29.default.join(frameworks, `${surface.module}.framework`, "Modules"), {
44340
44356
  recursive: true
44341
44357
  });
44342
- import_node_fs32.default.copyFileSync(
44343
- surface.modulemap,
44344
- import_node_path29.default.join(frameworks, `${surface.module}.framework`, "Modules", "module.modulemap")
44358
+ const modulemap = import_node_fs32.default.readFileSync(surface.modulemap, "utf8");
44359
+ import_node_fs32.default.writeFileSync(
44360
+ import_node_path29.default.join(frameworks, `${surface.module}.framework`, "Modules", "module.modulemap"),
44361
+ surface.interface ? modulemap.replace(
44362
+ new RegExp(`\\n\\s*module\\s+${surface.module}\\.Swift\\s*\\{[^}]*\\}`),
44363
+ ""
44364
+ ) : modulemap
44345
44365
  );
44346
44366
  if (surface.interface) {
44347
44367
  const from = import_node_path29.default.dirname(surface.interface);
@@ -44353,14 +44373,16 @@ function objcView(surface, toolchainBin, stdlib, cacheDir5, work, original, vend
44353
44373
  );
44354
44374
  import_node_fs32.default.mkdirSync(to, { recursive: true });
44355
44375
  for (const name3 of import_node_fs32.default.readdirSync(from))
44356
- if (name3.endsWith(".swiftinterface"))
44376
+ if (name3.endsWith(".swiftinterface")) {
44377
+ interfaceCopies.push(import_node_path29.default.join(to, name3));
44357
44378
  import_node_fs32.default.writeFileSync(
44358
44379
  import_node_path29.default.join(to, name3),
44359
- import_node_fs32.default.readFileSync(import_node_path29.default.join(from, name3), "utf8").replace(/\bCoreFoundation\.(?=CG)/g, "CoreGraphics.").replace(/\bCoreFoundation\.(?=\w)/g, "Foundation.").replace(
44380
+ import_node_fs32.default.readFileSync(import_node_path29.default.join(from, name3), "utf8").replace(/\bCoreFoundation\.(?=CG)/g, "CoreGraphics.").replace(/\bCoreFoundation\.(?=\w)/g, "Foundation.").replace(/\bDarwin\.OSStatus\b/g, "Swift.Int32").replace(
44360
44381
  /\bFoundation\.Data\.(?=Base64(?:En|De)codingOptions\b)/g,
44361
44382
  "Foundation.NSData."
44362
44383
  )
44363
44384
  );
44385
+ }
44364
44386
  }
44365
44387
  } else {
44366
44388
  import_node_fs32.default.copyFileSync(surface.modulemap, import_node_path29.default.join(headersDir, "module.modulemap"));
@@ -44518,6 +44540,7 @@ function objcView(surface, toolchainBin, stdlib, cacheDir5, work, original, vend
44518
44540
  return name3 ? { name: name3, before: text6.slice(0, column - 1), after: rest.slice(name3.length) } : null;
44519
44541
  };
44520
44542
  const typeKind = (name3, after) => /^[A-Z][A-Z0-9_]+$/.test(name3) && !/^\s*\*/.test(after) ? "macro" : /^\s*\*/.test(after) ? "class" : "struct";
44543
+ const selectors = /* @__PURE__ */ new Set();
44521
44544
  for (let round = 0; ; round++) {
44522
44545
  import_node_fs32.default.rmSync(out, { recursive: true, force: true });
44523
44546
  import_node_fs32.default.mkdirSync(out, { recursive: true });
@@ -44555,6 +44578,21 @@ function objcView(surface, toolchainBin, stdlib, cacheDir5, work, original, vend
44555
44578
  `original Objective-C declarations do not import as Swift: ${run12.stderr.trim() || run12.stdout.trim()}`
44556
44579
  );
44557
44580
  let progress = false;
44581
+ for (const [, shadowed, same] of run12.stderr.matchAll(
44582
+ /is not a member type of class '(\w+)\.(\w+)'/g
44583
+ ))
44584
+ if (shadowed === same && !selectors.has(shadowed)) {
44585
+ selectors.add(shadowed);
44586
+ progress = true;
44587
+ for (const file of interfaceCopies)
44588
+ import_node_fs32.default.writeFileSync(
44589
+ file,
44590
+ import_node_fs32.default.readFileSync(file, "utf8").replace(
44591
+ new RegExp(`\\b${shadowed}\\.(?=[A-Za-z_])`, "g"),
44592
+ `${shadowed}::`
44593
+ )
44594
+ );
44595
+ }
44558
44596
  const learn = (name3, kind) => {
44559
44597
  if (missing2.has(name3)) return;
44560
44598
  missing2.set(name3, kind);
@@ -44693,6 +44731,30 @@ function objcView(surface, toolchainBin, stdlib, cacheDir5, work, original, vend
44693
44731
  inherit(pairs2[Number(match[1])].superclass[0], "s:s8SendableP");
44694
44732
  }
44695
44733
  }
44734
+ const refined = [...originals.values()].flatMap(
44735
+ (text6) => [
44736
+ ...text6.matchAll(
44737
+ /\b(?:FOUNDATION_EXTERN|FOUNDATION_EXPORT|extern)\s+([\w\s*]+?)\s+const\s+(\w+)\s+NS_REFINED_FOR_SWIFT\s*;/g
44738
+ )
44739
+ ].flatMap(([, ctype, name3]) => {
44740
+ const type = REFINED_CONSTANT_TYPES.get(ctype.replace(/\s+/g, ""));
44741
+ if (!type) return [];
44742
+ return [
44743
+ {
44744
+ kind: { identifier: "swift.var" },
44745
+ identifier: { precise: `c:@${name3}` },
44746
+ pathComponents: [`__${name3}`],
44747
+ declarationFragments: [
44748
+ { kind: "keyword", spelling: "let" },
44749
+ { kind: "text", spelling: ` __${name3}: ${type}` }
44750
+ ],
44751
+ accessLevel: "public"
44752
+ }
44753
+ ];
44754
+ })
44755
+ );
44756
+ if (refined.length > 0)
44757
+ graphs.push({ module: { name: surface.module }, symbols: refined, relationships: [] });
44696
44758
  const imports2 = /* @__PURE__ */ new Set(["Foundation", "UIKit"]);
44697
44759
  for (const text6 of originals.values())
44698
44760
  for (const name3 of clangImportNames(text6)) imports2.add(name3);
@@ -45002,7 +45064,7 @@ function constantValue(node) {
45002
45064
  }
45003
45065
  return null;
45004
45066
  }
45005
- var import_node_child_process17, import_node_crypto14, import_node_fs32, import_node_path29, NATIVE_GRAPH_SDK_VERSION, WASI_EMULATION, WASI_EMULATION_FLAGS, NATIVE_GRAPH_INPUTS, NATIVE_GRAPH_ID, resolvedPinnedSdk, ROUNDS, sdkId, headerFiles, MISSING_IMPORT, FRAMEWORK_HEADER, FRAMEWORK_MODULEMAP, sdkDeclarations;
45067
+ var import_node_child_process17, import_node_crypto14, import_node_fs32, import_node_path29, REFINED_CONSTANT_TYPES, NATIVE_GRAPH_SDK_VERSION, WASI_EMULATION, WASI_EMULATION_FLAGS, NATIVE_GRAPH_INPUTS, NATIVE_GRAPH_ID, resolvedPinnedSdk, ROUNDS, sdkId, headerFiles, MISSING_IMPORT, FRAMEWORK_HEADER, FRAMEWORK_MODULEMAP, sdkDeclarations;
45006
45068
  var init_swift_objc_standin = __esm({
45007
45069
  "src/swift-objc-standin.ts"() {
45008
45070
  "use strict";
@@ -45017,6 +45079,15 @@ var init_swift_objc_standin = __esm({
45017
45079
  init_swift_package();
45018
45080
  init_swift_standin_emit();
45019
45081
  init_swift_toolchain();
45082
+ REFINED_CONSTANT_TYPES = /* @__PURE__ */ new Map([
45083
+ ["NSInteger", "Int"],
45084
+ ["NSUInteger", "UInt"],
45085
+ ["NSTimeInterval", "TimeInterval"],
45086
+ ["double", "Double"],
45087
+ ["CGFloat", "CGFloat"],
45088
+ ["BOOL", "Bool"],
45089
+ ["NSString*", "String"]
45090
+ ]);
45020
45091
  NATIVE_GRAPH_SDK_VERSION = "27.1";
45021
45092
  WASI_EMULATION = [
45022
45093
  "_WASI_EMULATED_SIGNAL",
@@ -57155,7 +57226,7 @@ var init_swift_compile = __esm({
57155
57226
  REACTOR_FLAG = '"-Xclang-linker", "-mexec-model=reactor",\n';
57156
57227
  MULTI_MANIFEST_VERSION = 66;
57157
57228
  SWIFT_HEADER_PRODUCTS_TARGET = "PeachHeaderProducts";
57158
- compilerSourceDigest = true ? "43445ac597f2b7673127e43186400d0f6863caf82dafb48c31ce3b516719ce13" : swiftCompilerSourceDigest(__sootsim_import_meta_dirname);
57229
+ compilerSourceDigest = true ? "4c6d0c445f1c9d7fab6a4d2bbd910ec116536acc8d1aa621f70c74c10dd9faba" : swiftCompilerSourceDigest(__sootsim_import_meta_dirname);
57159
57230
  nativeCxxCompilerFlags = ["-fno-cxx-modules"];
57160
57231
  cFlagArray = (flags) => JSON.stringify(withoutGlogModuleMap(flags));
57161
57232
  cxxFlagArray = (flags) => JSON.stringify([...nativeCxxCompilerFlags, ...withoutGlogModuleMap(flags)]);
@@ -63491,7 +63562,7 @@ var init_swift_standin_digest = __esm({
63491
63562
  STANDIN_DIGEST_ENTRYPOINTS = ["swift-standins.ts", "swift-objc-compile.ts"];
63492
63563
  SPECIFIER = /from\s*['"]([^'"]+)['"]|import\s*\(\s*['"]([^'"]+)['"]\s*\)/g;
63493
63564
  standinSourceDigest = (srcDir = __sootsim_import_meta_dirname) => sourceClosureDigest(srcDir, STANDIN_DIGEST_ENTRYPOINTS);
63494
- STANDIN_SOURCE_DIGEST = true ? "05087ee542759092b4dbe08e7a7c0a03416fa45a27f3c2e9b633d6d5ce98186a" : standinSourceDigest();
63565
+ STANDIN_SOURCE_DIGEST = true ? "01e0eae770cafd2bbd23d98a22897ab31ada19f5a273a8f25da7c88aa3086c09" : standinSourceDigest();
63495
63566
  }
63496
63567
  });
63497
63568
 
@@ -64221,7 +64292,7 @@ var init_expo_native_prebuilt = __esm({
64221
64292
  init_swift_native_pin();
64222
64293
  init_xcode_project();
64223
64294
  EXPO_NATIVE_ENTRY_NAME = "ios";
64224
- EXPO_NATIVE_COMPILER_DIGEST = true ? "9fd2ff84edb7b369a3643fb86c96987ded6cba6ac0477de1cb94ecd8e4b6f59a" : expoNativeCompilerDigest(__sootsim_import_meta_dirname);
64295
+ EXPO_NATIVE_COMPILER_DIGEST = true ? "022284864952d1dbc7df026947d11c21515e286edc351e6daa1c083fe4b3c12a" : expoNativeCompilerDigest(__sootsim_import_meta_dirname);
64225
64296
  IDENTITY_SOURCE_SKIPS = 1 | 4 | 8 | 16 | 32 | 64 | 128 | 4096;
64226
64297
  expoNativeEntryUrl = (key2, file) => `${NATIVE_PREBUILT_ORIGIN}/${nativeEntryPrefix("expo", EXPO_NATIVE_ENTRY_NAME, key2)}/${file}`;
64227
64298
  isStringRecord = (value) => isRecord(value) && Object.values(value).every((item) => typeof item === "string");
@@ -66614,7 +66685,13 @@ function mixedStandin(surface, binary2, toolchain, work, behavior, frameworkDirs
66614
66685
  }))
66615
66686
  };
66616
66687
  });
66617
- const imports2 = [.../* @__PURE__ */ new Set([...swiftImportNames(interfaceText), ...owners])].filter(
66688
+ const imports2 = [
66689
+ .../* @__PURE__ */ new Set([
66690
+ ...swiftImportNames(interfaceText),
66691
+ ...view.imports.filter((name3) => !STANDIN_IMPORTS.includes(name3)),
66692
+ ...owners
66693
+ ])
66694
+ ].filter(
66618
66695
  (module2) => module2 !== surface.module && (provided.has(module2) || siblings.has(module2))
66619
66696
  );
66620
66697
  return graphStandin(
@@ -82549,7 +82626,7 @@ var init_nitro_superset = __esm({
82549
82626
  init_swift_standin_digest();
82550
82627
  NITRO_SUPERSET_ENTRY_NAME = "superset";
82551
82628
  packageVersion = (root) => JSON.parse((0, import_node_fs92.readFileSync)((0, import_node_path90.join)(root, "package.json"), "utf8")).version;
82552
- NITRO_COMPILER_DIGEST = true ? "3ad21cbda2a2bd818f67e1ab27dcd9d6d1397386d5e1cf00a7b9539969ac577a" : nitroCompilerSourceDigest(__sootsim_import_meta_dirname, STANDIN_SOURCE_DIGEST2);
82629
+ NITRO_COMPILER_DIGEST = true ? "c785598cf743dc275f207273c9195800163f524e59977420e693f356cffa6d72" : nitroCompilerSourceDigest(__sootsim_import_meta_dirname, STANDIN_SOURCE_DIGEST2);
82553
82630
  nitroSupersetLock = parseLock(nitro_superset_lock_default);
82554
82631
  nitroSupersetKey = (inputs) => nativeEntryKey({ ...inputs, compiler: NITRO_COMPILER_DIGEST });
82555
82632
  published2 = /* @__PURE__ */ new Map();
@@ -1,4 +1,4 @@
1
- /*! peach v0.1.1966 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.1968 | (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;
@@ -12377,7 +12377,7 @@ var darwinRecordsRegion = (quoted) => quoted.length ? ["-Wl,--start-lib", ...quo
12377
12377
  var REACTOR_FLAG = '"-Xclang-linker", "-mexec-model=reactor",\n';
12378
12378
  var MULTI_MANIFEST_VERSION = 66;
12379
12379
  var SWIFT_HEADER_PRODUCTS_TARGET = "PeachHeaderProducts";
12380
- var compilerSourceDigest = true ? "43445ac597f2b7673127e43186400d0f6863caf82dafb48c31ce3b516719ce13" : swiftCompilerSourceDigest(__sootsim_import_meta_dirname);
12380
+ var compilerSourceDigest = true ? "4c6d0c445f1c9d7fab6a4d2bbd910ec116536acc8d1aa621f70c74c10dd9faba" : swiftCompilerSourceDigest(__sootsim_import_meta_dirname);
12381
12381
  function swiftArtifactHash(input, release, moduleRoot) {
12382
12382
  const hash = (0, import_node_crypto13.createHash)("sha256");
12383
12383
  hash.update(`swift-compile
@@ -1,4 +1,4 @@
1
- /*! peach v0.1.1966 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.1968 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
2
2
 
3
3
  // src/swift-compile.ts
4
4
  import {
@@ -12359,7 +12359,7 @@ var darwinRecordsRegion = (quoted) => quoted.length ? ["-Wl,--start-lib", ...quo
12359
12359
  var REACTOR_FLAG = '"-Xclang-linker", "-mexec-model=reactor",\n';
12360
12360
  var MULTI_MANIFEST_VERSION = 66;
12361
12361
  var SWIFT_HEADER_PRODUCTS_TARGET = "PeachHeaderProducts";
12362
- var compilerSourceDigest = true ? "43445ac597f2b7673127e43186400d0f6863caf82dafb48c31ce3b516719ce13" : swiftCompilerSourceDigest(import.meta.dirname);
12362
+ var compilerSourceDigest = true ? "4c6d0c445f1c9d7fab6a4d2bbd910ec116536acc8d1aa621f70c74c10dd9faba" : swiftCompilerSourceDigest(import.meta.dirname);
12363
12363
  function swiftArtifactHash(input, release, moduleRoot) {
12364
12364
  const hash = createHash13("sha256");
12365
12365
  hash.update(`swift-compile
@@ -1,4 +1,4 @@
1
- /*! peach v0.1.1966 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.1968 | (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.1966 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.1968 | (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.1966 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.1968 | (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.1966 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.1968 | (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.1966 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.1968 | (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.1966 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.1968 | (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.1966 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.1968 | (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;
@@ -6272,6 +6272,7 @@ function emitSwiftStandin(sourceGraphs, options) {
6272
6272
  const superclass = /* @__PURE__ */ new Map();
6273
6273
  const superId = /* @__PURE__ */ new Map();
6274
6274
  const conforms = /* @__PURE__ */ new Map();
6275
+ const conditional = [];
6275
6276
  const conformanceTargets = /* @__PURE__ */ new Map();
6276
6277
  const objectConformers = /* @__PURE__ */ new Set();
6277
6278
  const conformIds = /* @__PURE__ */ new Map();
@@ -6287,7 +6288,10 @@ function emitSwiftStandin(sourceGraphs, options) {
6287
6288
  const parts = fallback.split(".");
6288
6289
  const module2 = parts[0] === "SwiftUICore" ? "SwiftUI" : parts[0];
6289
6290
  const unqualified = parts.slice(1).join(".") || parts[0];
6290
- const name3 = family.has(parts[0]) && parts[0] !== "SwiftUICore" ? parts.join(".") : unqualified;
6291
+ const name3 = parts.length > 1 && family.has(parts[0]) && parts[0] !== "SwiftUICore" ? (
6292
+ // a module selector reaches past a class named like its module
6293
+ `${parts[0]}::${unqualified}`
6294
+ ) : unqualified;
6291
6295
  return { name: name3, module: module2, local: false };
6292
6296
  };
6293
6297
  const nsObject = nameOf("c:objc(cs)NSObject", "ObjectiveC.NSObject").name;
@@ -6302,6 +6306,7 @@ function emitSwiftStandin(sourceGraphs, options) {
6302
6306
  if (edge.sourceOrigin) origins.set(edge.source, edge.sourceOrigin.displayName);
6303
6307
  switch (edge.kind) {
6304
6308
  case "memberOf": {
6309
+ if (edge.source === edge.target) break;
6305
6310
  const parent = byId.get(edge.target);
6306
6311
  if (parent) {
6307
6312
  owner.set(edge.source, edge.target);
@@ -6332,7 +6337,15 @@ function emitSwiftStandin(sourceGraphs, options) {
6332
6337
  path: pathOf(source),
6333
6338
  reason: `unsupported Objective-C protocol parent ${edge.target}`
6334
6339
  });
6335
- if (name3) {
6340
+ if (name3 && edge.swiftConstraints?.length) {
6341
+ conditional.push({
6342
+ source,
6343
+ name: name3,
6344
+ where: edge.swiftConstraints.map(
6345
+ ({ kind, lhs, rhs }) => kind === "sameType" ? `${lhs} == ${rhs}` : `${lhs}: ${rhs}`
6346
+ ).join(", ")
6347
+ });
6348
+ } else if (name3) {
6336
6349
  conforms.set(edge.source, [...conforms.get(edge.source) ?? [], name3]);
6337
6350
  const targets = conformanceTargets.get(edge.source) ?? /* @__PURE__ */ new Map();
6338
6351
  targets.set(name3, edge.target);
@@ -6813,7 +6826,7 @@ function emitSwiftStandin(sourceGraphs, options) {
6813
6826
  if (!parentSymbol || !ownIds.has(parentSymbol.identifier.precise))
6814
6827
  list2.push(standinMarker);
6815
6828
  const open = symbol2.accessLevel === "open" && (!parentSymbol || parentSymbol.accessLevel === "open");
6816
- const objcName = /^c:objc\(cs\)(\w+)$/.exec(id)?.[1];
6829
+ const objcName = shape.generics ? void 0 : /^c:objc\(cs\)(\w+)$/.exec(id)?.[1];
6817
6830
  emit(
6818
6831
  `${indent2}${shape.attrs}${objcName ? `@objc(${objcName}) ` : ""}${shape.final}${open ? "open" : "public"} class ${shape.name}${shape.generics}${list2.length ? `: ${list2.join(", ")}` : ""}${selfConforming(shape.where)} {`
6819
6832
  );
@@ -7208,6 +7221,8 @@ function emitSwiftStandin(sourceGraphs, options) {
7208
7221
  emitWitness(witness.member, " ", witness.path);
7209
7222
  emit("}");
7210
7223
  }
7224
+ for (const { source, name: name3, where } of conditional)
7225
+ emitAt(pathOf(source), `extension ${pathOf(source)}: ${name3} where ${where} {}`);
7211
7226
  const banner = [
7212
7227
  ...options.placeholder ? [
7213
7228
  `// placeholder for ${options.module}, generated from ${options.source}: ${options.placeholder}.`,
@@ -7303,6 +7318,15 @@ function stripDefaults(decl) {
7303
7318
  }
7304
7319
 
7305
7320
  // src/swift-objc-standin.ts
7321
+ var REFINED_CONSTANT_TYPES = /* @__PURE__ */ new Map([
7322
+ ["NSInteger", "Int"],
7323
+ ["NSUInteger", "UInt"],
7324
+ ["NSTimeInterval", "TimeInterval"],
7325
+ ["double", "Double"],
7326
+ ["CGFloat", "CGFloat"],
7327
+ ["BOOL", "Bool"],
7328
+ ["NSString*", "String"]
7329
+ ]);
7306
7330
  var NATIVE_GRAPH_SDK_VERSION = "27.1";
7307
7331
  var WASI_EMULATION = [
7308
7332
  "_WASI_EMULATED_SIGNAL",
@@ -7596,13 +7620,18 @@ function objcView(surface, toolchainBin, stdlib, cacheDir5, work, original, vend
7596
7620
  import_node_fs7.default.mkdirSync(import_node_path7.default.dirname(file), { recursive: true });
7597
7621
  import_node_fs7.default.writeFileSync(file, text5);
7598
7622
  }
7623
+ const interfaceCopies = [];
7599
7624
  if (framework) {
7600
7625
  import_node_fs7.default.mkdirSync(import_node_path7.default.join(frameworks, `${surface.module}.framework`, "Modules"), {
7601
7626
  recursive: true
7602
7627
  });
7603
- import_node_fs7.default.copyFileSync(
7604
- surface.modulemap,
7605
- import_node_path7.default.join(frameworks, `${surface.module}.framework`, "Modules", "module.modulemap")
7628
+ const modulemap = import_node_fs7.default.readFileSync(surface.modulemap, "utf8");
7629
+ import_node_fs7.default.writeFileSync(
7630
+ import_node_path7.default.join(frameworks, `${surface.module}.framework`, "Modules", "module.modulemap"),
7631
+ surface.interface ? modulemap.replace(
7632
+ new RegExp(`\\n\\s*module\\s+${surface.module}\\.Swift\\s*\\{[^}]*\\}`),
7633
+ ""
7634
+ ) : modulemap
7606
7635
  );
7607
7636
  if (surface.interface) {
7608
7637
  const from = import_node_path7.default.dirname(surface.interface);
@@ -7614,14 +7643,16 @@ function objcView(surface, toolchainBin, stdlib, cacheDir5, work, original, vend
7614
7643
  );
7615
7644
  import_node_fs7.default.mkdirSync(to, { recursive: true });
7616
7645
  for (const name3 of import_node_fs7.default.readdirSync(from))
7617
- if (name3.endsWith(".swiftinterface"))
7646
+ if (name3.endsWith(".swiftinterface")) {
7647
+ interfaceCopies.push(import_node_path7.default.join(to, name3));
7618
7648
  import_node_fs7.default.writeFileSync(
7619
7649
  import_node_path7.default.join(to, name3),
7620
- import_node_fs7.default.readFileSync(import_node_path7.default.join(from, name3), "utf8").replace(/\bCoreFoundation\.(?=CG)/g, "CoreGraphics.").replace(/\bCoreFoundation\.(?=\w)/g, "Foundation.").replace(
7650
+ import_node_fs7.default.readFileSync(import_node_path7.default.join(from, name3), "utf8").replace(/\bCoreFoundation\.(?=CG)/g, "CoreGraphics.").replace(/\bCoreFoundation\.(?=\w)/g, "Foundation.").replace(/\bDarwin\.OSStatus\b/g, "Swift.Int32").replace(
7621
7651
  /\bFoundation\.Data\.(?=Base64(?:En|De)codingOptions\b)/g,
7622
7652
  "Foundation.NSData."
7623
7653
  )
7624
7654
  );
7655
+ }
7625
7656
  }
7626
7657
  } else {
7627
7658
  import_node_fs7.default.copyFileSync(surface.modulemap, import_node_path7.default.join(headersDir, "module.modulemap"));
@@ -7779,6 +7810,7 @@ function objcView(surface, toolchainBin, stdlib, cacheDir5, work, original, vend
7779
7810
  return name3 ? { name: name3, before: text5.slice(0, column - 1), after: rest.slice(name3.length) } : null;
7780
7811
  };
7781
7812
  const typeKind = (name3, after) => /^[A-Z][A-Z0-9_]+$/.test(name3) && !/^\s*\*/.test(after) ? "macro" : /^\s*\*/.test(after) ? "class" : "struct";
7813
+ const selectors = /* @__PURE__ */ new Set();
7782
7814
  for (let round = 0; ; round++) {
7783
7815
  import_node_fs7.default.rmSync(out, { recursive: true, force: true });
7784
7816
  import_node_fs7.default.mkdirSync(out, { recursive: true });
@@ -7816,6 +7848,21 @@ function objcView(surface, toolchainBin, stdlib, cacheDir5, work, original, vend
7816
7848
  `original Objective-C declarations do not import as Swift: ${run5.stderr.trim() || run5.stdout.trim()}`
7817
7849
  );
7818
7850
  let progress = false;
7851
+ for (const [, shadowed, same] of run5.stderr.matchAll(
7852
+ /is not a member type of class '(\w+)\.(\w+)'/g
7853
+ ))
7854
+ if (shadowed === same && !selectors.has(shadowed)) {
7855
+ selectors.add(shadowed);
7856
+ progress = true;
7857
+ for (const file of interfaceCopies)
7858
+ import_node_fs7.default.writeFileSync(
7859
+ file,
7860
+ import_node_fs7.default.readFileSync(file, "utf8").replace(
7861
+ new RegExp(`\\b${shadowed}\\.(?=[A-Za-z_])`, "g"),
7862
+ `${shadowed}::`
7863
+ )
7864
+ );
7865
+ }
7819
7866
  const learn = (name3, kind) => {
7820
7867
  if (missing.has(name3)) return;
7821
7868
  missing.set(name3, kind);
@@ -7954,6 +8001,30 @@ function objcView(surface, toolchainBin, stdlib, cacheDir5, work, original, vend
7954
8001
  inherit(pairs[Number(match[1])].superclass[0], "s:s8SendableP");
7955
8002
  }
7956
8003
  }
8004
+ const refined = [...originals.values()].flatMap(
8005
+ (text5) => [
8006
+ ...text5.matchAll(
8007
+ /\b(?:FOUNDATION_EXTERN|FOUNDATION_EXPORT|extern)\s+([\w\s*]+?)\s+const\s+(\w+)\s+NS_REFINED_FOR_SWIFT\s*;/g
8008
+ )
8009
+ ].flatMap(([, ctype, name3]) => {
8010
+ const type = REFINED_CONSTANT_TYPES.get(ctype.replace(/\s+/g, ""));
8011
+ if (!type) return [];
8012
+ return [
8013
+ {
8014
+ kind: { identifier: "swift.var" },
8015
+ identifier: { precise: `c:@${name3}` },
8016
+ pathComponents: [`__${name3}`],
8017
+ declarationFragments: [
8018
+ { kind: "keyword", spelling: "let" },
8019
+ { kind: "text", spelling: ` __${name3}: ${type}` }
8020
+ ],
8021
+ accessLevel: "public"
8022
+ }
8023
+ ];
8024
+ })
8025
+ );
8026
+ if (refined.length > 0)
8027
+ graphs.push({ module: { name: surface.module }, symbols: refined, relationships: [] });
7957
8028
  const imports2 = /* @__PURE__ */ new Set(["Foundation", "UIKit"]);
7958
8029
  for (const text5 of originals.values())
7959
8030
  for (const name3 of clangImportNames(text5)) imports2.add(name3);
@@ -16713,7 +16784,7 @@ var darwinRecordsRegion = (quoted) => quoted.length ? ["-Wl,--start-lib", ...quo
16713
16784
  var REACTOR_FLAG = '"-Xclang-linker", "-mexec-model=reactor",\n';
16714
16785
  var MULTI_MANIFEST_VERSION = 66;
16715
16786
  var SWIFT_HEADER_PRODUCTS_TARGET = "PeachHeaderProducts";
16716
- var compilerSourceDigest = true ? "43445ac597f2b7673127e43186400d0f6863caf82dafb48c31ce3b516719ce13" : swiftCompilerSourceDigest(__sootsim_import_meta_dirname);
16787
+ var compilerSourceDigest = true ? "4c6d0c445f1c9d7fab6a4d2bbd910ec116536acc8d1aa621f70c74c10dd9faba" : swiftCompilerSourceDigest(__sootsim_import_meta_dirname);
16717
16788
  function swiftArtifactHash(input, release, moduleRoot) {
16718
16789
  const hash = (0, import_node_crypto13.createHash)("sha256");
16719
16790
  hash.update(`swift-compile
@@ -29667,7 +29738,7 @@ function sourceClosureDigest(srcDir, entrypoints) {
29667
29738
  return hash.digest("hex");
29668
29739
  }
29669
29740
  var standinSourceDigest = (srcDir = __sootsim_import_meta_dirname) => sourceClosureDigest(srcDir, STANDIN_DIGEST_ENTRYPOINTS);
29670
- var STANDIN_SOURCE_DIGEST = true ? "05087ee542759092b4dbe08e7a7c0a03416fa45a27f3c2e9b633d6d5ce98186a" : standinSourceDigest();
29741
+ var STANDIN_SOURCE_DIGEST = true ? "01e0eae770cafd2bbd23d98a22897ab31ada19f5a273a8f25da7c88aa3086c09" : standinSourceDigest();
29671
29742
 
29672
29743
  // src/swift-standins.ts
29673
29744
  init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
@@ -31164,7 +31235,13 @@ function mixedStandin(surface, binary, toolchain, work, behavior, frameworkDirs,
31164
31235
  }))
31165
31236
  };
31166
31237
  });
31167
- const imports2 = [.../* @__PURE__ */ new Set([...swiftImportNames(interfaceText), ...owners])].filter(
31238
+ const imports2 = [
31239
+ .../* @__PURE__ */ new Set([
31240
+ ...swiftImportNames(interfaceText),
31241
+ ...view.imports.filter((name3) => !STANDIN_IMPORTS.includes(name3)),
31242
+ ...owners
31243
+ ])
31244
+ ].filter(
31168
31245
  (module2) => module2 !== surface.module && (provided.has(module2) || siblings.has(module2))
31169
31246
  );
31170
31247
  return graphStandin(
package/dist-lib/vite.cjs CHANGED
@@ -1,4 +1,4 @@
1
- /*! peach v0.1.1966 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.1968 | (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.1966 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.1968 | (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.1966 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.1968 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
2
2
 
3
3
  // src/worklet-executable.ts
4
4
  import { parse } from "acorn";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "peachsim",
3
- "version": "0.1.1966",
3
+ "version": "0.1.1968",
4
4
  "description": "Vite and Metro plugins, testing drivers, and SDK exports for peach.",
5
5
  "author": "Tamagui LLC",
6
6
  "license": "SEE LICENSE IN LICENSE",