AST: Remove AnyFunctionRef::setCaptureInfo()

This commit is contained in:
Slava Pestov
2024-04-22 15:51:18 -04:00
parent 83bb9d0fe2
commit ce62a2e93b

View File

@@ -75,13 +75,6 @@ public:
return TheFunction.get<AbstractClosureExpr *>()->getCaptureInfo(); return TheFunction.get<AbstractClosureExpr *>()->getCaptureInfo();
} }
void setCaptureInfo(CaptureInfo captures) const {
if (auto *AFD = TheFunction.dyn_cast<AbstractFunctionDecl *>()) {
AFD->setCaptureInfo(captures);
return;
}
TheFunction.get<AbstractClosureExpr *>()->setCaptureInfo(captures);
}
bool hasType() const { bool hasType() const {
if (auto *AFD = TheFunction.dyn_cast<AbstractFunctionDecl *>()) if (auto *AFD = TheFunction.dyn_cast<AbstractFunctionDecl *>())