1
Fork 0

Remove unnecessary elem.name.length === 0 since the rustdoc search eBNF does not allow elements without a name

This commit is contained in:
Guillaume Gomez 2022-04-16 16:13:57 +02:00
parent ab9cf32131
commit a6051c76db

View file

@ -925,7 +925,7 @@ window.initSearch = function(rawSearchIndex) {
* no match, returns `MAX_LEV_DISTANCE + 1`.
*/
function checkType(row, elem, literalSearch) {
if (elem.name.length === 0 || row[NAME].length === 0) {
if (row[NAME].length === 0) {
// This is a pure "generic" search, no need to run other checks.
if (row.length > GENERICS_DATA) {
return checkIfInGenerics(row, elem);