Skip to content

Commit 4c3a009

Browse files
committed
SILGen: Remove triplesAreValidForZippering() assert.
This assert was correctly catching the fact that `-target-variant` is not being normalized at the same time as `-target` when building arm64e modules from swiftinterface. That should be fixed, but at the moment it isn't causing any concrete harm and the assertion fails when building against the SDKs included with the latest Xcode 16 betas. Resolves rdar://133020098.
1 parent 736faac commit 4c3a009

File tree

3 files changed

+6
-1
lines changed

3 files changed

+6
-1
lines changed

lib/SILGen/SILGenDecl.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1771,7 +1771,6 @@ SILValue SILGenFunction::emitZipperedOSVersionRangeCheck(
17711771
// macCatalyst process it will use the iOS version.
17721772
llvm::Triple VariantTriple = *getASTContext().LangOpts.TargetVariant;
17731773
llvm::Triple TargetTriple = getASTContext().LangOpts.Target;
1774-
assert(triplesAreValidForZippering(TargetTriple, VariantTriple));
17751774

17761775
// From perspective of the driver and most of the frontend,
17771776
// -target and -target-variant are symmetric. That is, the user

lib/Serialization/SerializedModuleLoader.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1323,6 +1323,7 @@ bool swift::extractCompilerFlagsFromInterface(
13231323
// we have loaded a Swift interface from a different-but-compatible
13241324
// architecture slice. Use the compatible subarchitecture.
13251325
for (unsigned I = 1; I < SubArgs.size(); ++I) {
1326+
// FIXME: Also fix up -target-variant (rdar://135322077).
13261327
if (strcmp(SubArgs[I - 1], "-target") != 0) {
13271328
continue;
13281329
}
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
// RUN: %target-swift-frontend -typecheck %s
2+
3+
// REQUIRES: OS=macosx
4+
5+
import System

0 commit comments

Comments
 (0)