peachsim 0.1.1674 → 0.1.1692

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 (350) hide show
  1. package/cli/commands/control.ts +13 -1
  2. package/cli/commands/coverage-swift.ts +150 -27
  3. package/cli/commands/coverage.ts +219 -20
  4. package/cli/commands/detect.ts +10 -6
  5. package/cli/commands/inspect/actions.ts +1 -0
  6. package/cli/commands/inspect/core.ts +2 -0
  7. package/cli/commands/inspect/wait-ready.ts +7 -0
  8. package/cli/commands/screenshot.ts +12 -0
  9. package/cli/outbound-endpoints.ts +12 -0
  10. package/detox/index.ts +11 -1
  11. package/detox/jest-environment.cjs +14 -0
  12. package/dist-lib/agent-daemon-client.cjs +1 -1
  13. package/dist-lib/agent-events.cjs +1 -1
  14. package/dist-lib/attached-projects.cjs +1 -1
  15. package/dist-lib/auth/shared-session.cjs +1 -1
  16. package/dist-lib/backend-origin.cjs +1 -1
  17. package/dist-lib/beta.cjs +1 -1
  18. package/dist-lib/beta.mjs +1 -1
  19. package/dist-lib/bridge-constants.cjs +1 -1
  20. package/dist-lib/bridge-contract-input.cjs +1 -1
  21. package/dist-lib/bridge-contract-input.mjs +1 -1
  22. package/dist-lib/bridge-contract.cjs +1 -1
  23. package/dist-lib/bridge-contract.mjs +1 -1
  24. package/dist-lib/bundle-channel.cjs +4833 -2432
  25. package/dist-lib/capture-contract.cjs +1 -1
  26. package/dist-lib/capture-contract.mjs +1 -1
  27. package/dist-lib/cloud-contract.cjs +1 -1
  28. package/dist-lib/cloud-contract.mjs +1 -1
  29. package/dist-lib/cloud-test-args.cjs +1 -1
  30. package/dist-lib/cloud-test-args.mjs +1 -1
  31. package/dist-lib/cloud.cjs +1 -1
  32. package/dist-lib/cloud.mjs +1 -1
  33. package/dist-lib/config.cjs +1 -1
  34. package/dist-lib/config.mjs +1 -1
  35. package/dist-lib/detox/index.cjs +6 -4
  36. package/dist-lib/detox/jest-environment.cjs +14 -0
  37. package/dist-lib/dev-bundle-resolution.cjs +1 -1
  38. package/dist-lib/expo-swift-bundle.cjs +3785 -1737
  39. package/dist-lib/expo-swift-metadata.cjs +1 -1
  40. package/dist-lib/expo-swift-metadata.mjs +1 -1
  41. package/dist-lib/home-paths.cjs +1 -1
  42. package/dist-lib/host/bridge-host.cjs +4253 -2205
  43. package/dist-lib/host/fetch-proxy-handler.cjs +20 -7
  44. package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
  45. package/dist-lib/host/fetch-proxy-overrides.mjs +1 -1
  46. package/dist-lib/host/replacement-module-handler.cjs +1 -1
  47. package/dist-lib/host/websocket-proxy.cjs +1 -1
  48. package/dist-lib/index.cjs +2065 -796
  49. package/dist-lib/jump-to-source-babel.cjs +1 -1
  50. package/dist-lib/jump-to-source-native.cjs +1 -1
  51. package/dist-lib/kotlin-host.cjs +1 -1
  52. package/dist-lib/menu.cjs +1 -1
  53. package/dist-lib/menu.mjs +1 -1
  54. package/dist-lib/metro-fingerprint-registry.cjs +1 -1
  55. package/dist-lib/metro-fingerprint-registry.mjs +1 -1
  56. package/dist-lib/metro-production-bundle.cjs +1 -1
  57. package/dist-lib/metro-production-bundle.mjs +1 -1
  58. package/dist-lib/metro.cjs +6325 -4287
  59. package/dist-lib/native-app-identity-project.cjs +192 -55
  60. package/dist-lib/native-app-identity-project.mjs +235 -86
  61. package/dist-lib/native-app-identity.cjs +1 -1
  62. package/dist-lib/native-app-identity.mjs +1 -1
  63. package/dist-lib/native-firebase-metadata.cjs +1 -1
  64. package/dist-lib/native-firebase-metadata.mjs +1 -1
  65. package/dist-lib/plist.cjs +1 -1
  66. package/dist-lib/plist.mjs +1 -1
  67. package/dist-lib/profiles.cjs +1 -1
  68. package/dist-lib/public-brand.cjs +1 -1
  69. package/dist-lib/public-origins-lib-esm.json +27 -23
  70. package/dist-lib/public-origins-lib-static.json +1 -1
  71. package/dist-lib/public-origins-lib.json +156 -87
  72. package/dist-lib/react-native-host-modules.cjs +1 -1
  73. package/dist-lib/react-native-host-modules.mjs +1 -1
  74. package/dist-lib/reap-browser.cjs +2 -2
  75. package/dist-lib/scripts/dev-server-scanner.cjs +1 -1
  76. package/dist-lib/sdk.cjs +3 -2
  77. package/dist-lib/sdk.mjs +3 -2
  78. package/dist-lib/skills.cjs +5036 -2833
  79. package/dist-lib/swift-compile.cjs +2937 -437
  80. package/dist-lib/swift-compile.mjs +2932 -435
  81. package/dist-lib/swift-package.cjs +137 -49
  82. package/dist-lib/swift-package.mjs +132 -49
  83. package/dist-lib/swift-submit.cjs +1 -1
  84. package/dist-lib/swift-submit.mjs +1 -1
  85. package/dist-lib/swift-toolchain.cjs +26 -11
  86. package/dist-lib/swift.cjs +1 -1
  87. package/dist-lib/vite-swift.cjs +6005 -1725
  88. package/dist-lib/vite.cjs +1911 -776
  89. package/dist-lib/worklet-executable.cjs +7 -4
  90. package/dist-lib/worklet-executable.mjs +7 -4
  91. package/dist-types/packages/peach-engine/src/engine/canvaskit-api.d.ts +1 -1
  92. package/dist-types/packages/peach-engine/src/engine/clipboardContract.d.ts +24 -2
  93. package/dist-types/packages/peach-engine/src/preview/upload-protocol.d.ts +11 -3
  94. package/dist-types/packages/peach-engine/src/webview-automation-host.d.ts +6 -0
  95. package/dist-types/packages/peach-globals/src/clipboardBridgeContract.d.ts +8 -0
  96. package/dist-types/packages/peach-globals/src/index.d.ts +1 -1
  97. package/dist-types/packages/peach-globals/src/nodeContract.d.ts +3 -2
  98. package/dist-types/packages/peach-kit/src/capabilities.d.ts +1 -0
  99. package/package.json +1 -1
  100. package/runtime-companion.json +1 -1
  101. package/sdk/ios/System/Library/Frameworks/CoreFoundation.framework/Headers/CoreFoundation.h +60 -2
  102. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLAvailability.h +22 -0
  103. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLBackgroundActivitySession.h +145 -0
  104. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLBeaconIdentityCondition.h +113 -0
  105. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLBeaconIdentityConstraint.h +34 -0
  106. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLBeaconRegion.h +225 -0
  107. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLBody.h +26 -0
  108. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLCircularGeographicCondition.h +59 -0
  109. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLCircularRegion.h +64 -0
  110. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLCondition.h +48 -0
  111. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLError.h +52 -0
  112. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLErrorDomain.h +24 -0
  113. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLGeocoder.h +55 -0
  114. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLHeading.h +117 -0
  115. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLLocation.h +9 -0
  116. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLLocationManager+CLVisitExtensions.h +45 -0
  117. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLLocationManager.h +877 -0
  118. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLLocationManagerDelegate.h +225 -0
  119. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLLocationPushServiceError.h +33 -0
  120. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLLocationPushServiceExtension.h +28 -0
  121. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLLocationUpdater.h +250 -0
  122. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLMonitor.h +140 -0
  123. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLMonitorConfiguration.h +77 -0
  124. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLMonitoringEvent.h +184 -0
  125. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLMonitoringRecord.h +57 -0
  126. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLPlacemark.h +98 -0
  127. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLRegion.h +123 -0
  128. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLServiceSession.h +211 -0
  129. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLVisit.h +66 -0
  130. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CoreLocation.h +46 -0
  131. package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Modules/module.modulemap +7 -0
  132. package/sdk/ios/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h +117 -2
  133. package/sdk/ios/System/Library/Frameworks/IOSurface.framework/Headers/IOSurfaceBase.h +52 -0
  134. package/sdk/ios/System/Library/Frameworks/IOSurface.framework/Headers/IOSurfaceObjC.h +240 -0
  135. package/sdk/ios/System/Library/Frameworks/IOSurface.framework/Headers/IOSurfaceRef.h +474 -0
  136. package/sdk/ios/System/Library/Frameworks/IOSurface.framework/Headers/IOSurfaceTypes.h +66 -0
  137. package/sdk/ios/System/Library/Frameworks/IOSurface.framework/Modules/module.modulemap +10 -0
  138. package/sdk/ios/System/Library/Frameworks/MessageUI.framework/Headers/MFComposeAssistantViewController.h +29 -0
  139. package/sdk/ios/System/Library/Frameworks/MessageUI.framework/Headers/MFMailComposeControllerDeferredAction.h +14 -0
  140. package/sdk/ios/System/Library/Frameworks/MessageUI.framework/Headers/MFMailComposeViewController.h +162 -0
  141. package/sdk/ios/System/Library/Frameworks/MessageUI.framework/Headers/MFMailDraft.h +24 -0
  142. package/sdk/ios/System/Library/Frameworks/MessageUI.framework/Headers/MFMessageComposeViewController+UPI.h +31 -0
  143. package/sdk/ios/System/Library/Frameworks/MessageUI.framework/Headers/MFMessageComposeViewController.h +169 -0
  144. package/sdk/ios/System/Library/Frameworks/MessageUI.framework/Headers/MessageUI.h +13 -0
  145. package/sdk/ios/System/Library/Frameworks/MessageUI.framework/Modules/module.modulemap +11 -0
  146. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4AccelerationStructure.h +9 -0
  147. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4Archive.h +16 -0
  148. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4ArgumentTable.h +17 -0
  149. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4BinaryFunction.h +13 -0
  150. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4BinaryFunctionDescriptor.h +14 -0
  151. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4BufferRange.h +79 -0
  152. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4CommandAllocator.h +15 -0
  153. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4CommandBuffer.h +17 -0
  154. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4CommandEncoder.h +16 -0
  155. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4CommandQueue.h +19 -0
  156. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4CommitFeedback.h +15 -0
  157. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4Compiler.h +13 -0
  158. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4CompilerTask.h +13 -0
  159. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4ComputeCommandEncoder.h +19 -0
  160. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4ComputePipeline.h +13 -0
  161. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4Counters.h +19 -0
  162. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4FunctionDescriptor.h +13 -0
  163. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4LibraryDescriptor.h +13 -0
  164. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4LibraryFunctionDescriptor.h +13 -0
  165. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4LinkingDescriptor.h +13 -0
  166. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4MachineLearningCommandEncoder.h +17 -0
  167. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4MachineLearningPipeline.h +13 -0
  168. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4MeshRenderPipeline.h +13 -0
  169. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4PipelineDataSetSerializer.h +13 -0
  170. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4PipelineState.h +13 -0
  171. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4RenderCommandEncoder.h +17 -0
  172. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4RenderPass.h +17 -0
  173. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4RenderPipeline.h +13 -0
  174. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4SpecializedFunctionDescriptor.h +13 -0
  175. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4StitchedFunctionDescriptor.h +13 -0
  176. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTL4TileRenderPipeline.h +13 -0
  177. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLAccelerationStructure.h +1212 -0
  178. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLAccelerationStructureCommandEncoder.h +322 -0
  179. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLAccelerationStructureTypes.h +224 -0
  180. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLAllocation.h +22 -0
  181. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLArgument.h +279 -0
  182. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLArgumentEncoder.h +199 -0
  183. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLBinaryArchive.h +142 -0
  184. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLBlitCommandEncoder.h +266 -0
  185. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLBlitPass.h +82 -0
  186. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLBuffer.h +94 -0
  187. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLCaptureManager.h +113 -0
  188. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLCaptureScope.h +43 -0
  189. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLCommandBuffer.h +449 -0
  190. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLCommandEncoder.h +148 -0
  191. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLCommandQueue.h +102 -0
  192. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLComputeCommandEncoder.h +350 -0
  193. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLComputePass.h +90 -0
  194. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLComputePipeline.h +274 -0
  195. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLCounters.h +225 -0
  196. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLDataType.h +232 -0
  197. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLDefines.h +39 -0
  198. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLDepthStencil.h +93 -0
  199. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLDevice.h +1122 -0
  200. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLDeviceCertification.h +29 -0
  201. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLDrawable.h +36 -0
  202. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLDynamicLibrary.h +81 -0
  203. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLEvent.h +79 -0
  204. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLFence.h +22 -0
  205. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLFunctionConstantValues.h +30 -0
  206. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLFunctionDescriptor.h +95 -0
  207. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLFunctionHandle.h +29 -0
  208. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLFunctionLog.h +37 -0
  209. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLFunctionStitching.h +131 -0
  210. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLGPUAddress.h +19 -0
  211. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLHeap.h +284 -0
  212. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLIOCommandBuffer.h +10 -0
  213. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLIOCommandQueue.h +11 -0
  214. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLIOCompressor.h +10 -0
  215. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLIndirectCommandBuffer.h +157 -0
  216. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLIndirectCommandEncoder.h +110 -0
  217. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLIntersectionFunctionTable.h +186 -0
  218. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLLibrary.h +549 -0
  219. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLLinkedFunctions.h +57 -0
  220. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLLogState.h +65 -0
  221. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLParallelRenderCommandEncoder.h +77 -0
  222. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLPipeline.h +57 -0
  223. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLPixelFormat.h +342 -0
  224. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLRasterizationRate.h +323 -0
  225. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLRenderCommandEncoder.h +1068 -0
  226. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLRenderPass.h +411 -0
  227. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLRenderPipeline.h +788 -0
  228. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLResidencySet.h +141 -0
  229. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLResource.h +307 -0
  230. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLResourceStateCommandEncoder.h +125 -0
  231. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLResourceStatePass.h +85 -0
  232. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLResourceViewPool.h +22 -0
  233. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLSampler.h +252 -0
  234. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLStageInputOutputDescriptor.h +158 -0
  235. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLTensor.h +17 -0
  236. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLTexture.h +460 -0
  237. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLTextureViewPool.h +18 -0
  238. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLTypes.h +125 -0
  239. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLVertexDescriptor.h +153 -0
  240. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/MTLVisibleFunctionTable.h +45 -0
  241. package/sdk/ios/System/Library/Frameworks/Metal.framework/Headers/Metal.h +94 -0
  242. package/sdk/ios/System/Library/Frameworks/Metal.framework/Modules/module.modulemap +6 -0
  243. package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIKit.h +10 -0
  244. package/sdk/ios/System/Library/Frameworks/UniformTypeIdentifiers.framework/Headers/UTDefines.h +35 -0
  245. package/sdk/ios/System/Library/Frameworks/UniformTypeIdentifiers.framework/Headers/UTTagClass.h +33 -0
  246. package/sdk/ios/System/Library/Frameworks/UniformTypeIdentifiers.framework/Headers/UTType.h +504 -0
  247. package/sdk/ios/System/Library/Frameworks/_LocationEssentials.framework/Headers/CLEssentialsAvailability.h +14 -0
  248. package/sdk/ios/System/Library/Frameworks/_LocationEssentials.framework/Headers/CLLocationEssentials.h +444 -0
  249. package/sdk/ios/System/Library/Frameworks/_LocationEssentials.framework/Headers/LocationEssentials.h +14 -0
  250. package/sdk/ios/System/Library/Frameworks/_LocationEssentials.framework/Modules/module.modulemap +14 -0
  251. package/sdk/ios/usr/include/arm/param.h +151 -0
  252. package/sdk/ios/usr/include/complex.h +167 -0
  253. package/sdk/ios/usr/include/dispatch/dispatch.h +8 -0
  254. package/sdk/ios/usr/include/dlfcn.h +1 -2
  255. package/sdk/ios/usr/include/mach/mach_types.h +1 -0
  256. package/sdk/ios/usr/include/machine/param.h +42 -0
  257. package/sdk/ios/usr/include/math.h +835 -2
  258. package/sdk/ios/usr/include/net/if.h +1 -2
  259. package/sdk/ios/usr/include/peach/pthread.h +4 -4
  260. package/sdk/ios/usr/include/pthread/qos.h +304 -0
  261. package/sdk/ios/usr/include/sys/_types/_fd_clr.h +31 -0
  262. package/sdk/ios/usr/include/sys/_types/_fd_copy.h +31 -0
  263. package/sdk/ios/usr/include/sys/_types/_fd_def.h +121 -0
  264. package/sdk/ios/usr/include/sys/_types/_fd_isset.h +31 -0
  265. package/sdk/ios/usr/include/sys/_types/_fd_set.h +31 -0
  266. package/sdk/ios/usr/include/sys/_types/_fd_setsize.h +31 -0
  267. package/sdk/ios/usr/include/sys/_types/_fd_zero.h +31 -0
  268. package/sdk/ios/usr/include/sys/cdefs.h +3 -1
  269. package/sdk/ios/usr/include/sys/param.h +235 -0
  270. package/sdk/ios/usr/include/sys/proc.h +1 -0
  271. package/sdk/ios/usr/include/sys/qos.h +151 -12
  272. package/sdk/ios/wasm/include/__typedef_sigset_t.h +7 -0
  273. package/sdk/ios/wasm/include/fcntl.h +11 -0
  274. package/sdk/ios/wasm/include/mach/machine/boolean.h +2 -0
  275. package/sdk/ios/wasm/include/mach/machine/exception.h +5 -0
  276. package/sdk/ios/wasm/include/mach/machine/kern_return.h +2 -0
  277. package/sdk/ios/wasm/include/mach/machine/processor_info.h +2 -0
  278. package/sdk/ios/wasm/include/mach/machine/rpc.h +2 -0
  279. package/sdk/ios/wasm/include/mach/machine/thread_state.h +3 -0
  280. package/sdk/ios/wasm/include/mach/machine/thread_status.h +3 -0
  281. package/sdk/ios/wasm/include/mach/machine/vm_param.h +3 -0
  282. package/sdk/ios/wasm/include/mach/machine/vm_types.h +18 -0
  283. package/sdk/ios/wasm/include/machine/_types.h +153 -0
  284. package/sdk/ios/wasm/include/machine/endian.h +2 -0
  285. package/sdk/ios/wasm/include/machine/limits.h +2 -0
  286. package/sdk/ios/wasm/include/machine/types.h +30 -0
  287. package/sdk/ios/wasm/include/poll.h +8 -0
  288. package/sdk/ios/wasm/include/pthread.h +50 -0
  289. package/sdk/ios/wasm/include/signal.h +72 -0
  290. package/sdk/ios/wasm/include/stdlib.h +3 -0
  291. package/sdk/ios/wasm/include/string.h +10 -0
  292. package/sdk/ios/wasm/include/sys/_pthread/_pthread_attr_t.h +7 -0
  293. package/sdk/ios/wasm/include/sys/_pthread/_pthread_t.h +7 -0
  294. package/sdk/ios/wasm/include/sys/mman.h +122 -0
  295. package/sdk/ios/wasm/include/sys/select.h +37 -0
  296. package/sdk/ios/wasm/include/sys/signal.h +259 -0
  297. package/sdk/ios/wasm/include/sys/socket.h +8 -0
  298. package/sdk/ios/wasm/include/sys/types.h +14 -0
  299. package/sdk/ios/wasm/include/sys/ucontext.h +1 -0
  300. package/sdk/ios/wasm/include/sys/uio.h +11 -0
  301. package/sdk/ios/wasm/include/sys/wait.h +89 -0
  302. package/sdk/ios/wasm/include/time.h +8 -0
  303. package/sdk/ios/wasm/include/unistd.h +17 -0
  304. package/src/bridge-contract.ts +2 -0
  305. package/src/chromium-admission.ts +10 -5
  306. package/src/device-catalog.ts +4 -4
  307. package/src/generated/swift-c-predefines.json +1988 -0
  308. package/src/host/fetch-proxy-handler.ts +20 -0
  309. package/src/metro-plugin.ts +5 -2
  310. package/src/nitro-adapter.lock.json +6 -6
  311. package/src/nitro-bundle.ts +1 -0
  312. package/src/nitro-compile.ts +67 -2
  313. package/src/nitroContract.ts +18 -2
  314. package/src/numbered-lock.ts +72 -0
  315. package/src/react-native-coverage/capability-reference-resolution.ts +62 -5
  316. package/src/react-native-coverage/capability-source-references.ts +50 -13
  317. package/src/react-native-coverage/native-source-credit.ts +126 -0
  318. package/src/react-native-coverage/native-source-ranges-file.ts +38 -0
  319. package/src/react-native-coverage/native-surface.ts +49 -0
  320. package/src/react-native-coverage/verified-reach.ts +22 -2
  321. package/src/runtime-assets.ts +17 -0
  322. package/src/swift-compile.ts +530 -97
  323. package/src/swift-coverage/indexing.ts +17 -1
  324. package/src/swift-coverage/package.ts +3 -1
  325. package/src/swift-coverage/sdk.ts +71 -0
  326. package/src/swift-coverage/source.ts +74 -2
  327. package/src/swift-coverage/types.ts +6 -0
  328. package/src/swift-coverage/xcode-assets.ts +62 -2
  329. package/src/swift-coverage/xcode-packages.ts +11 -6
  330. package/src/swift-distribution.lock.json +12 -12
  331. package/src/swift-host.ts +457 -62
  332. package/src/swift-objc-compile.ts +26 -26
  333. package/src/swift-objc-metadata.ts +2 -8
  334. package/src/swift-objc-platform.ts +53 -0
  335. package/src/swift-objc-standin.ts +66 -12
  336. package/src/swift-package-manifest.ts +196 -28
  337. package/src/swift-package.ts +186 -60
  338. package/src/swift-packages.ts +298 -88
  339. package/src/swift-source-file.ts +10 -15
  340. package/src/swift-source-pods.ts +288 -0
  341. package/src/swift-standins.ts +87 -13
  342. package/src/swift-submit.ts +5 -0
  343. package/src/swift-toolchain.ts +32 -10
  344. package/src/swiftContract.ts +160 -75
  345. package/src/target-matcher.ts +15 -2
  346. package/src/vite-plugin-one.ts +5 -4
  347. package/src/worker-system-chunks.ts +7 -1
  348. package/src/worklet-executable.ts +7 -3
  349. package/src/xcode-json-project.ts +14 -2
  350. package/src/xcode-project.ts +193 -69
@@ -1,4 +1,4 @@
1
- /*! peach v0.1.1674 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
1
+ /*! peach v0.1.1692 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
2
2
  let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -51,6 +51,9 @@ __export(swift_compile_exports, {
51
51
  swiftArtifactHash: () => swiftArtifactHash,
52
52
  swiftAvailableModules: () => swiftAvailableModules,
53
53
  swiftBuilderHopTimeoutMs: () => swiftBuilderHopTimeoutMs,
54
+ swiftCDefinedNames: () => swiftCDefinedNames,
55
+ swiftCMainEntry: () => swiftCMainEntry,
56
+ swiftCPredefines: () => swiftCPredefines,
54
57
  swiftCodeMask: () => swiftCodeMask,
55
58
  swiftDistributionAt: () => swiftDistributionAt,
56
59
  swiftIcuAsset: () => swiftIcuAsset,
@@ -70,11 +73,11 @@ __export(swift_compile_exports, {
70
73
  writeSwiftProject: () => writeSwiftProject
71
74
  });
72
75
  module.exports = __toCommonJS(swift_compile_exports);
73
- var import_node_child_process7 = require("node:child_process");
76
+ var import_node_child_process8 = require("node:child_process");
74
77
  var import_node_crypto7 = require("node:crypto");
75
78
  var import_node_fs8 = require("node:fs");
76
79
  var import_node_os4 = __toESM(require("node:os"), 1);
77
- var import_node_path10 = __toESM(require("node:path"), 1);
80
+ var import_node_path11 = __toESM(require("node:path"), 1);
78
81
 
79
82
  // ../../node_modules/yaml/browser/dist/index.js
80
83
  var dist_exports = {};
@@ -162,17 +165,17 @@ function visit(node, visitor) {
162
165
  visit.BREAK = BREAK;
163
166
  visit.SKIP = SKIP;
164
167
  visit.REMOVE = REMOVE;
165
- function visit_(key, node, visitor, path10) {
166
- const ctrl = callVisitor(key, node, visitor, path10);
168
+ function visit_(key, node, visitor, path11) {
169
+ const ctrl = callVisitor(key, node, visitor, path11);
167
170
  if (isNode(ctrl) || isPair(ctrl)) {
168
- replaceNode(key, path10, ctrl);
169
- return visit_(key, ctrl, visitor, path10);
171
+ replaceNode(key, path11, ctrl);
172
+ return visit_(key, ctrl, visitor, path11);
170
173
  }
171
174
  if (typeof ctrl !== "symbol") {
172
175
  if (isCollection(node)) {
173
- path10 = Object.freeze(path10.concat(node));
176
+ path11 = Object.freeze(path11.concat(node));
174
177
  for (let i = 0; i < node.items.length; ++i) {
175
- const ci = visit_(i, node.items[i], visitor, path10);
178
+ const ci = visit_(i, node.items[i], visitor, path11);
176
179
  if (typeof ci === "number")
177
180
  i = ci - 1;
178
181
  else if (ci === BREAK)
@@ -183,13 +186,13 @@ function visit_(key, node, visitor, path10) {
183
186
  }
184
187
  }
185
188
  } else if (isPair(node)) {
186
- path10 = Object.freeze(path10.concat(node));
187
- const ck = visit_("key", node.key, visitor, path10);
189
+ path11 = Object.freeze(path11.concat(node));
190
+ const ck = visit_("key", node.key, visitor, path11);
188
191
  if (ck === BREAK)
189
192
  return BREAK;
190
193
  else if (ck === REMOVE)
191
194
  node.key = null;
192
- const cv = visit_("value", node.value, visitor, path10);
195
+ const cv = visit_("value", node.value, visitor, path11);
193
196
  if (cv === BREAK)
194
197
  return BREAK;
195
198
  else if (cv === REMOVE)
@@ -210,17 +213,17 @@ async function visitAsync(node, visitor) {
210
213
  visitAsync.BREAK = BREAK;
211
214
  visitAsync.SKIP = SKIP;
212
215
  visitAsync.REMOVE = REMOVE;
213
- async function visitAsync_(key, node, visitor, path10) {
214
- const ctrl = await callVisitor(key, node, visitor, path10);
216
+ async function visitAsync_(key, node, visitor, path11) {
217
+ const ctrl = await callVisitor(key, node, visitor, path11);
215
218
  if (isNode(ctrl) || isPair(ctrl)) {
216
- replaceNode(key, path10, ctrl);
217
- return visitAsync_(key, ctrl, visitor, path10);
219
+ replaceNode(key, path11, ctrl);
220
+ return visitAsync_(key, ctrl, visitor, path11);
218
221
  }
219
222
  if (typeof ctrl !== "symbol") {
220
223
  if (isCollection(node)) {
221
- path10 = Object.freeze(path10.concat(node));
224
+ path11 = Object.freeze(path11.concat(node));
222
225
  for (let i = 0; i < node.items.length; ++i) {
223
- const ci = await visitAsync_(i, node.items[i], visitor, path10);
226
+ const ci = await visitAsync_(i, node.items[i], visitor, path11);
224
227
  if (typeof ci === "number")
225
228
  i = ci - 1;
226
229
  else if (ci === BREAK)
@@ -231,13 +234,13 @@ async function visitAsync_(key, node, visitor, path10) {
231
234
  }
232
235
  }
233
236
  } else if (isPair(node)) {
234
- path10 = Object.freeze(path10.concat(node));
235
- const ck = await visitAsync_("key", node.key, visitor, path10);
237
+ path11 = Object.freeze(path11.concat(node));
238
+ const ck = await visitAsync_("key", node.key, visitor, path11);
236
239
  if (ck === BREAK)
237
240
  return BREAK;
238
241
  else if (ck === REMOVE)
239
242
  node.key = null;
240
- const cv = await visitAsync_("value", node.value, visitor, path10);
243
+ const cv = await visitAsync_("value", node.value, visitor, path11);
241
244
  if (cv === BREAK)
242
245
  return BREAK;
243
246
  else if (cv === REMOVE)
@@ -264,23 +267,23 @@ function initVisitor(visitor) {
264
267
  }
265
268
  return visitor;
266
269
  }
267
- function callVisitor(key, node, visitor, path10) {
270
+ function callVisitor(key, node, visitor, path11) {
268
271
  if (typeof visitor === "function")
269
- return visitor(key, node, path10);
272
+ return visitor(key, node, path11);
270
273
  if (isMap(node))
271
- return visitor.Map?.(key, node, path10);
274
+ return visitor.Map?.(key, node, path11);
272
275
  if (isSeq(node))
273
- return visitor.Seq?.(key, node, path10);
276
+ return visitor.Seq?.(key, node, path11);
274
277
  if (isPair(node))
275
- return visitor.Pair?.(key, node, path10);
278
+ return visitor.Pair?.(key, node, path11);
276
279
  if (isScalar(node))
277
- return visitor.Scalar?.(key, node, path10);
280
+ return visitor.Scalar?.(key, node, path11);
278
281
  if (isAlias(node))
279
- return visitor.Alias?.(key, node, path10);
282
+ return visitor.Alias?.(key, node, path11);
280
283
  return void 0;
281
284
  }
282
- function replaceNode(key, path10, node) {
283
- const parent = path10[path10.length - 1];
285
+ function replaceNode(key, path11, node) {
286
+ const parent = path11[path11.length - 1];
284
287
  if (isCollection(parent)) {
285
288
  parent.items[key] = node;
286
289
  } else if (isPair(parent)) {
@@ -809,10 +812,10 @@ function createNode(value, tagName, ctx) {
809
812
  }
810
813
 
811
814
  // ../../node_modules/yaml/browser/dist/nodes/Collection.js
812
- function collectionFromPath(schema4, path10, value) {
815
+ function collectionFromPath(schema4, path11, value) {
813
816
  let v = value;
814
- for (let i = path10.length - 1; i >= 0; --i) {
815
- const k = path10[i];
817
+ for (let i = path11.length - 1; i >= 0; --i) {
818
+ const k = path11[i];
816
819
  if (typeof k === "number" && Number.isInteger(k) && k >= 0) {
817
820
  const a = [];
818
821
  a[k] = v;
@@ -831,7 +834,7 @@ function collectionFromPath(schema4, path10, value) {
831
834
  sourceObjects: /* @__PURE__ */ new Map()
832
835
  });
833
836
  }
834
- var isEmptyPath = (path10) => path10 == null || typeof path10 === "object" && !!path10[Symbol.iterator]().next().done;
837
+ var isEmptyPath = (path11) => path11 == null || typeof path11 === "object" && !!path11[Symbol.iterator]().next().done;
835
838
  var Collection = class extends NodeBase {
836
839
  constructor(type, schema4) {
837
840
  super(type);
@@ -861,11 +864,11 @@ var Collection = class extends NodeBase {
861
864
  * be a Pair instance or a `{ key, value }` object, which may not have a key
862
865
  * that already exists in the map.
863
866
  */
864
- addIn(path10, value) {
865
- if (isEmptyPath(path10))
867
+ addIn(path11, value) {
868
+ if (isEmptyPath(path11))
866
869
  this.add(value);
867
870
  else {
868
- const [key, ...rest] = path10;
871
+ const [key, ...rest] = path11;
869
872
  const node = this.get(key, true);
870
873
  if (isCollection(node))
871
874
  node.addIn(rest, value);
@@ -879,8 +882,8 @@ var Collection = class extends NodeBase {
879
882
  * Removes a value from the collection.
880
883
  * @returns `true` if the item was found and removed.
881
884
  */
882
- deleteIn(path10) {
883
- const [key, ...rest] = path10;
885
+ deleteIn(path11) {
886
+ const [key, ...rest] = path11;
884
887
  if (rest.length === 0)
885
888
  return this.delete(key);
886
889
  const node = this.get(key, true);
@@ -894,8 +897,8 @@ var Collection = class extends NodeBase {
894
897
  * scalar values from their surrounding node; to disable set `keepScalar` to
895
898
  * `true` (collections are always returned intact).
896
899
  */
897
- getIn(path10, keepScalar) {
898
- const [key, ...rest] = path10;
900
+ getIn(path11, keepScalar) {
901
+ const [key, ...rest] = path11;
899
902
  const node = this.get(key, true);
900
903
  if (rest.length === 0)
901
904
  return !keepScalar && isScalar(node) ? node.value : node;
@@ -913,8 +916,8 @@ var Collection = class extends NodeBase {
913
916
  /**
914
917
  * Checks if the collection includes a value with the key `key`.
915
918
  */
916
- hasIn(path10) {
917
- const [key, ...rest] = path10;
919
+ hasIn(path11) {
920
+ const [key, ...rest] = path11;
918
921
  if (rest.length === 0)
919
922
  return this.has(key);
920
923
  const node = this.get(key, true);
@@ -924,8 +927,8 @@ var Collection = class extends NodeBase {
924
927
  * Sets a value in this collection. For `!!set`, `value` needs to be a
925
928
  * boolean to add/remove the item from the set.
926
929
  */
927
- setIn(path10, value) {
928
- const [key, ...rest] = path10;
930
+ setIn(path11, value) {
931
+ const [key, ...rest] = path11;
929
932
  if (rest.length === 0) {
930
933
  this.set(key, value);
931
934
  } else {
@@ -3064,9 +3067,9 @@ var Document = class _Document {
3064
3067
  this.contents.add(value);
3065
3068
  }
3066
3069
  /** Adds a value to the document. */
3067
- addIn(path10, value) {
3070
+ addIn(path11, value) {
3068
3071
  if (assertCollection(this.contents))
3069
- this.contents.addIn(path10, value);
3072
+ this.contents.addIn(path11, value);
3070
3073
  }
3071
3074
  /**
3072
3075
  * Create a new `Alias` node, ensuring that the target `node` has the required anchor.
@@ -3141,14 +3144,14 @@ var Document = class _Document {
3141
3144
  * Removes a value from the document.
3142
3145
  * @returns `true` if the item was found and removed.
3143
3146
  */
3144
- deleteIn(path10) {
3145
- if (isEmptyPath(path10)) {
3147
+ deleteIn(path11) {
3148
+ if (isEmptyPath(path11)) {
3146
3149
  if (this.contents == null)
3147
3150
  return false;
3148
3151
  this.contents = null;
3149
3152
  return true;
3150
3153
  }
3151
- return assertCollection(this.contents) ? this.contents.deleteIn(path10) : false;
3154
+ return assertCollection(this.contents) ? this.contents.deleteIn(path11) : false;
3152
3155
  }
3153
3156
  /**
3154
3157
  * Returns item at `key`, or `undefined` if not found. By default unwraps
@@ -3163,10 +3166,10 @@ var Document = class _Document {
3163
3166
  * scalar values from their surrounding node; to disable set `keepScalar` to
3164
3167
  * `true` (collections are always returned intact).
3165
3168
  */
3166
- getIn(path10, keepScalar) {
3167
- if (isEmptyPath(path10))
3169
+ getIn(path11, keepScalar) {
3170
+ if (isEmptyPath(path11))
3168
3171
  return !keepScalar && isScalar(this.contents) ? this.contents.value : this.contents;
3169
- return isCollection(this.contents) ? this.contents.getIn(path10, keepScalar) : void 0;
3172
+ return isCollection(this.contents) ? this.contents.getIn(path11, keepScalar) : void 0;
3170
3173
  }
3171
3174
  /**
3172
3175
  * Checks if the document includes a value with the key `key`.
@@ -3177,10 +3180,10 @@ var Document = class _Document {
3177
3180
  /**
3178
3181
  * Checks if the document includes a value at `path`.
3179
3182
  */
3180
- hasIn(path10) {
3181
- if (isEmptyPath(path10))
3183
+ hasIn(path11) {
3184
+ if (isEmptyPath(path11))
3182
3185
  return this.contents !== void 0;
3183
- return isCollection(this.contents) ? this.contents.hasIn(path10) : false;
3186
+ return isCollection(this.contents) ? this.contents.hasIn(path11) : false;
3184
3187
  }
3185
3188
  /**
3186
3189
  * Sets a value in this document. For `!!set`, `value` needs to be a
@@ -3197,13 +3200,13 @@ var Document = class _Document {
3197
3200
  * Sets a value in this document. For `!!set`, `value` needs to be a
3198
3201
  * boolean to add/remove the item from the set.
3199
3202
  */
3200
- setIn(path10, value) {
3201
- if (isEmptyPath(path10)) {
3203
+ setIn(path11, value) {
3204
+ if (isEmptyPath(path11)) {
3202
3205
  this.contents = value;
3203
3206
  } else if (this.contents == null) {
3204
- this.contents = collectionFromPath(this.schema, Array.from(path10), value);
3207
+ this.contents = collectionFromPath(this.schema, Array.from(path11), value);
3205
3208
  } else if (assertCollection(this.contents)) {
3206
- this.contents.setIn(path10, value);
3209
+ this.contents.setIn(path11, value);
3207
3210
  }
3208
3211
  }
3209
3212
  /**
@@ -4999,9 +5002,9 @@ function visit2(cst, visitor) {
4999
5002
  visit2.BREAK = BREAK2;
5000
5003
  visit2.SKIP = SKIP2;
5001
5004
  visit2.REMOVE = REMOVE2;
5002
- visit2.itemAtPath = (cst, path10) => {
5005
+ visit2.itemAtPath = (cst, path11) => {
5003
5006
  let item = cst;
5004
- for (const [field, index] of path10) {
5007
+ for (const [field, index] of path11) {
5005
5008
  const tok = item?.[field];
5006
5009
  if (tok && "items" in tok) {
5007
5010
  item = tok.items[index];
@@ -5010,23 +5013,23 @@ visit2.itemAtPath = (cst, path10) => {
5010
5013
  }
5011
5014
  return item;
5012
5015
  };
5013
- visit2.parentCollection = (cst, path10) => {
5014
- const parent = visit2.itemAtPath(cst, path10.slice(0, -1));
5015
- const field = path10[path10.length - 1][0];
5016
+ visit2.parentCollection = (cst, path11) => {
5017
+ const parent = visit2.itemAtPath(cst, path11.slice(0, -1));
5018
+ const field = path11[path11.length - 1][0];
5016
5019
  const coll = parent?.[field];
5017
5020
  if (coll && "items" in coll)
5018
5021
  return coll;
5019
5022
  throw new Error("Parent collection not found");
5020
5023
  };
5021
- function _visit(path10, item, visitor) {
5022
- let ctrl = visitor(item, path10);
5024
+ function _visit(path11, item, visitor) {
5025
+ let ctrl = visitor(item, path11);
5023
5026
  if (typeof ctrl === "symbol")
5024
5027
  return ctrl;
5025
5028
  for (const field of ["key", "value"]) {
5026
5029
  const token = item[field];
5027
5030
  if (token && "items" in token) {
5028
5031
  for (let i = 0; i < token.items.length; ++i) {
5029
- const ci = _visit(Object.freeze(path10.concat([[field, i]])), token.items[i], visitor);
5032
+ const ci = _visit(Object.freeze(path11.concat([[field, i]])), token.items[i], visitor);
5030
5033
  if (typeof ci === "number")
5031
5034
  i = ci - 1;
5032
5035
  else if (ci === BREAK2)
@@ -5037,10 +5040,10 @@ function _visit(path10, item, visitor) {
5037
5040
  }
5038
5041
  }
5039
5042
  if (typeof ctrl === "function" && field === "key")
5040
- ctrl = ctrl(item, path10);
5043
+ ctrl = ctrl(item, path11);
5041
5044
  }
5042
5045
  }
5043
- return typeof ctrl === "function" ? ctrl(item, path10) : ctrl;
5046
+ return typeof ctrl === "function" ? ctrl(item, path11) : ctrl;
5044
5047
  }
5045
5048
 
5046
5049
  // ../../node_modules/yaml/browser/dist/parse/cst.js
@@ -6704,6 +6707,1996 @@ function admittedMacBuilderSlot(env = process.env) {
6704
6707
  return windowAdmission() !== null;
6705
6708
  }
6706
6709
 
6710
+ // src/generated/swift-c-predefines.json
6711
+ var swift_c_predefines_default = {
6712
+ release: "swift-6.4.0-RELEASE-custom-8be2e4a7a393b003",
6713
+ languages: {
6714
+ c: {
6715
+ TARGET_IPHONE_SIMULATOR: "0",
6716
+ TARGET_OS_DRIVERKIT: "0",
6717
+ TARGET_OS_EMBEDDED: "1",
6718
+ TARGET_OS_FIRMWARE: "0",
6719
+ TARGET_OS_IOS: "1",
6720
+ TARGET_OS_IPHONE: "1",
6721
+ TARGET_OS_LINUX: "0",
6722
+ TARGET_OS_MAC: "1",
6723
+ TARGET_OS_MACCATALYST: "0",
6724
+ TARGET_OS_NANO: "0",
6725
+ TARGET_OS_OSX: "0",
6726
+ TARGET_OS_SIMULATOR: "0",
6727
+ TARGET_OS_TV: "0",
6728
+ TARGET_OS_UEFI: "0",
6729
+ TARGET_OS_UIKITFORMAC: "0",
6730
+ TARGET_OS_UNIX: "0",
6731
+ TARGET_OS_VISION: "0",
6732
+ TARGET_OS_WATCH: "0",
6733
+ TARGET_OS_WIN32: "0",
6734
+ TARGET_OS_WINDOWS: "0",
6735
+ _LP64: "1",
6736
+ __AARCH64EL__: "1",
6737
+ __AARCH64_CMODEL_SMALL__: "1",
6738
+ __AARCH64_SIMD__: "1",
6739
+ __APPLE_CC__: "6000",
6740
+ __APPLE__: "1",
6741
+ __ARM64_ARCH_8__: "1",
6742
+ __ARM_64BIT_STATE: "1",
6743
+ __ARM_ACLE: "202420",
6744
+ __ARM_ACLE_VERSION: "(year,quarter,patch) (100 * (year) + 10 * (quarter) + (patch))",
6745
+ __ARM_ALIGN_MAX_STACK_PWR: "4",
6746
+ __ARM_ARCH: "8",
6747
+ __ARM_ARCH_ISA_A64: "1",
6748
+ __ARM_ARCH_PROFILE: "'A'",
6749
+ __ARM_FEATURE_AES: "1",
6750
+ __ARM_FEATURE_CLZ: "1",
6751
+ __ARM_FEATURE_CRYPTO: "1",
6752
+ __ARM_FEATURE_DIRECTED_ROUNDING: "1",
6753
+ __ARM_FEATURE_DIV: "1",
6754
+ __ARM_FEATURE_FMA: "1",
6755
+ __ARM_FEATURE_IDIV: "1",
6756
+ __ARM_FEATURE_LDREX: "0xF",
6757
+ __ARM_FEATURE_NUMERIC_MAXMIN: "1",
6758
+ __ARM_FEATURE_SHA2: "1",
6759
+ __ARM_FEATURE_UNALIGNED: "1",
6760
+ __ARM_FP: "0xE",
6761
+ __ARM_FP16_ARGS: "1",
6762
+ __ARM_FP16_FORMAT_IEEE: "1",
6763
+ __ARM_NEON: "1",
6764
+ __ARM_NEON_FP: "0xE",
6765
+ __ARM_NEON_SVE_BRIDGE: "1",
6766
+ __ARM_NEON__: "1",
6767
+ __ARM_PCS_AAPCS64: "1",
6768
+ __ARM_SIZEOF_MINIMAL_ENUM: "4",
6769
+ __ARM_SIZEOF_WCHAR_T: "4",
6770
+ __ARM_STATE_ZA: "1",
6771
+ __ARM_STATE_ZT0: "1",
6772
+ __ATOMIC_ACQUIRE: "2",
6773
+ __ATOMIC_ACQ_REL: "4",
6774
+ __ATOMIC_CONSUME: "1",
6775
+ __ATOMIC_RELAXED: "0",
6776
+ __ATOMIC_RELEASE: "3",
6777
+ __ATOMIC_SEQ_CST: "5",
6778
+ __BIGGEST_ALIGNMENT__: "8",
6779
+ __BITINT_MAXWIDTH__: "128",
6780
+ __BLOCKS__: "1",
6781
+ __BOOL_WIDTH__: "1",
6782
+ __BYTE_ORDER__: "__ORDER_LITTLE_ENDIAN__",
6783
+ __CHAR16_TYPE__: "unsigned short",
6784
+ __CHAR32_TYPE__: "unsigned int",
6785
+ __CHAR_BIT__: "8",
6786
+ __CLANG_ATOMIC_BOOL_LOCK_FREE: "2",
6787
+ __CLANG_ATOMIC_CHAR16_T_LOCK_FREE: "2",
6788
+ __CLANG_ATOMIC_CHAR32_T_LOCK_FREE: "2",
6789
+ __CLANG_ATOMIC_CHAR_LOCK_FREE: "2",
6790
+ __CLANG_ATOMIC_INT_LOCK_FREE: "2",
6791
+ __CLANG_ATOMIC_LLONG_LOCK_FREE: "2",
6792
+ __CLANG_ATOMIC_LONG_LOCK_FREE: "2",
6793
+ __CLANG_ATOMIC_POINTER_LOCK_FREE: "2",
6794
+ __CLANG_ATOMIC_SHORT_LOCK_FREE: "2",
6795
+ __CLANG_ATOMIC_WCHAR_T_LOCK_FREE: "2",
6796
+ __CONSTANT_CFSTRINGS__: "1",
6797
+ __DBL_DECIMAL_DIG__: "17",
6798
+ __DBL_DENORM_MIN__: "4.9406564584124654e-324",
6799
+ __DBL_DIG__: "15",
6800
+ __DBL_EPSILON__: "2.2204460492503131e-16",
6801
+ __DBL_HAS_DENORM__: "1",
6802
+ __DBL_HAS_INFINITY__: "1",
6803
+ __DBL_HAS_QUIET_NAN__: "1",
6804
+ __DBL_MANT_DIG__: "53",
6805
+ __DBL_MAX_10_EXP__: "308",
6806
+ __DBL_MAX_EXP__: "1024",
6807
+ __DBL_MAX__: "1.7976931348623157e+308",
6808
+ __DBL_MIN_10_EXP__: "(-307)",
6809
+ __DBL_MIN_EXP__: "(-1021)",
6810
+ __DBL_MIN__: "2.2250738585072014e-308",
6811
+ __DBL_NORM_MAX__: "1.7976931348623157e+308",
6812
+ __DECIMAL_DIG__: "__LDBL_DECIMAL_DIG__",
6813
+ __DYNAMIC__: "1",
6814
+ __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__: "70000",
6815
+ __ENVIRONMENT_OS_VERSION_MIN_REQUIRED__: "70000",
6816
+ __FINITE_MATH_ONLY__: "0",
6817
+ __FLT16_DECIMAL_DIG__: "5",
6818
+ __FLT16_DENORM_MIN__: "5.9604644775390625e-8F16",
6819
+ __FLT16_DIG__: "3",
6820
+ __FLT16_EPSILON__: "9.765625e-4F16",
6821
+ __FLT16_HAS_DENORM__: "1",
6822
+ __FLT16_HAS_INFINITY__: "1",
6823
+ __FLT16_HAS_QUIET_NAN__: "1",
6824
+ __FLT16_MANT_DIG__: "11",
6825
+ __FLT16_MAX_10_EXP__: "4",
6826
+ __FLT16_MAX_EXP__: "16",
6827
+ __FLT16_MAX__: "6.5504e+4F16",
6828
+ __FLT16_MIN_10_EXP__: "(-4)",
6829
+ __FLT16_MIN_EXP__: "(-13)",
6830
+ __FLT16_MIN__: "6.103515625e-5F16",
6831
+ __FLT16_NORM_MAX__: "6.5504e+4F16",
6832
+ __FLT_DECIMAL_DIG__: "9",
6833
+ __FLT_DENORM_MIN__: "1.40129846e-45F",
6834
+ __FLT_DIG__: "6",
6835
+ __FLT_EPSILON__: "1.19209290e-7F",
6836
+ __FLT_HAS_DENORM__: "1",
6837
+ __FLT_HAS_INFINITY__: "1",
6838
+ __FLT_HAS_QUIET_NAN__: "1",
6839
+ __FLT_MANT_DIG__: "24",
6840
+ __FLT_MAX_10_EXP__: "38",
6841
+ __FLT_MAX_EXP__: "128",
6842
+ __FLT_MAX__: "3.40282347e+38F",
6843
+ __FLT_MIN_10_EXP__: "(-37)",
6844
+ __FLT_MIN_EXP__: "(-125)",
6845
+ __FLT_MIN__: "1.17549435e-38F",
6846
+ __FLT_NORM_MAX__: "3.40282347e+38F",
6847
+ __FLT_RADIX__: "2",
6848
+ __FPCLASS_NEGINF: "0x0004",
6849
+ __FPCLASS_NEGNORMAL: "0x0008",
6850
+ __FPCLASS_NEGSUBNORMAL: "0x0010",
6851
+ __FPCLASS_NEGZERO: "0x0020",
6852
+ __FPCLASS_POSINF: "0x0200",
6853
+ __FPCLASS_POSNORMAL: "0x0100",
6854
+ __FPCLASS_POSSUBNORMAL: "0x0080",
6855
+ __FPCLASS_POSZERO: "0x0040",
6856
+ __FPCLASS_QNAN: "0x0002",
6857
+ __FPCLASS_SNAN: "0x0001",
6858
+ __FP_FAST_FMA: "1",
6859
+ __FP_FAST_FMAF: "1",
6860
+ __FUNCTION_MULTI_VERSIONING_SUPPORT_LEVEL: "202430",
6861
+ __GCC_ASM_FLAG_OUTPUTS__: "1",
6862
+ __GCC_ATOMIC_BOOL_LOCK_FREE: "2",
6863
+ __GCC_ATOMIC_CHAR16_T_LOCK_FREE: "2",
6864
+ __GCC_ATOMIC_CHAR32_T_LOCK_FREE: "2",
6865
+ __GCC_ATOMIC_CHAR_LOCK_FREE: "2",
6866
+ __GCC_ATOMIC_INT_LOCK_FREE: "2",
6867
+ __GCC_ATOMIC_LLONG_LOCK_FREE: "2",
6868
+ __GCC_ATOMIC_LONG_LOCK_FREE: "2",
6869
+ __GCC_ATOMIC_POINTER_LOCK_FREE: "2",
6870
+ __GCC_ATOMIC_SHORT_LOCK_FREE: "2",
6871
+ __GCC_ATOMIC_TEST_AND_SET_TRUEVAL: "1",
6872
+ __GCC_ATOMIC_WCHAR_T_LOCK_FREE: "2",
6873
+ __GCC_CONSTRUCTIVE_SIZE: "64",
6874
+ __GCC_DESTRUCTIVE_SIZE: "256",
6875
+ __GCC_HAVE_DWARF2_CFI_ASM: "1",
6876
+ __GCC_HAVE_SYNC_COMPARE_AND_SWAP_1: "1",
6877
+ __GCC_HAVE_SYNC_COMPARE_AND_SWAP_16: "1",
6878
+ __GCC_HAVE_SYNC_COMPARE_AND_SWAP_2: "1",
6879
+ __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4: "1",
6880
+ __GCC_HAVE_SYNC_COMPARE_AND_SWAP_8: "1",
6881
+ __GNUC_MINOR__: "2",
6882
+ __GNUC_PATCHLEVEL__: "1",
6883
+ __GNUC_STDC_INLINE__: "1",
6884
+ __GNUC__: "4",
6885
+ __GXX_ABI_VERSION: "1002",
6886
+ __HAVE_FUNCTION_MULTI_VERSIONING: "1",
6887
+ __INT16_C: "(c) c",
6888
+ __INT16_C_SUFFIX__: null,
6889
+ __INT16_FMTd__: '"hd"',
6890
+ __INT16_FMTi__: '"hi"',
6891
+ __INT16_MAX__: "32767",
6892
+ __INT16_TYPE__: "short",
6893
+ __INT32_C: "(c) c",
6894
+ __INT32_C_SUFFIX__: null,
6895
+ __INT32_FMTd__: '"d"',
6896
+ __INT32_FMTi__: '"i"',
6897
+ __INT32_MAX__: "2147483647",
6898
+ __INT32_TYPE__: "int",
6899
+ __INT64_C: "(c) c##LL",
6900
+ __INT64_C_SUFFIX__: "LL",
6901
+ __INT64_FMTd__: '"lld"',
6902
+ __INT64_FMTi__: '"lli"',
6903
+ __INT64_MAX__: "9223372036854775807LL",
6904
+ __INT64_TYPE__: "long long int",
6905
+ __INT8_C: "(c) c",
6906
+ __INT8_C_SUFFIX__: null,
6907
+ __INT8_FMTd__: '"hhd"',
6908
+ __INT8_FMTi__: '"hhi"',
6909
+ __INT8_MAX__: "127",
6910
+ __INT8_TYPE__: "signed char",
6911
+ __INTMAX_C: "(c) c##L",
6912
+ __INTMAX_C_SUFFIX__: "L",
6913
+ __INTMAX_FMTd__: '"ld"',
6914
+ __INTMAX_FMTi__: '"li"',
6915
+ __INTMAX_MAX__: "9223372036854775807L",
6916
+ __INTMAX_TYPE__: "long int",
6917
+ __INTMAX_WIDTH__: "64",
6918
+ __INTPTR_FMTd__: '"ld"',
6919
+ __INTPTR_FMTi__: '"li"',
6920
+ __INTPTR_MAX__: "9223372036854775807L",
6921
+ __INTPTR_TYPE__: "long int",
6922
+ __INTPTR_WIDTH__: "64",
6923
+ __INT_FAST16_FMTd__: '"hd"',
6924
+ __INT_FAST16_FMTi__: '"hi"',
6925
+ __INT_FAST16_MAX__: "32767",
6926
+ __INT_FAST16_TYPE__: "short",
6927
+ __INT_FAST16_WIDTH__: "16",
6928
+ __INT_FAST32_FMTd__: '"d"',
6929
+ __INT_FAST32_FMTi__: '"i"',
6930
+ __INT_FAST32_MAX__: "2147483647",
6931
+ __INT_FAST32_TYPE__: "int",
6932
+ __INT_FAST32_WIDTH__: "32",
6933
+ __INT_FAST64_FMTd__: '"lld"',
6934
+ __INT_FAST64_FMTi__: '"lli"',
6935
+ __INT_FAST64_MAX__: "9223372036854775807LL",
6936
+ __INT_FAST64_TYPE__: "long long int",
6937
+ __INT_FAST64_WIDTH__: "64",
6938
+ __INT_FAST8_FMTd__: '"hhd"',
6939
+ __INT_FAST8_FMTi__: '"hhi"',
6940
+ __INT_FAST8_MAX__: "127",
6941
+ __INT_FAST8_TYPE__: "signed char",
6942
+ __INT_FAST8_WIDTH__: "8",
6943
+ __INT_LEAST16_FMTd__: '"hd"',
6944
+ __INT_LEAST16_FMTi__: '"hi"',
6945
+ __INT_LEAST16_MAX__: "32767",
6946
+ __INT_LEAST16_TYPE__: "short",
6947
+ __INT_LEAST16_WIDTH__: "16",
6948
+ __INT_LEAST32_FMTd__: '"d"',
6949
+ __INT_LEAST32_FMTi__: '"i"',
6950
+ __INT_LEAST32_MAX__: "2147483647",
6951
+ __INT_LEAST32_TYPE__: "int",
6952
+ __INT_LEAST32_WIDTH__: "32",
6953
+ __INT_LEAST64_FMTd__: '"lld"',
6954
+ __INT_LEAST64_FMTi__: '"lli"',
6955
+ __INT_LEAST64_MAX__: "9223372036854775807LL",
6956
+ __INT_LEAST64_TYPE__: "long long int",
6957
+ __INT_LEAST64_WIDTH__: "64",
6958
+ __INT_LEAST8_FMTd__: '"hhd"',
6959
+ __INT_LEAST8_FMTi__: '"hhi"',
6960
+ __INT_LEAST8_MAX__: "127",
6961
+ __INT_LEAST8_TYPE__: "signed char",
6962
+ __INT_LEAST8_WIDTH__: "8",
6963
+ __INT_MAX__: "2147483647",
6964
+ __INT_WIDTH__: "32",
6965
+ __LDBL_DECIMAL_DIG__: "17",
6966
+ __LDBL_DENORM_MIN__: "4.9406564584124654e-324L",
6967
+ __LDBL_DIG__: "15",
6968
+ __LDBL_EPSILON__: "2.2204460492503131e-16L",
6969
+ __LDBL_HAS_DENORM__: "1",
6970
+ __LDBL_HAS_INFINITY__: "1",
6971
+ __LDBL_HAS_QUIET_NAN__: "1",
6972
+ __LDBL_MANT_DIG__: "53",
6973
+ __LDBL_MAX_10_EXP__: "308",
6974
+ __LDBL_MAX_EXP__: "1024",
6975
+ __LDBL_MAX__: "1.7976931348623157e+308L",
6976
+ __LDBL_MIN_10_EXP__: "(-307)",
6977
+ __LDBL_MIN_EXP__: "(-1021)",
6978
+ __LDBL_MIN__: "2.2250738585072014e-308L",
6979
+ __LDBL_NORM_MAX__: "1.7976931348623157e+308L",
6980
+ __LITTLE_ENDIAN__: "1",
6981
+ __LLONG_WIDTH__: "64",
6982
+ __LONG_LONG_MAX__: "9223372036854775807LL",
6983
+ __LONG_MAX__: "9223372036854775807L",
6984
+ __LONG_WIDTH__: "64",
6985
+ __LP64__: "1",
6986
+ __MACH__: "1",
6987
+ __MEMORY_SCOPE_DEVICE: "1",
6988
+ __MEMORY_SCOPE_SINGLE: "4",
6989
+ __MEMORY_SCOPE_SYSTEM: "0",
6990
+ __MEMORY_SCOPE_WRKGRP: "2",
6991
+ __MEMORY_SCOPE_WVFRNT: "3",
6992
+ __NO_INLINE__: "1",
6993
+ __NO_MATH_ERRNO__: "1",
6994
+ __OBJC_BOOL_IS_BOOL: "1",
6995
+ __OPENCL_MEMORY_SCOPE_ALL_SVM_DEVICES: "3",
6996
+ __OPENCL_MEMORY_SCOPE_DEVICE: "2",
6997
+ __OPENCL_MEMORY_SCOPE_SUB_GROUP: "4",
6998
+ __OPENCL_MEMORY_SCOPE_WORK_GROUP: "1",
6999
+ __OPENCL_MEMORY_SCOPE_WORK_ITEM: "0",
7000
+ __ORDER_BIG_ENDIAN__: "4321",
7001
+ __ORDER_LITTLE_ENDIAN__: "1234",
7002
+ __ORDER_PDP_ENDIAN__: "3412",
7003
+ __PIC__: "2",
7004
+ __POINTER_WIDTH__: "64",
7005
+ __PRAGMA_REDEFINE_EXTNAME: "1",
7006
+ __PTRDIFF_FMTd__: '"ld"',
7007
+ __PTRDIFF_FMTi__: '"li"',
7008
+ __PTRDIFF_MAX__: "9223372036854775807L",
7009
+ __PTRDIFF_TYPE__: "long int",
7010
+ __PTRDIFF_WIDTH__: "64",
7011
+ __REGISTER_PREFIX__: null,
7012
+ __SCHAR_MAX__: "127",
7013
+ __SHRT_MAX__: "32767",
7014
+ __SHRT_WIDTH__: "16",
7015
+ __SIG_ATOMIC_MAX__: "2147483647",
7016
+ __SIG_ATOMIC_WIDTH__: "32",
7017
+ __SIZEOF_DOUBLE__: "8",
7018
+ __SIZEOF_FLOAT__: "4",
7019
+ __SIZEOF_INT128__: "16",
7020
+ __SIZEOF_INT__: "4",
7021
+ __SIZEOF_LONG_DOUBLE__: "8",
7022
+ __SIZEOF_LONG_LONG__: "8",
7023
+ __SIZEOF_LONG__: "8",
7024
+ __SIZEOF_POINTER__: "8",
7025
+ __SIZEOF_PTRDIFF_T__: "8",
7026
+ __SIZEOF_SHORT__: "2",
7027
+ __SIZEOF_SIZE_T__: "8",
7028
+ __SIZEOF_WCHAR_T__: "4",
7029
+ __SIZEOF_WINT_T__: "4",
7030
+ __SIZE_FMTX__: '"lX"',
7031
+ __SIZE_FMTo__: '"lo"',
7032
+ __SIZE_FMTu__: '"lu"',
7033
+ __SIZE_FMTx__: '"lx"',
7034
+ __SIZE_MAX__: "18446744073709551615UL",
7035
+ __SIZE_TYPE__: "long unsigned int",
7036
+ __SIZE_WIDTH__: "64",
7037
+ __SSP__: "1",
7038
+ __STDC_EMBED_EMPTY__: "2",
7039
+ __STDC_EMBED_FOUND__: "1",
7040
+ __STDC_EMBED_NOT_FOUND__: "0",
7041
+ __STDC_HOSTED__: "1",
7042
+ __STDC_NO_THREADS__: "1",
7043
+ __STDC_UTF_16__: "1",
7044
+ __STDC_UTF_32__: "1",
7045
+ __STDC_VERSION__: "201710L",
7046
+ __STDC__: "1",
7047
+ __UINT16_C: "(c) c",
7048
+ __UINT16_C_SUFFIX__: null,
7049
+ __UINT16_FMTX__: '"hX"',
7050
+ __UINT16_FMTo__: '"ho"',
7051
+ __UINT16_FMTu__: '"hu"',
7052
+ __UINT16_FMTx__: '"hx"',
7053
+ __UINT16_MAX__: "65535",
7054
+ __UINT16_TYPE__: "unsigned short",
7055
+ __UINT32_C: "(c) c##U",
7056
+ __UINT32_C_SUFFIX__: "U",
7057
+ __UINT32_FMTX__: '"X"',
7058
+ __UINT32_FMTo__: '"o"',
7059
+ __UINT32_FMTu__: '"u"',
7060
+ __UINT32_FMTx__: '"x"',
7061
+ __UINT32_MAX__: "4294967295U",
7062
+ __UINT32_TYPE__: "unsigned int",
7063
+ __UINT64_C: "(c) c##ULL",
7064
+ __UINT64_C_SUFFIX__: "ULL",
7065
+ __UINT64_FMTX__: '"llX"',
7066
+ __UINT64_FMTo__: '"llo"',
7067
+ __UINT64_FMTu__: '"llu"',
7068
+ __UINT64_FMTx__: '"llx"',
7069
+ __UINT64_MAX__: "18446744073709551615ULL",
7070
+ __UINT64_TYPE__: "long long unsigned int",
7071
+ __UINT8_C: "(c) c",
7072
+ __UINT8_C_SUFFIX__: null,
7073
+ __UINT8_FMTX__: '"hhX"',
7074
+ __UINT8_FMTo__: '"hho"',
7075
+ __UINT8_FMTu__: '"hhu"',
7076
+ __UINT8_FMTx__: '"hhx"',
7077
+ __UINT8_MAX__: "255",
7078
+ __UINT8_TYPE__: "unsigned char",
7079
+ __UINTMAX_C: "(c) c##UL",
7080
+ __UINTMAX_C_SUFFIX__: "UL",
7081
+ __UINTMAX_FMTX__: '"lX"',
7082
+ __UINTMAX_FMTo__: '"lo"',
7083
+ __UINTMAX_FMTu__: '"lu"',
7084
+ __UINTMAX_FMTx__: '"lx"',
7085
+ __UINTMAX_MAX__: "18446744073709551615UL",
7086
+ __UINTMAX_TYPE__: "long unsigned int",
7087
+ __UINTMAX_WIDTH__: "64",
7088
+ __UINTPTR_FMTX__: '"lX"',
7089
+ __UINTPTR_FMTo__: '"lo"',
7090
+ __UINTPTR_FMTu__: '"lu"',
7091
+ __UINTPTR_FMTx__: '"lx"',
7092
+ __UINTPTR_MAX__: "18446744073709551615UL",
7093
+ __UINTPTR_TYPE__: "long unsigned int",
7094
+ __UINTPTR_WIDTH__: "64",
7095
+ __UINT_FAST16_FMTX__: '"hX"',
7096
+ __UINT_FAST16_FMTo__: '"ho"',
7097
+ __UINT_FAST16_FMTu__: '"hu"',
7098
+ __UINT_FAST16_FMTx__: '"hx"',
7099
+ __UINT_FAST16_MAX__: "65535",
7100
+ __UINT_FAST16_TYPE__: "unsigned short",
7101
+ __UINT_FAST32_FMTX__: '"X"',
7102
+ __UINT_FAST32_FMTo__: '"o"',
7103
+ __UINT_FAST32_FMTu__: '"u"',
7104
+ __UINT_FAST32_FMTx__: '"x"',
7105
+ __UINT_FAST32_MAX__: "4294967295U",
7106
+ __UINT_FAST32_TYPE__: "unsigned int",
7107
+ __UINT_FAST64_FMTX__: '"llX"',
7108
+ __UINT_FAST64_FMTo__: '"llo"',
7109
+ __UINT_FAST64_FMTu__: '"llu"',
7110
+ __UINT_FAST64_FMTx__: '"llx"',
7111
+ __UINT_FAST64_MAX__: "18446744073709551615ULL",
7112
+ __UINT_FAST64_TYPE__: "long long unsigned int",
7113
+ __UINT_FAST8_FMTX__: '"hhX"',
7114
+ __UINT_FAST8_FMTo__: '"hho"',
7115
+ __UINT_FAST8_FMTu__: '"hhu"',
7116
+ __UINT_FAST8_FMTx__: '"hhx"',
7117
+ __UINT_FAST8_MAX__: "255",
7118
+ __UINT_FAST8_TYPE__: "unsigned char",
7119
+ __UINT_LEAST16_FMTX__: '"hX"',
7120
+ __UINT_LEAST16_FMTo__: '"ho"',
7121
+ __UINT_LEAST16_FMTu__: '"hu"',
7122
+ __UINT_LEAST16_FMTx__: '"hx"',
7123
+ __UINT_LEAST16_MAX__: "65535",
7124
+ __UINT_LEAST16_TYPE__: "unsigned short",
7125
+ __UINT_LEAST32_FMTX__: '"X"',
7126
+ __UINT_LEAST32_FMTo__: '"o"',
7127
+ __UINT_LEAST32_FMTu__: '"u"',
7128
+ __UINT_LEAST32_FMTx__: '"x"',
7129
+ __UINT_LEAST32_MAX__: "4294967295U",
7130
+ __UINT_LEAST32_TYPE__: "unsigned int",
7131
+ __UINT_LEAST64_FMTX__: '"llX"',
7132
+ __UINT_LEAST64_FMTo__: '"llo"',
7133
+ __UINT_LEAST64_FMTu__: '"llu"',
7134
+ __UINT_LEAST64_FMTx__: '"llx"',
7135
+ __UINT_LEAST64_MAX__: "18446744073709551615ULL",
7136
+ __UINT_LEAST64_TYPE__: "long long unsigned int",
7137
+ __UINT_LEAST8_FMTX__: '"hhX"',
7138
+ __UINT_LEAST8_FMTo__: '"hho"',
7139
+ __UINT_LEAST8_FMTu__: '"hhu"',
7140
+ __UINT_LEAST8_FMTx__: '"hhx"',
7141
+ __UINT_LEAST8_MAX__: "255",
7142
+ __UINT_LEAST8_TYPE__: "unsigned char",
7143
+ __USER_LABEL_PREFIX__: "_",
7144
+ __VERSION__: '"Clang 21.0.0"',
7145
+ __WCHAR_MAX__: "2147483647",
7146
+ __WCHAR_TYPE__: "int",
7147
+ __WCHAR_WIDTH__: "32",
7148
+ __WINT_MAX__: "2147483647",
7149
+ __WINT_TYPE__: "int",
7150
+ __WINT_WIDTH__: "32",
7151
+ __aarch64__: "1",
7152
+ __arm64: "1",
7153
+ __arm64__: "1",
7154
+ __block: "__attribute__((__blocks__(byref)))",
7155
+ __clang__: "1",
7156
+ __clang_literal_encoding__: '"UTF-8"',
7157
+ __clang_major__: "21",
7158
+ __clang_minor__: "0",
7159
+ __clang_patchlevel__: "0",
7160
+ __clang_version__: '"21.0.0 "',
7161
+ __clang_wide_literal_encoding__: '"UTF-32"',
7162
+ __llvm__: "1",
7163
+ __nonnull: "_Nonnull",
7164
+ __null_unspecified: "_Null_unspecified",
7165
+ __nullable: "_Nullable",
7166
+ __pic__: "2",
7167
+ __strong: null,
7168
+ __unsafe_unretained: null,
7169
+ __weak: "__attribute__((objc_gc(weak)))"
7170
+ },
7171
+ "c++": {
7172
+ TARGET_IPHONE_SIMULATOR: "0",
7173
+ TARGET_OS_DRIVERKIT: "0",
7174
+ TARGET_OS_EMBEDDED: "1",
7175
+ TARGET_OS_FIRMWARE: "0",
7176
+ TARGET_OS_IOS: "1",
7177
+ TARGET_OS_IPHONE: "1",
7178
+ TARGET_OS_LINUX: "0",
7179
+ TARGET_OS_MAC: "1",
7180
+ TARGET_OS_MACCATALYST: "0",
7181
+ TARGET_OS_NANO: "0",
7182
+ TARGET_OS_OSX: "0",
7183
+ TARGET_OS_SIMULATOR: "0",
7184
+ TARGET_OS_TV: "0",
7185
+ TARGET_OS_UEFI: "0",
7186
+ TARGET_OS_UIKITFORMAC: "0",
7187
+ TARGET_OS_UNIX: "0",
7188
+ TARGET_OS_VISION: "0",
7189
+ TARGET_OS_WATCH: "0",
7190
+ TARGET_OS_WIN32: "0",
7191
+ TARGET_OS_WINDOWS: "0",
7192
+ _LP64: "1",
7193
+ __AARCH64EL__: "1",
7194
+ __AARCH64_CMODEL_SMALL__: "1",
7195
+ __AARCH64_SIMD__: "1",
7196
+ __APPLE_CC__: "6000",
7197
+ __APPLE__: "1",
7198
+ __ARM64_ARCH_8__: "1",
7199
+ __ARM_64BIT_STATE: "1",
7200
+ __ARM_ACLE: "202420",
7201
+ __ARM_ACLE_VERSION: "(year,quarter,patch) (100 * (year) + 10 * (quarter) + (patch))",
7202
+ __ARM_ALIGN_MAX_STACK_PWR: "4",
7203
+ __ARM_ARCH: "8",
7204
+ __ARM_ARCH_ISA_A64: "1",
7205
+ __ARM_ARCH_PROFILE: "'A'",
7206
+ __ARM_FEATURE_AES: "1",
7207
+ __ARM_FEATURE_CLZ: "1",
7208
+ __ARM_FEATURE_CRYPTO: "1",
7209
+ __ARM_FEATURE_DIRECTED_ROUNDING: "1",
7210
+ __ARM_FEATURE_DIV: "1",
7211
+ __ARM_FEATURE_FMA: "1",
7212
+ __ARM_FEATURE_IDIV: "1",
7213
+ __ARM_FEATURE_LDREX: "0xF",
7214
+ __ARM_FEATURE_NUMERIC_MAXMIN: "1",
7215
+ __ARM_FEATURE_SHA2: "1",
7216
+ __ARM_FEATURE_UNALIGNED: "1",
7217
+ __ARM_FP: "0xE",
7218
+ __ARM_FP16_ARGS: "1",
7219
+ __ARM_FP16_FORMAT_IEEE: "1",
7220
+ __ARM_NEON: "1",
7221
+ __ARM_NEON_FP: "0xE",
7222
+ __ARM_NEON_SVE_BRIDGE: "1",
7223
+ __ARM_NEON__: "1",
7224
+ __ARM_PCS_AAPCS64: "1",
7225
+ __ARM_SIZEOF_MINIMAL_ENUM: "4",
7226
+ __ARM_SIZEOF_WCHAR_T: "4",
7227
+ __ARM_STATE_ZA: "1",
7228
+ __ARM_STATE_ZT0: "1",
7229
+ __ATOMIC_ACQUIRE: "2",
7230
+ __ATOMIC_ACQ_REL: "4",
7231
+ __ATOMIC_CONSUME: "1",
7232
+ __ATOMIC_RELAXED: "0",
7233
+ __ATOMIC_RELEASE: "3",
7234
+ __ATOMIC_SEQ_CST: "5",
7235
+ __BIGGEST_ALIGNMENT__: "8",
7236
+ __BITINT_MAXWIDTH__: "128",
7237
+ __BLOCKS__: "1",
7238
+ __BOOL_WIDTH__: "1",
7239
+ __BYTE_ORDER__: "__ORDER_LITTLE_ENDIAN__",
7240
+ __CHAR16_TYPE__: "unsigned short",
7241
+ __CHAR32_TYPE__: "unsigned int",
7242
+ __CHAR_BIT__: "8",
7243
+ __CLANG_ATOMIC_BOOL_LOCK_FREE: "2",
7244
+ __CLANG_ATOMIC_CHAR16_T_LOCK_FREE: "2",
7245
+ __CLANG_ATOMIC_CHAR32_T_LOCK_FREE: "2",
7246
+ __CLANG_ATOMIC_CHAR_LOCK_FREE: "2",
7247
+ __CLANG_ATOMIC_INT_LOCK_FREE: "2",
7248
+ __CLANG_ATOMIC_LLONG_LOCK_FREE: "2",
7249
+ __CLANG_ATOMIC_LONG_LOCK_FREE: "2",
7250
+ __CLANG_ATOMIC_POINTER_LOCK_FREE: "2",
7251
+ __CLANG_ATOMIC_SHORT_LOCK_FREE: "2",
7252
+ __CLANG_ATOMIC_WCHAR_T_LOCK_FREE: "2",
7253
+ __CONSTANT_CFSTRINGS__: "1",
7254
+ __DBL_DECIMAL_DIG__: "17",
7255
+ __DBL_DENORM_MIN__: "4.9406564584124654e-324",
7256
+ __DBL_DIG__: "15",
7257
+ __DBL_EPSILON__: "2.2204460492503131e-16",
7258
+ __DBL_HAS_DENORM__: "1",
7259
+ __DBL_HAS_INFINITY__: "1",
7260
+ __DBL_HAS_QUIET_NAN__: "1",
7261
+ __DBL_MANT_DIG__: "53",
7262
+ __DBL_MAX_10_EXP__: "308",
7263
+ __DBL_MAX_EXP__: "1024",
7264
+ __DBL_MAX__: "1.7976931348623157e+308",
7265
+ __DBL_MIN_10_EXP__: "(-307)",
7266
+ __DBL_MIN_EXP__: "(-1021)",
7267
+ __DBL_MIN__: "2.2250738585072014e-308",
7268
+ __DBL_NORM_MAX__: "1.7976931348623157e+308",
7269
+ __DECIMAL_DIG__: "__LDBL_DECIMAL_DIG__",
7270
+ __DEPRECATED: "1",
7271
+ __DYNAMIC__: "1",
7272
+ __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__: "70000",
7273
+ __ENVIRONMENT_OS_VERSION_MIN_REQUIRED__: "70000",
7274
+ __EXCEPTIONS: "1",
7275
+ __FINITE_MATH_ONLY__: "0",
7276
+ __FLT16_DECIMAL_DIG__: "5",
7277
+ __FLT16_DENORM_MIN__: "5.9604644775390625e-8F16",
7278
+ __FLT16_DIG__: "3",
7279
+ __FLT16_EPSILON__: "9.765625e-4F16",
7280
+ __FLT16_HAS_DENORM__: "1",
7281
+ __FLT16_HAS_INFINITY__: "1",
7282
+ __FLT16_HAS_QUIET_NAN__: "1",
7283
+ __FLT16_MANT_DIG__: "11",
7284
+ __FLT16_MAX_10_EXP__: "4",
7285
+ __FLT16_MAX_EXP__: "16",
7286
+ __FLT16_MAX__: "6.5504e+4F16",
7287
+ __FLT16_MIN_10_EXP__: "(-4)",
7288
+ __FLT16_MIN_EXP__: "(-13)",
7289
+ __FLT16_MIN__: "6.103515625e-5F16",
7290
+ __FLT16_NORM_MAX__: "6.5504e+4F16",
7291
+ __FLT_DECIMAL_DIG__: "9",
7292
+ __FLT_DENORM_MIN__: "1.40129846e-45F",
7293
+ __FLT_DIG__: "6",
7294
+ __FLT_EPSILON__: "1.19209290e-7F",
7295
+ __FLT_HAS_DENORM__: "1",
7296
+ __FLT_HAS_INFINITY__: "1",
7297
+ __FLT_HAS_QUIET_NAN__: "1",
7298
+ __FLT_MANT_DIG__: "24",
7299
+ __FLT_MAX_10_EXP__: "38",
7300
+ __FLT_MAX_EXP__: "128",
7301
+ __FLT_MAX__: "3.40282347e+38F",
7302
+ __FLT_MIN_10_EXP__: "(-37)",
7303
+ __FLT_MIN_EXP__: "(-125)",
7304
+ __FLT_MIN__: "1.17549435e-38F",
7305
+ __FLT_NORM_MAX__: "3.40282347e+38F",
7306
+ __FLT_RADIX__: "2",
7307
+ __FPCLASS_NEGINF: "0x0004",
7308
+ __FPCLASS_NEGNORMAL: "0x0008",
7309
+ __FPCLASS_NEGSUBNORMAL: "0x0010",
7310
+ __FPCLASS_NEGZERO: "0x0020",
7311
+ __FPCLASS_POSINF: "0x0200",
7312
+ __FPCLASS_POSNORMAL: "0x0100",
7313
+ __FPCLASS_POSSUBNORMAL: "0x0080",
7314
+ __FPCLASS_POSZERO: "0x0040",
7315
+ __FPCLASS_QNAN: "0x0002",
7316
+ __FPCLASS_SNAN: "0x0001",
7317
+ __FP_FAST_FMA: "1",
7318
+ __FP_FAST_FMAF: "1",
7319
+ __FUNCTION_MULTI_VERSIONING_SUPPORT_LEVEL: "202430",
7320
+ __GCC_ASM_FLAG_OUTPUTS__: "1",
7321
+ __GCC_ATOMIC_BOOL_LOCK_FREE: "2",
7322
+ __GCC_ATOMIC_CHAR16_T_LOCK_FREE: "2",
7323
+ __GCC_ATOMIC_CHAR32_T_LOCK_FREE: "2",
7324
+ __GCC_ATOMIC_CHAR_LOCK_FREE: "2",
7325
+ __GCC_ATOMIC_INT_LOCK_FREE: "2",
7326
+ __GCC_ATOMIC_LLONG_LOCK_FREE: "2",
7327
+ __GCC_ATOMIC_LONG_LOCK_FREE: "2",
7328
+ __GCC_ATOMIC_POINTER_LOCK_FREE: "2",
7329
+ __GCC_ATOMIC_SHORT_LOCK_FREE: "2",
7330
+ __GCC_ATOMIC_TEST_AND_SET_TRUEVAL: "1",
7331
+ __GCC_ATOMIC_WCHAR_T_LOCK_FREE: "2",
7332
+ __GCC_CONSTRUCTIVE_SIZE: "64",
7333
+ __GCC_DESTRUCTIVE_SIZE: "256",
7334
+ __GCC_HAVE_DWARF2_CFI_ASM: "1",
7335
+ __GCC_HAVE_SYNC_COMPARE_AND_SWAP_1: "1",
7336
+ __GCC_HAVE_SYNC_COMPARE_AND_SWAP_16: "1",
7337
+ __GCC_HAVE_SYNC_COMPARE_AND_SWAP_2: "1",
7338
+ __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4: "1",
7339
+ __GCC_HAVE_SYNC_COMPARE_AND_SWAP_8: "1",
7340
+ __GLIBCXX_BITSIZE_INT_N_0: "128",
7341
+ __GLIBCXX_TYPE_INT_N_0: "__int128",
7342
+ __GNUC_GNU_INLINE__: "1",
7343
+ __GNUC_MINOR__: "2",
7344
+ __GNUC_PATCHLEVEL__: "1",
7345
+ __GNUC__: "4",
7346
+ __GNUG__: "4",
7347
+ __GXX_ABI_VERSION: "1002",
7348
+ __GXX_EXPERIMENTAL_CXX0X__: "1",
7349
+ __GXX_RTTI: "1",
7350
+ __GXX_WEAK__: "1",
7351
+ __HAVE_FUNCTION_MULTI_VERSIONING: "1",
7352
+ __INT16_C: "(c) c",
7353
+ __INT16_C_SUFFIX__: null,
7354
+ __INT16_FMTd__: '"hd"',
7355
+ __INT16_FMTi__: '"hi"',
7356
+ __INT16_MAX__: "32767",
7357
+ __INT16_TYPE__: "short",
7358
+ __INT32_C: "(c) c",
7359
+ __INT32_C_SUFFIX__: null,
7360
+ __INT32_FMTd__: '"d"',
7361
+ __INT32_FMTi__: '"i"',
7362
+ __INT32_MAX__: "2147483647",
7363
+ __INT32_TYPE__: "int",
7364
+ __INT64_C: "(c) c##LL",
7365
+ __INT64_C_SUFFIX__: "LL",
7366
+ __INT64_FMTd__: '"lld"',
7367
+ __INT64_FMTi__: '"lli"',
7368
+ __INT64_MAX__: "9223372036854775807LL",
7369
+ __INT64_TYPE__: "long long int",
7370
+ __INT8_C: "(c) c",
7371
+ __INT8_C_SUFFIX__: null,
7372
+ __INT8_FMTd__: '"hhd"',
7373
+ __INT8_FMTi__: '"hhi"',
7374
+ __INT8_MAX__: "127",
7375
+ __INT8_TYPE__: "signed char",
7376
+ __INTMAX_C: "(c) c##L",
7377
+ __INTMAX_C_SUFFIX__: "L",
7378
+ __INTMAX_FMTd__: '"ld"',
7379
+ __INTMAX_FMTi__: '"li"',
7380
+ __INTMAX_MAX__: "9223372036854775807L",
7381
+ __INTMAX_TYPE__: "long int",
7382
+ __INTMAX_WIDTH__: "64",
7383
+ __INTPTR_FMTd__: '"ld"',
7384
+ __INTPTR_FMTi__: '"li"',
7385
+ __INTPTR_MAX__: "9223372036854775807L",
7386
+ __INTPTR_TYPE__: "long int",
7387
+ __INTPTR_WIDTH__: "64",
7388
+ __INT_FAST16_FMTd__: '"hd"',
7389
+ __INT_FAST16_FMTi__: '"hi"',
7390
+ __INT_FAST16_MAX__: "32767",
7391
+ __INT_FAST16_TYPE__: "short",
7392
+ __INT_FAST16_WIDTH__: "16",
7393
+ __INT_FAST32_FMTd__: '"d"',
7394
+ __INT_FAST32_FMTi__: '"i"',
7395
+ __INT_FAST32_MAX__: "2147483647",
7396
+ __INT_FAST32_TYPE__: "int",
7397
+ __INT_FAST32_WIDTH__: "32",
7398
+ __INT_FAST64_FMTd__: '"lld"',
7399
+ __INT_FAST64_FMTi__: '"lli"',
7400
+ __INT_FAST64_MAX__: "9223372036854775807LL",
7401
+ __INT_FAST64_TYPE__: "long long int",
7402
+ __INT_FAST64_WIDTH__: "64",
7403
+ __INT_FAST8_FMTd__: '"hhd"',
7404
+ __INT_FAST8_FMTi__: '"hhi"',
7405
+ __INT_FAST8_MAX__: "127",
7406
+ __INT_FAST8_TYPE__: "signed char",
7407
+ __INT_FAST8_WIDTH__: "8",
7408
+ __INT_LEAST16_FMTd__: '"hd"',
7409
+ __INT_LEAST16_FMTi__: '"hi"',
7410
+ __INT_LEAST16_MAX__: "32767",
7411
+ __INT_LEAST16_TYPE__: "short",
7412
+ __INT_LEAST16_WIDTH__: "16",
7413
+ __INT_LEAST32_FMTd__: '"d"',
7414
+ __INT_LEAST32_FMTi__: '"i"',
7415
+ __INT_LEAST32_MAX__: "2147483647",
7416
+ __INT_LEAST32_TYPE__: "int",
7417
+ __INT_LEAST32_WIDTH__: "32",
7418
+ __INT_LEAST64_FMTd__: '"lld"',
7419
+ __INT_LEAST64_FMTi__: '"lli"',
7420
+ __INT_LEAST64_MAX__: "9223372036854775807LL",
7421
+ __INT_LEAST64_TYPE__: "long long int",
7422
+ __INT_LEAST64_WIDTH__: "64",
7423
+ __INT_LEAST8_FMTd__: '"hhd"',
7424
+ __INT_LEAST8_FMTi__: '"hhi"',
7425
+ __INT_LEAST8_MAX__: "127",
7426
+ __INT_LEAST8_TYPE__: "signed char",
7427
+ __INT_LEAST8_WIDTH__: "8",
7428
+ __INT_MAX__: "2147483647",
7429
+ __INT_WIDTH__: "32",
7430
+ __LDBL_DECIMAL_DIG__: "17",
7431
+ __LDBL_DENORM_MIN__: "4.9406564584124654e-324L",
7432
+ __LDBL_DIG__: "15",
7433
+ __LDBL_EPSILON__: "2.2204460492503131e-16L",
7434
+ __LDBL_HAS_DENORM__: "1",
7435
+ __LDBL_HAS_INFINITY__: "1",
7436
+ __LDBL_HAS_QUIET_NAN__: "1",
7437
+ __LDBL_MANT_DIG__: "53",
7438
+ __LDBL_MAX_10_EXP__: "308",
7439
+ __LDBL_MAX_EXP__: "1024",
7440
+ __LDBL_MAX__: "1.7976931348623157e+308L",
7441
+ __LDBL_MIN_10_EXP__: "(-307)",
7442
+ __LDBL_MIN_EXP__: "(-1021)",
7443
+ __LDBL_MIN__: "2.2250738585072014e-308L",
7444
+ __LDBL_NORM_MAX__: "1.7976931348623157e+308L",
7445
+ __LITTLE_ENDIAN__: "1",
7446
+ __LLONG_WIDTH__: "64",
7447
+ __LONG_LONG_MAX__: "9223372036854775807LL",
7448
+ __LONG_MAX__: "9223372036854775807L",
7449
+ __LONG_WIDTH__: "64",
7450
+ __LP64__: "1",
7451
+ __MACH__: "1",
7452
+ __MEMORY_SCOPE_DEVICE: "1",
7453
+ __MEMORY_SCOPE_SINGLE: "4",
7454
+ __MEMORY_SCOPE_SYSTEM: "0",
7455
+ __MEMORY_SCOPE_WRKGRP: "2",
7456
+ __MEMORY_SCOPE_WVFRNT: "3",
7457
+ __NO_INLINE__: "1",
7458
+ __NO_MATH_ERRNO__: "1",
7459
+ __OBJC_BOOL_IS_BOOL: "1",
7460
+ __OPENCL_MEMORY_SCOPE_ALL_SVM_DEVICES: "3",
7461
+ __OPENCL_MEMORY_SCOPE_DEVICE: "2",
7462
+ __OPENCL_MEMORY_SCOPE_SUB_GROUP: "4",
7463
+ __OPENCL_MEMORY_SCOPE_WORK_GROUP: "1",
7464
+ __OPENCL_MEMORY_SCOPE_WORK_ITEM: "0",
7465
+ __ORDER_BIG_ENDIAN__: "4321",
7466
+ __ORDER_LITTLE_ENDIAN__: "1234",
7467
+ __ORDER_PDP_ENDIAN__: "3412",
7468
+ __PIC__: "2",
7469
+ __POINTER_WIDTH__: "64",
7470
+ __PRAGMA_REDEFINE_EXTNAME: "1",
7471
+ __PTRDIFF_FMTd__: '"ld"',
7472
+ __PTRDIFF_FMTi__: '"li"',
7473
+ __PTRDIFF_MAX__: "9223372036854775807L",
7474
+ __PTRDIFF_TYPE__: "long int",
7475
+ __PTRDIFF_WIDTH__: "64",
7476
+ __REGISTER_PREFIX__: null,
7477
+ __SCHAR_MAX__: "127",
7478
+ __SHRT_MAX__: "32767",
7479
+ __SHRT_WIDTH__: "16",
7480
+ __SIG_ATOMIC_MAX__: "2147483647",
7481
+ __SIG_ATOMIC_WIDTH__: "32",
7482
+ __SIZEOF_DOUBLE__: "8",
7483
+ __SIZEOF_FLOAT__: "4",
7484
+ __SIZEOF_INT128__: "16",
7485
+ __SIZEOF_INT__: "4",
7486
+ __SIZEOF_LONG_DOUBLE__: "8",
7487
+ __SIZEOF_LONG_LONG__: "8",
7488
+ __SIZEOF_LONG__: "8",
7489
+ __SIZEOF_POINTER__: "8",
7490
+ __SIZEOF_PTRDIFF_T__: "8",
7491
+ __SIZEOF_SHORT__: "2",
7492
+ __SIZEOF_SIZE_T__: "8",
7493
+ __SIZEOF_WCHAR_T__: "4",
7494
+ __SIZEOF_WINT_T__: "4",
7495
+ __SIZE_FMTX__: '"lX"',
7496
+ __SIZE_FMTo__: '"lo"',
7497
+ __SIZE_FMTu__: '"lu"',
7498
+ __SIZE_FMTx__: '"lx"',
7499
+ __SIZE_MAX__: "18446744073709551615UL",
7500
+ __SIZE_TYPE__: "long unsigned int",
7501
+ __SIZE_WIDTH__: "64",
7502
+ __SSP__: "1",
7503
+ __STDCPP_DEFAULT_NEW_ALIGNMENT__: "16UL",
7504
+ __STDCPP_THREADS__: "1",
7505
+ __STDC_EMBED_EMPTY__: "2",
7506
+ __STDC_EMBED_FOUND__: "1",
7507
+ __STDC_EMBED_NOT_FOUND__: "0",
7508
+ __STDC_HOSTED__: "1",
7509
+ __STDC_NO_THREADS__: "1",
7510
+ __STDC_UTF_16__: "1",
7511
+ __STDC_UTF_32__: "1",
7512
+ __STDC__: "1",
7513
+ __UINT16_C: "(c) c",
7514
+ __UINT16_C_SUFFIX__: null,
7515
+ __UINT16_FMTX__: '"hX"',
7516
+ __UINT16_FMTo__: '"ho"',
7517
+ __UINT16_FMTu__: '"hu"',
7518
+ __UINT16_FMTx__: '"hx"',
7519
+ __UINT16_MAX__: "65535",
7520
+ __UINT16_TYPE__: "unsigned short",
7521
+ __UINT32_C: "(c) c##U",
7522
+ __UINT32_C_SUFFIX__: "U",
7523
+ __UINT32_FMTX__: '"X"',
7524
+ __UINT32_FMTo__: '"o"',
7525
+ __UINT32_FMTu__: '"u"',
7526
+ __UINT32_FMTx__: '"x"',
7527
+ __UINT32_MAX__: "4294967295U",
7528
+ __UINT32_TYPE__: "unsigned int",
7529
+ __UINT64_C: "(c) c##ULL",
7530
+ __UINT64_C_SUFFIX__: "ULL",
7531
+ __UINT64_FMTX__: '"llX"',
7532
+ __UINT64_FMTo__: '"llo"',
7533
+ __UINT64_FMTu__: '"llu"',
7534
+ __UINT64_FMTx__: '"llx"',
7535
+ __UINT64_MAX__: "18446744073709551615ULL",
7536
+ __UINT64_TYPE__: "long long unsigned int",
7537
+ __UINT8_C: "(c) c",
7538
+ __UINT8_C_SUFFIX__: null,
7539
+ __UINT8_FMTX__: '"hhX"',
7540
+ __UINT8_FMTo__: '"hho"',
7541
+ __UINT8_FMTu__: '"hhu"',
7542
+ __UINT8_FMTx__: '"hhx"',
7543
+ __UINT8_MAX__: "255",
7544
+ __UINT8_TYPE__: "unsigned char",
7545
+ __UINTMAX_C: "(c) c##UL",
7546
+ __UINTMAX_C_SUFFIX__: "UL",
7547
+ __UINTMAX_FMTX__: '"lX"',
7548
+ __UINTMAX_FMTo__: '"lo"',
7549
+ __UINTMAX_FMTu__: '"lu"',
7550
+ __UINTMAX_FMTx__: '"lx"',
7551
+ __UINTMAX_MAX__: "18446744073709551615UL",
7552
+ __UINTMAX_TYPE__: "long unsigned int",
7553
+ __UINTMAX_WIDTH__: "64",
7554
+ __UINTPTR_FMTX__: '"lX"',
7555
+ __UINTPTR_FMTo__: '"lo"',
7556
+ __UINTPTR_FMTu__: '"lu"',
7557
+ __UINTPTR_FMTx__: '"lx"',
7558
+ __UINTPTR_MAX__: "18446744073709551615UL",
7559
+ __UINTPTR_TYPE__: "long unsigned int",
7560
+ __UINTPTR_WIDTH__: "64",
7561
+ __UINT_FAST16_FMTX__: '"hX"',
7562
+ __UINT_FAST16_FMTo__: '"ho"',
7563
+ __UINT_FAST16_FMTu__: '"hu"',
7564
+ __UINT_FAST16_FMTx__: '"hx"',
7565
+ __UINT_FAST16_MAX__: "65535",
7566
+ __UINT_FAST16_TYPE__: "unsigned short",
7567
+ __UINT_FAST32_FMTX__: '"X"',
7568
+ __UINT_FAST32_FMTo__: '"o"',
7569
+ __UINT_FAST32_FMTu__: '"u"',
7570
+ __UINT_FAST32_FMTx__: '"x"',
7571
+ __UINT_FAST32_MAX__: "4294967295U",
7572
+ __UINT_FAST32_TYPE__: "unsigned int",
7573
+ __UINT_FAST64_FMTX__: '"llX"',
7574
+ __UINT_FAST64_FMTo__: '"llo"',
7575
+ __UINT_FAST64_FMTu__: '"llu"',
7576
+ __UINT_FAST64_FMTx__: '"llx"',
7577
+ __UINT_FAST64_MAX__: "18446744073709551615ULL",
7578
+ __UINT_FAST64_TYPE__: "long long unsigned int",
7579
+ __UINT_FAST8_FMTX__: '"hhX"',
7580
+ __UINT_FAST8_FMTo__: '"hho"',
7581
+ __UINT_FAST8_FMTu__: '"hhu"',
7582
+ __UINT_FAST8_FMTx__: '"hhx"',
7583
+ __UINT_FAST8_MAX__: "255",
7584
+ __UINT_FAST8_TYPE__: "unsigned char",
7585
+ __UINT_LEAST16_FMTX__: '"hX"',
7586
+ __UINT_LEAST16_FMTo__: '"ho"',
7587
+ __UINT_LEAST16_FMTu__: '"hu"',
7588
+ __UINT_LEAST16_FMTx__: '"hx"',
7589
+ __UINT_LEAST16_MAX__: "65535",
7590
+ __UINT_LEAST16_TYPE__: "unsigned short",
7591
+ __UINT_LEAST32_FMTX__: '"X"',
7592
+ __UINT_LEAST32_FMTo__: '"o"',
7593
+ __UINT_LEAST32_FMTu__: '"u"',
7594
+ __UINT_LEAST32_FMTx__: '"x"',
7595
+ __UINT_LEAST32_MAX__: "4294967295U",
7596
+ __UINT_LEAST32_TYPE__: "unsigned int",
7597
+ __UINT_LEAST64_FMTX__: '"llX"',
7598
+ __UINT_LEAST64_FMTo__: '"llo"',
7599
+ __UINT_LEAST64_FMTu__: '"llu"',
7600
+ __UINT_LEAST64_FMTx__: '"llx"',
7601
+ __UINT_LEAST64_MAX__: "18446744073709551615ULL",
7602
+ __UINT_LEAST64_TYPE__: "long long unsigned int",
7603
+ __UINT_LEAST8_FMTX__: '"hhX"',
7604
+ __UINT_LEAST8_FMTo__: '"hho"',
7605
+ __UINT_LEAST8_FMTu__: '"hhu"',
7606
+ __UINT_LEAST8_FMTx__: '"hhx"',
7607
+ __UINT_LEAST8_MAX__: "255",
7608
+ __UINT_LEAST8_TYPE__: "unsigned char",
7609
+ __USER_LABEL_PREFIX__: "_",
7610
+ __VERSION__: '"Clang 21.0.0"',
7611
+ __WCHAR_MAX__: "2147483647",
7612
+ __WCHAR_TYPE__: "int",
7613
+ __WCHAR_WIDTH__: "32",
7614
+ __WINT_MAX__: "2147483647",
7615
+ __WINT_TYPE__: "int",
7616
+ __WINT_WIDTH__: "32",
7617
+ __aarch64__: "1",
7618
+ __arm64: "1",
7619
+ __arm64__: "1",
7620
+ __block: "__attribute__((__blocks__(byref)))",
7621
+ __clang__: "1",
7622
+ __clang_literal_encoding__: '"UTF-8"',
7623
+ __clang_major__: "21",
7624
+ __clang_minor__: "0",
7625
+ __clang_patchlevel__: "0",
7626
+ __clang_version__: '"21.0.0 "',
7627
+ __clang_wide_literal_encoding__: '"UTF-32"',
7628
+ __cplusplus: "201703L",
7629
+ __cpp_aggregate_bases: "201603L",
7630
+ __cpp_aggregate_nsdmi: "201304L",
7631
+ __cpp_alias_templates: "200704L",
7632
+ __cpp_attributes: "200809L",
7633
+ __cpp_binary_literals: "201304L",
7634
+ __cpp_capture_star_this: "201603L",
7635
+ __cpp_constexpr: "201603L",
7636
+ __cpp_constexpr_in_decltype: "201711L",
7637
+ __cpp_decltype: "200707L",
7638
+ __cpp_decltype_auto: "201304L",
7639
+ __cpp_deduction_guides: "201703L",
7640
+ __cpp_delegating_constructors: "200604L",
7641
+ __cpp_deleted_function: "202403L",
7642
+ __cpp_digit_separators: "201309L",
7643
+ __cpp_enumerator_attributes: "201411L",
7644
+ __cpp_exceptions: "199711L",
7645
+ __cpp_fold_expressions: "201603L",
7646
+ __cpp_generic_lambdas: "201304L",
7647
+ __cpp_guaranteed_copy_elision: "201606L",
7648
+ __cpp_hex_float: "201603L",
7649
+ __cpp_if_constexpr: "201606L",
7650
+ __cpp_impl_destroying_delete: "201806L",
7651
+ __cpp_inheriting_constructors: "201511L",
7652
+ __cpp_init_captures: "201304L",
7653
+ __cpp_initializer_lists: "200806L",
7654
+ __cpp_inline_variables: "201606L",
7655
+ __cpp_lambdas: "200907L",
7656
+ __cpp_named_character_escapes: "202207L",
7657
+ __cpp_namespace_attributes: "201411L",
7658
+ __cpp_nested_namespace_definitions: "201411L",
7659
+ __cpp_noexcept_function_type: "201510L",
7660
+ __cpp_nontype_template_args: "201411L",
7661
+ __cpp_nontype_template_parameter_auto: "201606L",
7662
+ __cpp_nsdmi: "200809L",
7663
+ __cpp_pack_indexing: "202311L",
7664
+ __cpp_placeholder_variables: "202306L",
7665
+ __cpp_range_based_for: "201603L",
7666
+ __cpp_raw_strings: "200710L",
7667
+ __cpp_ref_qualifiers: "200710L",
7668
+ __cpp_return_type_deduction: "201304L",
7669
+ __cpp_rtti: "199711L",
7670
+ __cpp_rvalue_references: "200610L",
7671
+ __cpp_static_assert: "202306L",
7672
+ __cpp_static_call_operator: "202207L",
7673
+ __cpp_structured_bindings: "202411L",
7674
+ __cpp_template_auto: "201606L",
7675
+ __cpp_template_template_args: "201611L",
7676
+ __cpp_threadsafe_static_init: "200806L",
7677
+ __cpp_unicode_characters: "200704L",
7678
+ __cpp_unicode_literals: "200710L",
7679
+ __cpp_user_defined_literals: "200809L",
7680
+ __cpp_variable_templates: "201304L",
7681
+ __cpp_variadic_friend: "202403L",
7682
+ __cpp_variadic_templates: "200704L",
7683
+ __cpp_variadic_using: "201611L",
7684
+ __llvm__: "1",
7685
+ __nonnull: "_Nonnull",
7686
+ __null_unspecified: "_Null_unspecified",
7687
+ __nullable: "_Nullable",
7688
+ __pic__: "2",
7689
+ __private_extern__: "extern",
7690
+ __strong: null,
7691
+ __unsafe_unretained: null,
7692
+ __weak: "__attribute__((objc_gc(weak)))"
7693
+ },
7694
+ "objective-c": {
7695
+ IBAction: "void)__attribute__((ibaction)",
7696
+ IBInspectable: null,
7697
+ IBOutlet: "__attribute__((iboutlet))",
7698
+ IBOutletCollection: "(ClassName) __attribute__((iboutletcollection(ClassName)))",
7699
+ IB_DESIGNABLE: null,
7700
+ OBJC_NEW_PROPERTIES: "1",
7701
+ OBJC_ZEROCOST_EXCEPTIONS: "1",
7702
+ TARGET_IPHONE_SIMULATOR: "0",
7703
+ TARGET_OS_DRIVERKIT: "0",
7704
+ TARGET_OS_EMBEDDED: "1",
7705
+ TARGET_OS_FIRMWARE: "0",
7706
+ TARGET_OS_IOS: "1",
7707
+ TARGET_OS_IPHONE: "1",
7708
+ TARGET_OS_LINUX: "0",
7709
+ TARGET_OS_MAC: "1",
7710
+ TARGET_OS_MACCATALYST: "0",
7711
+ TARGET_OS_NANO: "0",
7712
+ TARGET_OS_OSX: "0",
7713
+ TARGET_OS_SIMULATOR: "0",
7714
+ TARGET_OS_TV: "0",
7715
+ TARGET_OS_UEFI: "0",
7716
+ TARGET_OS_UIKITFORMAC: "0",
7717
+ TARGET_OS_UNIX: "0",
7718
+ TARGET_OS_VISION: "0",
7719
+ TARGET_OS_WATCH: "0",
7720
+ TARGET_OS_WIN32: "0",
7721
+ TARGET_OS_WINDOWS: "0",
7722
+ _LP64: "1",
7723
+ __AARCH64EL__: "1",
7724
+ __AARCH64_CMODEL_SMALL__: "1",
7725
+ __AARCH64_SIMD__: "1",
7726
+ __APPLE_CC__: "6000",
7727
+ __APPLE__: "1",
7728
+ __ARM64_ARCH_8__: "1",
7729
+ __ARM_64BIT_STATE: "1",
7730
+ __ARM_ACLE: "202420",
7731
+ __ARM_ACLE_VERSION: "(year,quarter,patch) (100 * (year) + 10 * (quarter) + (patch))",
7732
+ __ARM_ALIGN_MAX_STACK_PWR: "4",
7733
+ __ARM_ARCH: "8",
7734
+ __ARM_ARCH_ISA_A64: "1",
7735
+ __ARM_ARCH_PROFILE: "'A'",
7736
+ __ARM_FEATURE_AES: "1",
7737
+ __ARM_FEATURE_CLZ: "1",
7738
+ __ARM_FEATURE_CRYPTO: "1",
7739
+ __ARM_FEATURE_DIRECTED_ROUNDING: "1",
7740
+ __ARM_FEATURE_DIV: "1",
7741
+ __ARM_FEATURE_FMA: "1",
7742
+ __ARM_FEATURE_IDIV: "1",
7743
+ __ARM_FEATURE_LDREX: "0xF",
7744
+ __ARM_FEATURE_NUMERIC_MAXMIN: "1",
7745
+ __ARM_FEATURE_SHA2: "1",
7746
+ __ARM_FEATURE_UNALIGNED: "1",
7747
+ __ARM_FP: "0xE",
7748
+ __ARM_FP16_ARGS: "1",
7749
+ __ARM_FP16_FORMAT_IEEE: "1",
7750
+ __ARM_NEON: "1",
7751
+ __ARM_NEON_FP: "0xE",
7752
+ __ARM_NEON_SVE_BRIDGE: "1",
7753
+ __ARM_NEON__: "1",
7754
+ __ARM_PCS_AAPCS64: "1",
7755
+ __ARM_SIZEOF_MINIMAL_ENUM: "4",
7756
+ __ARM_SIZEOF_WCHAR_T: "4",
7757
+ __ARM_STATE_ZA: "1",
7758
+ __ARM_STATE_ZT0: "1",
7759
+ __ATOMIC_ACQUIRE: "2",
7760
+ __ATOMIC_ACQ_REL: "4",
7761
+ __ATOMIC_CONSUME: "1",
7762
+ __ATOMIC_RELAXED: "0",
7763
+ __ATOMIC_RELEASE: "3",
7764
+ __ATOMIC_SEQ_CST: "5",
7765
+ __BIGGEST_ALIGNMENT__: "8",
7766
+ __BITINT_MAXWIDTH__: "128",
7767
+ __BLOCKS__: "1",
7768
+ __BOOL_WIDTH__: "1",
7769
+ __BYTE_ORDER__: "__ORDER_LITTLE_ENDIAN__",
7770
+ __CHAR16_TYPE__: "unsigned short",
7771
+ __CHAR32_TYPE__: "unsigned int",
7772
+ __CHAR_BIT__: "8",
7773
+ __CLANG_ATOMIC_BOOL_LOCK_FREE: "2",
7774
+ __CLANG_ATOMIC_CHAR16_T_LOCK_FREE: "2",
7775
+ __CLANG_ATOMIC_CHAR32_T_LOCK_FREE: "2",
7776
+ __CLANG_ATOMIC_CHAR_LOCK_FREE: "2",
7777
+ __CLANG_ATOMIC_INT_LOCK_FREE: "2",
7778
+ __CLANG_ATOMIC_LLONG_LOCK_FREE: "2",
7779
+ __CLANG_ATOMIC_LONG_LOCK_FREE: "2",
7780
+ __CLANG_ATOMIC_POINTER_LOCK_FREE: "2",
7781
+ __CLANG_ATOMIC_SHORT_LOCK_FREE: "2",
7782
+ __CLANG_ATOMIC_WCHAR_T_LOCK_FREE: "2",
7783
+ __CONSTANT_CFSTRINGS__: "1",
7784
+ __DBL_DECIMAL_DIG__: "17",
7785
+ __DBL_DENORM_MIN__: "4.9406564584124654e-324",
7786
+ __DBL_DIG__: "15",
7787
+ __DBL_EPSILON__: "2.2204460492503131e-16",
7788
+ __DBL_HAS_DENORM__: "1",
7789
+ __DBL_HAS_INFINITY__: "1",
7790
+ __DBL_HAS_QUIET_NAN__: "1",
7791
+ __DBL_MANT_DIG__: "53",
7792
+ __DBL_MAX_10_EXP__: "308",
7793
+ __DBL_MAX_EXP__: "1024",
7794
+ __DBL_MAX__: "1.7976931348623157e+308",
7795
+ __DBL_MIN_10_EXP__: "(-307)",
7796
+ __DBL_MIN_EXP__: "(-1021)",
7797
+ __DBL_MIN__: "2.2250738585072014e-308",
7798
+ __DBL_NORM_MAX__: "1.7976931348623157e+308",
7799
+ __DECIMAL_DIG__: "__LDBL_DECIMAL_DIG__",
7800
+ __DYNAMIC__: "1",
7801
+ __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__: "70000",
7802
+ __ENVIRONMENT_OS_VERSION_MIN_REQUIRED__: "70000",
7803
+ __EXCEPTIONS: "1",
7804
+ __FINITE_MATH_ONLY__: "0",
7805
+ __FLT16_DECIMAL_DIG__: "5",
7806
+ __FLT16_DENORM_MIN__: "5.9604644775390625e-8F16",
7807
+ __FLT16_DIG__: "3",
7808
+ __FLT16_EPSILON__: "9.765625e-4F16",
7809
+ __FLT16_HAS_DENORM__: "1",
7810
+ __FLT16_HAS_INFINITY__: "1",
7811
+ __FLT16_HAS_QUIET_NAN__: "1",
7812
+ __FLT16_MANT_DIG__: "11",
7813
+ __FLT16_MAX_10_EXP__: "4",
7814
+ __FLT16_MAX_EXP__: "16",
7815
+ __FLT16_MAX__: "6.5504e+4F16",
7816
+ __FLT16_MIN_10_EXP__: "(-4)",
7817
+ __FLT16_MIN_EXP__: "(-13)",
7818
+ __FLT16_MIN__: "6.103515625e-5F16",
7819
+ __FLT16_NORM_MAX__: "6.5504e+4F16",
7820
+ __FLT_DECIMAL_DIG__: "9",
7821
+ __FLT_DENORM_MIN__: "1.40129846e-45F",
7822
+ __FLT_DIG__: "6",
7823
+ __FLT_EPSILON__: "1.19209290e-7F",
7824
+ __FLT_HAS_DENORM__: "1",
7825
+ __FLT_HAS_INFINITY__: "1",
7826
+ __FLT_HAS_QUIET_NAN__: "1",
7827
+ __FLT_MANT_DIG__: "24",
7828
+ __FLT_MAX_10_EXP__: "38",
7829
+ __FLT_MAX_EXP__: "128",
7830
+ __FLT_MAX__: "3.40282347e+38F",
7831
+ __FLT_MIN_10_EXP__: "(-37)",
7832
+ __FLT_MIN_EXP__: "(-125)",
7833
+ __FLT_MIN__: "1.17549435e-38F",
7834
+ __FLT_NORM_MAX__: "3.40282347e+38F",
7835
+ __FLT_RADIX__: "2",
7836
+ __FPCLASS_NEGINF: "0x0004",
7837
+ __FPCLASS_NEGNORMAL: "0x0008",
7838
+ __FPCLASS_NEGSUBNORMAL: "0x0010",
7839
+ __FPCLASS_NEGZERO: "0x0020",
7840
+ __FPCLASS_POSINF: "0x0200",
7841
+ __FPCLASS_POSNORMAL: "0x0100",
7842
+ __FPCLASS_POSSUBNORMAL: "0x0080",
7843
+ __FPCLASS_POSZERO: "0x0040",
7844
+ __FPCLASS_QNAN: "0x0002",
7845
+ __FPCLASS_SNAN: "0x0001",
7846
+ __FP_FAST_FMA: "1",
7847
+ __FP_FAST_FMAF: "1",
7848
+ __FUNCTION_MULTI_VERSIONING_SUPPORT_LEVEL: "202430",
7849
+ __GCC_ASM_FLAG_OUTPUTS__: "1",
7850
+ __GCC_ATOMIC_BOOL_LOCK_FREE: "2",
7851
+ __GCC_ATOMIC_CHAR16_T_LOCK_FREE: "2",
7852
+ __GCC_ATOMIC_CHAR32_T_LOCK_FREE: "2",
7853
+ __GCC_ATOMIC_CHAR_LOCK_FREE: "2",
7854
+ __GCC_ATOMIC_INT_LOCK_FREE: "2",
7855
+ __GCC_ATOMIC_LLONG_LOCK_FREE: "2",
7856
+ __GCC_ATOMIC_LONG_LOCK_FREE: "2",
7857
+ __GCC_ATOMIC_POINTER_LOCK_FREE: "2",
7858
+ __GCC_ATOMIC_SHORT_LOCK_FREE: "2",
7859
+ __GCC_ATOMIC_TEST_AND_SET_TRUEVAL: "1",
7860
+ __GCC_ATOMIC_WCHAR_T_LOCK_FREE: "2",
7861
+ __GCC_CONSTRUCTIVE_SIZE: "64",
7862
+ __GCC_DESTRUCTIVE_SIZE: "256",
7863
+ __GCC_HAVE_DWARF2_CFI_ASM: "1",
7864
+ __GCC_HAVE_SYNC_COMPARE_AND_SWAP_1: "1",
7865
+ __GCC_HAVE_SYNC_COMPARE_AND_SWAP_16: "1",
7866
+ __GCC_HAVE_SYNC_COMPARE_AND_SWAP_2: "1",
7867
+ __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4: "1",
7868
+ __GCC_HAVE_SYNC_COMPARE_AND_SWAP_8: "1",
7869
+ __GNUC_MINOR__: "2",
7870
+ __GNUC_PATCHLEVEL__: "1",
7871
+ __GNUC_STDC_INLINE__: "1",
7872
+ __GNUC__: "4",
7873
+ __GXX_ABI_VERSION: "1002",
7874
+ __HAVE_FUNCTION_MULTI_VERSIONING: "1",
7875
+ __INT16_C: "(c) c",
7876
+ __INT16_C_SUFFIX__: null,
7877
+ __INT16_FMTd__: '"hd"',
7878
+ __INT16_FMTi__: '"hi"',
7879
+ __INT16_MAX__: "32767",
7880
+ __INT16_TYPE__: "short",
7881
+ __INT32_C: "(c) c",
7882
+ __INT32_C_SUFFIX__: null,
7883
+ __INT32_FMTd__: '"d"',
7884
+ __INT32_FMTi__: '"i"',
7885
+ __INT32_MAX__: "2147483647",
7886
+ __INT32_TYPE__: "int",
7887
+ __INT64_C: "(c) c##LL",
7888
+ __INT64_C_SUFFIX__: "LL",
7889
+ __INT64_FMTd__: '"lld"',
7890
+ __INT64_FMTi__: '"lli"',
7891
+ __INT64_MAX__: "9223372036854775807LL",
7892
+ __INT64_TYPE__: "long long int",
7893
+ __INT8_C: "(c) c",
7894
+ __INT8_C_SUFFIX__: null,
7895
+ __INT8_FMTd__: '"hhd"',
7896
+ __INT8_FMTi__: '"hhi"',
7897
+ __INT8_MAX__: "127",
7898
+ __INT8_TYPE__: "signed char",
7899
+ __INTMAX_C: "(c) c##L",
7900
+ __INTMAX_C_SUFFIX__: "L",
7901
+ __INTMAX_FMTd__: '"ld"',
7902
+ __INTMAX_FMTi__: '"li"',
7903
+ __INTMAX_MAX__: "9223372036854775807L",
7904
+ __INTMAX_TYPE__: "long int",
7905
+ __INTMAX_WIDTH__: "64",
7906
+ __INTPTR_FMTd__: '"ld"',
7907
+ __INTPTR_FMTi__: '"li"',
7908
+ __INTPTR_MAX__: "9223372036854775807L",
7909
+ __INTPTR_TYPE__: "long int",
7910
+ __INTPTR_WIDTH__: "64",
7911
+ __INT_FAST16_FMTd__: '"hd"',
7912
+ __INT_FAST16_FMTi__: '"hi"',
7913
+ __INT_FAST16_MAX__: "32767",
7914
+ __INT_FAST16_TYPE__: "short",
7915
+ __INT_FAST16_WIDTH__: "16",
7916
+ __INT_FAST32_FMTd__: '"d"',
7917
+ __INT_FAST32_FMTi__: '"i"',
7918
+ __INT_FAST32_MAX__: "2147483647",
7919
+ __INT_FAST32_TYPE__: "int",
7920
+ __INT_FAST32_WIDTH__: "32",
7921
+ __INT_FAST64_FMTd__: '"lld"',
7922
+ __INT_FAST64_FMTi__: '"lli"',
7923
+ __INT_FAST64_MAX__: "9223372036854775807LL",
7924
+ __INT_FAST64_TYPE__: "long long int",
7925
+ __INT_FAST64_WIDTH__: "64",
7926
+ __INT_FAST8_FMTd__: '"hhd"',
7927
+ __INT_FAST8_FMTi__: '"hhi"',
7928
+ __INT_FAST8_MAX__: "127",
7929
+ __INT_FAST8_TYPE__: "signed char",
7930
+ __INT_FAST8_WIDTH__: "8",
7931
+ __INT_LEAST16_FMTd__: '"hd"',
7932
+ __INT_LEAST16_FMTi__: '"hi"',
7933
+ __INT_LEAST16_MAX__: "32767",
7934
+ __INT_LEAST16_TYPE__: "short",
7935
+ __INT_LEAST16_WIDTH__: "16",
7936
+ __INT_LEAST32_FMTd__: '"d"',
7937
+ __INT_LEAST32_FMTi__: '"i"',
7938
+ __INT_LEAST32_MAX__: "2147483647",
7939
+ __INT_LEAST32_TYPE__: "int",
7940
+ __INT_LEAST32_WIDTH__: "32",
7941
+ __INT_LEAST64_FMTd__: '"lld"',
7942
+ __INT_LEAST64_FMTi__: '"lli"',
7943
+ __INT_LEAST64_MAX__: "9223372036854775807LL",
7944
+ __INT_LEAST64_TYPE__: "long long int",
7945
+ __INT_LEAST64_WIDTH__: "64",
7946
+ __INT_LEAST8_FMTd__: '"hhd"',
7947
+ __INT_LEAST8_FMTi__: '"hhi"',
7948
+ __INT_LEAST8_MAX__: "127",
7949
+ __INT_LEAST8_TYPE__: "signed char",
7950
+ __INT_LEAST8_WIDTH__: "8",
7951
+ __INT_MAX__: "2147483647",
7952
+ __INT_WIDTH__: "32",
7953
+ __LDBL_DECIMAL_DIG__: "17",
7954
+ __LDBL_DENORM_MIN__: "4.9406564584124654e-324L",
7955
+ __LDBL_DIG__: "15",
7956
+ __LDBL_EPSILON__: "2.2204460492503131e-16L",
7957
+ __LDBL_HAS_DENORM__: "1",
7958
+ __LDBL_HAS_INFINITY__: "1",
7959
+ __LDBL_HAS_QUIET_NAN__: "1",
7960
+ __LDBL_MANT_DIG__: "53",
7961
+ __LDBL_MAX_10_EXP__: "308",
7962
+ __LDBL_MAX_EXP__: "1024",
7963
+ __LDBL_MAX__: "1.7976931348623157e+308L",
7964
+ __LDBL_MIN_10_EXP__: "(-307)",
7965
+ __LDBL_MIN_EXP__: "(-1021)",
7966
+ __LDBL_MIN__: "2.2250738585072014e-308L",
7967
+ __LDBL_NORM_MAX__: "1.7976931348623157e+308L",
7968
+ __LITTLE_ENDIAN__: "1",
7969
+ __LLONG_WIDTH__: "64",
7970
+ __LONG_LONG_MAX__: "9223372036854775807LL",
7971
+ __LONG_MAX__: "9223372036854775807L",
7972
+ __LONG_WIDTH__: "64",
7973
+ __LP64__: "1",
7974
+ __MACH__: "1",
7975
+ __MEMORY_SCOPE_DEVICE: "1",
7976
+ __MEMORY_SCOPE_SINGLE: "4",
7977
+ __MEMORY_SCOPE_SYSTEM: "0",
7978
+ __MEMORY_SCOPE_WRKGRP: "2",
7979
+ __MEMORY_SCOPE_WVFRNT: "3",
7980
+ __NEXT_RUNTIME__: "1",
7981
+ __NO_INLINE__: "1",
7982
+ __NO_MATH_ERRNO__: "1",
7983
+ __OBJC2__: "1",
7984
+ __OBJC_BOOL_IS_BOOL: "1",
7985
+ __OBJC__: "1",
7986
+ __OPENCL_MEMORY_SCOPE_ALL_SVM_DEVICES: "3",
7987
+ __OPENCL_MEMORY_SCOPE_DEVICE: "2",
7988
+ __OPENCL_MEMORY_SCOPE_SUB_GROUP: "4",
7989
+ __OPENCL_MEMORY_SCOPE_WORK_GROUP: "1",
7990
+ __OPENCL_MEMORY_SCOPE_WORK_ITEM: "0",
7991
+ __ORDER_BIG_ENDIAN__: "4321",
7992
+ __ORDER_LITTLE_ENDIAN__: "1234",
7993
+ __ORDER_PDP_ENDIAN__: "3412",
7994
+ __PIC__: "2",
7995
+ __POINTER_WIDTH__: "64",
7996
+ __PRAGMA_REDEFINE_EXTNAME: "1",
7997
+ __PTRDIFF_FMTd__: '"ld"',
7998
+ __PTRDIFF_FMTi__: '"li"',
7999
+ __PTRDIFF_MAX__: "9223372036854775807L",
8000
+ __PTRDIFF_TYPE__: "long int",
8001
+ __PTRDIFF_WIDTH__: "64",
8002
+ __REGISTER_PREFIX__: null,
8003
+ __SCHAR_MAX__: "127",
8004
+ __SHRT_MAX__: "32767",
8005
+ __SHRT_WIDTH__: "16",
8006
+ __SIG_ATOMIC_MAX__: "2147483647",
8007
+ __SIG_ATOMIC_WIDTH__: "32",
8008
+ __SIZEOF_DOUBLE__: "8",
8009
+ __SIZEOF_FLOAT__: "4",
8010
+ __SIZEOF_INT128__: "16",
8011
+ __SIZEOF_INT__: "4",
8012
+ __SIZEOF_LONG_DOUBLE__: "8",
8013
+ __SIZEOF_LONG_LONG__: "8",
8014
+ __SIZEOF_LONG__: "8",
8015
+ __SIZEOF_POINTER__: "8",
8016
+ __SIZEOF_PTRDIFF_T__: "8",
8017
+ __SIZEOF_SHORT__: "2",
8018
+ __SIZEOF_SIZE_T__: "8",
8019
+ __SIZEOF_WCHAR_T__: "4",
8020
+ __SIZEOF_WINT_T__: "4",
8021
+ __SIZE_FMTX__: '"lX"',
8022
+ __SIZE_FMTo__: '"lo"',
8023
+ __SIZE_FMTu__: '"lu"',
8024
+ __SIZE_FMTx__: '"lx"',
8025
+ __SIZE_MAX__: "18446744073709551615UL",
8026
+ __SIZE_TYPE__: "long unsigned int",
8027
+ __SIZE_WIDTH__: "64",
8028
+ __SSP__: "1",
8029
+ __STDC_EMBED_EMPTY__: "2",
8030
+ __STDC_EMBED_FOUND__: "1",
8031
+ __STDC_EMBED_NOT_FOUND__: "0",
8032
+ __STDC_HOSTED__: "1",
8033
+ __STDC_NO_THREADS__: "1",
8034
+ __STDC_UTF_16__: "1",
8035
+ __STDC_UTF_32__: "1",
8036
+ __STDC_VERSION__: "201112L",
8037
+ __STDC__: "1",
8038
+ __UINT16_C: "(c) c",
8039
+ __UINT16_C_SUFFIX__: null,
8040
+ __UINT16_FMTX__: '"hX"',
8041
+ __UINT16_FMTo__: '"ho"',
8042
+ __UINT16_FMTu__: '"hu"',
8043
+ __UINT16_FMTx__: '"hx"',
8044
+ __UINT16_MAX__: "65535",
8045
+ __UINT16_TYPE__: "unsigned short",
8046
+ __UINT32_C: "(c) c##U",
8047
+ __UINT32_C_SUFFIX__: "U",
8048
+ __UINT32_FMTX__: '"X"',
8049
+ __UINT32_FMTo__: '"o"',
8050
+ __UINT32_FMTu__: '"u"',
8051
+ __UINT32_FMTx__: '"x"',
8052
+ __UINT32_MAX__: "4294967295U",
8053
+ __UINT32_TYPE__: "unsigned int",
8054
+ __UINT64_C: "(c) c##ULL",
8055
+ __UINT64_C_SUFFIX__: "ULL",
8056
+ __UINT64_FMTX__: '"llX"',
8057
+ __UINT64_FMTo__: '"llo"',
8058
+ __UINT64_FMTu__: '"llu"',
8059
+ __UINT64_FMTx__: '"llx"',
8060
+ __UINT64_MAX__: "18446744073709551615ULL",
8061
+ __UINT64_TYPE__: "long long unsigned int",
8062
+ __UINT8_C: "(c) c",
8063
+ __UINT8_C_SUFFIX__: null,
8064
+ __UINT8_FMTX__: '"hhX"',
8065
+ __UINT8_FMTo__: '"hho"',
8066
+ __UINT8_FMTu__: '"hhu"',
8067
+ __UINT8_FMTx__: '"hhx"',
8068
+ __UINT8_MAX__: "255",
8069
+ __UINT8_TYPE__: "unsigned char",
8070
+ __UINTMAX_C: "(c) c##UL",
8071
+ __UINTMAX_C_SUFFIX__: "UL",
8072
+ __UINTMAX_FMTX__: '"lX"',
8073
+ __UINTMAX_FMTo__: '"lo"',
8074
+ __UINTMAX_FMTu__: '"lu"',
8075
+ __UINTMAX_FMTx__: '"lx"',
8076
+ __UINTMAX_MAX__: "18446744073709551615UL",
8077
+ __UINTMAX_TYPE__: "long unsigned int",
8078
+ __UINTMAX_WIDTH__: "64",
8079
+ __UINTPTR_FMTX__: '"lX"',
8080
+ __UINTPTR_FMTo__: '"lo"',
8081
+ __UINTPTR_FMTu__: '"lu"',
8082
+ __UINTPTR_FMTx__: '"lx"',
8083
+ __UINTPTR_MAX__: "18446744073709551615UL",
8084
+ __UINTPTR_TYPE__: "long unsigned int",
8085
+ __UINTPTR_WIDTH__: "64",
8086
+ __UINT_FAST16_FMTX__: '"hX"',
8087
+ __UINT_FAST16_FMTo__: '"ho"',
8088
+ __UINT_FAST16_FMTu__: '"hu"',
8089
+ __UINT_FAST16_FMTx__: '"hx"',
8090
+ __UINT_FAST16_MAX__: "65535",
8091
+ __UINT_FAST16_TYPE__: "unsigned short",
8092
+ __UINT_FAST32_FMTX__: '"X"',
8093
+ __UINT_FAST32_FMTo__: '"o"',
8094
+ __UINT_FAST32_FMTu__: '"u"',
8095
+ __UINT_FAST32_FMTx__: '"x"',
8096
+ __UINT_FAST32_MAX__: "4294967295U",
8097
+ __UINT_FAST32_TYPE__: "unsigned int",
8098
+ __UINT_FAST64_FMTX__: '"llX"',
8099
+ __UINT_FAST64_FMTo__: '"llo"',
8100
+ __UINT_FAST64_FMTu__: '"llu"',
8101
+ __UINT_FAST64_FMTx__: '"llx"',
8102
+ __UINT_FAST64_MAX__: "18446744073709551615ULL",
8103
+ __UINT_FAST64_TYPE__: "long long unsigned int",
8104
+ __UINT_FAST8_FMTX__: '"hhX"',
8105
+ __UINT_FAST8_FMTo__: '"hho"',
8106
+ __UINT_FAST8_FMTu__: '"hhu"',
8107
+ __UINT_FAST8_FMTx__: '"hhx"',
8108
+ __UINT_FAST8_MAX__: "255",
8109
+ __UINT_FAST8_TYPE__: "unsigned char",
8110
+ __UINT_LEAST16_FMTX__: '"hX"',
8111
+ __UINT_LEAST16_FMTo__: '"ho"',
8112
+ __UINT_LEAST16_FMTu__: '"hu"',
8113
+ __UINT_LEAST16_FMTx__: '"hx"',
8114
+ __UINT_LEAST16_MAX__: "65535",
8115
+ __UINT_LEAST16_TYPE__: "unsigned short",
8116
+ __UINT_LEAST32_FMTX__: '"X"',
8117
+ __UINT_LEAST32_FMTo__: '"o"',
8118
+ __UINT_LEAST32_FMTu__: '"u"',
8119
+ __UINT_LEAST32_FMTx__: '"x"',
8120
+ __UINT_LEAST32_MAX__: "4294967295U",
8121
+ __UINT_LEAST32_TYPE__: "unsigned int",
8122
+ __UINT_LEAST64_FMTX__: '"llX"',
8123
+ __UINT_LEAST64_FMTo__: '"llo"',
8124
+ __UINT_LEAST64_FMTu__: '"llu"',
8125
+ __UINT_LEAST64_FMTx__: '"llx"',
8126
+ __UINT_LEAST64_MAX__: "18446744073709551615ULL",
8127
+ __UINT_LEAST64_TYPE__: "long long unsigned int",
8128
+ __UINT_LEAST8_FMTX__: '"hhX"',
8129
+ __UINT_LEAST8_FMTo__: '"hho"',
8130
+ __UINT_LEAST8_FMTu__: '"hhu"',
8131
+ __UINT_LEAST8_FMTx__: '"hhx"',
8132
+ __UINT_LEAST8_MAX__: "255",
8133
+ __UINT_LEAST8_TYPE__: "unsigned char",
8134
+ __USER_LABEL_PREFIX__: "_",
8135
+ __VERSION__: '"Clang 21.0.0"',
8136
+ __WCHAR_MAX__: "2147483647",
8137
+ __WCHAR_TYPE__: "int",
8138
+ __WCHAR_WIDTH__: "32",
8139
+ __WINT_MAX__: "2147483647",
8140
+ __WINT_TYPE__: "int",
8141
+ __WINT_WIDTH__: "32",
8142
+ __aarch64__: "1",
8143
+ __arm64: "1",
8144
+ __arm64__: "1",
8145
+ __autoreleasing: "__attribute__((objc_ownership(autoreleasing)))",
8146
+ __block: "__attribute__((__blocks__(byref)))",
8147
+ __clang__: "1",
8148
+ __clang_literal_encoding__: '"UTF-8"',
8149
+ __clang_major__: "21",
8150
+ __clang_minor__: "0",
8151
+ __clang_patchlevel__: "0",
8152
+ __clang_version__: '"21.0.0 "',
8153
+ __clang_wide_literal_encoding__: '"UTF-32"',
8154
+ __llvm__: "1",
8155
+ __nonnull: "_Nonnull",
8156
+ __null_unspecified: "_Null_unspecified",
8157
+ __nullable: "_Nullable",
8158
+ __pic__: "2",
8159
+ __strong: "__attribute__((objc_ownership(strong)))",
8160
+ __unsafe_unretained: "__attribute__((objc_ownership(none)))",
8161
+ __weak: "__attribute__((objc_ownership(weak)))"
8162
+ },
8163
+ "objective-c++": {
8164
+ IBAction: "void)__attribute__((ibaction)",
8165
+ IBInspectable: null,
8166
+ IBOutlet: "__attribute__((iboutlet))",
8167
+ IBOutletCollection: "(ClassName) __attribute__((iboutletcollection(ClassName)))",
8168
+ IB_DESIGNABLE: null,
8169
+ OBJC_NEW_PROPERTIES: "1",
8170
+ OBJC_ZEROCOST_EXCEPTIONS: "1",
8171
+ TARGET_IPHONE_SIMULATOR: "0",
8172
+ TARGET_OS_DRIVERKIT: "0",
8173
+ TARGET_OS_EMBEDDED: "1",
8174
+ TARGET_OS_FIRMWARE: "0",
8175
+ TARGET_OS_IOS: "1",
8176
+ TARGET_OS_IPHONE: "1",
8177
+ TARGET_OS_LINUX: "0",
8178
+ TARGET_OS_MAC: "1",
8179
+ TARGET_OS_MACCATALYST: "0",
8180
+ TARGET_OS_NANO: "0",
8181
+ TARGET_OS_OSX: "0",
8182
+ TARGET_OS_SIMULATOR: "0",
8183
+ TARGET_OS_TV: "0",
8184
+ TARGET_OS_UEFI: "0",
8185
+ TARGET_OS_UIKITFORMAC: "0",
8186
+ TARGET_OS_UNIX: "0",
8187
+ TARGET_OS_VISION: "0",
8188
+ TARGET_OS_WATCH: "0",
8189
+ TARGET_OS_WIN32: "0",
8190
+ TARGET_OS_WINDOWS: "0",
8191
+ _LP64: "1",
8192
+ __AARCH64EL__: "1",
8193
+ __AARCH64_CMODEL_SMALL__: "1",
8194
+ __AARCH64_SIMD__: "1",
8195
+ __APPLE_CC__: "6000",
8196
+ __APPLE__: "1",
8197
+ __ARM64_ARCH_8__: "1",
8198
+ __ARM_64BIT_STATE: "1",
8199
+ __ARM_ACLE: "202420",
8200
+ __ARM_ACLE_VERSION: "(year,quarter,patch) (100 * (year) + 10 * (quarter) + (patch))",
8201
+ __ARM_ALIGN_MAX_STACK_PWR: "4",
8202
+ __ARM_ARCH: "8",
8203
+ __ARM_ARCH_ISA_A64: "1",
8204
+ __ARM_ARCH_PROFILE: "'A'",
8205
+ __ARM_FEATURE_AES: "1",
8206
+ __ARM_FEATURE_CLZ: "1",
8207
+ __ARM_FEATURE_CRYPTO: "1",
8208
+ __ARM_FEATURE_DIRECTED_ROUNDING: "1",
8209
+ __ARM_FEATURE_DIV: "1",
8210
+ __ARM_FEATURE_FMA: "1",
8211
+ __ARM_FEATURE_IDIV: "1",
8212
+ __ARM_FEATURE_LDREX: "0xF",
8213
+ __ARM_FEATURE_NUMERIC_MAXMIN: "1",
8214
+ __ARM_FEATURE_SHA2: "1",
8215
+ __ARM_FEATURE_UNALIGNED: "1",
8216
+ __ARM_FP: "0xE",
8217
+ __ARM_FP16_ARGS: "1",
8218
+ __ARM_FP16_FORMAT_IEEE: "1",
8219
+ __ARM_NEON: "1",
8220
+ __ARM_NEON_FP: "0xE",
8221
+ __ARM_NEON_SVE_BRIDGE: "1",
8222
+ __ARM_NEON__: "1",
8223
+ __ARM_PCS_AAPCS64: "1",
8224
+ __ARM_SIZEOF_MINIMAL_ENUM: "4",
8225
+ __ARM_SIZEOF_WCHAR_T: "4",
8226
+ __ARM_STATE_ZA: "1",
8227
+ __ARM_STATE_ZT0: "1",
8228
+ __ATOMIC_ACQUIRE: "2",
8229
+ __ATOMIC_ACQ_REL: "4",
8230
+ __ATOMIC_CONSUME: "1",
8231
+ __ATOMIC_RELAXED: "0",
8232
+ __ATOMIC_RELEASE: "3",
8233
+ __ATOMIC_SEQ_CST: "5",
8234
+ __BIGGEST_ALIGNMENT__: "8",
8235
+ __BITINT_MAXWIDTH__: "128",
8236
+ __BLOCKS__: "1",
8237
+ __BOOL_WIDTH__: "1",
8238
+ __BYTE_ORDER__: "__ORDER_LITTLE_ENDIAN__",
8239
+ __CHAR16_TYPE__: "unsigned short",
8240
+ __CHAR32_TYPE__: "unsigned int",
8241
+ __CHAR_BIT__: "8",
8242
+ __CLANG_ATOMIC_BOOL_LOCK_FREE: "2",
8243
+ __CLANG_ATOMIC_CHAR16_T_LOCK_FREE: "2",
8244
+ __CLANG_ATOMIC_CHAR32_T_LOCK_FREE: "2",
8245
+ __CLANG_ATOMIC_CHAR_LOCK_FREE: "2",
8246
+ __CLANG_ATOMIC_INT_LOCK_FREE: "2",
8247
+ __CLANG_ATOMIC_LLONG_LOCK_FREE: "2",
8248
+ __CLANG_ATOMIC_LONG_LOCK_FREE: "2",
8249
+ __CLANG_ATOMIC_POINTER_LOCK_FREE: "2",
8250
+ __CLANG_ATOMIC_SHORT_LOCK_FREE: "2",
8251
+ __CLANG_ATOMIC_WCHAR_T_LOCK_FREE: "2",
8252
+ __CONSTANT_CFSTRINGS__: "1",
8253
+ __DBL_DECIMAL_DIG__: "17",
8254
+ __DBL_DENORM_MIN__: "4.9406564584124654e-324",
8255
+ __DBL_DIG__: "15",
8256
+ __DBL_EPSILON__: "2.2204460492503131e-16",
8257
+ __DBL_HAS_DENORM__: "1",
8258
+ __DBL_HAS_INFINITY__: "1",
8259
+ __DBL_HAS_QUIET_NAN__: "1",
8260
+ __DBL_MANT_DIG__: "53",
8261
+ __DBL_MAX_10_EXP__: "308",
8262
+ __DBL_MAX_EXP__: "1024",
8263
+ __DBL_MAX__: "1.7976931348623157e+308",
8264
+ __DBL_MIN_10_EXP__: "(-307)",
8265
+ __DBL_MIN_EXP__: "(-1021)",
8266
+ __DBL_MIN__: "2.2250738585072014e-308",
8267
+ __DBL_NORM_MAX__: "1.7976931348623157e+308",
8268
+ __DECIMAL_DIG__: "__LDBL_DECIMAL_DIG__",
8269
+ __DEPRECATED: "1",
8270
+ __DYNAMIC__: "1",
8271
+ __ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__: "70000",
8272
+ __ENVIRONMENT_OS_VERSION_MIN_REQUIRED__: "70000",
8273
+ __EXCEPTIONS: "1",
8274
+ __FINITE_MATH_ONLY__: "0",
8275
+ __FLT16_DECIMAL_DIG__: "5",
8276
+ __FLT16_DENORM_MIN__: "5.9604644775390625e-8F16",
8277
+ __FLT16_DIG__: "3",
8278
+ __FLT16_EPSILON__: "9.765625e-4F16",
8279
+ __FLT16_HAS_DENORM__: "1",
8280
+ __FLT16_HAS_INFINITY__: "1",
8281
+ __FLT16_HAS_QUIET_NAN__: "1",
8282
+ __FLT16_MANT_DIG__: "11",
8283
+ __FLT16_MAX_10_EXP__: "4",
8284
+ __FLT16_MAX_EXP__: "16",
8285
+ __FLT16_MAX__: "6.5504e+4F16",
8286
+ __FLT16_MIN_10_EXP__: "(-4)",
8287
+ __FLT16_MIN_EXP__: "(-13)",
8288
+ __FLT16_MIN__: "6.103515625e-5F16",
8289
+ __FLT16_NORM_MAX__: "6.5504e+4F16",
8290
+ __FLT_DECIMAL_DIG__: "9",
8291
+ __FLT_DENORM_MIN__: "1.40129846e-45F",
8292
+ __FLT_DIG__: "6",
8293
+ __FLT_EPSILON__: "1.19209290e-7F",
8294
+ __FLT_HAS_DENORM__: "1",
8295
+ __FLT_HAS_INFINITY__: "1",
8296
+ __FLT_HAS_QUIET_NAN__: "1",
8297
+ __FLT_MANT_DIG__: "24",
8298
+ __FLT_MAX_10_EXP__: "38",
8299
+ __FLT_MAX_EXP__: "128",
8300
+ __FLT_MAX__: "3.40282347e+38F",
8301
+ __FLT_MIN_10_EXP__: "(-37)",
8302
+ __FLT_MIN_EXP__: "(-125)",
8303
+ __FLT_MIN__: "1.17549435e-38F",
8304
+ __FLT_NORM_MAX__: "3.40282347e+38F",
8305
+ __FLT_RADIX__: "2",
8306
+ __FPCLASS_NEGINF: "0x0004",
8307
+ __FPCLASS_NEGNORMAL: "0x0008",
8308
+ __FPCLASS_NEGSUBNORMAL: "0x0010",
8309
+ __FPCLASS_NEGZERO: "0x0020",
8310
+ __FPCLASS_POSINF: "0x0200",
8311
+ __FPCLASS_POSNORMAL: "0x0100",
8312
+ __FPCLASS_POSSUBNORMAL: "0x0080",
8313
+ __FPCLASS_POSZERO: "0x0040",
8314
+ __FPCLASS_QNAN: "0x0002",
8315
+ __FPCLASS_SNAN: "0x0001",
8316
+ __FP_FAST_FMA: "1",
8317
+ __FP_FAST_FMAF: "1",
8318
+ __FUNCTION_MULTI_VERSIONING_SUPPORT_LEVEL: "202430",
8319
+ __GCC_ASM_FLAG_OUTPUTS__: "1",
8320
+ __GCC_ATOMIC_BOOL_LOCK_FREE: "2",
8321
+ __GCC_ATOMIC_CHAR16_T_LOCK_FREE: "2",
8322
+ __GCC_ATOMIC_CHAR32_T_LOCK_FREE: "2",
8323
+ __GCC_ATOMIC_CHAR_LOCK_FREE: "2",
8324
+ __GCC_ATOMIC_INT_LOCK_FREE: "2",
8325
+ __GCC_ATOMIC_LLONG_LOCK_FREE: "2",
8326
+ __GCC_ATOMIC_LONG_LOCK_FREE: "2",
8327
+ __GCC_ATOMIC_POINTER_LOCK_FREE: "2",
8328
+ __GCC_ATOMIC_SHORT_LOCK_FREE: "2",
8329
+ __GCC_ATOMIC_TEST_AND_SET_TRUEVAL: "1",
8330
+ __GCC_ATOMIC_WCHAR_T_LOCK_FREE: "2",
8331
+ __GCC_CONSTRUCTIVE_SIZE: "64",
8332
+ __GCC_DESTRUCTIVE_SIZE: "256",
8333
+ __GCC_HAVE_DWARF2_CFI_ASM: "1",
8334
+ __GCC_HAVE_SYNC_COMPARE_AND_SWAP_1: "1",
8335
+ __GCC_HAVE_SYNC_COMPARE_AND_SWAP_16: "1",
8336
+ __GCC_HAVE_SYNC_COMPARE_AND_SWAP_2: "1",
8337
+ __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4: "1",
8338
+ __GCC_HAVE_SYNC_COMPARE_AND_SWAP_8: "1",
8339
+ __GLIBCXX_BITSIZE_INT_N_0: "128",
8340
+ __GLIBCXX_TYPE_INT_N_0: "__int128",
8341
+ __GNUC_GNU_INLINE__: "1",
8342
+ __GNUC_MINOR__: "2",
8343
+ __GNUC_PATCHLEVEL__: "1",
8344
+ __GNUC__: "4",
8345
+ __GNUG__: "4",
8346
+ __GXX_ABI_VERSION: "1002",
8347
+ __GXX_EXPERIMENTAL_CXX0X__: "1",
8348
+ __GXX_RTTI: "1",
8349
+ __GXX_WEAK__: "1",
8350
+ __HAVE_FUNCTION_MULTI_VERSIONING: "1",
8351
+ __INT16_C: "(c) c",
8352
+ __INT16_C_SUFFIX__: null,
8353
+ __INT16_FMTd__: '"hd"',
8354
+ __INT16_FMTi__: '"hi"',
8355
+ __INT16_MAX__: "32767",
8356
+ __INT16_TYPE__: "short",
8357
+ __INT32_C: "(c) c",
8358
+ __INT32_C_SUFFIX__: null,
8359
+ __INT32_FMTd__: '"d"',
8360
+ __INT32_FMTi__: '"i"',
8361
+ __INT32_MAX__: "2147483647",
8362
+ __INT32_TYPE__: "int",
8363
+ __INT64_C: "(c) c##LL",
8364
+ __INT64_C_SUFFIX__: "LL",
8365
+ __INT64_FMTd__: '"lld"',
8366
+ __INT64_FMTi__: '"lli"',
8367
+ __INT64_MAX__: "9223372036854775807LL",
8368
+ __INT64_TYPE__: "long long int",
8369
+ __INT8_C: "(c) c",
8370
+ __INT8_C_SUFFIX__: null,
8371
+ __INT8_FMTd__: '"hhd"',
8372
+ __INT8_FMTi__: '"hhi"',
8373
+ __INT8_MAX__: "127",
8374
+ __INT8_TYPE__: "signed char",
8375
+ __INTMAX_C: "(c) c##L",
8376
+ __INTMAX_C_SUFFIX__: "L",
8377
+ __INTMAX_FMTd__: '"ld"',
8378
+ __INTMAX_FMTi__: '"li"',
8379
+ __INTMAX_MAX__: "9223372036854775807L",
8380
+ __INTMAX_TYPE__: "long int",
8381
+ __INTMAX_WIDTH__: "64",
8382
+ __INTPTR_FMTd__: '"ld"',
8383
+ __INTPTR_FMTi__: '"li"',
8384
+ __INTPTR_MAX__: "9223372036854775807L",
8385
+ __INTPTR_TYPE__: "long int",
8386
+ __INTPTR_WIDTH__: "64",
8387
+ __INT_FAST16_FMTd__: '"hd"',
8388
+ __INT_FAST16_FMTi__: '"hi"',
8389
+ __INT_FAST16_MAX__: "32767",
8390
+ __INT_FAST16_TYPE__: "short",
8391
+ __INT_FAST16_WIDTH__: "16",
8392
+ __INT_FAST32_FMTd__: '"d"',
8393
+ __INT_FAST32_FMTi__: '"i"',
8394
+ __INT_FAST32_MAX__: "2147483647",
8395
+ __INT_FAST32_TYPE__: "int",
8396
+ __INT_FAST32_WIDTH__: "32",
8397
+ __INT_FAST64_FMTd__: '"lld"',
8398
+ __INT_FAST64_FMTi__: '"lli"',
8399
+ __INT_FAST64_MAX__: "9223372036854775807LL",
8400
+ __INT_FAST64_TYPE__: "long long int",
8401
+ __INT_FAST64_WIDTH__: "64",
8402
+ __INT_FAST8_FMTd__: '"hhd"',
8403
+ __INT_FAST8_FMTi__: '"hhi"',
8404
+ __INT_FAST8_MAX__: "127",
8405
+ __INT_FAST8_TYPE__: "signed char",
8406
+ __INT_FAST8_WIDTH__: "8",
8407
+ __INT_LEAST16_FMTd__: '"hd"',
8408
+ __INT_LEAST16_FMTi__: '"hi"',
8409
+ __INT_LEAST16_MAX__: "32767",
8410
+ __INT_LEAST16_TYPE__: "short",
8411
+ __INT_LEAST16_WIDTH__: "16",
8412
+ __INT_LEAST32_FMTd__: '"d"',
8413
+ __INT_LEAST32_FMTi__: '"i"',
8414
+ __INT_LEAST32_MAX__: "2147483647",
8415
+ __INT_LEAST32_TYPE__: "int",
8416
+ __INT_LEAST32_WIDTH__: "32",
8417
+ __INT_LEAST64_FMTd__: '"lld"',
8418
+ __INT_LEAST64_FMTi__: '"lli"',
8419
+ __INT_LEAST64_MAX__: "9223372036854775807LL",
8420
+ __INT_LEAST64_TYPE__: "long long int",
8421
+ __INT_LEAST64_WIDTH__: "64",
8422
+ __INT_LEAST8_FMTd__: '"hhd"',
8423
+ __INT_LEAST8_FMTi__: '"hhi"',
8424
+ __INT_LEAST8_MAX__: "127",
8425
+ __INT_LEAST8_TYPE__: "signed char",
8426
+ __INT_LEAST8_WIDTH__: "8",
8427
+ __INT_MAX__: "2147483647",
8428
+ __INT_WIDTH__: "32",
8429
+ __LDBL_DECIMAL_DIG__: "17",
8430
+ __LDBL_DENORM_MIN__: "4.9406564584124654e-324L",
8431
+ __LDBL_DIG__: "15",
8432
+ __LDBL_EPSILON__: "2.2204460492503131e-16L",
8433
+ __LDBL_HAS_DENORM__: "1",
8434
+ __LDBL_HAS_INFINITY__: "1",
8435
+ __LDBL_HAS_QUIET_NAN__: "1",
8436
+ __LDBL_MANT_DIG__: "53",
8437
+ __LDBL_MAX_10_EXP__: "308",
8438
+ __LDBL_MAX_EXP__: "1024",
8439
+ __LDBL_MAX__: "1.7976931348623157e+308L",
8440
+ __LDBL_MIN_10_EXP__: "(-307)",
8441
+ __LDBL_MIN_EXP__: "(-1021)",
8442
+ __LDBL_MIN__: "2.2250738585072014e-308L",
8443
+ __LDBL_NORM_MAX__: "1.7976931348623157e+308L",
8444
+ __LITTLE_ENDIAN__: "1",
8445
+ __LLONG_WIDTH__: "64",
8446
+ __LONG_LONG_MAX__: "9223372036854775807LL",
8447
+ __LONG_MAX__: "9223372036854775807L",
8448
+ __LONG_WIDTH__: "64",
8449
+ __LP64__: "1",
8450
+ __MACH__: "1",
8451
+ __MEMORY_SCOPE_DEVICE: "1",
8452
+ __MEMORY_SCOPE_SINGLE: "4",
8453
+ __MEMORY_SCOPE_SYSTEM: "0",
8454
+ __MEMORY_SCOPE_WRKGRP: "2",
8455
+ __MEMORY_SCOPE_WVFRNT: "3",
8456
+ __NEXT_RUNTIME__: "1",
8457
+ __NO_INLINE__: "1",
8458
+ __NO_MATH_ERRNO__: "1",
8459
+ __OBJC2__: "1",
8460
+ __OBJC_BOOL_IS_BOOL: "1",
8461
+ __OBJC__: "1",
8462
+ __OPENCL_MEMORY_SCOPE_ALL_SVM_DEVICES: "3",
8463
+ __OPENCL_MEMORY_SCOPE_DEVICE: "2",
8464
+ __OPENCL_MEMORY_SCOPE_SUB_GROUP: "4",
8465
+ __OPENCL_MEMORY_SCOPE_WORK_GROUP: "1",
8466
+ __OPENCL_MEMORY_SCOPE_WORK_ITEM: "0",
8467
+ __ORDER_BIG_ENDIAN__: "4321",
8468
+ __ORDER_LITTLE_ENDIAN__: "1234",
8469
+ __ORDER_PDP_ENDIAN__: "3412",
8470
+ __PIC__: "2",
8471
+ __POINTER_WIDTH__: "64",
8472
+ __PRAGMA_REDEFINE_EXTNAME: "1",
8473
+ __PTRDIFF_FMTd__: '"ld"',
8474
+ __PTRDIFF_FMTi__: '"li"',
8475
+ __PTRDIFF_MAX__: "9223372036854775807L",
8476
+ __PTRDIFF_TYPE__: "long int",
8477
+ __PTRDIFF_WIDTH__: "64",
8478
+ __REGISTER_PREFIX__: null,
8479
+ __SCHAR_MAX__: "127",
8480
+ __SHRT_MAX__: "32767",
8481
+ __SHRT_WIDTH__: "16",
8482
+ __SIG_ATOMIC_MAX__: "2147483647",
8483
+ __SIG_ATOMIC_WIDTH__: "32",
8484
+ __SIZEOF_DOUBLE__: "8",
8485
+ __SIZEOF_FLOAT__: "4",
8486
+ __SIZEOF_INT128__: "16",
8487
+ __SIZEOF_INT__: "4",
8488
+ __SIZEOF_LONG_DOUBLE__: "8",
8489
+ __SIZEOF_LONG_LONG__: "8",
8490
+ __SIZEOF_LONG__: "8",
8491
+ __SIZEOF_POINTER__: "8",
8492
+ __SIZEOF_PTRDIFF_T__: "8",
8493
+ __SIZEOF_SHORT__: "2",
8494
+ __SIZEOF_SIZE_T__: "8",
8495
+ __SIZEOF_WCHAR_T__: "4",
8496
+ __SIZEOF_WINT_T__: "4",
8497
+ __SIZE_FMTX__: '"lX"',
8498
+ __SIZE_FMTo__: '"lo"',
8499
+ __SIZE_FMTu__: '"lu"',
8500
+ __SIZE_FMTx__: '"lx"',
8501
+ __SIZE_MAX__: "18446744073709551615UL",
8502
+ __SIZE_TYPE__: "long unsigned int",
8503
+ __SIZE_WIDTH__: "64",
8504
+ __SSP__: "1",
8505
+ __STDCPP_DEFAULT_NEW_ALIGNMENT__: "16UL",
8506
+ __STDCPP_THREADS__: "1",
8507
+ __STDC_EMBED_EMPTY__: "2",
8508
+ __STDC_EMBED_FOUND__: "1",
8509
+ __STDC_EMBED_NOT_FOUND__: "0",
8510
+ __STDC_HOSTED__: "1",
8511
+ __STDC_NO_THREADS__: "1",
8512
+ __STDC_UTF_16__: "1",
8513
+ __STDC_UTF_32__: "1",
8514
+ __STDC__: "1",
8515
+ __UINT16_C: "(c) c",
8516
+ __UINT16_C_SUFFIX__: null,
8517
+ __UINT16_FMTX__: '"hX"',
8518
+ __UINT16_FMTo__: '"ho"',
8519
+ __UINT16_FMTu__: '"hu"',
8520
+ __UINT16_FMTx__: '"hx"',
8521
+ __UINT16_MAX__: "65535",
8522
+ __UINT16_TYPE__: "unsigned short",
8523
+ __UINT32_C: "(c) c##U",
8524
+ __UINT32_C_SUFFIX__: "U",
8525
+ __UINT32_FMTX__: '"X"',
8526
+ __UINT32_FMTo__: '"o"',
8527
+ __UINT32_FMTu__: '"u"',
8528
+ __UINT32_FMTx__: '"x"',
8529
+ __UINT32_MAX__: "4294967295U",
8530
+ __UINT32_TYPE__: "unsigned int",
8531
+ __UINT64_C: "(c) c##ULL",
8532
+ __UINT64_C_SUFFIX__: "ULL",
8533
+ __UINT64_FMTX__: '"llX"',
8534
+ __UINT64_FMTo__: '"llo"',
8535
+ __UINT64_FMTu__: '"llu"',
8536
+ __UINT64_FMTx__: '"llx"',
8537
+ __UINT64_MAX__: "18446744073709551615ULL",
8538
+ __UINT64_TYPE__: "long long unsigned int",
8539
+ __UINT8_C: "(c) c",
8540
+ __UINT8_C_SUFFIX__: null,
8541
+ __UINT8_FMTX__: '"hhX"',
8542
+ __UINT8_FMTo__: '"hho"',
8543
+ __UINT8_FMTu__: '"hhu"',
8544
+ __UINT8_FMTx__: '"hhx"',
8545
+ __UINT8_MAX__: "255",
8546
+ __UINT8_TYPE__: "unsigned char",
8547
+ __UINTMAX_C: "(c) c##UL",
8548
+ __UINTMAX_C_SUFFIX__: "UL",
8549
+ __UINTMAX_FMTX__: '"lX"',
8550
+ __UINTMAX_FMTo__: '"lo"',
8551
+ __UINTMAX_FMTu__: '"lu"',
8552
+ __UINTMAX_FMTx__: '"lx"',
8553
+ __UINTMAX_MAX__: "18446744073709551615UL",
8554
+ __UINTMAX_TYPE__: "long unsigned int",
8555
+ __UINTMAX_WIDTH__: "64",
8556
+ __UINTPTR_FMTX__: '"lX"',
8557
+ __UINTPTR_FMTo__: '"lo"',
8558
+ __UINTPTR_FMTu__: '"lu"',
8559
+ __UINTPTR_FMTx__: '"lx"',
8560
+ __UINTPTR_MAX__: "18446744073709551615UL",
8561
+ __UINTPTR_TYPE__: "long unsigned int",
8562
+ __UINTPTR_WIDTH__: "64",
8563
+ __UINT_FAST16_FMTX__: '"hX"',
8564
+ __UINT_FAST16_FMTo__: '"ho"',
8565
+ __UINT_FAST16_FMTu__: '"hu"',
8566
+ __UINT_FAST16_FMTx__: '"hx"',
8567
+ __UINT_FAST16_MAX__: "65535",
8568
+ __UINT_FAST16_TYPE__: "unsigned short",
8569
+ __UINT_FAST32_FMTX__: '"X"',
8570
+ __UINT_FAST32_FMTo__: '"o"',
8571
+ __UINT_FAST32_FMTu__: '"u"',
8572
+ __UINT_FAST32_FMTx__: '"x"',
8573
+ __UINT_FAST32_MAX__: "4294967295U",
8574
+ __UINT_FAST32_TYPE__: "unsigned int",
8575
+ __UINT_FAST64_FMTX__: '"llX"',
8576
+ __UINT_FAST64_FMTo__: '"llo"',
8577
+ __UINT_FAST64_FMTu__: '"llu"',
8578
+ __UINT_FAST64_FMTx__: '"llx"',
8579
+ __UINT_FAST64_MAX__: "18446744073709551615ULL",
8580
+ __UINT_FAST64_TYPE__: "long long unsigned int",
8581
+ __UINT_FAST8_FMTX__: '"hhX"',
8582
+ __UINT_FAST8_FMTo__: '"hho"',
8583
+ __UINT_FAST8_FMTu__: '"hhu"',
8584
+ __UINT_FAST8_FMTx__: '"hhx"',
8585
+ __UINT_FAST8_MAX__: "255",
8586
+ __UINT_FAST8_TYPE__: "unsigned char",
8587
+ __UINT_LEAST16_FMTX__: '"hX"',
8588
+ __UINT_LEAST16_FMTo__: '"ho"',
8589
+ __UINT_LEAST16_FMTu__: '"hu"',
8590
+ __UINT_LEAST16_FMTx__: '"hx"',
8591
+ __UINT_LEAST16_MAX__: "65535",
8592
+ __UINT_LEAST16_TYPE__: "unsigned short",
8593
+ __UINT_LEAST32_FMTX__: '"X"',
8594
+ __UINT_LEAST32_FMTo__: '"o"',
8595
+ __UINT_LEAST32_FMTu__: '"u"',
8596
+ __UINT_LEAST32_FMTx__: '"x"',
8597
+ __UINT_LEAST32_MAX__: "4294967295U",
8598
+ __UINT_LEAST32_TYPE__: "unsigned int",
8599
+ __UINT_LEAST64_FMTX__: '"llX"',
8600
+ __UINT_LEAST64_FMTo__: '"llo"',
8601
+ __UINT_LEAST64_FMTu__: '"llu"',
8602
+ __UINT_LEAST64_FMTx__: '"llx"',
8603
+ __UINT_LEAST64_MAX__: "18446744073709551615ULL",
8604
+ __UINT_LEAST64_TYPE__: "long long unsigned int",
8605
+ __UINT_LEAST8_FMTX__: '"hhX"',
8606
+ __UINT_LEAST8_FMTo__: '"hho"',
8607
+ __UINT_LEAST8_FMTu__: '"hhu"',
8608
+ __UINT_LEAST8_FMTx__: '"hhx"',
8609
+ __UINT_LEAST8_MAX__: "255",
8610
+ __UINT_LEAST8_TYPE__: "unsigned char",
8611
+ __USER_LABEL_PREFIX__: "_",
8612
+ __VERSION__: '"Clang 21.0.0"',
8613
+ __WCHAR_MAX__: "2147483647",
8614
+ __WCHAR_TYPE__: "int",
8615
+ __WCHAR_WIDTH__: "32",
8616
+ __WINT_MAX__: "2147483647",
8617
+ __WINT_TYPE__: "int",
8618
+ __WINT_WIDTH__: "32",
8619
+ __aarch64__: "1",
8620
+ __arm64: "1",
8621
+ __arm64__: "1",
8622
+ __autoreleasing: "__attribute__((objc_ownership(autoreleasing)))",
8623
+ __block: "__attribute__((__blocks__(byref)))",
8624
+ __clang__: "1",
8625
+ __clang_literal_encoding__: '"UTF-8"',
8626
+ __clang_major__: "21",
8627
+ __clang_minor__: "0",
8628
+ __clang_patchlevel__: "0",
8629
+ __clang_version__: '"21.0.0 "',
8630
+ __clang_wide_literal_encoding__: '"UTF-32"',
8631
+ __cplusplus: "201703L",
8632
+ __cpp_aggregate_bases: "201603L",
8633
+ __cpp_aggregate_nsdmi: "201304L",
8634
+ __cpp_alias_templates: "200704L",
8635
+ __cpp_attributes: "200809L",
8636
+ __cpp_binary_literals: "201304L",
8637
+ __cpp_capture_star_this: "201603L",
8638
+ __cpp_constexpr: "201603L",
8639
+ __cpp_constexpr_in_decltype: "201711L",
8640
+ __cpp_decltype: "200707L",
8641
+ __cpp_decltype_auto: "201304L",
8642
+ __cpp_deduction_guides: "201703L",
8643
+ __cpp_delegating_constructors: "200604L",
8644
+ __cpp_deleted_function: "202403L",
8645
+ __cpp_digit_separators: "201309L",
8646
+ __cpp_enumerator_attributes: "201411L",
8647
+ __cpp_exceptions: "199711L",
8648
+ __cpp_fold_expressions: "201603L",
8649
+ __cpp_generic_lambdas: "201304L",
8650
+ __cpp_guaranteed_copy_elision: "201606L",
8651
+ __cpp_hex_float: "201603L",
8652
+ __cpp_if_constexpr: "201606L",
8653
+ __cpp_impl_destroying_delete: "201806L",
8654
+ __cpp_inheriting_constructors: "201511L",
8655
+ __cpp_init_captures: "201304L",
8656
+ __cpp_initializer_lists: "200806L",
8657
+ __cpp_inline_variables: "201606L",
8658
+ __cpp_lambdas: "200907L",
8659
+ __cpp_named_character_escapes: "202207L",
8660
+ __cpp_namespace_attributes: "201411L",
8661
+ __cpp_nested_namespace_definitions: "201411L",
8662
+ __cpp_noexcept_function_type: "201510L",
8663
+ __cpp_nontype_template_args: "201411L",
8664
+ __cpp_nontype_template_parameter_auto: "201606L",
8665
+ __cpp_nsdmi: "200809L",
8666
+ __cpp_pack_indexing: "202311L",
8667
+ __cpp_placeholder_variables: "202306L",
8668
+ __cpp_range_based_for: "201603L",
8669
+ __cpp_raw_strings: "200710L",
8670
+ __cpp_ref_qualifiers: "200710L",
8671
+ __cpp_return_type_deduction: "201304L",
8672
+ __cpp_rtti: "199711L",
8673
+ __cpp_rvalue_references: "200610L",
8674
+ __cpp_static_assert: "202306L",
8675
+ __cpp_static_call_operator: "202207L",
8676
+ __cpp_structured_bindings: "202411L",
8677
+ __cpp_template_auto: "201606L",
8678
+ __cpp_template_template_args: "201611L",
8679
+ __cpp_threadsafe_static_init: "200806L",
8680
+ __cpp_unicode_characters: "200704L",
8681
+ __cpp_unicode_literals: "200710L",
8682
+ __cpp_user_defined_literals: "200809L",
8683
+ __cpp_variable_templates: "201304L",
8684
+ __cpp_variadic_friend: "202403L",
8685
+ __cpp_variadic_templates: "200704L",
8686
+ __cpp_variadic_using: "201611L",
8687
+ __llvm__: "1",
8688
+ __nonnull: "_Nonnull",
8689
+ __null_unspecified: "_Null_unspecified",
8690
+ __nullable: "_Nullable",
8691
+ __pic__: "2",
8692
+ __private_extern__: "extern",
8693
+ __strong: "__attribute__((objc_ownership(strong)))",
8694
+ __unsafe_unretained: "__attribute__((objc_ownership(none)))",
8695
+ __weak: "__attribute__((objc_ownership(weak)))"
8696
+ }
8697
+ }
8698
+ };
8699
+
6707
8700
  // src/home-paths.ts
6708
8701
  var import_node_os = require("node:os");
6709
8702
  var import_node_path = __toESM(require("node:path"), 1);
@@ -7410,9 +9403,9 @@ var EXCERPT = /^(\s*)(\d+)( \| )(.*)$/;
7410
9403
  var MARKER = /^(\s*)( \| )(.*)$/;
7411
9404
  function designTimeDiagnostic(output, files) {
7412
9405
  const rewritten = /* @__PURE__ */ new Map();
7413
- const linesOf = (path10) => {
9406
+ const linesOf = (path11) => {
7414
9407
  const file = Object.keys(files).find(
7415
- (name2) => name2.endsWith(".swift") && (path10 === name2 || path10.endsWith(`/${name2}`))
9408
+ (name2) => name2.endsWith(".swift") && (path11 === name2 || path11.endsWith(`/${name2}`))
7416
9409
  );
7417
9410
  if (file === void 0) return null;
7418
9411
  let lines = rewritten.get(file);
@@ -7523,20 +9516,20 @@ function swiftSdkOptions() {
7523
9516
  }
7524
9517
  return [];
7525
9518
  }
7526
- var SWIFT_HOST_COMPILER_RELEASE = "swift-6.4.0-RELEASE-custom-0d775d32d7c74eae";
7527
- var SWIFT_HOST_COMPILER_ID = "0d775d32d7c74eae";
9519
+ var SWIFT_HOST_COMPILER_RELEASE = "swift-6.4.0-RELEASE-custom-8be2e4a7a393b003";
9520
+ var SWIFT_HOST_COMPILER_ID = "8be2e4a7a393b003";
7528
9521
  var compilerArchives = {
7529
9522
  "darwin-arm64": {
7530
- checksum: "957e85486f92327ee5cf8d3c5bb9336d17ab80145c87645c637c49130a50477a",
7531
- manifest: "c63e2f81694e8d8ad046d10c71d0638dbae4e5a36601294ed670988d1cb5b6f1"
9523
+ checksum: "88d69b7ac912962adaadce9fdb2c57fe07cd19e4d8158088e0acbd247496ca6d",
9524
+ manifest: "70d5e2be8c959eb5dd1d9b576e6c209e1f58bfb9089f90c38c2d7e087759f0b3"
7532
9525
  },
7533
9526
  "linux-x64": {
7534
- checksum: "6302230fb126b79c9af5fc2bc0208a936bb573c343da7ae949c5c1687e761cd2",
7535
- manifest: "31b507a6a8648a2266a187b9fed092e29a63cae99d57c5defdf2e82a7cbbc113"
9527
+ checksum: "7c42ded03742d16816e64f8ae8fca478aaaff450d22ab3d698daf78c010854b2",
9528
+ manifest: "90cfb09c5a0ba8c119066787cf47244a45bf3cda68dce94c6b1a16337b9b91bd"
7536
9529
  },
7537
9530
  "linux-arm64": {
7538
- checksum: "9b40d39ea5ba82fd9a417868f0a449f5e98e37cf83acaac9cedd3a8b8d91a218",
7539
- manifest: "fe07a29d4f4374cad47b29de70e90aa2e3b7664e08c8b53d304585e65637da24"
9531
+ checksum: "f9f1d96fb1a6325d3bb30ab12a75fc06e4e8535aab58a91581e03f3d91f68fa6",
9532
+ manifest: "f988181dce795f6c8a6d4a8d86f7b61768f23a743b4e7bea76e64862ef328ad6"
7540
9533
  }
7541
9534
  };
7542
9535
  function swiftHostCompilerArchive(release, host2 = `${process.platform}-${process.arch}`) {
@@ -9116,12 +11109,65 @@ for (const [file, text3] of tree) {
9116
11109
  }
9117
11110
 
9118
11111
  // src/swift-objc-standin.ts
9119
- var import_node_child_process5 = require("node:child_process");
11112
+ var import_node_child_process6 = require("node:child_process");
9120
11113
  var import_node_crypto5 = require("node:crypto");
9121
11114
  var import_node_fs5 = __toESM(require("node:fs"), 1);
11115
+ var import_node_path8 = __toESM(require("node:path"), 1);
11116
+
11117
+ // src/swift-objc-platform.ts
11118
+ var import_node_child_process5 = require("node:child_process");
9122
11119
  var import_node_path7 = __toESM(require("node:path"), 1);
11120
+ var platforms = /* @__PURE__ */ new Map();
11121
+ function swiftObjCPlatformFlags(toolchainBin, minimum) {
11122
+ const key = `${toolchainBin}:${minimum}`;
11123
+ const cached = platforms.get(key);
11124
+ if (cached) return cached;
11125
+ const version = [
11126
+ Math.floor(minimum / 1e4),
11127
+ Math.floor(minimum % 1e4 / 100),
11128
+ minimum % 100
11129
+ ].join(".");
11130
+ const result = (0, import_node_child_process5.spawnSync)(
11131
+ import_node_path7.default.join(toolchainBin, "clang"),
11132
+ [
11133
+ "-target",
11134
+ `arm64-apple-ios${version}-simulator`,
11135
+ "-dM",
11136
+ "-E",
11137
+ "-x",
11138
+ "objective-c",
11139
+ "-"
11140
+ ],
11141
+ {
11142
+ input: "",
11143
+ encoding: "utf8",
11144
+ env: swiftEnvironment(),
11145
+ timeout: 3e4,
11146
+ maxBuffer: 1024 * 1024
11147
+ }
11148
+ );
11149
+ if (result.error || result.status !== 0)
11150
+ throw new Error(
11151
+ `could not read iOS compiler platform predefines: ${result.error?.message ?? result.stderr}`
11152
+ );
11153
+ const flags = [
11154
+ ...result.stdout.matchAll(
11155
+ /^#define (TARGET_OS_\w+|TARGET_IPHONE_SIMULATOR|__APPLE\w*__|__MACH__|__ENVIRONMENT_\w+) (.*)$/gm
11156
+ )
11157
+ ].map(([, name2, value]) => `-D${name2}=${value}`);
11158
+ if (!flags.includes("-D__APPLE__=1") || !flags.includes("-D__MACH__=1"))
11159
+ throw new Error("iOS compiler platform predefines lack Apple and Mach identity");
11160
+ platforms.set(key, flags);
11161
+ return flags;
11162
+ }
11163
+
11164
+ // src/swift-objc-standin.ts
9123
11165
  var NATIVE_GRAPH_SDK_VERSION = "27.1";
9124
- var WASI_EMULATION = ["_WASI_EMULATED_SIGNAL", "_WASI_EMULATED_MMAN"];
11166
+ var WASI_EMULATION = [
11167
+ "_WASI_EMULATED_SIGNAL",
11168
+ "_WASI_EMULATED_MMAN",
11169
+ "_WASI_EMULATED_PROCESS_CLOCKS"
11170
+ ];
9125
11171
  var WASI_EMULATION_FLAGS = WASI_EMULATION.map((name2) => `-D${name2}`);
9126
11172
  var NATIVE_GRAPH_INPUTS = {
9127
11173
  sdk: NATIVE_GRAPH_SDK_VERSION,
@@ -9147,13 +11193,13 @@ ${text3}`
9147
11193
  }
9148
11194
  var IOS_SDK_ID = (0, import_node_crypto5.createHash)("sha256").update(JSON.stringify(iosSdkEntries())).digest("hex").slice(0, 16);
9149
11195
  function materializeObjcSdk(cacheDir2) {
9150
- const sdk = import_node_path7.default.join(cacheDir2, "ios-sdk", IOS_SDK_ID);
11196
+ const sdk = import_node_path8.default.join(cacheDir2, "ios-sdk", IOS_SDK_ID);
9151
11197
  if (import_node_fs5.default.existsSync(sdk)) return sdk;
9152
- import_node_fs5.default.mkdirSync(import_node_path7.default.dirname(sdk), { recursive: true });
11198
+ import_node_fs5.default.mkdirSync(import_node_path8.default.dirname(sdk), { recursive: true });
9153
11199
  const staging = import_node_fs5.default.mkdtempSync(`${sdk}-`);
9154
11200
  for (const [file, text3] of iosSdkEntries()) {
9155
- import_node_fs5.default.mkdirSync(import_node_path7.default.dirname(import_node_path7.default.join(staging, file)), { recursive: true });
9156
- import_node_fs5.default.writeFileSync(import_node_path7.default.join(staging, file), text3);
11201
+ import_node_fs5.default.mkdirSync(import_node_path8.default.dirname(import_node_path8.default.join(staging, file)), { recursive: true });
11202
+ import_node_fs5.default.writeFileSync(import_node_path8.default.join(staging, file), text3);
9157
11203
  }
9158
11204
  try {
9159
11205
  import_node_fs5.default.renameSync(staging, sdk);
@@ -9163,7 +11209,45 @@ function materializeObjcSdk(cacheDir2) {
9163
11209
  }
9164
11210
  return sdk;
9165
11211
  }
11212
+ function objcSdkIntakeFlags(headers, toolchainBin, minimum) {
11213
+ return [
11214
+ ...swiftObjCPlatformFlags(toolchainBin, minimum),
11215
+ // AvailabilityInternal.h derives this through __is_target_os(ios), which
11216
+ // is false for wasm32.
11217
+ `-D__IPHONE_OS_VERSION_MIN_REQUIRED=${minimum}`,
11218
+ // apple's build setting for a 32-bit target to keep NSInteger and
11219
+ // NSUInteger long, the nominal types they have on arm64.
11220
+ "-DNS_BUILD_32_LIKE_64=1",
11221
+ // the installed libc's default feature set otherwise defines
11222
+ // _XOPEN_SOURCE, which darwin's sys/cdefs.h turns into a strict posix
11223
+ // level; iOS compiles at darwin's full level with neither defined.
11224
+ "-D_BSD_SOURCE",
11225
+ ...WASI_EMULATION_FLAGS,
11226
+ "-iframework",
11227
+ import_node_path8.default.join(headers, "System/Library/Frameworks"),
11228
+ "-isystem",
11229
+ import_node_path8.default.join(headers, "wasm/include"),
11230
+ "-idirafter",
11231
+ import_node_path8.default.join(headers, "usr/include")
11232
+ ];
11233
+ }
11234
+ function iosDeploymentMinimum(version) {
11235
+ const parts = /^(\d{1,2})(?:\.(\d{1,2}))?(?:\.(\d{1,2}))?$/.exec(version ?? "");
11236
+ if (!parts) return void 0;
11237
+ return Number(parts[1]) * 1e4 + Number(parts[2] ?? 0) * 100 + Number(parts[3] ?? 0);
11238
+ }
9166
11239
  var headerFiles = (dir) => import_node_fs5.default.readdirSync(dir, { recursive: true, encoding: "utf8" }).filter((file) => file.endsWith(".h")).sort();
11240
+ function moduleMapHeaders(modulemap, directoryHeaders = []) {
11241
+ const headers = [];
11242
+ const excluded = /* @__PURE__ */ new Set();
11243
+ for (const match of import_node_fs5.default.readFileSync(modulemap, "utf8").matchAll(/\b(?:(exclude)\s+)?header\s+"([^"]+)"/g)) {
11244
+ if (match[1] === "exclude") excluded.add(match[2]);
11245
+ else headers.push(match[2]);
11246
+ }
11247
+ return (headers.length > 0 ? headers : directoryHeaders).filter(
11248
+ (header) => !excluded.has(header)
11249
+ );
11250
+ }
9167
11251
  function missingHeader(missing) {
9168
11252
  const lines = ["#import <Foundation/Foundation.h>", "#import <UIKit/UIKit.h>"];
9169
11253
  for (const [name2, kind] of missing) if (kind === "macro") lines.push(`#define ${name2}`);
@@ -9185,52 +11269,52 @@ function objcView(surface, toolchainBin, stdlib, cacheDir2, work, original) {
9185
11269
  `this peach's Swift has no iOS simulator standard library at ${stdlib}`
9186
11270
  );
9187
11271
  const sdk = materializeObjcSdk(cacheDir2);
9188
- const framework = import_node_path7.default.basename(import_node_path7.default.dirname(surface.modulemap)) === "Modules";
9189
- const frameworks = import_node_path7.default.join(work, "frameworks");
9190
- const include = import_node_path7.default.join(work, "include");
9191
- const headersDir = framework ? import_node_path7.default.join(frameworks, `${surface.module}.framework`, "Headers") : import_node_path7.default.join(include, surface.module);
11272
+ const framework = import_node_path8.default.basename(import_node_path8.default.dirname(surface.modulemap)) === "Modules";
11273
+ const frameworks = import_node_path8.default.join(work, "frameworks");
11274
+ const include = import_node_path8.default.join(work, "include");
11275
+ const headersDir = framework ? import_node_path8.default.join(frameworks, `${surface.module}.framework`, "Headers") : import_node_path8.default.join(include, surface.module);
9192
11276
  import_node_fs5.default.mkdirSync(headersDir, { recursive: true });
9193
11277
  const originals = new Map(
9194
11278
  headerFiles(surface.headers).map((file) => [
9195
- import_node_path7.default.join(headersDir, file),
9196
- import_node_fs5.default.readFileSync(import_node_path7.default.join(surface.headers, file), "utf8")
11279
+ import_node_path8.default.join(headersDir, file),
11280
+ import_node_fs5.default.readFileSync(import_node_path8.default.join(surface.headers, file), "utf8")
9197
11281
  ])
9198
11282
  );
9199
11283
  for (const [file, text3] of originals) {
9200
- import_node_fs5.default.mkdirSync(import_node_path7.default.dirname(file), { recursive: true });
11284
+ import_node_fs5.default.mkdirSync(import_node_path8.default.dirname(file), { recursive: true });
9201
11285
  import_node_fs5.default.writeFileSync(file, text3);
9202
11286
  }
9203
11287
  if (framework) {
9204
- import_node_fs5.default.mkdirSync(import_node_path7.default.join(frameworks, `${surface.module}.framework`, "Modules"), {
11288
+ import_node_fs5.default.mkdirSync(import_node_path8.default.join(frameworks, `${surface.module}.framework`, "Modules"), {
9205
11289
  recursive: true
9206
11290
  });
9207
11291
  import_node_fs5.default.copyFileSync(
9208
11292
  surface.modulemap,
9209
- import_node_path7.default.join(frameworks, `${surface.module}.framework`, "Modules", "module.modulemap")
11293
+ import_node_path8.default.join(frameworks, `${surface.module}.framework`, "Modules", "module.modulemap")
9210
11294
  );
9211
11295
  } else {
9212
- import_node_fs5.default.copyFileSync(surface.modulemap, import_node_path7.default.join(headersDir, "module.modulemap"));
11296
+ import_node_fs5.default.copyFileSync(surface.modulemap, import_node_path8.default.join(headersDir, "module.modulemap"));
9213
11297
  }
9214
11298
  const dependencyOriginals = /* @__PURE__ */ new Map();
9215
11299
  for (const dependency of surface.dependencies ?? []) {
9216
- const dir = import_node_path7.default.join(include, dependency.module);
11300
+ const dir = import_node_path8.default.join(include, dependency.module);
9217
11301
  import_node_fs5.default.mkdirSync(dir, { recursive: true });
9218
11302
  for (const file of headerFiles(dependency.headers)) {
9219
- const destination = import_node_path7.default.join(dir, file);
9220
- const text3 = import_node_fs5.default.readFileSync(import_node_path7.default.join(dependency.headers, file), "utf8");
11303
+ const destination = import_node_path8.default.join(dir, file);
11304
+ const text3 = import_node_fs5.default.readFileSync(import_node_path8.default.join(dependency.headers, file), "utf8");
9221
11305
  dependencyOriginals.set(destination, text3);
9222
- import_node_fs5.default.mkdirSync(import_node_path7.default.dirname(destination), { recursive: true });
11306
+ import_node_fs5.default.mkdirSync(import_node_path8.default.dirname(destination), { recursive: true });
9223
11307
  import_node_fs5.default.writeFileSync(destination, text3);
9224
11308
  }
9225
- const supplied = import_node_path7.default.join(dependency.headers, "module.modulemap");
11309
+ const supplied = import_node_path8.default.join(dependency.headers, "module.modulemap");
9226
11310
  import_node_fs5.default.writeFileSync(
9227
- import_node_path7.default.join(dir, "module.modulemap"),
11311
+ import_node_path8.default.join(dir, "module.modulemap"),
9228
11312
  import_node_fs5.default.existsSync(supplied) ? import_node_fs5.default.readFileSync(supplied, "utf8") : `module ${dependency.module} { umbrella "." export * }
9229
11313
  `
9230
11314
  );
9231
11315
  }
9232
- const stubs = import_node_path7.default.join(work, "stubs");
9233
- const stubIncludes = import_node_path7.default.join(work, "stub-include");
11316
+ const stubs = import_node_path8.default.join(work, "stubs");
11317
+ const stubIncludes = import_node_path8.default.join(work, "stub-include");
9234
11318
  import_node_fs5.default.mkdirSync(stubs, { recursive: true });
9235
11319
  import_node_fs5.default.mkdirSync(stubIncludes, { recursive: true });
9236
11320
  const search = [
@@ -9238,11 +11322,11 @@ function objcView(surface, toolchainBin, stdlib, cacheDir2, work, original) {
9238
11322
  sdk,
9239
11323
  // keep compiler support headers without importing host platform modules.
9240
11324
  "-resource-dir",
9241
- import_node_path7.default.join(sdk, "usr/lib/swift"),
11325
+ import_node_path8.default.join(sdk, "usr/lib/swift"),
9242
11326
  "-I",
9243
- import_node_path7.default.resolve(toolchainBin, "../lib/swift/clang/include"),
11327
+ import_node_path8.default.resolve(toolchainBin, "../lib/swift/clang/include"),
9244
11328
  "-I",
9245
- import_node_path7.default.resolve(toolchainBin, "../lib/swift/shims"),
11329
+ import_node_path8.default.resolve(toolchainBin, "../lib/swift/shims"),
9246
11330
  "-I",
9247
11331
  stdlib,
9248
11332
  "-F",
@@ -9253,7 +11337,7 @@ function objcView(surface, toolchainBin, stdlib, cacheDir2, work, original) {
9253
11337
  headersDir,
9254
11338
  ...(surface.dependencies ?? []).flatMap((dependency) => [
9255
11339
  "-I",
9256
- import_node_path7.default.join(include, dependency.module)
11340
+ import_node_path8.default.join(include, dependency.module)
9257
11341
  ]),
9258
11342
  "-F",
9259
11343
  stubs,
@@ -9262,7 +11346,7 @@ function objcView(surface, toolchainBin, stdlib, cacheDir2, work, original) {
9262
11346
  ];
9263
11347
  const missing = /* @__PURE__ */ new Map();
9264
11348
  const stubbed = /* @__PURE__ */ new Set();
9265
- const out = import_node_path7.default.join(work, "graphs");
11349
+ const out = import_node_path8.default.join(work, "graphs");
9266
11350
  const stub = (include2) => {
9267
11351
  if (stubbed.has(include2)) return false;
9268
11352
  stubbed.add(include2);
@@ -9274,22 +11358,22 @@ function objcView(surface, toolchainBin, stdlib, cacheDir2, work, original) {
9274
11358
  IOS_SDK_HEADERS,
9275
11359
  `System/Library/Frameworks/${name2}.framework/Headers/${name2}.h`
9276
11360
  )) {
9277
- const header2 = import_node_path7.default.join(stubIncludes, include2);
9278
- import_node_fs5.default.mkdirSync(import_node_path7.default.dirname(header2), { recursive: true });
11361
+ const header2 = import_node_path8.default.join(stubIncludes, include2);
11362
+ import_node_fs5.default.mkdirSync(import_node_path8.default.dirname(header2), { recursive: true });
9279
11363
  import_node_fs5.default.writeFileSync(header2, `#import <${umbrella}>
9280
11364
  `);
9281
11365
  return true;
9282
11366
  }
9283
- const root = import_node_path7.default.join(stubs, `${name2}.framework`);
9284
- const header = import_node_path7.default.join(root, "Headers", include2.slice(slash + 1));
9285
- import_node_fs5.default.mkdirSync(import_node_path7.default.dirname(header), { recursive: true });
11367
+ const root = import_node_path8.default.join(stubs, `${name2}.framework`);
11368
+ const header = import_node_path8.default.join(root, "Headers", include2.slice(slash + 1));
11369
+ import_node_fs5.default.mkdirSync(import_node_path8.default.dirname(header), { recursive: true });
9286
11370
  import_node_fs5.default.writeFileSync(
9287
11371
  header,
9288
11372
  "#import <Foundation/Foundation.h>\n#import <UIKit/UIKit.h>\n"
9289
11373
  );
9290
- import_node_fs5.default.mkdirSync(import_node_path7.default.join(root, "Modules"), { recursive: true });
11374
+ import_node_fs5.default.mkdirSync(import_node_path8.default.join(root, "Modules"), { recursive: true });
9291
11375
  import_node_fs5.default.writeFileSync(
9292
- import_node_path7.default.join(root, "Modules", "module.modulemap"),
11376
+ import_node_path8.default.join(root, "Modules", "module.modulemap"),
9293
11377
  `framework module ${name2} {
9294
11378
  umbrella "Headers"
9295
11379
  export *
@@ -9298,19 +11382,19 @@ function objcView(surface, toolchainBin, stdlib, cacheDir2, work, original) {
9298
11382
  `
9299
11383
  );
9300
11384
  } else {
9301
- const header = import_node_path7.default.join(stubIncludes, include2);
9302
- import_node_fs5.default.mkdirSync(import_node_path7.default.dirname(header), { recursive: true });
11385
+ const header = import_node_path8.default.join(stubIncludes, include2);
11386
+ import_node_fs5.default.mkdirSync(import_node_path8.default.dirname(header), { recursive: true });
9303
11387
  import_node_fs5.default.writeFileSync(header, "");
9304
11388
  }
9305
11389
  return true;
9306
11390
  };
9307
11391
  const declareMissing = () => {
9308
- const root = import_node_path7.default.join(stubs, "PeachMissing.framework");
9309
- import_node_fs5.default.mkdirSync(import_node_path7.default.join(root, "Headers"), { recursive: true });
9310
- import_node_fs5.default.mkdirSync(import_node_path7.default.join(root, "Modules"), { recursive: true });
9311
- import_node_fs5.default.writeFileSync(import_node_path7.default.join(root, "Headers", "PeachMissing.h"), missingHeader(missing));
11392
+ const root = import_node_path8.default.join(stubs, "PeachMissing.framework");
11393
+ import_node_fs5.default.mkdirSync(import_node_path8.default.join(root, "Headers"), { recursive: true });
11394
+ import_node_fs5.default.mkdirSync(import_node_path8.default.join(root, "Modules"), { recursive: true });
11395
+ import_node_fs5.default.writeFileSync(import_node_path8.default.join(root, "Headers", "PeachMissing.h"), missingHeader(missing));
9312
11396
  import_node_fs5.default.writeFileSync(
9313
- import_node_path7.default.join(root, "Modules", "module.modulemap"),
11397
+ import_node_path8.default.join(root, "Modules", "module.modulemap"),
9314
11398
  'framework module PeachMissing {\n umbrella header "PeachMissing.h"\n export *\n}\n'
9315
11399
  );
9316
11400
  for (const [file, text3] of [...originals, ...dependencyOriginals])
@@ -9327,8 +11411,8 @@ function objcView(surface, toolchainBin, stdlib, cacheDir2, work, original) {
9327
11411
  for (let round = 0; ; round++) {
9328
11412
  import_node_fs5.default.rmSync(out, { recursive: true, force: true });
9329
11413
  import_node_fs5.default.mkdirSync(out, { recursive: true });
9330
- const run2 = (0, import_node_child_process5.spawnSync)(
9331
- import_node_path7.default.join(toolchainBin, "swift-symbolgraph-extract"),
11414
+ const run2 = (0, import_node_child_process6.spawnSync)(
11415
+ import_node_path8.default.join(toolchainBin, "swift-symbolgraph-extract"),
9332
11416
  [
9333
11417
  "-module-name",
9334
11418
  surface.module,
@@ -9337,7 +11421,7 @@ function objcView(surface, toolchainBin, stdlib, cacheDir2, work, original) {
9337
11421
  ...search,
9338
11422
  ...original?.flags.flatMap((flag) => ["-Xcc", flag]) ?? [],
9339
11423
  "-module-cache-path",
9340
- import_node_path7.default.join(cacheDir2, "ios-module-cache"),
11424
+ import_node_path8.default.join(cacheDir2, "ios-module-cache"),
9341
11425
  "-minimum-access-level",
9342
11426
  // symbol graphs hide public underscored names at the public threshold.
9343
11427
  // original clang headers remain the declaration boundary.
@@ -9400,7 +11484,7 @@ function objcView(surface, toolchainBin, stdlib, cacheDir2, work, original) {
9400
11484
  );
9401
11485
  if (missing.size > 0) declareMissing();
9402
11486
  }
9403
- const graphs = import_node_fs5.default.readdirSync(out).filter((name2) => name2.endsWith(".symbols.json")).sort().map((name2) => JSON.parse(import_node_fs5.default.readFileSync(import_node_path7.default.join(out, name2), "utf8")));
11487
+ const graphs = import_node_fs5.default.readdirSync(out).filter((name2) => name2.endsWith(".symbols.json")).sort().map((name2) => JSON.parse(import_node_fs5.default.readFileSync(import_node_path8.default.join(out, name2), "utf8")));
9404
11488
  const imports = /* @__PURE__ */ new Set(["Foundation", "UIKit"]);
9405
11489
  for (const text3 of originals.values())
9406
11490
  for (const match of text3.matchAll(
@@ -9426,10 +11510,8 @@ function objcView(surface, toolchainBin, stdlib, cacheDir2, work, original) {
9426
11510
  };
9427
11511
  }
9428
11512
  function objcDeclarationAST(surface, framework, toolchainBin, search, work, originalFlags, target) {
9429
- const roots = [
9430
- ...import_node_fs5.default.readFileSync(surface.modulemap, "utf8").matchAll(/(?:umbrella\s+)?header\s+"([^"]+)"/g)
9431
- ].map((match) => match[1]);
9432
- const probe = import_node_path7.default.join(work, "declarations.m");
11513
+ const roots = moduleMapHeaders(surface.modulemap);
11514
+ const probe = import_node_path8.default.join(work, "declarations.m");
9433
11515
  import_node_fs5.default.writeFileSync(
9434
11516
  probe,
9435
11517
  roots.map(
@@ -9459,8 +11541,8 @@ function objcDeclarationAST(surface, framework, toolchainBin, search, work, orig
9459
11541
  "-ast-dump-all=json"
9460
11542
  ];
9461
11543
  const dump = (filter) => {
9462
- const run2 = (0, import_node_child_process5.spawnSync)(
9463
- import_node_path7.default.join(toolchainBin, "clang"),
11544
+ const run2 = (0, import_node_child_process6.spawnSync)(
11545
+ import_node_path8.default.join(toolchainBin, "clang"),
9464
11546
  [
9465
11547
  ...args,
9466
11548
  ...filter ? ["-Xclang", "-ast-dump-filter", "-Xclang", filter] : [],
@@ -9521,10 +11603,8 @@ function enumValues(graphs, surface, framework, toolchainBin, search, work, orig
9521
11603
  }
9522
11604
  const values = /* @__PURE__ */ new Map();
9523
11605
  if (wanted.size === 0) return values;
9524
- const roots = [
9525
- ...import_node_fs5.default.readFileSync(surface.modulemap, "utf8").matchAll(/(?:umbrella\s+)?header\s+"([^"]+)"/g)
9526
- ].map((match) => match[1]);
9527
- const probe = import_node_path7.default.join(work, "values.m");
11606
+ const roots = moduleMapHeaders(surface.modulemap);
11607
+ const probe = import_node_path8.default.join(work, "values.m");
9528
11608
  import_node_fs5.default.writeFileSync(
9529
11609
  probe,
9530
11610
  roots.map(
@@ -9539,8 +11619,8 @@ function enumValues(graphs, surface, framework, toolchainBin, search, work, orig
9539
11619
  if (flag === "-sdk") flags.push("-isysroot", dir);
9540
11620
  else flags.push(flag, dir);
9541
11621
  }
9542
- const run2 = (0, import_node_child_process5.spawnSync)(
9543
- import_node_path7.default.join(toolchainBin, "clang"),
11622
+ const run2 = (0, import_node_child_process6.spawnSync)(
11623
+ import_node_path8.default.join(toolchainBin, "clang"),
9544
11624
  [
9545
11625
  "-x",
9546
11626
  "objective-c",
@@ -9553,7 +11633,7 @@ function enumValues(graphs, surface, framework, toolchainBin, search, work, orig
9553
11633
  original?.target ?? IOS_SDK_TARGET,
9554
11634
  ...flags,
9555
11635
  ...original?.flags ?? [],
9556
- `-fmodules-cache-path=${import_node_path7.default.join(work, "clang-modules")}`,
11636
+ `-fmodules-cache-path=${import_node_path8.default.join(work, "clang-modules")}`,
9557
11637
  "-Xclang",
9558
11638
  "-ast-dump=json",
9559
11639
  probe
@@ -9824,6 +11904,40 @@ function splitManifestArguments(source) {
9824
11904
  if (final) arguments_.push(final);
9825
11905
  return arguments_;
9826
11906
  }
11907
+ function swiftManifestPackages(manifest) {
11908
+ return new Map(
11909
+ manifestCalls(manifest, ["package"]).flatMap(({ flat }) => {
11910
+ const directory = /\bpath\s*:\s*"([^"]+)"/.exec(flat)?.[1];
11911
+ if (!directory) return [];
11912
+ const name2 = /\bname\s*:\s*"([^"]+)"/.exec(flat)?.[1] ?? directory.split("/").pop();
11913
+ return [[name2.toLowerCase(), directory]];
11914
+ })
11915
+ );
11916
+ }
11917
+ var SWIFT_NATIVE_TRANSLATION_UNIT_EXTENSIONS = [
11918
+ ".c",
11919
+ ".cc",
11920
+ ".cpp",
11921
+ ".cxx",
11922
+ ".m",
11923
+ ".mm"
11924
+ ];
11925
+ function isSwiftNativeTranslationUnit(file) {
11926
+ return SWIFT_NATIVE_TRANSLATION_UNIT_EXTENSIONS.some(
11927
+ (extension) => file.endsWith(extension)
11928
+ );
11929
+ }
11930
+ var SWIFT_NATIVE_SOURCE_EXTENSIONS = [
11931
+ ...SWIFT_NATIVE_TRANSLATION_UNIT_EXTENSIONS,
11932
+ ".h",
11933
+ ".hh",
11934
+ ".hpp",
11935
+ ".hxx",
11936
+ ".pch",
11937
+ ".inc",
11938
+ ".inl",
11939
+ ".modulemap"
11940
+ ];
9827
11941
  function swiftTargetModuleName(name2) {
9828
11942
  return name2.replace(/[^A-Za-z0-9_]/g, "_").replace(/^[0-9]/, "_");
9829
11943
  }
@@ -9839,21 +11953,45 @@ var swiftEscapes = {
9839
11953
  r: "\r",
9840
11954
  t: " "
9841
11955
  };
11956
+ function bracketBody(text3, openIndex) {
11957
+ let depth = 1;
11958
+ let index = openIndex;
11959
+ for (; index < text3.length && depth > 0; index++) {
11960
+ const char = text3[index];
11961
+ if (char === '"') {
11962
+ for (index++; index < text3.length && text3[index] !== '"'; index++)
11963
+ if (text3[index] === "\\") index++;
11964
+ } else if (char === "[") depth++;
11965
+ else if (char === "]") depth--;
11966
+ }
11967
+ return text3.slice(openIndex, index - 1);
11968
+ }
11969
+ function settingsBlocks(call, tool) {
11970
+ const bodies = [];
11971
+ for (const open of call.matchAll(new RegExp(`\\b${tool}Settings\\s*:\\s*\\[`, "g")))
11972
+ bodies.push(bracketBody(call, open.index + open[0].length));
11973
+ return bodies;
11974
+ }
11975
+ function settingFeatures(call, setting) {
11976
+ const found = [];
11977
+ for (const body of settingsBlocks(call, "swift")) {
11978
+ if (setting === ".unsafeFlags") {
11979
+ for (const open of body.matchAll(/\.unsafeFlags\(\s*\[/g))
11980
+ for (const match of bracketBody(body, open.index + open[0].length).matchAll(
11981
+ /"((?:[^"\\]|\\.)*)"/g
11982
+ ))
11983
+ found.push(JSON.parse(`"${match[1]}"`));
11984
+ } else {
11985
+ const name2 = "([A-Za-z_][A-Za-z0-9_]*(?:=[A-Za-z_][A-Za-z0-9_.-]*)?)";
11986
+ const pattern = setting === ".enableExperimentalFeature" ? new RegExp(`\\.enableExperimentalFeature\\(\\s*"${name2}"\\s*\\)`, "g") : new RegExp(`\\.enableUpcomingFeature\\(\\s*"${name2}"\\s*\\)`, "g");
11987
+ for (const match of body.matchAll(pattern)) found.push(match[1]);
11988
+ }
11989
+ }
11990
+ return found;
11991
+ }
9842
11992
  function settingDefines(call, tool) {
9843
11993
  const defines = [];
9844
- for (const open of call.matchAll(new RegExp(`\\b${tool}Settings\\s*:\\s*\\[`, "g"))) {
9845
- let depth = 1;
9846
- let index = open.index + open[0].length;
9847
- const start = index;
9848
- for (; index < call.length && depth > 0; index++) {
9849
- const char = call[index];
9850
- if (char === '"') {
9851
- for (index++; index < call.length && call[index] !== '"'; index++)
9852
- if (call[index] === "\\") index++;
9853
- } else if (char === "[") depth++;
9854
- else if (char === "]") depth--;
9855
- }
9856
- const body = call.slice(start, index - 1);
11994
+ for (const body of settingsBlocks(call, tool)) {
9857
11995
  for (const match of body.matchAll(
9858
11996
  /\.define\(\s*"([A-Za-z_][A-Za-z0-9_]*)"\s*(?:,\s*to:\s*"((?:[^"\\]|\\.)*)"\s*)?\)/g
9859
11997
  )) {
@@ -9872,26 +12010,61 @@ function settingDefines(call, tool) {
9872
12010
  }
9873
12011
  return defines;
9874
12012
  }
9875
- function swiftManifestTargets(manifest, resourcePaths = []) {
12013
+ function swiftManifestDeclarations(manifest, resourcePaths = []) {
9876
12014
  const implicitResources = swiftImplicitResourcePaths(resourcePaths);
9877
12015
  const targets = [];
9878
- const declarations = manifestCalls(manifest, [
12016
+ for (const declaration of manifestCalls(manifest, [
9879
12017
  "executableTarget",
9880
12018
  "target",
9881
12019
  "systemLibrary"
9882
- ]);
9883
- const targetNames = new Set(
9884
- declarations.flatMap(({ flat }) => {
9885
- const name2 = /\bname\s*:\s*"([^"]+)"/.exec(flat)?.[1];
9886
- return name2 ? [name2] : [];
9887
- })
9888
- );
9889
- for (const { kind, flat, call } of declarations) {
9890
- const executable = kind === "executableTarget";
12020
+ ])) {
12021
+ const { kind, flat } = declaration;
9891
12022
  const name2 = /\bname\s*:\s*"([^"]+)"/.exec(flat)?.[1];
9892
12023
  if (!name2) continue;
9893
12024
  const rawPath = /\bpath\s*:\s*"([^"]*)"/.exec(flat)?.[1];
9894
12025
  const targetPath = rawPath == null || rawPath === "" ? `Sources/${name2}` : rawPath.replace(/^\.\//, "").replace(/\/+$/, "");
12026
+ const exclude = /\bexclude\s*:\s*\[/.exec(flat);
12027
+ const excluded = [
12028
+ ...(exclude ? bracketBody(flat, exclude.index + exclude[0].length) : "").matchAll(
12029
+ /"([^"]+)"/g
12030
+ )
12031
+ ].map((match) => match[1].replace(/^\.\//, "").replace(/\/+$/, ""));
12032
+ const prefix = targetPath === "." ? "" : `${targetPath}/`;
12033
+ const resources = /\bresources\s*:/.test(flat) || implicitResources.some((file) => {
12034
+ if (!file.startsWith(prefix)) return false;
12035
+ const relative = file.slice(prefix.length);
12036
+ if (excluded.some(
12037
+ (exclude2) => relative === exclude2 || relative.startsWith(`${exclude2}/`)
12038
+ ))
12039
+ return false;
12040
+ return true;
12041
+ });
12042
+ targets.push({
12043
+ ...declaration,
12044
+ name: name2,
12045
+ path: targetPath,
12046
+ executable: kind === "executableTarget",
12047
+ resources,
12048
+ exclude: excluded
12049
+ });
12050
+ }
12051
+ return targets;
12052
+ }
12053
+ function swiftManifestTargets(manifest, resourcePaths = []) {
12054
+ const targets = [];
12055
+ const declarations = swiftManifestDeclarations(manifest, resourcePaths);
12056
+ const targetNames = new Set(declarations.map(({ name: name2 }) => name2));
12057
+ for (const {
12058
+ kind,
12059
+ flat,
12060
+ call,
12061
+ name: name2,
12062
+ path: targetPath,
12063
+ executable,
12064
+ resources,
12065
+ exclude: excluded
12066
+ } of declarations) {
12067
+ const publicHeadersPath = /\bpublicHeadersPath\s*:\s*"([^"]*)"/.exec(flat)?.[1];
9895
12068
  const languageMode = Number(
9896
12069
  /\.swiftLanguageMode\(\s*\.v(\d+)\s*\)/.exec(call)?.[1] ?? "5"
9897
12070
  );
@@ -9900,50 +12073,47 @@ function swiftManifestTargets(manifest, resourcePaths = []) {
9900
12073
  call.replace(/"(?:\\.|[^"\\])*"/g, "")
9901
12074
  );
9902
12075
  const defines = settingDefines(call, "swift").map((define) => define.split("=")[0]);
12076
+ const experimentalFeatures = settingFeatures(call, ".enableExperimentalFeature");
12077
+ const upcomingFeatures = settingFeatures(call, ".enableUpcomingFeature");
12078
+ const swiftFlags = settingFeatures(call, ".unsafeFlags");
9903
12079
  const cDefines = settingDefines(call, "c");
9904
12080
  const cxxDefines = settingDefines(call, "cxx");
9905
12081
  const linkedLibraries = [...call.matchAll(/\.linkedLibrary\(\s*"([^"]+)"\s*\)/g)].map(
9906
12082
  (match) => match[1]
9907
12083
  );
9908
- const excluded = [
9909
- ...(/\bexclude\s*:\s*\[([^\]]*)\]/.exec(flat)?.[1] ?? "").matchAll(/"([^"]+)"/g)
9910
- ].map((match) => match[1].replace(/^\.\//, "").replace(/\/+$/, ""));
9911
- const prefix = targetPath === "." ? "" : `${targetPath}/`;
9912
- const resources = /\bresources\s*:/.test(flat) || implicitResources.some((file) => {
9913
- if (!file.startsWith(prefix)) return false;
9914
- const relative = file.slice(prefix.length);
9915
- if (excluded.some(
9916
- (exclude) => relative === exclude || relative.startsWith(`${exclude}/`)
9917
- ))
9918
- return false;
9919
- return true;
9920
- });
9921
12084
  const targetArguments = splitManifestArguments(call.slice(0, -1));
9922
12085
  const dependencyArgument = targetArguments.find(
9923
12086
  (argument) => /^dependencies\s*:/.test(argument)
9924
12087
  );
9925
12088
  const dependencyList = dependencyArgument?.replace(/^dependencies\s*:\s*/, "").trim();
9926
- const dependencyNames = /* @__PURE__ */ new Set();
12089
+ const dependencies = [];
9927
12090
  if (dependencyList?.startsWith("[") && dependencyList.endsWith("]")) {
9928
12091
  for (const dependency of splitManifestArguments(dependencyList.slice(1, -1))) {
12092
+ const product = /^\.product\s*\(\s*name\s*:\s*"([^"]+)"\s*,\s*package\s*:\s*"([^"]+)"\s*\)$/.exec(
12093
+ dependency
12094
+ );
12095
+ if (product) {
12096
+ dependencies.push({ kind: "product", name: product[1], package: product[2] });
12097
+ continue;
12098
+ }
9929
12099
  const dependencyName = /^"([^"]+)"$/.exec(dependency)?.[1] ?? /^\.(?:target|byName)\s*\(\s*name\s*:\s*"([^"]+)"/.exec(dependency)?.[1];
9930
12100
  if (dependencyName && targetNames.has(dependencyName))
9931
- dependencyNames.add(dependencyName);
12101
+ dependencies.push({ kind: "target", name: dependencyName });
9932
12102
  }
9933
12103
  }
9934
- const dependencies = [...dependencyNames].map((name3) => ({
9935
- kind: "target",
9936
- name: name3
9937
- }));
9938
12104
  targets.push({
9939
12105
  name: name2,
9940
12106
  path: targetPath,
9941
12107
  executable,
9942
12108
  ...kind === "systemLibrary" ? { systemLibrary: true } : {},
12109
+ ...publicHeadersPath === void 0 ? {} : { publicHeadersPath },
9943
12110
  languageMode,
9944
12111
  mainActorIsolation,
9945
12112
  ...cxxInterop ? { cxxInterop: true } : {},
9946
12113
  ...defines.length === 0 ? {} : { defines },
12114
+ ...experimentalFeatures.length === 0 ? {} : { experimentalFeatures },
12115
+ ...upcomingFeatures.length === 0 ? {} : { upcomingFeatures },
12116
+ ...swiftFlags.length === 0 ? {} : { swiftFlags },
9947
12117
  ...cDefines.length === 0 ? {} : { cDefines },
9948
12118
  ...cxxDefines.length === 0 ? {} : { cxxDefines },
9949
12119
  ...linkedLibraries.length === 0 ? {} : { linkedLibraries },
@@ -10031,14 +12201,14 @@ function swiftObjCResourceAccessor(bundleName) {
10031
12201
  }
10032
12202
  function swiftPackagePartition(manifest, resourcePaths = []) {
10033
12203
  const targets = swiftManifestTargets(manifest, resourcePaths);
10034
- return targets.length === 1 && targets[0].executable && targets[0].path === "." && targets[0].languageMode === 5 && !targets[0].mainActorIsolation && !targets[0].defines?.length && !targets[0].linkedLibraries?.length && !targets[0].cxxInterop && !swiftManifestCxxLanguageStandard(manifest) ? [] : targets;
12204
+ return targets.length === 1 && targets[0].executable && targets[0].path === "." && targets[0].languageMode === 5 && !targets[0].mainActorIsolation && !targets[0].defines?.length && !targets[0].experimentalFeatures?.length && !targets[0].upcomingFeatures?.length && !targets[0].swiftFlags?.length && !targets[0].linkedLibraries?.length && !targets[0].cxxInterop && !swiftManifestCxxLanguageStandard(manifest) ? [] : targets;
10035
12205
  }
10036
12206
 
10037
12207
  // src/swift-root-lock.ts
10038
- var import_node_child_process6 = require("node:child_process");
12208
+ var import_node_child_process7 = require("node:child_process");
10039
12209
  var import_node_crypto6 = require("node:crypto");
10040
12210
  var import_node_fs6 = require("node:fs");
10041
- var import_node_path8 = __toESM(require("node:path"), 1);
12211
+ var import_node_path9 = __toESM(require("node:path"), 1);
10042
12212
  var POLL_MS = 250;
10043
12213
  var START_TOLERANCE_MS = 2e3;
10044
12214
  function errorCode(error) {
@@ -10050,7 +12220,7 @@ function parseStart(text3) {
10050
12220
  return start;
10051
12221
  }
10052
12222
  function processTable() {
10053
- const result = (0, import_node_child_process6.spawnSync)("ps", ["-A", "-o", "pid=,pgid=,stat=,lstart="], {
12223
+ const result = (0, import_node_child_process7.spawnSync)("ps", ["-A", "-o", "pid=,pgid=,stat=,lstart="], {
10054
12224
  encoding: "utf8",
10055
12225
  env: { ...process.env, LC_ALL: "C", TZ: "UTC" },
10056
12226
  stdio: ["ignore", "pipe", "pipe"],
@@ -10113,7 +12283,7 @@ function generationNumbers(directory) {
10113
12283
  function readGeneration(directory, number) {
10114
12284
  let owner;
10115
12285
  try {
10116
- owner = (0, import_node_fs6.readFileSync)(import_node_path8.default.join(directory, name(number, "owner")), "utf8");
12286
+ owner = (0, import_node_fs6.readFileSync)(import_node_path9.default.join(directory, name(number, "owner")), "utf8");
10117
12287
  } catch (error) {
10118
12288
  if (errorCode(error) === "ENOENT") return null;
10119
12289
  throw error;
@@ -10126,7 +12296,7 @@ function readGeneration(directory, number) {
10126
12296
  }
10127
12297
  function readChildren(directory, number) {
10128
12298
  const prefix = name(number, "child.");
10129
- return (0, import_node_fs6.readdirSync)(directory).filter((entry) => entry.startsWith(prefix)).map((entry) => parseIdentity((0, import_node_fs6.readFileSync)(import_node_path8.default.join(directory, entry), "utf8")));
12299
+ return (0, import_node_fs6.readdirSync)(directory).filter((entry) => entry.startsWith(prefix)).map((entry) => parseIdentity((0, import_node_fs6.readFileSync)(import_node_path9.default.join(directory, entry), "utf8")));
10130
12300
  }
10131
12301
  function groupAlive(table, leader) {
10132
12302
  const row = table.find((candidate) => candidate.pid === leader.pid);
@@ -10134,7 +12304,7 @@ function groupAlive(table, leader) {
10134
12304
  return table.some((candidate) => candidate.pgid === leader.pid && !candidate.zombie);
10135
12305
  }
10136
12306
  async function withSwiftRootLock(root, work, signal) {
10137
- const directory = import_node_path8.default.join(
12307
+ const directory = import_node_path9.default.join(
10138
12308
  rnxHomeDir(),
10139
12309
  "cache",
10140
12310
  "swift-root-locks",
@@ -10143,7 +12313,7 @@ async function withSwiftRootLock(root, work, signal) {
10143
12313
  (0, import_node_fs6.mkdirSync)(directory, { recursive: true });
10144
12314
  const token = (0, import_node_crypto6.randomUUID)();
10145
12315
  const owner = JSON.stringify(ownIdentity(process.pid));
10146
- const pending = import_node_path8.default.join(directory, `pending.${token}`);
12316
+ const pending = import_node_path9.default.join(directory, `pending.${token}`);
10147
12317
  let held = 0;
10148
12318
  for (; ; ) {
10149
12319
  signal?.throwIfAborted();
@@ -10164,7 +12334,7 @@ async function withSwiftRootLock(root, work, signal) {
10164
12334
  }
10165
12335
  (0, import_node_fs6.writeFileSync)(pending, owner);
10166
12336
  try {
10167
- (0, import_node_fs6.linkSync)(pending, import_node_path8.default.join(directory, name(newest + 1, "owner")));
12337
+ (0, import_node_fs6.linkSync)(pending, import_node_path9.default.join(directory, name(newest + 1, "owner")));
10168
12338
  } catch (error) {
10169
12339
  if (errorCode(error) === "EEXIST") continue;
10170
12340
  throw error;
@@ -10173,7 +12343,7 @@ async function withSwiftRootLock(root, work, signal) {
10173
12343
  }
10174
12344
  const numbers = generationNumbers(directory);
10175
12345
  if (numbers.at(-1) !== newest + 1) {
10176
- (0, import_node_fs6.rmSync)(import_node_path8.default.join(directory, name(newest + 1, "owner")), { force: true });
12346
+ (0, import_node_fs6.rmSync)(import_node_path9.default.join(directory, name(newest + 1, "owner")), { force: true });
10177
12347
  continue;
10178
12348
  }
10179
12349
  held = newest + 1;
@@ -10181,14 +12351,14 @@ async function withSwiftRootLock(root, work, signal) {
10181
12351
  if (number < held) {
10182
12352
  for (const entry of (0, import_node_fs6.readdirSync)(directory))
10183
12353
  if (entry.startsWith(name(number, "")))
10184
- (0, import_node_fs6.rmSync)(import_node_path8.default.join(directory, entry), { force: true });
12354
+ (0, import_node_fs6.rmSync)(import_node_path9.default.join(directory, entry), { force: true });
10185
12355
  }
10186
12356
  break;
10187
12357
  }
10188
12358
  const children = [];
10189
12359
  const lease = {
10190
12360
  spawn(command, args, options) {
10191
- const child = (0, import_node_child_process6.spawn)(
12361
+ const child = (0, import_node_child_process7.spawn)(
10192
12362
  "/bin/sh",
10193
12363
  ["-c", 'IFS= read -r go || exit 1; exec "$@" </dev/null', "sh", command, ...args],
10194
12364
  { ...options, detached: true, stdio: ["pipe", "pipe", "pipe"] }
@@ -10205,7 +12375,7 @@ async function withSwiftRootLock(root, work, signal) {
10205
12375
  const childPending = `${pending}.child.${child.pid}`;
10206
12376
  try {
10207
12377
  (0, import_node_fs6.writeFileSync)(childPending, JSON.stringify(ownIdentity(child.pid)));
10208
- (0, import_node_fs6.linkSync)(childPending, import_node_path8.default.join(directory, name(held, `child.${child.pid}`)));
12378
+ (0, import_node_fs6.linkSync)(childPending, import_node_path9.default.join(directory, name(held, `child.${child.pid}`)));
10209
12379
  } finally {
10210
12380
  (0, import_node_fs6.rmSync)(childPending, { force: true });
10211
12381
  }
@@ -10221,23 +12391,37 @@ async function withSwiftRootLock(root, work, signal) {
10221
12391
  return await work(lease);
10222
12392
  } finally {
10223
12393
  await Promise.all(children.map((child) => terminateProcessGroup(child, "SIGKILL", 0)));
10224
- (0, import_node_fs6.writeFileSync)(import_node_path8.default.join(directory, name(held, "released")), "");
12394
+ (0, import_node_fs6.writeFileSync)(import_node_path9.default.join(directory, name(held, "released")), "");
10225
12395
  }
10226
12396
  }
10227
12397
 
10228
12398
  // src/swiftContract.ts
12399
+ var SWIFT_REMOTE_PACKAGES_DIR = "__packages__";
12400
+ var SWIFT_LOCAL_PACKAGES_DIR = "__local_packages__";
12401
+ function isSwiftPackageFiles(value) {
12402
+ return value !== null && typeof value === "object" && !Array.isArray(value) && Object.entries(value).every(
12403
+ ([file, bytes]) => isSwiftResourcePath(file) && (file.startsWith(`${SWIFT_REMOTE_PACKAGES_DIR}/`) || file.startsWith(`${SWIFT_LOCAL_PACKAGES_DIR}/`)) && typeof bytes === "string" && /^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/.test(bytes)
12404
+ );
12405
+ }
10229
12406
  function isSwiftObjCPeerStartup(value) {
10230
12407
  return value !== null && typeof value === "object" && "registration" in value && isSwiftResourcePath(value.registration) && value.registration.endsWith(".swift") && Object.keys(value).length === 1;
10231
12408
  }
10232
12409
  var SWIFT_NATIVE_INPUT_ROOT = "$(PEACH_INPUT_ROOT)";
10233
12410
  var SWIFT_NATIVE_SDK_INCLUDE = "$(PEACH_SDK_INCLUDE)";
10234
12411
  function isSwiftNativeTargets(value) {
12412
+ return swiftNativeTargetsRefusal(value) === null;
12413
+ }
12414
+ function swiftNativeTargetsRefusal(value) {
10235
12415
  const strings = (value2) => Array.isArray(value2) && value2.every((item) => typeof item === "string" && !item.includes("\0"));
10236
12416
  const paths = (value2) => strings(value2) && value2.every(isSwiftResourcePath);
10237
- return Array.isArray(value) && value.length <= 128 && value.every((target) => {
10238
- if (!target || typeof target !== "object") return false;
10239
- const field = (name2) => Reflect.get(target, name2);
10240
- const nullablePath = (name2) => field(name2) === null || isSwiftResourcePath(field(name2));
12417
+ if (!Array.isArray(value)) return "nativeTargets";
12418
+ if (value.length > 128) return "nativeTargets:length";
12419
+ for (const target of value) {
12420
+ if (!target || typeof target !== "object") return "nativeTargets:shape";
12421
+ const field = (name3) => Reflect.get(target, name3);
12422
+ const name2 = typeof field("name") === "string" ? String(field("name")) : "?";
12423
+ const at = (shape) => `nativeTargets:${name2}:${shape}`;
12424
+ const nullablePath = (key) => field(key) === null || isSwiftResourcePath(field(key));
10241
12425
  const perFile = field("fileFlags");
10242
12426
  const directories = field("sourceDirectories");
10243
12427
  const searches = field("headerSearchPaths");
@@ -10247,21 +12431,46 @@ function isSwiftNativeTargets(value) {
10247
12431
  const products = field("productHeaders");
10248
12432
  const inputPath = (value2) => typeof value2 === "string" && value2.startsWith(`${SWIFT_NATIVE_INPUT_ROOT}/`) && isSwiftResourcePath(value2.slice(SWIFT_NATIVE_INPUT_ROOT.length + 1));
10249
12433
  const deployment = field("deploymentTarget");
10250
- return typeof field("name") === "string" && /^[A-Za-z_]\w*$/.test(String(field("name"))) && (deployment === null || typeof deployment === "string" && /^\d+(?:\.\d+){0,2}$/.test(deployment)) && paths(field("headers")) && paths(field("publicHeaders")) && nullablePath("bridgingHeader") && nullablePath("prefixHeader") && strings(searches) && searches.every((item) => item === "." || isSwiftResourcePath(item)) && strings(userSearches) && userSearches.every((item) => item === "." || isSwiftResourcePath(item)) && strings(frameworks) && frameworks.every((item) => item === "." || isSwiftResourcePath(item)) && Array.isArray(maps) && maps.every((map2) => {
12434
+ const targetName = field("name");
12435
+ if (typeof targetName !== "string" || targetName.length === 0 || targetName.length > 4096 || targetName.includes("\0") || targetName.includes("/") || targetName.includes("\\") || targetName === "." || targetName === "..")
12436
+ return at("name");
12437
+ if (!(deployment === null || typeof deployment === "string" && /^\d+(?:\.\d+){0,2}$/.test(deployment)))
12438
+ return at("deploymentTarget");
12439
+ if (!paths(field("headers"))) return at("headers");
12440
+ if (!paths(field("publicHeaders"))) return at("publicHeaders");
12441
+ if (!nullablePath("bridgingHeader")) return at("bridgingHeader");
12442
+ if (!nullablePath("prefixHeader")) return at("prefixHeader");
12443
+ if (!strings(searches) || !searches.every((item) => item === "." || isSwiftResourcePath(item)))
12444
+ return at("headerSearchPaths");
12445
+ if (!strings(userSearches) || !userSearches.every((item) => item === "." || isSwiftResourcePath(item)))
12446
+ return at("userHeaderSearchPaths");
12447
+ if (!strings(frameworks) || !frameworks.every((item) => item === "." || isSwiftResourcePath(item)))
12448
+ return at("frameworkSearchPaths");
12449
+ if (!Array.isArray(maps) || !maps.every((map2) => {
10251
12450
  if (!map2 || typeof map2 !== "object") return false;
10252
12451
  const flag = Reflect.get(map2, "flag");
10253
12452
  const entries = Reflect.get(map2, "entries");
10254
12453
  return (flag === "-I" || flag === "-iquote") && Array.isArray(entries) && entries.every(
10255
12454
  (entry) => Array.isArray(entry) && entry.length === 2 && typeof entry[0] === "string" && !entry[0].includes("\0") && (inputPath(entry[1]) || isSwiftResourcePath(entry[1]))
10256
12455
  );
10257
- }) && !!products && typeof products === "object" && !Array.isArray(products) && Object.entries(products).every(
12456
+ }))
12457
+ return at("headerMaps");
12458
+ if (!products || typeof products !== "object" || Array.isArray(products) || !Object.entries(products).every(
10258
12459
  ([product, file]) => isSwiftResourcePath(product) && isSwiftResourcePath(file)
10259
- ) && strings(field("flags")) && strings(field("cxxFlags")) && !!perFile && typeof perFile === "object" && !Array.isArray(perFile) && Object.entries(perFile).every(
12460
+ ))
12461
+ return at("productHeaders");
12462
+ if (!strings(field("flags"))) return at("flags");
12463
+ if (!strings(field("cxxFlags"))) return at("cxxFlags");
12464
+ if (!perFile || typeof perFile !== "object" || Array.isArray(perFile) || !Object.entries(perFile).every(
10260
12465
  ([file, flags]) => isSwiftResourcePath(file) && strings(flags)
10261
- ) && !!directories && typeof directories === "object" && !Array.isArray(directories) && Object.entries(directories).every(
12466
+ ))
12467
+ return at("fileFlags");
12468
+ if (!directories || typeof directories !== "object" || Array.isArray(directories) || !Object.entries(directories).every(
10262
12469
  ([file, directory]) => isSwiftResourcePath(file) && (directory === "." || isSwiftResourcePath(directory))
10263
- );
10264
- });
12470
+ ))
12471
+ return at("sourceDirectories");
12472
+ }
12473
+ return null;
10265
12474
  }
10266
12475
  function isSwiftResourcePath(value) {
10267
12476
  return typeof value === "string" && value.length <= 4096 && !value.startsWith("/") && !value.includes("\\") && !value.includes("\0") && value.split("/").every((part) => part !== "" && part !== "." && part !== "..");
@@ -10277,7 +12486,7 @@ function isSwiftResourceBundles(value) {
10277
12486
 
10278
12487
  // src/xcode-header-search.ts
10279
12488
  var import_node_fs7 = __toESM(require("node:fs"), 1);
10280
- var import_node_path9 = __toESM(require("node:path"), 1);
12489
+ var import_node_path10 = __toESM(require("node:path"), 1);
10281
12490
  function headerMap(entries) {
10282
12491
  const unique = /* @__PURE__ */ new Map();
10283
12492
  for (const entry of entries)
@@ -10324,11 +12533,11 @@ function writeXcodeHeaderSearch(directory, targets) {
10324
12533
  const productDirectories = /* @__PURE__ */ new Map();
10325
12534
  for (const target of targets)
10326
12535
  for (const [product, file] of Object.entries(target.productHeaders)) {
10327
- const listed = productDirectories.get(import_node_path9.default.dirname(product)) ?? [];
10328
- productDirectories.set(import_node_path9.default.dirname(product), listed);
10329
- listed.push({ name: import_node_path9.default.basename(product), file });
12536
+ const listed = productDirectories.get(import_node_path10.default.dirname(product)) ?? [];
12537
+ productDirectories.set(import_node_path10.default.dirname(product), listed);
12538
+ listed.push({ name: import_node_path10.default.basename(product), file });
10330
12539
  }
10331
- const overlay = import_node_path9.default.join(directory, "all-product-headers.yaml");
12540
+ const overlay = import_node_path10.default.join(directory, "all-product-headers.yaml");
10332
12541
  import_node_fs7.default.writeFileSync(
10333
12542
  overlay,
10334
12543
  JSON.stringify({
@@ -10348,7 +12557,7 @@ function writeXcodeHeaderSearch(directory, targets) {
10348
12557
  const files = [overlay];
10349
12558
  const flags = targets.map((target, index) => {
10350
12559
  const maps = target.headerMaps.map((map2, order) => {
10351
- const file = import_node_path9.default.join(directory, `${index}-${order}.hmap`);
12560
+ const file = import_node_path10.default.join(directory, `${index}-${order}.hmap`);
10352
12561
  import_node_fs7.default.writeFileSync(file, headerMap(map2.entries));
10353
12562
  files.push(file);
10354
12563
  return { flag: map2.flag, file };
@@ -10374,7 +12583,7 @@ async function runCompiler(command, args, options, stream = false, quiet) {
10374
12583
  detached: true,
10375
12584
  stdio: ["ignore", "pipe", "pipe"]
10376
12585
  };
10377
- const child = options.lease ? options.lease.spawn(command, args, launch) : (0, import_node_child_process7.spawn)(command, args, launch);
12586
+ const child = options.lease ? options.lease.spawn(command, args, launch) : (0, import_node_child_process8.spawn)(command, args, launch);
10378
12587
  let stopping;
10379
12588
  try {
10380
12589
  return await new Promise((resolve, reject) => {
@@ -10465,7 +12674,7 @@ function swiftBuilderHopTimeoutMs(compileTimeoutMs) {
10465
12674
  return (compileTimeoutMs ?? SWIFT_BUILDER_DEFAULT_COMPILE_MS) + SWIFT_BUILDER_TRANSPORT_MARGIN_MS;
10466
12675
  }
10467
12676
  function swiftDistributionAt(root) {
10468
- const file = import_node_path10.default.join(root, SWIFT_DISTRIBUTION_MANIFEST);
12677
+ const file = import_node_path11.default.join(root, SWIFT_DISTRIBUTION_MANIFEST);
10469
12678
  if (!(0, import_node_fs8.existsSync)(file)) return null;
10470
12679
  return parseSwiftDistributionManifest(JSON.parse((0, import_node_fs8.readFileSync)(file, "utf8")));
10471
12680
  }
@@ -10494,7 +12703,7 @@ function swiftModuleInputFiles(root) {
10494
12703
  "toolchain.json"
10495
12704
  ];
10496
12705
  const walk = (dir) => {
10497
- for (const entry of (0, import_node_fs8.readdirSync)(import_node_path10.default.join(root, dir), {
12706
+ for (const entry of (0, import_node_fs8.readdirSync)(import_node_path11.default.join(root, dir), {
10498
12707
  withFileTypes: true
10499
12708
  })) {
10500
12709
  const relative = `${dir}/${entry.name}`;
@@ -10512,32 +12721,32 @@ function swiftMacroPlugins(moduleRoot) {
10512
12721
  const distribution = swiftDistributionAt(moduleRoot);
10513
12722
  if (distribution)
10514
12723
  return {
10515
- libraries: distribution.plugins.map((plugin) => import_node_path10.default.join(moduleRoot, plugin)),
12724
+ libraries: distribution.plugins.map((plugin) => import_node_path11.default.join(moduleRoot, plugin)),
10516
12725
  stale: false
10517
12726
  };
10518
- const dir = import_node_path10.default.join(moduleRoot, ".build/host/RnxPreviewMacros");
12727
+ const dir = import_node_path11.default.join(moduleRoot, ".build/host/RnxPreviewMacros");
10519
12728
  const release = JSON.parse(
10520
- (0, import_node_fs8.readFileSync)(import_node_path10.default.join(moduleRoot, "toolchain.json"), "utf8")
12729
+ (0, import_node_fs8.readFileSync)(import_node_path11.default.join(moduleRoot, "toolchain.json"), "utf8")
10521
12730
  ).release;
10522
- const compilerStamp = import_node_path10.default.join(dir, "compiler-release");
12731
+ const compilerStamp = import_node_path11.default.join(dir, "compiler-release");
10523
12732
  const ext = process.platform === "darwin" ? "dylib" : "so";
10524
12733
  const plugins = [
10525
12734
  {
10526
- library: import_node_path10.default.join(dir, `libRnxPreviewMacros.${ext}`),
10527
- sources: [import_node_path10.default.join(moduleRoot, "Sources/RnxPreviewMacros/PreviewMacro.swift")]
12735
+ library: import_node_path11.default.join(dir, `libRnxPreviewMacros.${ext}`),
12736
+ sources: [import_node_path11.default.join(moduleRoot, "Sources/RnxPreviewMacros/PreviewMacro.swift")]
10528
12737
  },
10529
12738
  {
10530
- library: import_node_path10.default.join(dir, `libFoundationMacros.${ext}`),
12739
+ library: import_node_path11.default.join(dir, `libFoundationMacros.${ext}`),
10531
12740
  sources: [
10532
- import_node_path10.default.join(moduleRoot, "Sources/FoundationMacros/PredicateMacro.swift"),
10533
- import_node_path10.default.join(moduleRoot, "Sources/SwiftMacroSupport/PredicateExpression.swift")
12741
+ import_node_path11.default.join(moduleRoot, "Sources/FoundationMacros/PredicateMacro.swift"),
12742
+ import_node_path11.default.join(moduleRoot, "Sources/SwiftMacroSupport/PredicateExpression.swift")
10534
12743
  ]
10535
12744
  },
10536
12745
  {
10537
- library: import_node_path10.default.join(dir, `libTipKitMacros.${ext}`),
12746
+ library: import_node_path11.default.join(dir, `libTipKitMacros.${ext}`),
10538
12747
  sources: [
10539
- import_node_path10.default.join(moduleRoot, "Sources/TipKitMacros/TipKitMacros.swift"),
10540
- import_node_path10.default.join(moduleRoot, "Sources/SwiftMacroSupport/PredicateExpression.swift")
12748
+ import_node_path11.default.join(moduleRoot, "Sources/TipKitMacros/TipKitMacros.swift"),
12749
+ import_node_path11.default.join(moduleRoot, "Sources/SwiftMacroSupport/PredicateExpression.swift")
10541
12750
  ]
10542
12751
  }
10543
12752
  ];
@@ -10554,14 +12763,14 @@ async function ensureMacroPlugins(moduleRoot, toolchainBin, release, signal) {
10554
12763
  await runCompiler(
10555
12764
  "sh",
10556
12765
  [
10557
- import_node_path10.default.join(moduleRoot, "scripts/build-preview-plugin.sh"),
12766
+ import_node_path11.default.join(moduleRoot, "scripts/build-preview-plugin.sh"),
10558
12767
  toolchainBin,
10559
12768
  libraries[0]
10560
12769
  ],
10561
12770
  { signal }
10562
12771
  );
10563
12772
  (0, import_node_fs8.writeFileSync)(
10564
- import_node_path10.default.join(import_node_path10.default.dirname(libraries[0]), "compiler-release"),
12773
+ import_node_path11.default.join(import_node_path11.default.dirname(libraries[0]), "compiler-release"),
10565
12774
  `${release}
10566
12775
  `
10567
12776
  );
@@ -10577,7 +12786,7 @@ function swiftModuleDigest(root) {
10577
12786
  const files = swiftModuleInputFiles(root);
10578
12787
  const stampHash = (0, import_node_crypto7.createHash)("sha256");
10579
12788
  for (const file of files) {
10580
- const stat = (0, import_node_fs8.statSync)(import_node_path10.default.join(root, file), { bigint: true });
12789
+ const stat = (0, import_node_fs8.statSync)(import_node_path11.default.join(root, file), { bigint: true });
10581
12790
  stampHash.update(file);
10582
12791
  stampHash.update(
10583
12792
  `${stat.dev}:${stat.ino}:${stat.size}:${stat.mtimeNs}:${stat.ctimeNs}
@@ -10591,7 +12800,7 @@ function swiftModuleDigest(root) {
10591
12800
  for (const file of files) {
10592
12801
  hash2.update((0, import_node_crypto7.createHash)("sha256").update(file).digest());
10593
12802
  hash2.update(
10594
- (0, import_node_crypto7.createHash)("sha256").update((0, import_node_fs8.readFileSync)(import_node_path10.default.join(root, file))).digest()
12803
+ (0, import_node_crypto7.createHash)("sha256").update((0, import_node_fs8.readFileSync)(import_node_path11.default.join(root, file))).digest()
10595
12804
  );
10596
12805
  }
10597
12806
  const digest = hash2.digest();
@@ -10615,7 +12824,7 @@ function withNativeSourceGlue(input, glue) {
10615
12824
  ...input,
10616
12825
  files: {
10617
12826
  ...input.files,
10618
- [import_node_path10.default.posix.join(targetPath, "OneNativeSource.generated.swift")]: glue
12827
+ [import_node_path11.default.posix.join(targetPath, "OneNativeSource.generated.swift")]: glue
10619
12828
  },
10620
12829
  oneModule: true
10621
12830
  };
@@ -10686,8 +12895,8 @@ function swiftCondition(text3, available) {
10686
12895
  if (!call) return void 0;
10687
12896
  const [, name2, argument] = call;
10688
12897
  if (name2 === "os") return argument === "iOS" || argument === "WASI";
10689
- if (name2 === "canImport") return available.has(argument);
10690
- if (name2 === "targetEnvironment") return false;
12898
+ if (name2 === "canImport") return available?.has(argument);
12899
+ if (name2 === "targetEnvironment") return argument === "simulator";
10691
12900
  if (name2 === "arch") return argument === "wasm32";
10692
12901
  return void 0;
10693
12902
  };
@@ -10711,12 +12920,11 @@ function swiftCondition(text3, available) {
10711
12920
  };
10712
12921
  return either();
10713
12922
  }
10714
- function swiftImportNames(contents, available) {
10715
- const names = [];
12923
+ function* swiftConditionalLines(contents, available) {
10716
12924
  const frames = [];
10717
12925
  for (const line of contents.split("\n")) {
10718
12926
  const directive = /^\s*#(if|elseif|else|endif)\b(.*)$/.exec(line);
10719
- if (directive && available) {
12927
+ if (directive) {
10720
12928
  const [, kind, rest] = directive;
10721
12929
  const condition = (rest ?? "").replace(/\/\/.*$/, "").trim();
10722
12930
  if (kind === "if") {
@@ -10729,9 +12937,19 @@ function swiftImportNames(contents, available) {
10729
12937
  frame.active = frame.taken === true ? false : frame.taken === false ? holds : holds && void 0;
10730
12938
  frame.taken = frame.taken === true || holds === true ? true : frame.taken === false ? holds : void 0;
10731
12939
  }
12940
+ yield { line, active: false };
10732
12941
  continue;
10733
12942
  }
10734
- if (available && frames.some((frame) => frame.active !== true)) continue;
12943
+ yield {
12944
+ line,
12945
+ active: frames.some((frame) => frame.active === false) ? false : frames.every((frame) => frame.active === true) ? true : void 0
12946
+ };
12947
+ }
12948
+ }
12949
+ function swiftImportNames(contents, available) {
12950
+ const names = [];
12951
+ for (const { line, active } of swiftConditionalLines(contents, available)) {
12952
+ if (available && active !== true) continue;
10735
12953
  const name2 = SWIFT_IMPORT.exec(line)?.[1];
10736
12954
  if (name2) names.push(name2);
10737
12955
  }
@@ -10739,11 +12957,9 @@ function swiftImportNames(contents, available) {
10739
12957
  }
10740
12958
  function swiftPeachModules(moduleRoot) {
10741
12959
  const distribution = swiftDistributionAt(moduleRoot);
10742
- return distribution ? distribution.modules : [
10743
- ...(0, import_node_fs8.readFileSync)(import_node_path10.default.join(moduleRoot, "Package.swift"), "utf8").matchAll(
10744
- /\.(?:target|systemLibrary)\(\s*name:\s*"([^"]+)"/g
10745
- )
10746
- ].map((match) => match[1]);
12960
+ return distribution ? distribution.modules : swiftManifestDeclarations(
12961
+ (0, import_node_fs8.readFileSync)(import_node_path11.default.join(moduleRoot, "Package.swift"), "utf8")
12962
+ ).filter((target) => !target.executable).map((target) => target.name);
10747
12963
  }
10748
12964
  var sdkPaths = /* @__PURE__ */ new Map();
10749
12965
  function swiftSdkPaths(moduleRoot, toolchainBin) {
@@ -10751,8 +12967,8 @@ function swiftSdkPaths(moduleRoot, toolchainBin) {
10751
12967
  const key = JSON.stringify([toolchainBin, sdk, swiftSdkOptions()]);
10752
12968
  const cached = sdkPaths.get(key);
10753
12969
  if (cached) return cached;
10754
- const configuration = (0, import_node_child_process7.execFileSync)(
10755
- import_node_path10.default.join(toolchainBin, "swift"),
12970
+ const configuration = (0, import_node_child_process8.execFileSync)(
12971
+ import_node_path11.default.join(toolchainBin, "swift"),
10756
12972
  [
10757
12973
  "sdk",
10758
12974
  "configure",
@@ -10783,12 +12999,12 @@ function swiftAvailableModules(moduleRoot, toolchainBin) {
10783
12999
  if (cached) return cached;
10784
13000
  const modules = new Set(swiftPeachModules(moduleRoot));
10785
13001
  const { resources } = swiftSdkPaths(moduleRoot, toolchainBin);
10786
- for (const entry of (0, import_node_fs8.readdirSync)(import_node_path10.default.join(resources, "wasi"))) {
13002
+ for (const entry of (0, import_node_fs8.readdirSync)(import_node_path11.default.join(resources, "wasi"))) {
10787
13003
  if (entry.endsWith(".swiftmodule"))
10788
13004
  modules.add(entry.slice(0, -".swiftmodule".length));
10789
13005
  }
10790
13006
  for (const entry of (0, import_node_fs8.readdirSync)(resources)) {
10791
- const map2 = import_node_path10.default.join(resources, entry, "module.modulemap");
13007
+ const map2 = import_node_path11.default.join(resources, entry, "module.modulemap");
10792
13008
  if (!(0, import_node_fs8.existsSync)(map2)) continue;
10793
13009
  for (const match of (0, import_node_fs8.readFileSync)(map2, "utf8").matchAll(/^module\s+([A-Za-z_]\w*)/gm))
10794
13010
  modules.add(match[1]);
@@ -10796,12 +13012,14 @@ function swiftAvailableModules(moduleRoot, toolchainBin) {
10796
13012
  availableModules.set(key, modules);
10797
13013
  return modules;
10798
13014
  }
10799
- function missingSwiftModules(files, available) {
13015
+ function missingSwiftModules(files, available, providedByFile = () => []) {
10800
13016
  const missing = /* @__PURE__ */ new Map();
10801
13017
  for (const [file, contents] of Object.entries(files)) {
10802
13018
  if (!file.endsWith(".swift") || file === "Package.swift") continue;
10803
- for (const name2 of new Set(swiftImportNames(contents, available))) {
10804
- if (available.has(name2)) continue;
13019
+ const extra = providedByFile(file);
13020
+ const scoped = extra.length === 0 ? available : /* @__PURE__ */ new Set([...available, ...extra]);
13021
+ for (const name2 of new Set(swiftImportNames(contents, scoped))) {
13022
+ if (scoped.has(name2)) continue;
10805
13023
  missing.set(name2, [...missing.get(name2) ?? [], file]);
10806
13024
  }
10807
13025
  }
@@ -10853,8 +13071,8 @@ var EXECUTABLE_LINK_FLAGS = ` "-Xclang-linker", "-O0",
10853
13071
  "-Xlinker", "--global-base=8372224",
10854
13072
  `;
10855
13073
  var REACTOR_FLAG = '"-Xclang-linker", "-mexec-model=reactor",\n';
10856
- var MULTI_MANIFEST_VERSION = 40;
10857
- var compilerSourceDigest = true ? "9c8bf514e9d972c32ef441bda4effae79610e2c5add1faca769349803321528f" : swiftCompilerSourceDigest(__sootsim_import_meta_dirname);
13074
+ var MULTI_MANIFEST_VERSION = 43;
13075
+ var compilerSourceDigest = true ? "c3642227b6260bfa89e4a5f0278959ecb55637a4506e5196604eb471ca8418d1" : swiftCompilerSourceDigest(__sootsim_import_meta_dirname);
10858
13076
  function swiftArtifactHash(input, release, moduleRoot) {
10859
13077
  const hash2 = (0, import_node_crypto7.createHash)("sha256");
10860
13078
  hash2.update(`swift-compile
@@ -10897,6 +13115,11 @@ ${release}
10897
13115
  )
10898
13116
  );
10899
13117
  hash2.update(JSON.stringify(input.nativeTargets ?? []));
13118
+ hash2.update(JSON.stringify(input.packageGuestImports ?? []));
13119
+ for (const file of Object.keys(input.packageFiles ?? {}).sort()) {
13120
+ hash2.update(`package-file\0${file}\0`);
13121
+ hash2.update((0, import_node_crypto7.createHash)("sha256").update(input.packageFiles[file]).digest());
13122
+ }
10900
13123
  hash2.update(JSON.stringify(input.objcPeerStartup ?? null));
10901
13124
  for (const target of Object.keys(input.libraries ?? {}).sort()) {
10902
13125
  hash2.update(`library
@@ -10921,6 +13144,20 @@ ${target}
10921
13144
  }
10922
13145
  return hash2.digest("hex");
10923
13146
  }
13147
+ function swiftCrossImportFlags(moduleRoot, distribution) {
13148
+ const overlayRoot = import_node_path11.default.join(
13149
+ moduleRoot,
13150
+ distribution ? "modules" : "cross-import-overlays"
13151
+ );
13152
+ return (0, import_node_fs8.readdirSync)(overlayRoot, { encoding: "utf8", recursive: true }).filter((file) => file.endsWith(".swiftoverlay")).sort((left, right) => left.localeCompare(right)).flatMap((file) => [
13153
+ "-Xfrontend",
13154
+ "-swift-module-cross-import",
13155
+ "-Xfrontend",
13156
+ import_node_path11.default.basename(import_node_path11.default.dirname(file), ".swiftcrossimport"),
13157
+ "-Xfrontend",
13158
+ import_node_path11.default.join(overlayRoot, file)
13159
+ ]);
13160
+ }
10924
13161
  function emitSwiftPackageManifest(args) {
10925
13162
  const { targets, siblings, moduleRoot, oneModule, spriteKit, distribution } = args;
10926
13163
  const reachedFrameworks = /* @__PURE__ */ new Set();
@@ -10950,22 +13187,11 @@ function emitSwiftPackageManifest(args) {
10950
13187
  distributionLink.files.set(
10951
13188
  distributionLink.path,
10952
13189
  objects.map(
10953
- (object) => `"${import_node_path10.default.join(moduleRoot, object).replaceAll("\\", "\\\\").replaceAll('"', '\\"')}"`
13190
+ (object) => `"${import_node_path11.default.join(moduleRoot, object).replaceAll("\\", "\\\\").replaceAll('"', '\\"')}"`
10954
13191
  ).join("\n") + "\n"
10955
13192
  );
10956
13193
  }
10957
- const overlayRoot = import_node_path10.default.join(
10958
- moduleRoot,
10959
- distribution ? "modules" : "cross-import-overlays"
10960
- );
10961
- const overlayFlags = (0, import_node_fs8.readdirSync)(overlayRoot, { encoding: "utf8", recursive: true }).filter((file) => file.endsWith(".swiftoverlay")).sort((left, right) => left.localeCompare(right)).flatMap((file) => [
10962
- "-Xfrontend",
10963
- "-swift-module-cross-import",
10964
- "-Xfrontend",
10965
- import_node_path10.default.basename(import_node_path10.default.dirname(file), ".swiftcrossimport"),
10966
- "-Xfrontend",
10967
- import_node_path10.default.join(overlayRoot, file)
10968
- ]).map((flag) => `, ${JSON.stringify(flag)}`).join("");
13194
+ const overlayFlags = swiftCrossImportFlags(moduleRoot, Boolean(distribution)).map((flag) => `, ${JSON.stringify(flag)}`).join("");
10969
13195
  const executable = targets.find((target) => target.executable);
10970
13196
  if (!executable) throw new Error("swift-compile: no executable target to emit");
10971
13197
  const linkedNativeModules = [...args.native?.entries() ?? []].flatMap(
@@ -10979,7 +13205,10 @@ function emitSwiftPackageManifest(args) {
10979
13205
  const interoperability = target.cxxInterop ? " .interoperabilityMode(.Cxx)," : "";
10980
13206
  const exports2 = args.objcExports?.modules.has(target.name) || args.objcExports?.rootModule === target.name ? ' .enableExperimentalFeature("Extern"),' : "";
10981
13207
  const defines = (target.defines ?? []).map((name2) => ` .define(${JSON.stringify(name2)}),`).join("");
10982
- const imports = distribution ? `, "-I", ${JSON.stringify(import_node_path10.default.join(moduleRoot, "modules"))}` : "";
13208
+ const features = (target.experimentalFeatures ?? []).map((name2) => ` .enableExperimentalFeature(${JSON.stringify(name2)}),`).join("");
13209
+ const upcoming = (target.upcomingFeatures ?? []).map((name2) => ` .enableUpcomingFeature(${JSON.stringify(name2)}),`).join("");
13210
+ const upstream = (target.swiftFlags ?? []).map((flag) => `, ${JSON.stringify(flag)}`).join("");
13211
+ const imports = distribution ? `, "-I", ${JSON.stringify(import_node_path11.default.join(moduleRoot, "modules"))}` : "";
10983
13212
  const native = args.native?.get(target.name);
10984
13213
  const clang = native && !native.mixed;
10985
13214
  const nativeImports = (siblings.get(target.name) ?? []).filter((name2) => args.native?.has(name2) && !args.native.get(name2)?.mixed).map(
@@ -10999,10 +13228,15 @@ function emitSwiftPackageManifest(args) {
10999
13228
  const nativeImportFlags = [...importContext].flatMap((name2) => args.native?.get(name2)?.clang?.importFlags ?? []).map((flag) => `, "-Xcc", ${JSON.stringify(flag)}`).join("");
11000
13229
  const header = args.headerDirectory && [...args.native?.values() ?? []].some(
11001
13230
  (value) => value.late?.producers.includes(target.name)
11002
- ) ? `, "-emit-objc-header-path", ${JSON.stringify(import_node_path10.default.join(args.headerDirectory, `${target.name}-${args.objcExports?.modules.has(target.name) ? "Cxx" : "Swift"}.h`))}` : "";
11003
- const swiftSettings = `swiftSettings: [.swiftLanguageMode(.v${target.languageMode}),${isolation}${interoperability}${defines}${exports2} .unsafeFlags(["-Osize", "-Xfrontend", "-enable-cross-import-overlays"${overlayFlags}${FOUNDATION_IMPLICIT_FLAGS}${oneModule ? ONE_IMPLICIT_FLAGS : ""}${imports}${nativeImports}${nativeImportFlags}${header}])]`;
13231
+ ) ? `, "-emit-objc-header-path", ${JSON.stringify(import_node_path11.default.join(args.headerDirectory, `${target.name}-${args.objcExports?.modules.has(target.name) ? "Cxx" : "Swift"}.h`))}` : "";
13232
+ const swiftSettings = `swiftSettings: [.swiftLanguageMode(.v${target.languageMode}),${isolation}${interoperability}${defines}${features}${upcoming}${exports2} .unsafeFlags(["-Osize", "-Xfrontend", "-enable-cross-import-overlays"${overlayFlags}${FOUNDATION_IMPLICIT_FLAGS}${oneModule ? ONE_IMPLICIT_FLAGS : ""}${imports}${nativeImports}${nativeImportFlags}${header}${upstream}])]`;
11004
13233
  const deps = [
11005
13234
  .../* @__PURE__ */ new Set([
13235
+ ...(target.dependencies ?? []).flatMap(
13236
+ (dependency) => dependency.kind === "product" ? [
13237
+ `.product(name: ${JSON.stringify(dependency.name)}, package: ${JSON.stringify(dependency.package)})`
13238
+ ] : []
13239
+ ),
11006
13240
  ...target.executable ? [
11007
13241
  .../* @__PURE__ */ new Set([
11008
13242
  ...args.objcExports?.modules ?? [],
@@ -11051,11 +13285,11 @@ function emitSwiftPackageManifest(args) {
11051
13285
  const cDefines = macroSettings(target.cDefines);
11052
13286
  const cxxDefines = macroSettings(target.cxxDefines);
11053
13287
  const nativeSettings = native?.clang ? [
11054
- `cSettings: [${cDefines} .unsafeFlags(${JSON.stringify([...args.objcExports?.flags ?? args.nativeFlags ?? [], ...native.clang.flags])})]`,
11055
- `cxxSettings: [${cxxDefines} .unsafeFlags(${JSON.stringify(["-fno-cxx-modules", ...args.objcExports?.flags ?? args.nativeFlags ?? [], ...native.clang.cxxFlags])})]`
13288
+ `cSettings: [${cDefines} .unsafeFlags(${JSON.stringify([...args.nativeFlags?.get(target.name) ?? [], ...native.clang.flags])})]`,
13289
+ `cxxSettings: [${cxxDefines} .unsafeFlags(${JSON.stringify(["-fno-cxx-modules", ...args.nativeFlags?.get(target.name) ?? [], ...native.clang.cxxFlags])})]`
11056
13290
  ].join(", ") : [
11057
- `cSettings: [${cDefines} .unsafeFlags(${JSON.stringify([...args.objcExports?.flags ?? args.nativeFlags ?? [], ...native?.flags ?? []])})]`,
11058
- `cxxSettings: [${cxxDefines} .unsafeFlags(${JSON.stringify(["-fno-cxx-modules", ...args.objcExports?.flags ?? args.nativeFlags ?? [], ...native?.cxxFlags ?? []])})]`
13291
+ `cSettings: [${cDefines} .unsafeFlags(${JSON.stringify([...args.nativeFlags?.get(target.name) ?? [], ...native?.flags ?? []])})]`,
13292
+ `cxxSettings: [${cxxDefines} .unsafeFlags(${JSON.stringify(["-fno-cxx-modules", ...args.nativeFlags?.get(target.name) ?? [], ...native?.cxxFlags ?? []])})]`
11059
13293
  ].join(", ");
11060
13294
  return [
11061
13295
  ` ${kind}(`,
@@ -11064,9 +13298,10 @@ function emitSwiftPackageManifest(args) {
11064
13298
  ` path: ${JSON.stringify(native?.clang ? "." : target.path)},`,
11065
13299
  ...native ? [` exclude: ${JSON.stringify(native.exclude ?? native.lateSources)},`] : [],
11066
13300
  ...native?.clang ? [
11067
- ` sources: ${JSON.stringify(native.clang.sources.map((source) => import_node_path10.default.posix.join(native.path, source)))},`,
11068
- ` publicHeadersPath: ${JSON.stringify(import_node_path10.default.posix.dirname(native.clang.modulemap))},`
13301
+ ` sources: ${JSON.stringify(native.clang.sources.map((source) => import_node_path11.default.posix.join(native.path, source)))},`,
13302
+ ` publicHeadersPath: ${JSON.stringify(import_node_path11.default.posix.dirname(native.clang.modulemap))},`
11069
13303
  ] : native?.flags ? [` sources: ${JSON.stringify(native.sources)},`] : [],
13304
+ ...!native?.clang && target.publicHeadersPath !== void 0 ? [` publicHeadersPath: ${JSON.stringify(target.publicHeadersPath)},`] : [],
11070
13305
  // the native backend supplies dependency module maps without their
11071
13306
  // compiled modules. textual c++ includes keep those dependencies usable.
11072
13307
  ` ${clang ? nativeSettings : swiftSettings}${link}`,
@@ -11081,7 +13316,12 @@ function emitSwiftPackageManifest(args) {
11081
13316
  "let package = Package(",
11082
13317
  ' name: "app",',
11083
13318
  ` products: [.executable(name: "${executable.name}", targets: ["${executable.name}"])],`,
11084
- ` dependencies: [${distribution ? "" : `.package(path: "${moduleRoot}")`}],`,
13319
+ ` dependencies: [${[
13320
+ ...distribution ? [] : [`.package(path: ${JSON.stringify(moduleRoot)})`],
13321
+ ...[...args.packages ?? []].map(
13322
+ ([name2, directory]) => `.package(name: ${JSON.stringify(name2)}, path: ${JSON.stringify(directory)})`
13323
+ )
13324
+ ].join(", ")}],`,
11085
13325
  " targets: [",
11086
13326
  ...targets.map(stanza),
11087
13327
  ...args.objcExports ? [
@@ -11090,7 +13330,7 @@ function emitSwiftPackageManifest(args) {
11090
13330
  ' path: "PeachObjCExports",',
11091
13331
  ` sources: ${JSON.stringify(["root.m", ...[...args.objcExports.modules].map((name2) => `${name2}.m`)])},`,
11092
13332
  ' publicHeadersPath: "include",',
11093
- ` cSettings: [.unsafeFlags(${JSON.stringify([...args.objcExports.flags.filter((flag) => flag !== "-fobjc-arc"), "-fno-objc-arc", "-Xclang", "-disable-objc-default-synthesize-properties"])})]),`
13333
+ ` cSettings: [.unsafeFlags(${JSON.stringify([...args.nativeFlags.get(args.objcExports.rootModule).filter((flag) => flag !== "-fobjc-arc"), "-fno-objc-arc", "-Xclang", "-disable-objc-default-synthesize-properties"])})]),`
11094
13334
  ] : [],
11095
13335
  ...[...args.native?.entries() ?? []].flatMap(([name2, native]) => {
11096
13336
  const late = native.late;
@@ -11106,10 +13346,10 @@ function emitSwiftPackageManifest(args) {
11106
13346
  ` .target(name: ${JSON.stringify(group.name)},`,
11107
13347
  ` dependencies: ${JSON.stringify(native.mixed ? [] : [name2, ...late.producers])},`,
11108
13348
  ` path: ${JSON.stringify(native.clang ? "." : native.path)},`,
11109
- ` sources: ${JSON.stringify(native.clang ? group.sources.map((source) => import_node_path10.default.posix.join(native.path, source)) : group.sources)},`,
11110
- ` publicHeadersPath: ${JSON.stringify(native.clang ? import_node_path10.default.posix.dirname(native.clang.modulemap) : "include")},`,
11111
- ` cSettings: [${macroSettings(owner?.cDefines)} .unsafeFlags(${JSON.stringify([...args.objcExports?.flags ?? args.nativeFlags ?? [], ...group.flags])})],`,
11112
- ` cxxSettings: [${macroSettings(owner?.cxxDefines)} .unsafeFlags(${JSON.stringify(["-fno-cxx-modules", ...args.objcExports?.flags ?? args.nativeFlags ?? [], "-I", native.includeDirectory, "-I", args.headerDirectory, ...group.cxxFlags])})]),`
13349
+ ` sources: ${JSON.stringify(native.clang ? group.sources.map((source) => import_node_path11.default.posix.join(native.path, source)) : group.sources)},`,
13350
+ ` publicHeadersPath: ${JSON.stringify(native.clang ? import_node_path11.default.posix.dirname(native.clang.modulemap) : "include")},`,
13351
+ ` cSettings: [${macroSettings(owner?.cDefines)} .unsafeFlags(${JSON.stringify([...args.nativeFlags?.get(name2) ?? [], ...group.flags])})],`,
13352
+ ` cxxSettings: [${macroSettings(owner?.cxxDefines)} .unsafeFlags(${JSON.stringify(["-fno-cxx-modules", ...args.nativeFlags?.get(name2) ?? [], "-I", native.includeDirectory, "-I", args.headerDirectory, ...group.cxxFlags])})]),`
11113
13353
  ]) : [];
11114
13354
  }),
11115
13355
  args.cxxLanguageStandard ? ` ],
@@ -11122,7 +13362,7 @@ function syncSwiftTree(base, files) {
11122
13362
  (0, import_node_fs8.mkdirSync)(base, { recursive: true });
11123
13363
  const walk = (dir) => {
11124
13364
  for (const entry of (0, import_node_fs8.readdirSync)(dir, { withFileTypes: true })) {
11125
- const full = import_node_path10.default.join(dir, entry.name);
13365
+ const full = import_node_path11.default.join(dir, entry.name);
11126
13366
  if (dir === base && entry.name === ".build") continue;
11127
13367
  if (entry.isDirectory()) walk(full);
11128
13368
  else if (!files.has(full)) (0, import_node_fs8.rmSync)(full, { force: true });
@@ -11132,7 +13372,7 @@ function syncSwiftTree(base, files) {
11132
13372
  for (const [full, contents] of files) {
11133
13373
  if ((0, import_node_fs8.existsSync)(full) && (typeof contents === "string" ? (0, import_node_fs8.readFileSync)(full, "utf8") === contents : (0, import_node_fs8.readFileSync)(full).equals(contents)))
11134
13374
  continue;
11135
- (0, import_node_fs8.mkdirSync)(import_node_path10.default.dirname(full), { recursive: true });
13375
+ (0, import_node_fs8.mkdirSync)(import_node_path11.default.dirname(full), { recursive: true });
11136
13376
  (0, import_node_fs8.writeFileSync)(full, contents);
11137
13377
  }
11138
13378
  }
@@ -14901,25 +17141,229 @@ function swiftSourceClosure(files, roots) {
14901
17141
  return Object.fromEntries(Object.entries(files).filter(([file]) => included.has(file)));
14902
17142
  }
14903
17143
  function swiftApplicationEntry(file, source) {
14904
- const { tokens } = swiftCodeScan(source);
17144
+ const code = [...swiftConditionalLines(swiftCodeMask(source))].map(({ line, active }) => active === false ? " ".repeat(line.length) : line).join("\n");
17145
+ const { tokens } = swiftCodeScan(code);
14905
17146
  let depth = 0;
14906
17147
  for (const at of tokens) {
14907
17148
  if (source[at] === "{") depth++;
14908
17149
  else if (source[at] === "}") depth--;
14909
17150
  else if (depth === 0 && /^@(?:main|UIApplicationMain)\b/.test(source.slice(at)))
14910
17151
  return true;
14911
- else if (depth === 0 && import_node_path10.default.basename(file) === "main.swift" && /^UIApplicationMain\s*\(/.test(source.slice(at)))
17152
+ else if (depth === 0 && import_node_path11.default.basename(file) === "main.swift" && /^UIApplicationMain\s*\(/.test(source.slice(at)))
14912
17153
  return true;
14913
17154
  }
14914
17155
  return false;
14915
17156
  }
17157
+ var emptyMacroEnvironment = {
17158
+ defines: /* @__PURE__ */ new Map(),
17159
+ predefines: /* @__PURE__ */ new Map(),
17160
+ targetDefined: /* @__PURE__ */ new Set()
17161
+ };
17162
+ function cMacroDefined(name2, env) {
17163
+ if (env.defines.has(name2) || env.predefines.has(name2)) return true;
17164
+ if (env.targetDefined.has(name2)) return void 0;
17165
+ return false;
17166
+ }
17167
+ function cMacroIntOrTrue(value) {
17168
+ if (value === void 0) return true;
17169
+ if (/^0[xX][0-9a-fA-F]+[uUlL]*$/.test(value) || /^\d+[uUlL]*$/.test(value))
17170
+ return Number.parseInt(value) !== 0;
17171
+ return void 0;
17172
+ }
17173
+ function cMacroBareValue(name2, env) {
17174
+ if (env.defines.has(name2)) return cMacroIntOrTrue(env.defines.get(name2));
17175
+ if (env.predefines.has(name2)) return cMacroIntOrTrue(env.predefines.get(name2));
17176
+ if (env.targetDefined.has(name2)) return void 0;
17177
+ return false;
17178
+ }
17179
+ function cMacroNegated(name2, env) {
17180
+ const value = cMacroDefined(name2, env);
17181
+ return value === void 0 ? void 0 : !value;
17182
+ }
17183
+ function cConditionValue(expression, env) {
17184
+ let i = 0;
17185
+ const skipSpaces = () => {
17186
+ while (i < expression.length && /\s/.test(expression[i])) i++;
17187
+ };
17188
+ const parseOr = () => {
17189
+ let value2 = parseAnd();
17190
+ for (; ; ) {
17191
+ skipSpaces();
17192
+ if (!expression.startsWith("||", i)) return value2;
17193
+ i += 2;
17194
+ const right = parseAnd();
17195
+ value2 = value2 === void 0 || right === void 0 ? void 0 : value2 || right;
17196
+ }
17197
+ };
17198
+ const parseAnd = () => {
17199
+ let value2 = parseUnary();
17200
+ for (; ; ) {
17201
+ skipSpaces();
17202
+ if (!expression.startsWith("&&", i)) return value2;
17203
+ i += 2;
17204
+ const right = parseUnary();
17205
+ value2 = value2 === void 0 || right === void 0 ? void 0 : value2 && right;
17206
+ }
17207
+ };
17208
+ const parseUnary = () => {
17209
+ skipSpaces();
17210
+ if (expression[i] === "!") {
17211
+ i++;
17212
+ const value2 = parseUnary();
17213
+ return value2 === void 0 ? void 0 : !value2;
17214
+ }
17215
+ if (expression[i] === "(") {
17216
+ i++;
17217
+ const value2 = parseOr();
17218
+ skipSpaces();
17219
+ return expression[i] === ")" ? (i++, value2) : void 0;
17220
+ }
17221
+ const defined = /^defined\b/.exec(expression.slice(i));
17222
+ if (defined) {
17223
+ i += defined[0].length;
17224
+ skipSpaces();
17225
+ const parenthesized = expression[i] === "(";
17226
+ if (parenthesized) {
17227
+ i++;
17228
+ skipSpaces();
17229
+ }
17230
+ const name3 = /^\w+/.exec(expression.slice(i))?.[0];
17231
+ if (!name3) return void 0;
17232
+ i += name3.length;
17233
+ skipSpaces();
17234
+ if (parenthesized) {
17235
+ if (expression[i] !== ")") return void 0;
17236
+ i++;
17237
+ }
17238
+ return cMacroDefined(name3, env);
17239
+ }
17240
+ const literal = /^(0[xX][0-9a-fA-F]+|\d+)[uUlL]*/.exec(expression.slice(i));
17241
+ if (literal) {
17242
+ i += literal[0].length;
17243
+ return Number(literal[1]) !== 0;
17244
+ }
17245
+ const name2 = /^\w+/.exec(expression.slice(i))?.[0];
17246
+ if (!name2) return void 0;
17247
+ i += name2.length;
17248
+ return cMacroBareValue(name2, env);
17249
+ };
17250
+ const value = parseOr();
17251
+ skipSpaces();
17252
+ return i === expression.length ? value : void 0;
17253
+ }
17254
+ function cActiveCode(code, env) {
17255
+ const kept = [];
17256
+ const stack = [];
17257
+ let active = true;
17258
+ for (const line of code.replace(/\\\r?\n/g, "").split("\n")) {
17259
+ const directive = /^\s*#\s*(if|ifdef|ifndef|elif|elifdef|elifndef|else|endif)\b(.*)$/.exec(line);
17260
+ if (!directive) {
17261
+ if (active) kept.push(line);
17262
+ continue;
17263
+ }
17264
+ const keyword = directive[1];
17265
+ const rest = directive[2].trim();
17266
+ if (keyword === "if" || keyword === "ifdef" || keyword === "ifndef") {
17267
+ const name2 = /^\w+$/.exec(rest)?.[0];
17268
+ const value = keyword === "if" ? cConditionValue(rest, env) : name2 === void 0 ? void 0 : keyword === "ifdef" ? cMacroDefined(name2, env) : cMacroNegated(name2, env);
17269
+ stack.push({ parent: active, taken: value === true });
17270
+ active = active && value !== false;
17271
+ } else if (keyword === "endif") {
17272
+ active = stack.pop()?.parent ?? true;
17273
+ } else if (stack.length === 0) {
17274
+ continue;
17275
+ } else {
17276
+ const frame = stack[stack.length - 1];
17277
+ if (keyword === "else") {
17278
+ active = frame.parent && !frame.taken;
17279
+ frame.taken = true;
17280
+ } else {
17281
+ const name2 = /^\w+$/.exec(rest)?.[0];
17282
+ const value = keyword === "elif" ? cConditionValue(rest, env) : name2 === void 0 ? void 0 : keyword === "elifdef" ? cMacroDefined(name2, env) : cMacroNegated(name2, env);
17283
+ const branch = !frame.taken && value !== false;
17284
+ if (branch && value === true) frame.taken = true;
17285
+ active = frame.parent && branch;
17286
+ }
17287
+ }
17288
+ }
17289
+ return kept.join("\n");
17290
+ }
17291
+ function stripCCode(source) {
17292
+ let code = "";
17293
+ let i = 0;
17294
+ while (i < source.length) {
17295
+ if (source.startsWith("//", i)) {
17296
+ const end = source.indexOf("\n", i);
17297
+ i = end === -1 ? source.length : end;
17298
+ } else if (source.startsWith("/*", i)) {
17299
+ const end = source.indexOf("*/", i + 2);
17300
+ i = end === -1 ? source.length : end + 2;
17301
+ } else if (source[i] === '"' || source[i] === "'") {
17302
+ const quote = source[i];
17303
+ i++;
17304
+ while (i < source.length && source[i] !== quote) i += source[i] === "\\" ? 2 : 1;
17305
+ i++;
17306
+ } else {
17307
+ code += source[i];
17308
+ i++;
17309
+ }
17310
+ }
17311
+ return code;
17312
+ }
17313
+ function swiftCDefinedNames(sources) {
17314
+ const names = /* @__PURE__ */ new Set();
17315
+ for (const source of sources)
17316
+ for (const line of stripCCode(source).split("\n")) {
17317
+ const name2 = /^\s*#\s*define\s+([A-Za-z_]\w*)/.exec(line)?.[1];
17318
+ if (name2) names.add(name2);
17319
+ }
17320
+ return names;
17321
+ }
17322
+ var cPredefineTable = swift_c_predefines_default;
17323
+ var cPredefineCache = /* @__PURE__ */ new Map();
17324
+ function swiftCPredefines(language) {
17325
+ const cached = cPredefineCache.get(language);
17326
+ if (cached) return cached;
17327
+ const predefines = /* @__PURE__ */ new Map();
17328
+ for (const [name2, value] of Object.entries(cPredefineTable.languages[language]))
17329
+ predefines.set(name2, value ?? void 0);
17330
+ cPredefineCache.set(language, predefines);
17331
+ return predefines;
17332
+ }
17333
+ function swiftCMainEntry(file, source, env = emptyMacroEnvironment) {
17334
+ if (!isSwiftNativeTranslationUnit(file)) return false;
17335
+ const code = cActiveCode(stripCCode(source), env);
17336
+ for (const match of code.matchAll(/^\s*(?:int\s+|void\s+)?main\s*\(/gm)) {
17337
+ let depth = 1;
17338
+ let index = match.index + match[0].length;
17339
+ for (; index < code.length && depth > 0; index++) {
17340
+ if (code[index] === "(") depth++;
17341
+ else if (code[index] === ")") depth--;
17342
+ }
17343
+ if (depth > 0) continue;
17344
+ for (; index < code.length; index++) {
17345
+ const char = code[index];
17346
+ if (char === "{") return true;
17347
+ if (char === ";" || char === "}") break;
17348
+ if (char === "(" || char === "[") {
17349
+ const closer = char === "(" ? ")" : "]";
17350
+ let nested = 1;
17351
+ while (nested > 0 && ++index < code.length) {
17352
+ if (code[index] === char) nested++;
17353
+ else if (code[index] === closer) nested--;
17354
+ }
17355
+ }
17356
+ }
17357
+ }
17358
+ return false;
17359
+ }
14916
17360
  function installObjcPeerStartup(input, targets, compiled) {
14917
17361
  const startup = input.objcPeerStartup;
14918
17362
  if (!startup) return;
14919
17363
  function fail(detail) {
14920
17364
  throw new Error(`Objective-C peer startup: ${detail}`);
14921
17365
  }
14922
- if ((input.nativeTargets?.length ?? 0) > 0 || Object.keys(input.files).some((file2) => /\.(?:c|cc|cpp|cxx|m|mm)$/.test(file2)))
17366
+ if ((input.nativeTargets?.length ?? 0) > 0 || Object.keys(input.files).some(isSwiftNativeTranslationUnit))
14923
17367
  fail("original native source targets require constructor provenance before admission");
14924
17368
  validateObjcPeerStartupLibraries(input.libraries ?? {});
14925
17369
  const executables = targets.filter((target2) => target2.executable);
@@ -14941,7 +17385,7 @@ function installObjcPeerStartup(input, targets, compiled) {
14941
17385
  );
14942
17386
  if (entries.length === 0) {
14943
17387
  const source2 = compiled.get(input.entry);
14944
- if (import_node_path10.default.basename(input.entry) !== "main.swift" || source2 === void 0)
17388
+ if (import_node_path11.default.basename(input.entry) !== "main.swift" || source2 === void 0)
14945
17389
  fail("requires main.swift or a supported @main App/UIApplicationDelegate entry");
14946
17390
  compiled.set(input.entry, `_peachRegisterObjcPeers()
14947
17391
  ${source2}`);
@@ -15077,14 +17521,14 @@ function prepareSwiftDependency(source, destination) {
15077
17521
  for (const entry of (0, import_node_fs8.readdirSync)(from, { withFileTypes: true })) {
15078
17522
  if (entry.name === ".git" || entry.name === ".build" || entry.name === ".swiftpm")
15079
17523
  continue;
15080
- const file = import_node_path10.default.join(from, entry.name);
17524
+ const file = import_node_path11.default.join(from, entry.name);
15081
17525
  if (entry.isDirectory()) gather(file);
15082
17526
  else if (entry.isFile() && entry.name.endsWith(".swift"))
15083
- origins[import_node_path10.default.relative(source, file)] = (0, import_node_fs8.readFileSync)(file, "utf8");
17527
+ origins[import_node_path11.default.relative(source, file)] = (0, import_node_fs8.readFileSync)(file, "utf8");
15084
17528
  }
15085
17529
  };
15086
17530
  gather(source);
15087
- const manifest = import_node_path10.default.join(source, "Package.swift");
17531
+ const manifest = import_node_path11.default.join(source, "Package.swift");
15088
17532
  const targets = (0, import_node_fs8.existsSync)(manifest) ? swiftManifestTargets((0, import_node_fs8.readFileSync)(manifest, "utf8")) : [];
15089
17533
  const compiled = compiledSwiftSources(origins, targets);
15090
17534
  const copy = (from, to) => {
@@ -15092,11 +17536,11 @@ function prepareSwiftDependency(source, destination) {
15092
17536
  for (const entry of (0, import_node_fs8.readdirSync)(from, { withFileTypes: true })) {
15093
17537
  if (entry.name === ".git" || entry.name === ".build" || entry.name === ".swiftpm")
15094
17538
  continue;
15095
- const file = import_node_path10.default.join(from, entry.name);
15096
- const target = import_node_path10.default.join(to, entry.name);
17539
+ const file = import_node_path11.default.join(from, entry.name);
17540
+ const target = import_node_path11.default.join(to, entry.name);
15097
17541
  if (entry.isDirectory()) copy(file, target);
15098
17542
  else if (entry.isFile() && entry.name.endsWith(".swift"))
15099
- (0, import_node_fs8.writeFileSync)(target, compiled.get(import_node_path10.default.relative(source, file)));
17543
+ (0, import_node_fs8.writeFileSync)(target, compiled.get(import_node_path11.default.relative(source, file)));
15100
17544
  else (0, import_node_fs8.cpSync)(file, target, { verbatimSymlinks: true });
15101
17545
  }
15102
17546
  };
@@ -15108,6 +17552,14 @@ function writeSwiftProject(layout, input, moduleRoot) {
15108
17552
  throw new Error("swift compile input has invalid Objective-C peer startup metadata");
15109
17553
  if (input.nativeTargets !== void 0 && !isSwiftNativeTargets(input.nativeTargets))
15110
17554
  throw new Error("swift compile input has invalid original clang target inputs");
17555
+ if (input.packageFiles !== void 0 && !isSwiftPackageFiles(input.packageFiles))
17556
+ throw new Error("swift compile input has invalid original package files");
17557
+ const packages = input.packageFiles ? swiftManifestPackages(input.files["Package.swift"] ?? "") : /* @__PURE__ */ new Map();
17558
+ for (const directory of packages.values())
17559
+ if (!isSwiftResourcePath(directory) || !Object.hasOwn(input.packageFiles ?? {}, `${directory}/Package.swift`))
17560
+ throw new Error(
17561
+ `swift compile input has no transported package manifest for ${directory}`
17562
+ );
15111
17563
  if (input.resourceBundles !== void 0 && !isSwiftResourceBundles(input.resourceBundles))
15112
17564
  throw new Error("swift compile input has invalid target bundle assignments");
15113
17565
  const resourceTargets = swiftManifestTargets(
@@ -15118,7 +17570,7 @@ function writeSwiftProject(layout, input, moduleRoot) {
15118
17570
  const targets = distribution && compileTargets(input).length === 0 ? [
15119
17571
  {
15120
17572
  name: "App",
15121
- path: import_node_path10.default.relative(layout.root, layout.sources),
17573
+ path: import_node_path11.default.relative(layout.root, layout.sources),
15122
17574
  executable: true,
15123
17575
  languageMode: 5,
15124
17576
  mainActorIsolation: false,
@@ -15139,17 +17591,25 @@ function writeSwiftProject(layout, input, moduleRoot) {
15139
17591
  );
15140
17592
  if (target) swiftTargets.add(target.name);
15141
17593
  }
15142
- const headerDirectory = import_node_path10.default.join(layout.root, ".build", "peach-cxx-headers");
15143
- const headerModuleDirectory = import_node_path10.default.join(
17594
+ const headerDirectory = import_node_path11.default.join(layout.root, ".build", "peach-cxx-headers");
17595
+ const headerModuleDirectory = import_node_path11.default.join(
15144
17596
  layout.root,
15145
17597
  ".build",
15146
17598
  "peach-objc-export-modules"
15147
17599
  );
15148
17600
  const imports = /* @__PURE__ */ new Map();
15149
17601
  const objcProducers = /* @__PURE__ */ new Set();
17602
+ let checkedToolchain;
17603
+ const nativeToolchain = () => {
17604
+ if (checkedToolchain) return checkedToolchain;
17605
+ const pin = distribution ?? JSON.parse((0, import_node_fs8.readFileSync)(import_node_path11.default.join(moduleRoot, "toolchain.json"), "utf8"));
17606
+ checkedToolchain = swiftToolchain(pin.release, swiftModuleSdk(moduleRoot));
17607
+ return checkedToolchain;
17608
+ };
17609
+ const deploymentTarget = (name2) => input.nativeTargets?.find((value) => value.name === name2)?.deploymentTarget ?? "16.0";
15150
17610
  const targetStagedFiles = /* @__PURE__ */ new Map();
15151
17611
  const stageTargetFile = (target, file, contents, options) => {
15152
- const relative = import_node_path10.default.relative(layout.root, file).split(import_node_path10.default.sep).join(import_node_path10.default.posix.sep);
17612
+ const relative = import_node_path11.default.relative(layout.root, file).split(import_node_path11.default.sep).join(import_node_path11.default.posix.sep);
15153
17613
  const prior = files.has(file) ? files.get(file) : Object.hasOwn(input.files, relative) ? input.files[relative] : void 0;
15154
17614
  if (!options?.allowExisting && prior !== void 0)
15155
17615
  throw new Error(`target ${target} already contains generated output ${relative}`);
@@ -15178,9 +17638,9 @@ function writeSwiftProject(layout, input, moduleRoot) {
15178
17638
  else files.set(file, prior);
15179
17639
  }
15180
17640
  targetStagedFiles.delete(target.name);
15181
- if (entries.some(([file]) => /\.(?:c|cc|cpp|cxx|m|mm)$/.test(file)) && (swift || input.nativeTargets?.some((value) => value.name === target.name))) {
17641
+ if (entries.some(([file]) => isSwiftNativeTranslationUnit(file)) && (swift || input.nativeTargets?.some((value) => value.name === target.name))) {
15182
17642
  if (!swift) {
15183
- const unprepared = import_node_path10.default.join(
17643
+ const unprepared = import_node_path11.default.join(
15184
17644
  layout.root,
15185
17645
  target.path,
15186
17646
  "PeachUnprepared.generated.swift"
@@ -15195,7 +17655,7 @@ function writeSwiftProject(layout, input, moduleRoot) {
15195
17655
  native.set(target.name, {
15196
17656
  mixed: true,
15197
17657
  path: target.path,
15198
- includeDirectory: import_node_path10.default.join(layout.root, target.path, "include"),
17658
+ includeDirectory: import_node_path11.default.join(layout.root, target.path, "include"),
15199
17659
  sources: [],
15200
17660
  lateSources: [],
15201
17661
  exclude: entries.filter(([file]) => !file.endsWith(".swift") && !file.endsWith(".metal")).map(([file]) => file.slice(prefix.length))
@@ -15207,26 +17667,26 @@ function writeSwiftProject(layout, input, moduleRoot) {
15207
17667
  const contents = input.files[file];
15208
17668
  if (contents === void 0)
15209
17669
  throw new Error(`missing original Objective-C header ${file}`);
15210
- const destination = import_node_path10.default.join(layout.root, file);
15211
- (0, import_node_fs8.mkdirSync)(import_node_path10.default.dirname(destination), { recursive: true });
17670
+ const destination = import_node_path11.default.join(layout.root, file);
17671
+ (0, import_node_fs8.mkdirSync)(import_node_path11.default.dirname(destination), { recursive: true });
15212
17672
  (0, import_node_fs8.writeFileSync)(destination, contents);
15213
17673
  files.set(destination, contents);
15214
17674
  }
15215
17675
  for (const header of settings.publicHeaders) {
15216
- const destination = import_node_path10.default.join(headerDirectory, settings.name, import_node_path10.default.basename(header));
17676
+ const destination = import_node_path11.default.join(headerDirectory, settings.name, import_node_path11.default.basename(header));
15217
17677
  if (files.has(destination))
15218
17678
  throw new Error(`duplicate product header ${destination}`);
15219
- const contents = `#import ${JSON.stringify(import_node_path10.default.join(layout.root, header))}
17679
+ const contents = `#import ${JSON.stringify(import_node_path11.default.join(layout.root, header))}
15220
17680
  `;
15221
17681
  files.set(destination, contents);
15222
- (0, import_node_fs8.mkdirSync)(import_node_path10.default.dirname(destination), { recursive: true });
17682
+ (0, import_node_fs8.mkdirSync)(import_node_path11.default.dirname(destination), { recursive: true });
15223
17683
  (0, import_node_fs8.writeFileSync)(destination, contents);
15224
17684
  }
15225
17685
  }
15226
17686
  const nativeTargets = input.nativeTargets ?? [];
15227
- const fromInputRoot = (file) => file.startsWith(`${SWIFT_NATIVE_INPUT_ROOT}/`) ? import_node_path10.default.join(layout.root, file.slice(SWIFT_NATIVE_INPUT_ROOT.length + 1)) : file;
17687
+ const fromInputRoot = (file) => file.startsWith(`${SWIFT_NATIVE_INPUT_ROOT}/`) ? import_node_path11.default.join(layout.root, file.slice(SWIFT_NATIVE_INPUT_ROOT.length + 1)) : file;
15228
17688
  const headerSearch = writeXcodeHeaderSearch(
15229
- import_node_path10.default.join(layout.root, ".build", "peach-xcode-headers"),
17689
+ import_node_path11.default.join(layout.root, ".build", "peach-xcode-headers"),
15230
17690
  nativeTargets.map((settings) => ({
15231
17691
  headerMaps: settings.headerMaps.map((map2) => ({
15232
17692
  flag: map2.flag,
@@ -15237,19 +17697,19 @@ function writeSwiftProject(layout, input, moduleRoot) {
15237
17697
  })),
15238
17698
  productHeaders: Object.fromEntries(
15239
17699
  Object.entries(settings.productHeaders).map(([product, file]) => [
15240
- import_node_path10.default.join(layout.root, product),
15241
- import_node_path10.default.join(layout.root, file)
17700
+ import_node_path11.default.join(layout.root, product),
17701
+ import_node_path11.default.join(layout.root, file)
15242
17702
  ])
15243
17703
  ),
15244
17704
  userHeaderSearchPaths: settings.userHeaderSearchPaths.map(
15245
- (directory) => import_node_path10.default.join(layout.root, directory)
17705
+ (directory) => import_node_path11.default.join(layout.root, directory)
15246
17706
  )
15247
17707
  }))
15248
17708
  );
15249
17709
  for (const target of targets) {
15250
17710
  const prefix = target.path === "." ? "" : `${target.path}/`;
15251
17711
  const entries = targetEntries(target);
15252
- const units = entries.filter(([file]) => /\.(?:c|cc|cpp|cxx|m|mm)$/.test(file));
17712
+ const units = entries.filter(([file]) => isSwiftNativeTranslationUnit(file));
15253
17713
  if (units.length === 0) continue;
15254
17714
  const includes = `${prefix}include/`;
15255
17715
  const consumers = /* @__PURE__ */ new Map();
@@ -15265,7 +17725,7 @@ function writeSwiftProject(layout, input, moduleRoot) {
15265
17725
  if (producer && targets.some((value) => value.name === producer))
15266
17726
  producers2.add(producer);
15267
17727
  const local = [
15268
- import_node_path10.default.posix.join(import_node_path10.default.posix.dirname(file), include2),
17728
+ import_node_path11.default.posix.join(import_node_path11.default.posix.dirname(file), include2),
15269
17729
  `${includes}${include2}`
15270
17730
  ].find((candidate) => input.files[candidate] !== void 0);
15271
17731
  if (local) {
@@ -15295,21 +17755,16 @@ function writeSwiftProject(layout, input, moduleRoot) {
15295
17755
  const headers = settings.headers;
15296
17756
  const roots2 = settings.bridgingHeader ? [settings.bridgingHeader] : settings.publicHeaders;
15297
17757
  for (const file of headers) {
15298
- const destination = import_node_path10.default.join(layout.root, file);
15299
- (0, import_node_fs8.mkdirSync)(import_node_path10.default.dirname(destination), { recursive: true });
17758
+ const destination = import_node_path11.default.join(layout.root, file);
17759
+ (0, import_node_fs8.mkdirSync)(import_node_path11.default.dirname(destination), { recursive: true });
15300
17760
  (0, import_node_fs8.writeFileSync)(destination, input.files[file]);
15301
17761
  }
15302
- const search = [
15303
- .../* @__PURE__ */ new Set([
15304
- ...settings?.headerSearchPaths ?? [],
15305
- ...headers.map((file) => import_node_path10.default.posix.dirname(file))
15306
- ])
15307
- ].flatMap((dir) => ["-I", import_node_path10.default.join(layout.root, dir)]);
15308
- const pin = distribution ?? JSON.parse((0, import_node_fs8.readFileSync)(import_node_path10.default.join(moduleRoot, "toolchain.json"), "utf8"));
15309
- const release = pin.release;
15310
- const toolchainBin = swiftToolchain(release, swiftModuleSdk(moduleRoot));
17762
+ const search = [.../* @__PURE__ */ new Set([...settings?.headerSearchPaths ?? []])].flatMap(
17763
+ (dir) => ["-I", import_node_path11.default.join(layout.root, dir)]
17764
+ );
17765
+ const toolchainBin = nativeToolchain();
15311
17766
  const sdkHeaders = materializeObjcSdk(
15312
- import_node_path10.default.join(layout.root, ".build", "peach-objc-sdk")
17767
+ import_node_path11.default.join(layout.root, ".build", "peach-objc-sdk")
15313
17768
  );
15314
17769
  const stageFlags = (flags2, sdkInclude) => flags2.map(
15315
17770
  (flag) => flag.replaceAll(SWIFT_NATIVE_INPUT_ROOT, layout.root).replaceAll(SWIFT_NATIVE_SDK_INCLUDE, sdkInclude)
@@ -15320,27 +17775,27 @@ function writeSwiftProject(layout, input, moduleRoot) {
15320
17775
  ...search,
15321
17776
  ...(settings?.frameworkSearchPaths ?? []).flatMap((dir) => [
15322
17777
  "-F",
15323
- import_node_path10.default.join(layout.root, dir)
17778
+ import_node_path11.default.join(layout.root, dir)
15324
17779
  ]),
15325
17780
  "-I",
15326
17781
  headerDirectory
15327
17782
  ];
15328
17783
  const flags = stageFlags(
15329
17784
  originalFlags,
15330
- import_node_path10.default.join(swiftSdkPaths(moduleRoot, toolchainBin).sysroot, "include")
17785
+ import_node_path11.default.join(swiftSdkPaths(moduleRoot, toolchainBin).sysroot, "include")
15331
17786
  );
15332
- const prefixHeader = settings?.prefixHeader ? ["-include", import_node_path10.default.join(layout.root, settings.prefixHeader)] : [];
17787
+ const prefixHeader = settings?.prefixHeader ? ["-include", import_node_path11.default.join(layout.root, settings.prefixHeader)] : [];
15333
17788
  const bundleName = entries.some(([file]) => file.endsWith(".swift")) ? void 0 : swiftObjCResourceBundleName({
15334
17789
  target: target.name,
15335
17790
  path: target.path,
15336
17791
  resources: resourceTargets.find((candidate) => candidate.name === target.name)?.resources ?? false,
15337
17792
  usesBundleMacro: entries.some(
15338
- ([file, contents]) => /\.(?:c|cc|cpp|cxx|m|mm|h|hpp|hh|hxx)$/.test(file) && /\bSWIFTPM_MODULE_BUNDLE\b/.test(contents)
17793
+ ([file, contents]) => (isSwiftNativeTranslationUnit(file) || /\.(?:h|hpp|hh|hxx)$/.test(file)) && /\bSWIFTPM_MODULE_BUNDLE\b/.test(contents)
15339
17794
  ),
15340
17795
  bundles: input.resourceBundles
15341
17796
  });
15342
17797
  const accessor = bundleName === void 0 ? void 0 : swiftObjCResourceAccessor(bundleName);
15343
- const accessorHeader = import_node_path10.default.join(
17798
+ const accessorHeader = import_node_path11.default.join(
15344
17799
  layout.root,
15345
17800
  target.path,
15346
17801
  OBJC_RESOURCE_ACCESSOR_HEADER
@@ -15351,23 +17806,23 @@ function writeSwiftProject(layout, input, moduleRoot) {
15351
17806
  const nativeUnits = accessor ? [...units, [accessorUnit, accessor.body]] : units;
15352
17807
  const unitSource = (file) => {
15353
17808
  const relative = file.slice(prefix.length);
15354
- return relative.split("/").some((part) => part.startsWith(".")) ? import_node_path10.default.posix.join(HIDDEN_UNITS, relative.replaceAll(/(^|\/)\./g, "$1%2E")) : relative;
17809
+ return relative.split("/").some((part) => part.startsWith(".")) ? import_node_path11.default.posix.join(HIDDEN_UNITS, relative.replaceAll(/(^|\/)\./g, "$1%2E")) : relative;
15355
17810
  };
15356
17811
  const accessorFlags = accessor ? ["-include", accessorHeader] : [];
15357
17812
  let nativeC = !roots2.length && !entries.some(([file]) => file.endsWith(".swift")) && !units.some(([file]) => /\.mm?$/.test(file));
15358
17813
  if (roots2.length) {
15359
- const sourceHeaders = import_node_path10.default.join(
17814
+ const sourceHeaders = import_node_path11.default.join(
15360
17815
  layout.root,
15361
17816
  ".build",
15362
17817
  "peach-objc-originals",
15363
17818
  target.name
15364
17819
  );
15365
17820
  (0, import_node_fs8.mkdirSync)(sourceHeaders, { recursive: true });
15366
- const modulemap = import_node_path10.default.join(sourceHeaders, "module.modulemap");
17821
+ const modulemap = import_node_path11.default.join(sourceHeaders, "module.modulemap");
15367
17822
  (0, import_node_fs8.writeFileSync)(
15368
17823
  modulemap,
15369
17824
  `module ${swiftTargetModuleName(target.name)} {
15370
- ${roots2.map((file) => `header ${JSON.stringify(import_node_path10.default.join(layout.root, file))}`).join("\n")}
17825
+ ${roots2.map((file) => `header ${JSON.stringify(import_node_path11.default.join(layout.root, file))}`).join("\n")}
15371
17826
  export *
15372
17827
  }
15373
17828
  `
@@ -15379,12 +17834,12 @@ export *
15379
17834
  modulemap
15380
17835
  },
15381
17836
  toolchainBin,
15382
- import_node_path10.default.join(moduleRoot, "ios-simulator-stdlib"),
15383
- import_node_path10.default.join(layout.root, ".build", "peach-objc-sdk"),
15384
- import_node_path10.default.join(layout.root, ".build", "peach-objc-imports", target.name),
17837
+ import_node_path11.default.join(moduleRoot, "ios-simulator-stdlib"),
17838
+ import_node_path11.default.join(layout.root, ".build", "peach-objc-sdk"),
17839
+ import_node_path11.default.join(layout.root, ".build", "peach-objc-imports", target.name),
15385
17840
  {
15386
- flags: stageFlags(originalFlags, import_node_path10.default.join(sdkHeaders, "usr/include")),
15387
- target: `arm64-apple-ios${settings?.deploymentTarget ?? "16.0"}-simulator`
17841
+ flags: stageFlags(originalFlags, import_node_path11.default.join(sdkHeaders, "usr/include")),
17842
+ target: `arm64-apple-ios${deploymentTarget(target.name)}-simulator`
15388
17843
  }
15389
17844
  );
15390
17845
  const defined = /* @__PURE__ */ new Set();
@@ -15422,7 +17877,7 @@ export *
15422
17877
  imports.set(target.name, {
15423
17878
  view,
15424
17879
  classes: [...foreignTypes.values()],
15425
- headers: roots2.map((file) => import_node_path10.default.join(layout.root, file)),
17880
+ headers: roots2.map((file) => import_node_path11.default.join(layout.root, file)),
15426
17881
  foreignTypes
15427
17882
  });
15428
17883
  }
@@ -15431,25 +17886,25 @@ export *
15431
17886
  for (const [file, contents] of nativeUnits) {
15432
17887
  const origin = settings?.sourceDirectories[file];
15433
17888
  if (origin) {
15434
- const original = import_node_path10.default.join(layout.root, origin, import_node_path10.default.posix.basename(file));
15435
- (0, import_node_fs8.mkdirSync)(import_node_path10.default.dirname(original), { recursive: true });
17889
+ const original = import_node_path11.default.join(layout.root, origin, import_node_path11.default.posix.basename(file));
17890
+ (0, import_node_fs8.mkdirSync)(import_node_path11.default.dirname(original), { recursive: true });
15436
17891
  stageTargetFile(target.name, original, contents, { allowExisting: true });
15437
17892
  }
15438
17893
  const source = unitSource(file);
15439
17894
  if (source !== file.slice(prefix.length))
15440
17895
  stageTargetFile(
15441
17896
  target.name,
15442
- import_node_path10.default.join(layout.root, target.path, source),
17897
+ import_node_path11.default.join(layout.root, target.path, source),
15443
17898
  contents,
15444
17899
  {
15445
17900
  allowExisting: true
15446
17901
  }
15447
17902
  );
15448
17903
  const perFile = [
15449
- ...origin ? ["-iquote", import_node_path10.default.join(layout.root, origin)] : [],
17904
+ ...origin ? ["-iquote", import_node_path11.default.join(layout.root, origin)] : [],
15450
17905
  ...stageFlags(
15451
17906
  settings?.fileFlags[file] ?? [],
15452
- import_node_path10.default.join(swiftSdkPaths(moduleRoot, toolchainBin).sysroot, "include")
17907
+ import_node_path11.default.join(swiftSdkPaths(moduleRoot, toolchainBin).sysroot, "include")
15453
17908
  )
15454
17909
  ];
15455
17910
  const cxx = /\.(?:cc|cpp|cxx|mm)$/.test(file);
@@ -15470,7 +17925,7 @@ export *
15470
17925
  ...accessorFlags,
15471
17926
  ...stageFlags(
15472
17927
  cxx ? settings.cxxFlags : [],
15473
- import_node_path10.default.join(swiftSdkPaths(moduleRoot, toolchainBin).sysroot, "include")
17928
+ import_node_path11.default.join(swiftSdkPaths(moduleRoot, toolchainBin).sysroot, "include")
15474
17929
  ),
15475
17930
  ...perFile
15476
17931
  ]
@@ -15485,12 +17940,12 @@ export *
15485
17940
  flags: [...flags, "-fobjc-arc"],
15486
17941
  cxxFlags: [...flags, "-fobjc-arc"]
15487
17942
  });
15488
- const include2 = import_node_path10.default.join(layout.root, target.path, "include");
17943
+ const include2 = import_node_path11.default.join(layout.root, target.path, "include");
15489
17944
  if (accessor) {
15490
17945
  stageTargetFile(target.name, accessorHeader, accessor.header);
15491
17946
  stageTargetFile(
15492
17947
  target.name,
15493
- import_node_path10.default.join(layout.root, accessorUnit),
17948
+ import_node_path11.default.join(layout.root, accessorUnit),
15494
17949
  accessor.body
15495
17950
  );
15496
17951
  }
@@ -15529,12 +17984,12 @@ export *
15529
17984
  const contents = input.files[original];
15530
17985
  if (contents === void 0)
15531
17986
  throw new Error(`missing original module map ${original}`);
15532
- stageTargetFile(target.name, import_node_path10.default.join(layout.root, product), contents);
17987
+ stageTargetFile(target.name, import_node_path11.default.join(layout.root, product), contents);
15533
17988
  const [owner, ...implementations] = groups.values();
15534
17989
  if (!owner) throw new Error(`target ${target.name} has no original units`);
15535
17990
  native.set(target.name, {
15536
17991
  path: target.path,
15537
- includeDirectory: import_node_path10.default.join(layout.root, import_node_path10.default.dirname(product)),
17992
+ includeDirectory: import_node_path11.default.join(layout.root, import_node_path11.default.dirname(product)),
15538
17993
  sources: nativeUnits.map(([file]) => unitSource(file)),
15539
17994
  lateSources: implementations.flatMap((group) => group.sources),
15540
17995
  exclude: [],
@@ -15555,7 +18010,7 @@ export *
15555
18010
  }
15556
18011
  stageTargetFile(
15557
18012
  target.name,
15558
- import_node_path10.default.join(include2, "module.modulemap"),
18013
+ import_node_path11.default.join(include2, "module.modulemap"),
15559
18014
  `module ${target.name}ImplementationDeclarations { export * }
15560
18015
  `
15561
18016
  );
@@ -15591,7 +18046,7 @@ export *
15591
18046
  }
15592
18047
  native.set(target.name, {
15593
18048
  path: target.path,
15594
- includeDirectory: import_node_path10.default.join(layout.root, includes),
18049
+ includeDirectory: import_node_path11.default.join(layout.root, includes),
15595
18050
  sources: units.map(([file]) => file.slice(prefix.length)),
15596
18051
  lateSources: late.map(([file]) => file.slice(prefix.length)),
15597
18052
  ...late.length > 0 ? {
@@ -15609,7 +18064,7 @@ export *
15609
18064
  ([file]) => file.startsWith(includes) && /\.(?:h|hpp|hh|hxx)$/.test(file) && consumers.get(file).size === 0
15610
18065
  );
15611
18066
  files.set(
15612
- import_node_path10.default.join(layout.root, includes, "module.modulemap"),
18067
+ import_node_path11.default.join(layout.root, includes, "module.modulemap"),
15613
18068
  [
15614
18069
  `module ${target.name} {`,
15615
18070
  ...roots.map(
@@ -15626,7 +18081,7 @@ export *
15626
18081
  swiftModuleInputFiles(moduleRoot).join("\n")
15627
18082
  );
15628
18083
  if (!distribution) {
15629
- modulePlan.update((0, import_node_fs8.readFileSync)(import_node_path10.default.join(moduleRoot, "Package.swift")));
18084
+ modulePlan.update((0, import_node_fs8.readFileSync)(import_node_path11.default.join(moduleRoot, "Package.swift")));
15630
18085
  }
15631
18086
  const resourcePlan = (0, import_node_crypto7.createHash)("sha256").update(
15632
18087
  JSON.stringify(
@@ -15707,27 +18162,27 @@ export *
15707
18162
  objcModules.add(name2);
15708
18163
  rootOwner ??= exported ? [...exported.swift.keys()][0] : `${prefix}PeachObjCImports.generated.swift`;
15709
18164
  files.set(
15710
- import_node_path10.default.join(headerDirectory, `${name2}-Swift.h`),
18165
+ import_node_path11.default.join(headerDirectory, `${name2}-Swift.h`),
15711
18166
  exported?.header ?? "#pragma once\n"
15712
18167
  );
15713
18168
  files.set(
15714
- import_node_path10.default.join(headerDirectory, name2, `${name2}-Swift.h`),
18169
+ import_node_path11.default.join(headerDirectory, name2, `${name2}-Swift.h`),
15715
18170
  `#include "../${name2}-Swift.h"
15716
18171
  `
15717
18172
  );
15718
18173
  files.set(
15719
- import_node_path10.default.join(headerModuleDirectory, name2, "module.modulemap"),
18174
+ import_node_path11.default.join(headerModuleDirectory, name2, "module.modulemap"),
15720
18175
  `module ${swiftTargetModuleName(name2)} {
15721
18176
  ${[
15722
- import_node_path10.default.join(headerDirectory, `${name2}-Swift.h`),
15723
- ...(input.nativeTargets?.find((target2) => target2.name === name2)?.publicHeaders ?? []).map((header) => import_node_path10.default.join(layout.root, header))
18177
+ import_node_path11.default.join(headerDirectory, `${name2}-Swift.h`),
18178
+ ...(input.nativeTargets?.find((target2) => target2.name === name2)?.publicHeaders ?? []).map((header) => import_node_path11.default.join(layout.root, header))
15724
18179
  ].map((header) => ` header ${JSON.stringify(header)}`).join("\n")}
15725
18180
  export *
15726
18181
  }
15727
18182
  `
15728
18183
  );
15729
18184
  files.set(
15730
- import_node_path10.default.join(layout.root, "PeachObjCExports", `${name2}.m`),
18185
+ import_node_path11.default.join(layout.root, "PeachObjCExports", `${name2}.m`),
15731
18186
  exported?.implementation ?? `#include "${name2}-Cxx.h"
15732
18187
  `
15733
18188
  );
@@ -15739,13 +18194,13 @@ ${[
15739
18194
  if (generated) {
15740
18195
  const register = `_peach_objc_imports_${swiftTargetModuleName(name2)}`;
15741
18196
  files.set(
15742
- import_node_path10.default.join(layout.root, target.path, "PeachObjCImports.generated.swift"),
18197
+ import_node_path11.default.join(layout.root, target.path, "PeachObjCImports.generated.swift"),
15743
18198
  generated.swift + generated.registration + `
15744
18199
  @_cdecl("${register}") public func __peachRegisterOriginalObjC() { ${generated.registerFunction}() }
15745
18200
  `
15746
18201
  );
15747
18202
  files.set(
15748
- import_node_path10.default.join(layout.root, target.path, "PeachObjCImports.generated.m"),
18203
+ import_node_path11.default.join(layout.root, target.path, "PeachObjCImports.generated.m"),
15749
18204
  generated.objc
15750
18205
  );
15751
18206
  registrations.push(`${register}();`);
@@ -15803,7 +18258,7 @@ ${[
15803
18258
  exclude: []
15804
18259
  });
15805
18260
  files.set(
15806
- import_node_path10.default.join(layout.root, `PeachApplication/${name2}/Entry.swift`),
18261
+ import_node_path11.default.join(layout.root, `PeachApplication/${name2}/Entry.swift`),
15807
18262
  `import ${swiftTargetModuleName(target.name)}
15808
18263
  @main struct __PeachApplicationEntry { @MainActor static func main() { __peachRunApplication() } }
15809
18264
  `
@@ -15811,22 +18266,35 @@ ${[
15811
18266
  }
15812
18267
  const nativeFlags = (() => {
15813
18268
  if (native.size === 0) return void 0;
15814
- const headers = materializeObjcSdk(import_node_path10.default.join(layout.root, ".build", "peach-objc-sdk"));
15815
- return [
15816
- "-fobjc-runtime=gnustep-2.2",
15817
- "-fobjc-exceptions",
15818
- "-fexceptions",
15819
- "-fwasm-exceptions",
15820
- ...WASI_EMULATION_FLAGS,
15821
- "-fobjc-arc",
15822
- "-fblocks",
15823
- "-F",
15824
- import_node_path10.default.join(headers, "System/Library/Frameworks"),
15825
- "-idirafter",
15826
- import_node_path10.default.join(headers, "usr/include"),
15827
- "-I",
15828
- headerDirectory
15829
- ];
18269
+ const headers = materializeObjcSdk(import_node_path11.default.join(layout.root, ".build", "peach-objc-sdk"));
18270
+ const moduleMaps = rootOwner ? [...objcModules].map(
18271
+ (name2) => `-fmodule-map-file=${import_node_path11.default.join(headerModuleDirectory, name2, "module.modulemap")}`
18272
+ ) : [];
18273
+ return new Map(
18274
+ targets.map((target) => {
18275
+ const version = deploymentTarget(target.name);
18276
+ const minimum = iosDeploymentMinimum(version);
18277
+ if (minimum === void 0)
18278
+ throw new Error(
18279
+ `${target.name}: unsupported IPHONEOS_DEPLOYMENT_TARGET ${JSON.stringify(version)}`
18280
+ );
18281
+ return [
18282
+ target.name,
18283
+ [
18284
+ "-fobjc-runtime=gnustep-2.2",
18285
+ "-fobjc-exceptions",
18286
+ "-fexceptions",
18287
+ "-fwasm-exceptions",
18288
+ "-fobjc-arc",
18289
+ "-fblocks",
18290
+ ...objcSdkIntakeFlags(headers, nativeToolchain(), minimum),
18291
+ "-I",
18292
+ headerDirectory,
18293
+ ...moduleMaps
18294
+ ]
18295
+ ];
18296
+ })
18297
+ );
15830
18298
  })();
15831
18299
  let objcExports;
15832
18300
  if (rootOwner && input.objcPeerStartup)
@@ -15843,7 +18311,7 @@ ${[
15843
18311
  throw new Error(
15844
18312
  "Swift Objective-C export target conflicts with application sources"
15845
18313
  );
15846
- const ownerFile = import_node_path10.default.join(layout.root, rootOwner);
18314
+ const ownerFile = import_node_path11.default.join(layout.root, rootOwner);
15847
18315
  const ownerSource = compiled.get(rootOwner) ?? files.get(ownerFile);
15848
18316
  if (typeof ownerSource !== "string")
15849
18317
  throw new Error("Objective-C root registration has no owning Swift source");
@@ -15860,11 +18328,11 @@ public func __peachObjcExportRoot() { _objcRegisterPeerClass(NSObject.self, nati
15860
18328
  );
15861
18329
  if (compiled.has(rootOwner)) compiled.set(rootOwner, files.get(ownerFile).toString());
15862
18330
  files.set(
15863
- import_node_path10.default.join(layout.root, "PeachObjCExports", "include", "module.modulemap"),
18331
+ import_node_path11.default.join(layout.root, "PeachObjCExports", "include", "module.modulemap"),
15864
18332
  "module PeachSwiftObjCExports { export * }\n"
15865
18333
  );
15866
18334
  files.set(
15867
- import_node_path10.default.join(layout.root, "PeachObjCExports", "root.m"),
18335
+ import_node_path11.default.join(layout.root, "PeachObjCExports", "root.m"),
15868
18336
  [
15869
18337
  "#import <Foundation/Foundation.h>",
15870
18338
  "extern void _peach_objc_ensure_exports(void);",
@@ -15886,24 +18354,15 @@ public func __peachObjcExportRoot() { _objcRegisterPeerClass(NSObject.self, nati
15886
18354
  ""
15887
18355
  ].join("\n")
15888
18356
  );
15889
- objcExports = {
15890
- modules: objcModules,
15891
- rootModule,
15892
- flags: [
15893
- ...nativeFlags,
15894
- ...[...objcModules].map(
15895
- (name2) => `-fmodule-map-file=${import_node_path10.default.join(headerModuleDirectory, name2, "module.modulemap")}`
15896
- )
15897
- ]
15898
- };
18357
+ objcExports = { modules: objcModules, rootModule };
15899
18358
  }
15900
18359
  if (targets.length === 0) {
15901
18360
  for (const [file, contents] of Object.entries(input.files)) {
15902
18361
  if (file === "Package.swift") continue;
15903
- files.set(import_node_path10.default.join(layout.sources, file), compiled.get(file) ?? contents);
18362
+ files.set(import_node_path11.default.join(layout.sources, file), compiled.get(file) ?? contents);
15904
18363
  }
15905
18364
  let manifest = (0, import_node_fs8.readFileSync)(
15906
- import_node_path10.default.join(moduleRoot, "scripts/contrast-app-Package.swift"),
18365
+ import_node_path11.default.join(moduleRoot, "scripts/contrast-app-Package.swift"),
15907
18366
  "utf8"
15908
18367
  ).replaceAll("__SOOTSIM_SWIFT_PACKAGE__", moduleRoot);
15909
18368
  const reactor = ` ${REACTOR_FLAG}`;
@@ -15947,23 +18406,24 @@ public func __peachObjcExportRoot() { _objcRegisterPeerClass(NSObject.self, nati
15947
18406
  manifest = manifest.replace(anchor, `${anchor}
15948
18407
  ${SPRITEKIT_PRODUCT},`);
15949
18408
  }
15950
- files.set(import_node_path10.default.join(layout.root, "Package.swift"), manifest + moduleFiles);
18409
+ files.set(import_node_path11.default.join(layout.root, "Package.swift"), manifest + moduleFiles);
15951
18410
  } else {
15952
18411
  const base = layout.multi ? layout.root : layout.sources;
15953
18412
  const libraries = /* @__PURE__ */ new Map();
15954
18413
  for (const [target, data] of Object.entries(input.libraries ?? {})) {
15955
- const file = import_node_path10.default.join(layout.root, ".peach-libraries", `lib${target}.a`);
18414
+ const file = import_node_path11.default.join(layout.root, ".peach-libraries", `lib${target}.a`);
15956
18415
  files.set(file, Buffer.from(data, "base64"));
15957
18416
  libraries.set(target, file);
15958
18417
  }
15959
18418
  for (const [file, contents] of Object.entries(input.files)) {
15960
18419
  if (file === "Package.swift") continue;
15961
- files.set(import_node_path10.default.join(base, file), compiled.get(file) ?? contents);
18420
+ files.set(import_node_path11.default.join(base, file), compiled.get(file) ?? contents);
15962
18421
  }
15963
18422
  files.set(
15964
- import_node_path10.default.join(layout.root, "Package.swift"),
18423
+ import_node_path11.default.join(layout.root, "Package.swift"),
15965
18424
  emitSwiftPackageManifest({
15966
18425
  targets,
18426
+ packages,
15967
18427
  native,
15968
18428
  objcExports,
15969
18429
  nativeFlags,
@@ -15980,13 +18440,38 @@ public func __peachObjcExportRoot() { _objcRegisterPeerClass(NSObject.self, nati
15980
18440
  spriteKit: importsSpriteKit(input.files),
15981
18441
  distribution: distribution ?? void 0,
15982
18442
  distributionLink: {
15983
- path: import_node_path10.default.join(layout.root, ".peach-distribution-objects.rsp"),
18443
+ path: import_node_path11.default.join(layout.root, ".peach-distribution-objects.rsp"),
15984
18444
  files
15985
18445
  },
15986
18446
  libraries
15987
18447
  }) + moduleFiles
15988
18448
  );
15989
18449
  }
18450
+ for (const [file, bytes] of Object.entries(input.packageFiles ?? {}))
18451
+ files.set(import_node_path11.default.join(layout.root, file), Buffer.from(bytes, "base64"));
18452
+ if (input.packageFiles) {
18453
+ files.set(
18454
+ import_node_path11.default.join(layout.root, ".peach-target-toolset.json"),
18455
+ JSON.stringify({
18456
+ schemaVersion: "1.0",
18457
+ swiftCompiler: {
18458
+ extraCLIOptions: [
18459
+ "-I",
18460
+ distribution ? import_node_path11.default.join(moduleRoot, "modules") : import_node_path11.default.join(layout.root, ".build", WASM_TRIPLE, "release", "Modules"),
18461
+ "-Xfrontend",
18462
+ "-enable-cross-import-overlays",
18463
+ ...swiftCrossImportFlags(moduleRoot, Boolean(distribution)),
18464
+ ...distribution ? FOUNDATION_IMPLICIT_MODULES.flatMap((module2) => [
18465
+ "-Xfrontend",
18466
+ "-import-module",
18467
+ "-Xfrontend",
18468
+ module2
18469
+ ]) : []
18470
+ ]
18471
+ }
18472
+ })
18473
+ );
18474
+ }
15990
18475
  for (const target of resourceTargets) {
15991
18476
  if (!target.resources) continue;
15992
18477
  const bundle = input.resourceBundles?.find(
@@ -15996,9 +18481,9 @@ public func __peachObjcExportRoot() { _objcRegisterPeerClass(NSObject.self, nati
15996
18481
  throw new Error(
15997
18482
  `swift resource target ${target.name} has no matching bundle assignment`
15998
18483
  );
15999
- const directory = layout.multi ? import_node_path10.default.join(layout.root, target.path) : layout.sources;
18484
+ const directory = layout.multi ? import_node_path11.default.join(layout.root, target.path) : layout.sources;
16000
18485
  files.set(
16001
- import_node_path10.default.join(directory, "ResourceBundleAccessor.generated.swift"),
18486
+ import_node_path11.default.join(directory, "ResourceBundleAccessor.generated.swift"),
16002
18487
  [
16003
18488
  "import Foundation",
16004
18489
  "",
@@ -16015,7 +18500,7 @@ public func __peachObjcExportRoot() { _objcRegisterPeerClass(NSObject.self, nati
16015
18500
  }
16016
18501
  for (const [file, source] of compiled)
16017
18502
  if (!Object.hasOwn(input.files, file))
16018
- files.set(import_node_path10.default.join(layout.multi ? layout.root : layout.sources, file), source);
18503
+ files.set(import_node_path11.default.join(layout.multi ? layout.root : layout.sources, file), source);
16019
18504
  syncSwiftTree(layout.root, files);
16020
18505
  const producers = [
16021
18506
  .../* @__PURE__ */ new Set([
@@ -16037,10 +18522,10 @@ public func __peachObjcExportRoot() { _objcRegisterPeerClass(NSObject.self, nati
16037
18522
  targetFailures,
16038
18523
  ...rootOwner && objcExports ? {
16039
18524
  objcImplementations: {
16040
- owner: import_node_path10.default.join(layout.root, rootOwner),
18525
+ owner: import_node_path11.default.join(layout.root, rootOwner),
16041
18526
  registeredClasses: [...registeredClasses],
16042
18527
  units: [...native.values()].flatMap(
16043
- (value) => value.sources.filter((file) => /\.mm?$/.test(file)).map((file) => import_node_path10.default.join(layout.root, value.path, file))
18528
+ (value) => value.sources.filter((file) => /\.mm?$/.test(file)).map((file) => import_node_path11.default.join(layout.root, value.path, file))
16044
18529
  )
16045
18530
  }
16046
18531
  } : {}
@@ -16062,13 +18547,13 @@ function outputOf(error) {
16062
18547
  return error instanceof Error ? error.message : String(error);
16063
18548
  }
16064
18549
  function builtArtifact(layout) {
16065
- const binDir = import_node_path10.default.join(layout.root, ".build", WASM_TRIPLE, "release");
16066
- const manifest = (0, import_node_fs8.readFileSync)(import_node_path10.default.join(layout.root, "Package.swift"), "utf8");
18550
+ const binDir = import_node_path11.default.join(layout.root, ".build", WASM_TRIPLE, "release");
18551
+ const manifest = (0, import_node_fs8.readFileSync)(import_node_path11.default.join(layout.root, "Package.swift"), "utf8");
16067
18552
  const executable = swiftManifestTargets(manifest).find((target) => target.executable);
16068
18553
  if (executable === void 0) {
16069
18554
  throw new Error("swift-compile: the written manifest names no executable target");
16070
18555
  }
16071
- const file = import_node_path10.default.join(binDir, `${executable.name}.wasm`);
18556
+ const file = import_node_path11.default.join(binDir, `${executable.name}.wasm`);
16072
18557
  if (!(0, import_node_fs8.existsSync)(file)) {
16073
18558
  const found = (0, import_node_fs8.existsSync)(binDir) ? (0, import_node_fs8.readdirSync)(binDir).filter((name2) => name2.endsWith(".wasm")).sort() : [];
16074
18559
  throw new Error(
@@ -16079,7 +18564,7 @@ function builtArtifact(layout) {
16079
18564
  }
16080
18565
  function projectDiagnostic(output, layout, files) {
16081
18566
  const base = layout.multi ? layout.root : layout.sources;
16082
- const prefix = `${base}${import_node_path10.default.sep}`;
18567
+ const prefix = `${base}${import_node_path11.default.sep}`;
16083
18568
  return designTimeDiagnostic(output, files).split("\n").filter((line) => !SWIFTPM_NOISE.test(line)).map((line) => line.startsWith(prefix) ? line.slice(prefix.length) : line).join("\n").trim();
16084
18569
  }
16085
18570
  var ROOT_LOCKS = Symbol.for("peachsim.swiftCompile.rootLocks");
@@ -16115,12 +18600,12 @@ function serialize(root, work, signal) {
16115
18600
  function readCompiledArtifact(directory, hash2) {
16116
18601
  try {
16117
18602
  const receipt = JSON.parse(
16118
- (0, import_node_fs8.readFileSync)(import_node_path10.default.join(directory, "artifact.json"), "utf8")
18603
+ (0, import_node_fs8.readFileSync)(import_node_path11.default.join(directory, "artifact.json"), "utf8")
16119
18604
  );
16120
18605
  if (!receipt || typeof receipt !== "object" || !("hash" in receipt) || receipt.hash !== hash2 || !("icu" in receipt) || typeof receipt.icu !== "string" || !("wasm" in receipt) || typeof receipt.wasm !== "string")
16121
18606
  return null;
16122
- const bytes = (0, import_node_fs8.readFileSync)(import_node_path10.default.join(directory, "app.wasm"));
16123
- const gzip2 = (0, import_node_fs8.readFileSync)(import_node_path10.default.join(directory, "icu.gz"));
18607
+ const bytes = (0, import_node_fs8.readFileSync)(import_node_path11.default.join(directory, "app.wasm"));
18608
+ const gzip2 = (0, import_node_fs8.readFileSync)(import_node_path11.default.join(directory, "icu.gz"));
16124
18609
  if ((0, import_node_crypto7.createHash)("sha256").update(bytes).digest("hex") !== receipt.wasm || (0, import_node_crypto7.createHash)("sha256").update(gzip2).digest("hex") !== receipt.icu || bytes.length < 8 || bytes.readUInt32LE(0) !== 1836278016 || bytes.readUInt32LE(4) !== 1)
16125
18610
  return null;
16126
18611
  return { hash: hash2, bytes, icu: { sha256: receipt.icu, gzip: gzip2 } };
@@ -16131,14 +18616,14 @@ function readCompiledArtifact(directory, hash2) {
16131
18616
  }
16132
18617
  }
16133
18618
  function saveCompiledArtifact(root, artifact) {
16134
- const directory = import_node_path10.default.join(root, "artifact");
18619
+ const directory = import_node_path11.default.join(root, "artifact");
16135
18620
  (0, import_node_fs8.mkdirSync)(directory, { recursive: true });
16136
- const pending = (0, import_node_fs8.mkdtempSync)(import_node_path10.default.join(root, ".artifact-"));
18621
+ const pending = (0, import_node_fs8.mkdtempSync)(import_node_path11.default.join(root, ".artifact-"));
16137
18622
  try {
16138
- (0, import_node_fs8.writeFileSync)(import_node_path10.default.join(pending, "app.wasm"), artifact.bytes);
16139
- (0, import_node_fs8.writeFileSync)(import_node_path10.default.join(pending, "icu.gz"), artifact.icu.gzip);
18623
+ (0, import_node_fs8.writeFileSync)(import_node_path11.default.join(pending, "app.wasm"), artifact.bytes);
18624
+ (0, import_node_fs8.writeFileSync)(import_node_path11.default.join(pending, "icu.gz"), artifact.icu.gzip);
16140
18625
  (0, import_node_fs8.writeFileSync)(
16141
- import_node_path10.default.join(pending, "artifact.json"),
18626
+ import_node_path11.default.join(pending, "artifact.json"),
16142
18627
  JSON.stringify({
16143
18628
  hash: artifact.hash,
16144
18629
  wasm: (0, import_node_crypto7.createHash)("sha256").update(artifact.bytes).digest("hex"),
@@ -16146,7 +18631,7 @@ function saveCompiledArtifact(root, artifact) {
16146
18631
  })
16147
18632
  );
16148
18633
  for (const file of ["app.wasm", "icu.gz", "artifact.json"]) {
16149
- (0, import_node_fs8.renameSync)(import_node_path10.default.join(pending, file), import_node_path10.default.join(directory, file));
18634
+ (0, import_node_fs8.renameSync)(import_node_path11.default.join(pending, file), import_node_path11.default.join(directory, file));
16150
18635
  }
16151
18636
  } finally {
16152
18637
  (0, import_node_fs8.rmSync)(pending, { recursive: true, force: true });
@@ -16168,16 +18653,16 @@ function renewSharedArtifact(sharedRoot) {
16168
18653
  function pruneSharedArtifacts(parent, keep) {
16169
18654
  const entries = [];
16170
18655
  for (const name2 of (0, import_node_fs8.readdirSync)(parent)) {
16171
- const directory = import_node_path10.default.join(parent, name2);
18656
+ const directory = import_node_path11.default.join(parent, name2);
16172
18657
  if (name2.startsWith(RETIRED_PREFIX)) {
16173
18658
  (0, import_node_fs8.rmSync)(directory, { recursive: true, force: true });
16174
18659
  continue;
16175
18660
  }
16176
18661
  try {
16177
18662
  let bytes = 0;
16178
- for (const file of (0, import_node_fs8.readdirSync)(import_node_path10.default.join(directory, "artifact"))) {
18663
+ for (const file of (0, import_node_fs8.readdirSync)(import_node_path11.default.join(directory, "artifact"))) {
16179
18664
  try {
16180
- bytes += (0, import_node_fs8.statSync)(import_node_path10.default.join(directory, "artifact", file)).size;
18665
+ bytes += (0, import_node_fs8.statSync)(import_node_path11.default.join(directory, "artifact", file)).size;
16181
18666
  } catch (error) {
16182
18667
  if (!vanished(error)) throw error;
16183
18668
  }
@@ -16192,9 +18677,9 @@ function pruneSharedArtifacts(parent, keep) {
16192
18677
  if (total <= SHARED_ARTIFACT_BUDGET_BYTES) break;
16193
18678
  if (entry.directory === keep || Date.now() - entry.used < SHARED_ARTIFACT_GRACE_MS)
16194
18679
  continue;
16195
- const retired = import_node_path10.default.join(
18680
+ const retired = import_node_path11.default.join(
16196
18681
  parent,
16197
- `${RETIRED_PREFIX}${process.pid}-${import_node_path10.default.basename(entry.directory)}`
18682
+ `${RETIRED_PREFIX}${process.pid}-${import_node_path11.default.basename(entry.directory)}`
16198
18683
  );
16199
18684
  try {
16200
18685
  if ((0, import_node_fs8.statSync)(entry.directory).mtimeMs !== entry.used) continue;
@@ -16210,7 +18695,7 @@ function pruneSharedArtifacts(parent, keep) {
16210
18695
  function saveSharedArtifact(sharedRoot, artifact) {
16211
18696
  saveCompiledArtifact(sharedRoot, artifact);
16212
18697
  renewSharedArtifact(sharedRoot);
16213
- pruneSharedArtifacts(import_node_path10.default.dirname(sharedRoot), sharedRoot);
18698
+ pruneSharedArtifacts(import_node_path11.default.dirname(sharedRoot), sharedRoot);
16214
18699
  }
16215
18700
  var retainedArtifacts = /* @__PURE__ */ new Map();
16216
18701
  function retain(root, artifact) {
@@ -16227,14 +18712,14 @@ function compileSwiftProjectUnit(input, options) {
16227
18712
  options.signal?.throwIfAborted();
16228
18713
  (0, import_node_fs8.mkdirSync)(options.buildRoot, { recursive: true });
16229
18714
  const root = (0, import_node_fs8.realpathSync)(options.buildRoot);
16230
- const moduleRoot = import_node_path10.default.resolve(options.moduleRoot);
18715
+ const moduleRoot = import_node_path11.default.resolve(options.moduleRoot);
16231
18716
  const layout = {
16232
18717
  root,
16233
- sources: import_node_path10.default.join(root, "Sources", "App"),
18718
+ sources: import_node_path11.default.join(root, "Sources", "App"),
16234
18719
  multi: compileTargets(input).length > 0
16235
18720
  };
16236
18721
  const hash2 = swiftArtifactHash(input, options.release, moduleRoot);
16237
- const sharedRoot = import_node_path10.default.join(rnxHomeDir(), "cache", "swift-projects", hash2);
18722
+ const sharedRoot = import_node_path11.default.join(rnxHomeDir(), "cache", "swift-projects", hash2);
16238
18723
  const report = (message) => {
16239
18724
  console.error(`[swift-project ${hash2.slice(0, 16)}] ${message}`);
16240
18725
  options.onStage?.(message);
@@ -16248,8 +18733,8 @@ function compileSwiftProjectUnit(input, options) {
16248
18733
  report("reusing memory artifact");
16249
18734
  return retain(root, retained);
16250
18735
  }
16251
- const cached = readCompiledArtifact(import_node_path10.default.join(sharedRoot, "artifact"), hash2);
16252
- const previous = cached ?? readCompiledArtifact(import_node_path10.default.join(root, "artifact"), hash2);
18736
+ const cached = readCompiledArtifact(import_node_path11.default.join(sharedRoot, "artifact"), hash2);
18737
+ const previous = cached ?? readCompiledArtifact(import_node_path11.default.join(root, "artifact"), hash2);
16253
18738
  if (previous) {
16254
18739
  if (cached) renewSharedArtifact(sharedRoot);
16255
18740
  else saveSharedArtifact(sharedRoot, previous);
@@ -16258,8 +18743,8 @@ function compileSwiftProjectUnit(input, options) {
16258
18743
  }
16259
18744
  if (process.platform === "darwin" && process.env.TM_SESSION && !admittedMacBuilderSlot() && process.env.CI !== "true" && moduleRoot === sourceSwiftCheckout() && !swiftDistributionAt(moduleRoot)) {
16260
18745
  const requestRoot = (0, import_node_fs8.mkdtempSync)(`${root}.builder-request-`);
16261
- const output = import_node_path10.default.join(requestRoot, "output");
16262
- const request = import_node_path10.default.join(requestRoot, "request.json");
18746
+ const output = import_node_path11.default.join(requestRoot, "output");
18747
+ const request = import_node_path11.default.join(requestRoot, "request.json");
16263
18748
  (0, import_node_fs8.writeFileSync)(
16264
18749
  request,
16265
18750
  JSON.stringify({
@@ -16273,12 +18758,12 @@ function compileSwiftProjectUnit(input, options) {
16273
18758
  })
16274
18759
  );
16275
18760
  try {
16276
- const repo = import_node_path10.default.resolve(moduleRoot, "../..");
18761
+ const repo = import_node_path11.default.resolve(moduleRoot, "../..");
16277
18762
  report("requesting builder admission or cached result");
16278
18763
  await runCompiler(
16279
18764
  "bun",
16280
18765
  [
16281
- import_node_path10.default.join(repo, "scripts/build/swift-project.ts"),
18766
+ import_node_path11.default.join(repo, "scripts/build/swift-project.ts"),
16282
18767
  "--request",
16283
18768
  request,
16284
18769
  "--output",
@@ -16312,7 +18797,7 @@ function compileSwiftProjectUnit(input, options) {
16312
18797
  return withSwiftRootLock(
16313
18798
  root,
16314
18799
  async (lease) => {
16315
- const built = readCompiledArtifact(import_node_path10.default.join(sharedRoot, "artifact"), hash2);
18800
+ const built = readCompiledArtifact(import_node_path11.default.join(sharedRoot, "artifact"), hash2);
16316
18801
  if (built) {
16317
18802
  report("reusing verified disk artifact");
16318
18803
  return retain(root, built);
@@ -16321,7 +18806,7 @@ function compileSwiftProjectUnit(input, options) {
16321
18806
  const unprepared = preparation.targetFailures.map(
16322
18807
  (failure) => `error: target ${failure}`
16323
18808
  );
16324
- const swift = import_node_path10.default.join(options.toolchainBin, "swift");
18809
+ const swift = import_node_path11.default.join(options.toolchainBin, "swift");
16325
18810
  if (!(0, import_node_fs8.existsSync)(swift)) {
16326
18811
  throw new Error(
16327
18812
  `swift-compile: no swift.org toolchain at ${options.toolchainBin}; install ${options.release} and its matching wasm sdk`
@@ -16348,6 +18833,7 @@ function compileSwiftProjectUnit(input, options) {
16348
18833
  ...swiftSdkOptions(),
16349
18834
  "--swift-sdk",
16350
18835
  sdk,
18836
+ ...input.packageFiles ? ["--toolset", import_node_path11.default.join(root, ".peach-target-toolset.json")] : [],
16351
18837
  "-c",
16352
18838
  "release",
16353
18839
  "-Xswiftc",
@@ -16369,8 +18855,8 @@ function compileSwiftProjectUnit(input, options) {
16369
18855
  // shipped host plugins resolve against the selected compiler's runtime.
16370
18856
  ...process.platform === "linux" ? {
16371
18857
  LD_LIBRARY_PATH: [
16372
- import_node_path10.default.resolve(options.toolchainBin, "../lib/swift/linux"),
16373
- import_node_path10.default.resolve(options.toolchainBin, "../lib/swift/host"),
18858
+ import_node_path11.default.resolve(options.toolchainBin, "../lib/swift/linux"),
18859
+ import_node_path11.default.resolve(options.toolchainBin, "../lib/swift/host"),
16374
18860
  process.env.LD_LIBRARY_PATH
16375
18861
  ].filter(Boolean).join(":")
16376
18862
  } : {}
@@ -16382,6 +18868,17 @@ function compileSwiftProjectUnit(input, options) {
16382
18868
  };
16383
18869
  report("compiling and linking Swift modules");
16384
18870
  try {
18871
+ if (input.packageFiles && !swiftDistributionAt(moduleRoot)) {
18872
+ const frameworks = /* @__PURE__ */ new Set(["SwiftUI"]);
18873
+ for (const name2 of input.packageGuestImports ?? [])
18874
+ if (OPTIONAL_FRAMEWORKS.has(name2)) frameworks.add(name2);
18875
+ for (const framework of frameworks)
18876
+ await runCompiler(
18877
+ swift,
18878
+ [...buildArgs, "--target", framework],
18879
+ buildOptions
18880
+ );
18881
+ }
16385
18882
  for (const producer of preparation.headerProducers) {
16386
18883
  await runCompiler(
16387
18884
  swift,
@@ -16394,7 +18891,7 @@ function compileSwiftProjectUnit(input, options) {
16394
18891
  if (preparation.objcImplementations) {
16395
18892
  const plan = preparation.objcImplementations;
16396
18893
  const manifest = browser_default.parse(
16397
- (0, import_node_fs8.readFileSync)(import_node_path10.default.join(root, ".build", "release.yaml"), "utf8")
18894
+ (0, import_node_fs8.readFileSync)(import_node_path11.default.join(root, ".build", "release.yaml"), "utf8")
16398
18895
  );
16399
18896
  if (!isRecord(manifest) || !isRecord(manifest.commands))
16400
18897
  throw new Error("missing SwiftPM native compiler commands");
@@ -16451,7 +18948,7 @@ function compileSwiftProjectUnit(input, options) {
16451
18948
  );
16452
18949
  } catch (error) {
16453
18950
  const output = outputOf(error);
16454
- const moduleCache = import_node_path10.default.join(
18951
+ const moduleCache = import_node_path11.default.join(
16455
18952
  root,
16456
18953
  ".build",
16457
18954
  WASM_TRIPLE,
@@ -16524,6 +19021,9 @@ function compileSwiftProjectUnit(input, options) {
16524
19021
  swiftArtifactHash,
16525
19022
  swiftAvailableModules,
16526
19023
  swiftBuilderHopTimeoutMs,
19024
+ swiftCDefinedNames,
19025
+ swiftCMainEntry,
19026
+ swiftCPredefines,
16527
19027
  swiftCodeMask,
16528
19028
  swiftDistributionAt,
16529
19029
  swiftIcuAsset,