diff options
| author | bors <bors@rust-lang.org> | 2021-03-05 13:34:33 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2021-03-05 13:34:33 +0000 |
| commit | 8fd946c63a6c3aae9788bd459d278cb2efa77099 (patch) | |
| tree | 96945c52f9a705346f2b6f198475a80c3451c639 /src/librustdoc/html | |
| parent | 8ccc89bc312caa65ca46b55b47492abdd5b6910a (diff) | |
| parent | 16518e70fba278b8e1f7ae70f6941b453c459654 (diff) | |
| download | rust-8fd946c63a6c3aae9788bd459d278cb2efa77099.tar.gz rust-8fd946c63a6c3aae9788bd459d278cb2efa77099.zip | |
Auto merge of #82795 - m-ou-se:rollup-uzx0b92, r=m-ou-se
Rollup of 10 pull requests
Successful merges:
- #80723 (Implement NOOP_METHOD_CALL lint)
- #80763 (resolve: Reduce scope of `pub_use_of_private_extern_crate` deprecation lint)
- #81136 (Improved IO Bytes Size Hint)
- #81939 (Add suggestion `.collect()` for iterators in iterators)
- #82289 (Fix underflow in specialized ZipImpl::size_hint)
- #82728 (Avoid unnecessary Vec construction in BufReader)
- #82764 (Add {BTreeMap,HashMap}::try_insert)
- #82770 (Add assert_matches macro.)
- #82773 (Add diagnostic item to `Default` trait)
- #82787 (Remove unused code from main.js)
Failed merges:
r? `@ghost`
`@rustbot` modify labels: rollup
Diffstat (limited to 'src/librustdoc/html')
| -rw-r--r-- | src/librustdoc/html/static/main.js | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/src/librustdoc/html/static/main.js b/src/librustdoc/html/static/main.js index 89b1362b32b..c9b8100fd03 100644 --- a/src/librustdoc/html/static/main.js +++ b/src/librustdoc/html/static/main.js @@ -843,7 +843,6 @@ function defocusSearchBar() { function checkGenerics(obj, val) { // The names match, but we need to be sure that all generics kinda // match as well. - var lev_distance = MAX_LEV_DISTANCE + 1; if (val.generics.length > 0) { if (obj.length > GENERICS_DATA && obj[GENERICS_DATA].length >= val.generics.length) { @@ -866,7 +865,6 @@ function defocusSearchBar() { } if (lev.pos !== -1) { elems.splice(lev.pos, 1); - lev_distance = Math.min(lev.lev, lev_distance); total += lev.lev; done += 1; } else { @@ -2054,24 +2052,6 @@ function defocusSearchBar() { } } - /** - * Convert HTML to plaintext: - * - * * Replace "<code>foo</code>" with "`foo`" - * * Strip all other HTML tags - * - * Used by the dynamic sidebar crate list renderer. - * - * @param {[string]} html [The HTML to convert] - * @return {[string]} [The resulting plaintext] - */ - function convertHTMLToPlaintext(html) { - var x = document.createElement("div"); - x.innerHTML = html.replace('<code>', '`').replace('</code>', '`'); - return x.innerText; - } - - // delayed sidebar rendering. window.initSidebarItems = function(items) { var sidebar = document.getElementsByClassName("sidebar-elems")[0]; |
