Skip to content

Commit 2acaa1a

Browse files
committed
ObjCBridgeMemo is only used on ObjC-supporting platforms
1 parent a2cd863 commit 2acaa1a

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

stdlib/public/runtime/DynamicCast.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -616,6 +616,7 @@ bool _swift_dictionaryDownCastConditionalIndirect(OpaqueValue *destination,
616616
const void *sourceKeyHashable,
617617
const void *targetKeyHashable);
618618

619+
#if SWIFT_OBJC_INTEROP
619620
// Helper to memoize bridging conformance data for a particular
620621
// Swift struct type. This is used to speed up the most common
621622
// ObjC->Swift bridging conversions by eliminating repeeated
@@ -691,6 +692,7 @@ struct ObjCBridgeMemo {
691692
destBridgeWitness, targetBridgedType);
692693
}
693694
};
695+
#endif
694696

695697
static DynamicCastResult
696698
tryCastToAnyHashable(

0 commit comments

Comments
 (0)