Skip to content

Commit fceea87

Browse files
committed
KeyPaths: Support instantiating generic property descriptors from concrete contexts.
This is a bit easier than the fully general case where both the external descriptor and local pattern have captured arguments (because of generics or subscript indices) since we don't have to combine the two argument files in one component.
1 parent 02fa631 commit fceea87

File tree

4 files changed

+355
-178
lines changed

4 files changed

+355
-178
lines changed

stdlib/public/SwiftShims/KeyPath.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,11 @@ static const __swift_uint32_t _SwiftKeyPathComponentHeader_ComputedIDResolved
9898
static const __swift_uint32_t _SwiftKeyPathComponentHeader_ComputedIDUnresolvedIndirectPointer
9999
= 0x00000002U;
100100

101+
extern void *(swift_keyPathGenericWitnessTable[]);
102+
103+
static inline void *__swift_keyPathGenericWitnessTable_addr(void) {
104+
return swift_keyPathGenericWitnessTable;
105+
}
101106

102107
#ifdef __cplusplus
103108
} // extern "C"

0 commit comments

Comments
 (0)