@@ -172,7 +172,7 @@ FormalLinkage swift::getGenericSignatureLinkage(CanGenericSignature sig) {
172
172
case RequirementKind::Conformance:
173
173
case RequirementKind::SameType:
174
174
case RequirementKind::Superclass:
175
- switch (getTypeLinkage_correct (CanType (req.getSecondType ()))) {
175
+ switch (getTypeLinkage (CanType (req.getSecondType ()))) {
176
176
case FormalLinkage::PublicUnique:
177
177
case FormalLinkage::PublicNonUnique:
178
178
continue ;
@@ -189,19 +189,6 @@ FormalLinkage swift::getGenericSignatureLinkage(CanGenericSignature sig) {
189
189
return linkage;
190
190
}
191
191
192
- // / Return the formal linkage of the given formal type.
193
- // /
194
- // / Note that this function is buggy and generally should not be
195
- // / used in new code; we should migrate all callers to
196
- // / getTypeLinkage_correct and then consolidate them.
197
- FormalLinkage swift::getTypeLinkage (CanType t) {
198
- assert (t->isLegalFormalType ());
199
- // Due to a bug, this always returns PublicUnique.
200
- // It's a bit late in the 5.7 timeline to be changing that, but
201
- // we can optimize it!
202
- return FormalLinkage::PublicUnique;
203
- }
204
-
205
192
// / Return the formal linkage of the given formal type.
206
193
// / This in the appropriate linkage for a lazily-emitted entity
207
194
// / derived from the type.
@@ -211,7 +198,7 @@ FormalLinkage swift::getTypeLinkage(CanType t) {
211
198
// / uniquely-emitted nominal type, the formal linkage of that
212
199
// / type may differ from the formal linkage of the underlying
213
200
// / type declaration.
214
- FormalLinkage swift::getTypeLinkage_correct (CanType t) {
201
+ FormalLinkage swift::getTypeLinkage (CanType t) {
215
202
assert (t->isLegalFormalType ());
216
203
217
204
class Walker : public TypeWalker {
@@ -265,7 +252,6 @@ static bool isTypeMetadataForLayoutAccessible(SILModule &M, SILType type) {
265
252
266
253
// Otherwise, check that we can fetch the type metadata.
267
254
return M.isTypeMetadataAccessible (type.getASTType ());
268
-
269
255
}
270
256
271
257
// / Can we perform value operations on the given type? We have no way
0 commit comments