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.
2 parents 69c05c0 + 2aa0a71 commit 02ba2d3Copy full SHA for 02ba2d3
lib/Sema/TypeCheckAccess.cpp
@@ -1872,7 +1872,12 @@ class ExportabilityChecker : public DeclVisitor<ExportabilityChecker> {
1872
}
1873
1874
void visitExtensionDecl(ExtensionDecl *ED) {
1875
- if (shouldSkipChecking(ED->getExtendedNominal()))
+ auto extendedType = ED->getExtendedNominal();
1876
+ // TODO: Sometimes we have an extension that is marked valid but has no
1877
+ // extended type. Assert, just in case we see it while testing, but
1878
+ // don't crash. rdar://50401284
1879
+ assert(extendedType && "valid extension with no extended type?");
1880
+ if (!extendedType || shouldSkipChecking(extendedType))
1881
return;
1882
1883
// FIXME: We should allow conforming to implementation-only protocols,
0 commit comments