Enhance SubscriptDecl to be a DeclContext, so it can hold its indices.

This is necessary for some other work I'm doing, which really wants
paramdecls to have reasonable declcontexts.  It is also a small step
towards generic subscripts.
This commit is contained in:
Chris Lattner
2015-12-31 12:37:33 -08:00
parent 6dcb6ef594
commit feace85d5a
21 changed files with 104 additions and 26 deletions

View File

@@ -458,6 +458,7 @@ void Module::lookupMember(SmallVectorImpl<ValueDecl*> &results,
case DeclContextKind::Initializer:
case DeclContextKind::TopLevelCodeDecl:
case DeclContextKind::AbstractFunctionDecl:
case DeclContextKind::SubscriptDecl:
llvm_unreachable("This context does not support lookup.");
case DeclContextKind::FileUnit: