mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Merge pull request #40587 from CodaFi/substitute-teacher
Initial Semantics for Variadic Generics
This commit is contained in:
@@ -4107,7 +4107,10 @@ GenericTypeParamDecl::GenericTypeParamDecl(DeclContext *dc, Identifier name,
|
||||
assert(Bits.GenericTypeParamDecl.Index == index && "Truncation");
|
||||
Bits.GenericTypeParamDecl.TypeSequence = isTypeSequence;
|
||||
auto &ctx = dc->getASTContext();
|
||||
auto type = new (ctx, AllocationArena::Permanent) GenericTypeParamType(this);
|
||||
RecursiveTypeProperties props = RecursiveTypeProperties::HasTypeParameter;
|
||||
if (this->isTypeSequence())
|
||||
props |= RecursiveTypeProperties::HasTypeSequence;
|
||||
auto type = new (ctx, AllocationArena::Permanent) GenericTypeParamType(this, props);
|
||||
setInterfaceType(MetatypeType::get(type, ctx));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user