SIL representation

This commit is contained in:
Arnold Schwaighofer
2021-10-05 08:01:59 -07:00
parent 71f46a4f25
commit c2b2f1331f
19 changed files with 129 additions and 29 deletions

View File

@@ -3114,12 +3114,15 @@ public:
}
void noteUseOfExportedPrespecialization(const AbstractFunctionDecl *afd) {
bool hasNoted = false;
for (auto *A : afd->getAttrs().getAttributes<SpecializeAttr>()) {
auto *SA = cast<SpecializeAttr>(A);
if (!SA->isExported())
continue;
if (auto *targetFunctionDecl = SA->getTargetFunctionDecl(afd)) {
exportedPrespecializationDecls.push_back(S.addDeclRef(afd));
if (!hasNoted)
exportedPrespecializationDecls.push_back(S.addDeclRef(afd));
hasNoted = true;
}
}
}