mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
[ConstraintSystem] Look through ArgumentAttribute element when computing a callee
This element is used purely for diagnostic purposes and locator
should behavior as if it's completely transparent.
(cherry picked from commit 622475bf15)
This commit is contained in:
@@ -730,7 +730,9 @@ ConstraintLocator *ConstraintSystem::getCalleeLocator(
|
||||
}
|
||||
|
||||
if (locator->isLastElement<LocatorPathElt::ArgumentAttribute>()) {
|
||||
return getConstraintLocator(anchor, path.drop_back());
|
||||
auto argLoc = getConstraintLocator(anchor, path.drop_back());
|
||||
return getCalleeLocator(argLoc, lookThroughApply, getType, simplifyType,
|
||||
getOverloadFor);
|
||||
}
|
||||
|
||||
// If we have a locator that starts with a key path component element, we
|
||||
|
||||
Reference in New Issue
Block a user