Open
Description
This is made more obvious by #41877, which corrects the spans of tags to their full spans, making the error spans even more ungainly. Here's one example; see the errors.txt diffs in the linked PR for more.
Expected behavior:
/** @type {Gioconda} */
~~~~~~~~~~~~~~~~ // before #41877
~~~~~~~~~~~~~~~~~ // after #41877 (both are wrong)
!!! error TS8030: The type of a function declaration must match the function's signature.
function monaLisa(sb) {
return typeof sb === 'string' ? 1 : 2;
}
Actual behavior:
/** @type {Gioconda} */
~~~~~~~~
!!! error TS8030: The type of a function declaration must match the function's signature.
function monaLisa(sb) {
return typeof sb === 'string' ? 1 : 2;
}