mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Push get/setInterfaceType() up to ValueDecl.
No functionality change here. Swift SVN r9552
This commit is contained in:
@@ -749,10 +749,8 @@ static Optional<swift::Associativity> getActualAssociativity(uint8_t assoc) {
|
||||
|
||||
/// Retrieve the interface type for the given declaration.
|
||||
static Type getValueInterfaceType(ValueDecl *value) {
|
||||
if (auto func = dyn_cast<AbstractFunctionDecl>(value)) {
|
||||
if (auto interfaceTy = func->getInterfaceType())
|
||||
return interfaceTy;
|
||||
}
|
||||
if (auto interfaceTy = value->getInterfaceType())
|
||||
return interfaceTy;
|
||||
|
||||
return value->getType();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user