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 af1defc commit 9823d16Copy full SHA for 9823d16
lib/AST/Decl.cpp
@@ -286,8 +286,8 @@ llvm::raw_ostream &swift::operator<<(llvm::raw_ostream &OS,
286
DeclContext *Decl::getInnermostDeclContext() const {
287
if (auto func = dyn_cast<AbstractFunctionDecl>(this))
288
return const_cast<AbstractFunctionDecl*>(func);
289
- if (auto nominal = dyn_cast<NominalTypeDecl>(this))
290
- return const_cast<NominalTypeDecl*>(nominal);
+ if (auto nominal = dyn_cast<GenericTypeDecl>(this))
+ return const_cast<GenericTypeDecl*>(nominal);
291
if (auto ext = dyn_cast<ExtensionDecl>(this))
292
return const_cast<ExtensionDecl*>(ext);
293
if (auto topLevel = dyn_cast<TopLevelCodeDecl>(this))
0 commit comments