IRGen: Use SILTypes in field projection functions.

Swift SVN r5154
This commit is contained in:
Joe Groff
2013-05-10 23:17:08 +00:00
parent cdf95e6c5a
commit b439e49625
7 changed files with 36 additions and 19 deletions

View File

@@ -97,9 +97,9 @@ namespace {
OwnedAddress irgen::projectPhysicalStructMemberAddress(IRGenFunction &IGF,
OwnedAddress base,
CanType baseType,
SILType baseType,
unsigned fieldIndex) {
assert((baseType->is<StructType>() || baseType->is<BoundGenericStructType>())
assert((baseType.is<StructType>() || baseType.is<BoundGenericStructType>())
&& "not a struct type");
auto &baseTI = IGF.getFragileTypeInfo(baseType).as<StructTypeInfo>();
auto &fieldI = baseTI.getFields()[fieldIndex];
@@ -109,7 +109,7 @@ OwnedAddress irgen::projectPhysicalStructMemberAddress(IRGenFunction &IGF,
}
void irgen::projectPhysicalStructMemberFromExplosion(IRGenFunction &IGF,
CanType baseType,
SILType baseType,
Explosion &base,
unsigned fieldNo,
Explosion &out) {