mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-05-20 05:17:43 -05:00
fix(39245): change related diagnostic for missing rest parameter arguments (#39356)
Co-authored-by: Nathan Shively-Sanders <293473+sandersn@users.noreply.github.com>
This commit is contained in:
@@ -26377,7 +26377,8 @@ namespace ts {
|
||||
if (paramDecl) {
|
||||
related = createDiagnosticForNode(
|
||||
paramDecl,
|
||||
isBindingPattern(paramDecl.name) ? Diagnostics.An_argument_matching_this_binding_pattern_was_not_provided : Diagnostics.An_argument_for_0_was_not_provided,
|
||||
isBindingPattern(paramDecl.name) ? Diagnostics.An_argument_matching_this_binding_pattern_was_not_provided :
|
||||
isRestParameter(paramDecl) ? Diagnostics.Arguments_for_the_rest_parameter_0_were_not_provided : Diagnostics.An_argument_for_0_was_not_provided,
|
||||
!paramDecl.name ? argCount : !isBindingPattern(paramDecl.name) ? idText(getFirstIdentifier(paramDecl.name)) : undefined
|
||||
);
|
||||
}
|
||||
|
||||
@@ -4473,6 +4473,10 @@
|
||||
"category": "Message",
|
||||
"code": 6235
|
||||
},
|
||||
"Arguments for the rest parameter '{0}' were not provided.": {
|
||||
"category": "Error",
|
||||
"code": 6236
|
||||
},
|
||||
|
||||
"Projects to reference": {
|
||||
"category": "Message",
|
||||
|
||||
Reference in New Issue
Block a user