mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-31 21:47:15 +03:00
search.js: local variable extra is an array, annotate it as such.
This commit is contained in:
@@ -2398,9 +2398,9 @@ class DocSearch {
|
||||
continue;
|
||||
}
|
||||
if (!foundStopChar) {
|
||||
let extra = "";
|
||||
/** @type String[] */
|
||||
let extra = [];
|
||||
if (isLastElemGeneric(query.elems, parserState)) {
|
||||
// @ts-expect-error
|
||||
extra = [" after ", ">"];
|
||||
} else if (prevIs(parserState, "\"")) {
|
||||
throw ["Cannot have more than one element if you use quotes"];
|
||||
|
||||
Reference in New Issue
Block a user