@@ -2901,7 +2901,7 @@ class DocSearch {
2901
2901
const whereClause = new Map ( ) ;
2902
2902
2903
2903
const fnParamNames = obj . paramNames || [ ] ;
2904
- // @ts -expect-error
2904
+ /** @type { string[] } */
2905
2905
const queryParamNames = [ ] ;
2906
2906
/**
2907
2907
* Recursively writes a map of IDs to query generic names,
@@ -2934,7 +2934,7 @@ class DocSearch {
2934
2934
* index 2 is not highlighted, etc.
2935
2935
*
2936
2936
* @param {{name?: string, highlighted?: boolean} } fnType - input
2937
- * @param {[ string] } result
2937
+ * @param {string[ ] } result
2938
2938
*/
2939
2939
const pushText = ( fnType , result ) => {
2940
2940
// If !!(result.length % 2) == false, then pushing a new slot starts an even
@@ -2946,7 +2946,6 @@ class DocSearch {
2946
2946
// needs coerced to a boolean.
2947
2947
if ( ! ! ( result . length % 2 ) === ! ! fnType . highlighted ) {
2948
2948
result . push ( "" ) ;
2949
- // @ts -expect-error
2950
2949
} else if ( result . length === 0 && ! ! fnType . highlighted ) {
2951
2950
result . push ( "" ) ;
2952
2951
result . push ( "" ) ;
@@ -2960,7 +2959,7 @@ class DocSearch {
2960
2959
* or a trait bound on Fn, FnMut, or FnOnce.
2961
2960
*
2962
2961
* @param {rustdoc.HighlightedFunctionType } fnType - input
2963
- * @param {[ string] } result
2962
+ * @param {string[ ] } result
2964
2963
*/
2965
2964
const writeHof = ( fnType , result ) => {
2966
2965
const hofOutput = fnType . bindings . get ( this . typeNameIdOfOutput ) || [ ] ;
@@ -3000,7 +2999,7 @@ class DocSearch {
3000
2999
* Returns `false` if the supplied type isn't special.
3001
3000
*
3002
3001
* @param {rustdoc.HighlightedFunctionType } fnType
3003
- * @param {[ string] } result
3002
+ * @param {string[ ] } result
3004
3003
*/
3005
3004
const writeSpecialPrimitive = ( fnType , result ) => {
3006
3005
if ( fnType . id === this . typeNameIdOfArray || fnType . id === this . typeNameIdOfSlice ||
@@ -3047,7 +3046,7 @@ class DocSearch {
3047
3046
* updating the where clause and generic type param map.
3048
3047
*
3049
3048
* @param {rustdoc.HighlightedFunctionType } fnType
3050
- * @param {[ string] } result
3049
+ * @param {string[ ] } result
3051
3050
*/
3052
3051
const writeFn = ( fnType , result ) => {
3053
3052
if ( fnType . id !== null && fnType . id < 0 ) {
@@ -3065,7 +3064,6 @@ class DocSearch {
3065
3064
for ( const [ queryId , fnId ] of mgens ) {
3066
3065
if ( fnId === fnType . id ) {
3067
3066
mappedNames . set (
3068
- // @ts -expect-error
3069
3067
queryParamNames [ - 1 - queryId ] ,
3070
3068
fnParamNames [ - 1 - fnType . id ] ,
3071
3069
) ;
@@ -3080,7 +3078,6 @@ class DocSearch {
3080
3078
const where = [ ] ;
3081
3079
onEachBtwn (
3082
3080
fnType . generics ,
3083
- // @ts -expect-error
3084
3081
nested => writeFn ( nested , where ) ,
3085
3082
// @ts -expect-error
3086
3083
( ) => pushText ( { name : " + " , highlighted : false } , where ) ,
@@ -3115,7 +3112,6 @@ class DocSearch {
3115
3112
// shown in the where clause and name mapping output, but is
3116
3113
// redundant in this spot
3117
3114
for ( const value of values ) {
3118
- // @ts -expect-error
3119
3115
writeFn ( value , [ ] ) ;
3120
3116
}
3121
3117
return true ;
0 commit comments