mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-05-29 16:29:19 -05:00
Give a related span pointing to the implementation signature when reporting incompatibility.
This commit is contained in:
@@ -24448,7 +24448,10 @@ namespace ts {
|
||||
const bodySignature = getSignatureFromDeclaration(bodyDeclaration);
|
||||
for (const signature of signatures) {
|
||||
if (!isImplementationCompatibleWithOverload(bodySignature, signature)) {
|
||||
error(signature.declaration, Diagnostics.This_overload_signature_is_not_compatible_with_its_implementation_signature);
|
||||
addRelatedInfo(
|
||||
error(signature.declaration, Diagnostics.This_overload_signature_is_not_compatible_with_its_implementation_signature),
|
||||
createDiagnosticForNode(bodyDeclaration, Diagnostics.The_implementation_signature_is_declared_here)
|
||||
);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2585,6 +2585,10 @@
|
||||
"category": "Error",
|
||||
"code": 2749
|
||||
},
|
||||
"The implementation signature is declared here.": {
|
||||
"category": "Error",
|
||||
"code": 2750
|
||||
},
|
||||
|
||||
"Import declaration '{0}' is using private name '{1}'.": {
|
||||
"category": "Error",
|
||||
|
||||
Reference in New Issue
Block a user