rust/src/librustdoc
Dylan DPC 2f06ac08e9
Rollup merge of #71250 - GuillaumeGomez:use-json-instead-of-js, r=kinnison
Replace big JS dict with JSON parsing

Part of #56545.

@ollie27 suggested that using JSON instead of a JS dict might be faster, so I decided to test it. And the results far exceeded whatever expectations I had...

I used https://github.com/adamgreig/stm32ral for my tests. If you want to build it locally:

```bash
$ cargo doc --features doc --open
```

But I strongly recommend to do it with this PR. Some numbers:

 * Loading a page with the JSON search-index: less than 1 second
 * Loading a page with the JS search-index: crashed after 30 seconds

I think the results are clear enough...

r? @ollie27

cc @rust-lang/rustdoc
2020-04-20 18:07:05 +02:00
..
clean Rollup merge of #71221 - cuviper:rustdoc_or_patterns, r=Mark-Simulacrum 2020-04-16 23:34:46 +02:00
html Rollup merge of #71250 - GuillaumeGomez:use-json-instead-of-js, r=kinnison 2020-04-20 18:07:05 +02:00
passes Dogfood or_patterns in rustdoc 2020-04-16 13:58:47 -07:00
test Normalize syntax::edition imports. 2020-01-02 19:31:38 +01:00
theme Add test to check if minified theme are handled correctly 2020-02-12 15:49:39 +01:00
Cargo.toml Update pulldown-cmark dependency 2020-02-14 22:39:45 +01:00
config.rs Depend on getopts from crates.io 2020-04-11 17:49:16 -04:00
core.rs Replace uses of parse_opt_* with parse_* where possible. 2020-04-19 19:53:54 +10:00
docfs.rs Fix clippy warnings 2020-04-15 23:38:48 +02:00
doctree.rs Don't redundantly repeat field names (clippy::redundant_field_names) 2020-03-06 19:42:18 +01:00
externalfiles.rs nix syntax::errors & prefer rustc_errors over errors 2020-01-10 07:41:30 +01:00
fold.rs Format the world 2019-12-22 17:42:47 -05:00
lib.rs Dogfood or_patterns in rustdoc 2020-04-16 13:58:47 -07:00
markdown.rs Create output dir in rustdoc markdown render 2020-03-26 23:06:17 +01:00
README.md rust-lang.github.io/rustc-dev-guide -> rustc-dev-guide.rust-lang.org 2020-03-10 17:08:18 -03:00
test.rs don't clone types that are copy (clippy::clone_on_copy) 2020-04-16 00:17:38 +02:00
theme.rs Expand and remove try_something macro. 2020-04-02 19:55:56 +02:00
visit_ast.rs Dogfood or_patterns in rustdoc 2020-04-16 13:58:47 -07:00
visit_lib.rs rustc -> rustc_middle part 3 (rustfmt) 2020-03-30 07:19:55 +02:00

For more information about how librustdoc works, see the rustc dev guide.