Add FunctionArgApplyInfo::getArgDescription

This commit adds a member which produces a string
describing the argument being applied. This will
either be its argument label or position in the
argument list.
This commit is contained in:
Hamish Knight
2019-11-04 11:03:05 -08:00
parent 398cb58a0d
commit 912a7acc1e
2 changed files with 54 additions and 6 deletions

View File

@@ -286,8 +286,8 @@ FailureDiagnostic::getFunctionArgApplyInfo(ConstraintLocator *locator) const {
auto argIdx = applyArgElt->getArgIdx();
auto paramIdx = applyArgElt->getParamIdx();
return FunctionArgApplyInfo(argExpr, argIdx, getType(argExpr), paramIdx,
fnInterfaceType, fnType, callee);
return FunctionArgApplyInfo(cs, argExpr, argIdx, getType(argExpr),
paramIdx, fnInterfaceType, fnType, callee);
}
Type FailureDiagnostic::restoreGenericParameters(