32
32
using namespace swift ;
33
33
using namespace irgen ;
34
34
35
- void OutliningMetadataCollector::collectTypeMetadataForLayout (SILType type ) {
35
+ void OutliningMetadataCollector::collectTypeMetadataForLayout (SILType ty ) {
36
36
// If the type has no archetypes, we can emit it from scratch in the callee.
37
- if (!type .hasArchetype ()) {
37
+ if (!ty .hasArchetype ()) {
38
38
return ;
39
39
}
40
40
41
41
// Substitute opaque types if allowed.
42
- type =
43
- IGF.IGM .substOpaqueTypesWithUnderlyingTypes (type, CanGenericSignature ());
42
+ ty = IGF.IGM .substOpaqueTypesWithUnderlyingTypes (ty, CanGenericSignature ());
44
43
45
- auto formalType = type .getASTType ();
46
- auto &ti = IGF.IGM .getTypeInfoForLowered (formalType );
44
+ auto astType = ty .getASTType ();
45
+ auto &ti = IGF.IGM .getTypeInfoForLowered (astType );
47
46
48
47
// We don't need the metadata for fixed size types or types that are not ABI
49
48
// accessible. Outlining will call the value witness of the enclosing type of
@@ -55,11 +54,11 @@ void OutliningMetadataCollector::collectTypeMetadataForLayout(SILType type) {
55
54
// If the type is a legal formal type, add it as a formal type.
56
55
// FIXME: does this force us to emit a more expensive metadata than we need
57
56
// to?
58
- if (formalType ->isLegalFormalType ()) {
59
- return collectFormalTypeMetadata (formalType );
57
+ if (astType ->isLegalFormalType ()) {
58
+ return collectFormalTypeMetadata (astType );
60
59
}
61
60
62
- collectRepresentationTypeMetadata (type );
61
+ collectRepresentationTypeMetadata (ty );
63
62
}
64
63
65
64
void OutliningMetadataCollector::collectFormalTypeMetadata (CanType type) {
0 commit comments