We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c2b13cd commit 3f553beCopy full SHA for 3f553be
stdlib/public/Reflection/TypeLowering.cpp
@@ -2121,7 +2121,9 @@ class LowerType
2121
return TC.getReferenceTypeInfo(Kind, ReferenceTI->getReferenceCounting());
2122
2123
if (auto *EnumTI = dyn_cast<EnumTypeInfo>(TI)) {
2124
- if (EnumTI->isOptional() && Kind == ReferenceKind::Weak) {
+ if (EnumTI->isOptional() &&
2125
+ (Kind == ReferenceKind::Weak || Kind == ReferenceKind::Unowned ||
2126
+ Kind == ReferenceKind::Unmanaged)) {
2127
auto *TI = TC.getTypeInfo(EnumTI->getCases()[0].TR, ExternalTypeInfo);
2128
return rebuildStorageTypeInfo(TI, Kind);
2129
}
0 commit comments