Remove code completion's dependencies on getProtocols().

Swift SVN r27976
This commit is contained in:
Doug Gregor
2015-04-30 16:13:43 +00:00
parent 46d61c52bb
commit 103526b771

View File

@@ -1888,7 +1888,7 @@ public:
if (auto *GP = dyn_cast<GenericTypeParamDecl>(D)) {
addGenericTypeParamRef(GP, Reason);
for (auto *protocol : GP->getProtocols())
for (auto *protocol : GP->getConformingProtocols(nullptr))
addConstructorCallsForType(protocol->getType(), GP->getName(),
Reason);
return;
@@ -1950,7 +1950,7 @@ public:
if (auto *GP = dyn_cast<GenericTypeParamDecl>(D)) {
addGenericTypeParamRef(GP, Reason);
for (auto *protocol : GP->getProtocols())
for (auto *protocol : GP->getConformingProtocols(nullptr))
addConstructorCallsForType(protocol->getType(), GP->getName(),
Reason);
return;