[clang] [llvm] [clang][driver][darwin] Base the system prefix on the SDK, not the target (PR #171970)

Cyndy Ishida via llvm-commits llvm-commits at lists.llvm.org
Tue Dec 23 09:22:12 PST 2025


================
@@ -143,18 +179,29 @@ class DarwinSDKInfo {
 
   DarwinSDKInfo(
       VersionTuple Version, VersionTuple MaximumDeploymentTarget,
-      llvm::Triple::OSType OS,
+      ArrayRef<SupportedPlatform> SupportedPlatforms =
+          ArrayRef<SupportedPlatform>(),
       llvm::DenseMap<OSEnvPair::StorageType,
                      std::optional<RelatedTargetVersionMapping>>
           VersionMappings =
               llvm::DenseMap<OSEnvPair::StorageType,
                              std::optional<RelatedTargetVersionMapping>>())
       : Version(Version), MaximumDeploymentTarget(MaximumDeploymentTarget),
-        OS(OS), VersionMappings(std::move(VersionMappings)) {}
+        SupportedPlatforms(SupportedPlatforms),
+        VersionMappings(std::move(VersionMappings)) {}
 
   const llvm::VersionTuple &getVersion() const { return Version; }
 
-  const llvm::Triple::OSType &getOS() const { return OS; }
+  const SupportedPlatform &getCanonicalPlatform() const {
----------------
cyndyishida wrote:

Please also change this function name to match the return type name. 

https://github.com/llvm/llvm-project/pull/171970


More information about the llvm-commits mailing list