rust/src/librustdoc/html
Andy Russell 2f6226518b
use top level fs functions where appropriate
This commit replaces many usages of `File::open` and reading or writing
with `fs::read_to_string`, `fs::read` and `fs::write`. This reduces code
complexity, and will improve performance for most reads, since the
functions allocate the buffer to be the size of the file.

I believe that this commit will not impact behavior in any way, so some
matches will check the error kind in case the file was not valid UTF-8.
Some of these cases may not actually care about the error.
2018-12-07 12:54:11 -05:00
..
static Rollup merge of #56332 - GuillaumeGomez:specifi-crate-search, r=QuietMisdreavus 2018-12-06 07:48:50 +01:00
escape.rs try! -> ? 2016-03-22 22:01:37 -05:00
format.rs rustdoc: Use dyn keyword when rendering dynamic traits 2018-10-15 00:48:57 +01:00
highlight.rs Remove not used DotEq token 2018-12-02 23:11:08 +09:00
item_type.rs handle proc-macros as macros instead of functions 2018-09-25 14:56:43 -05:00
layout.rs Rollup merge of #56332 - GuillaumeGomez:specifi-crate-search, r=QuietMisdreavus 2018-12-06 07:48:50 +01:00
markdown.rs Remove short doc where it starts with a codeblock 2018-11-10 19:03:58 +01:00
render.rs use top level fs functions where appropriate 2018-12-07 12:54:11 -05:00
static_files.rs Rollup merge of #56332 - GuillaumeGomez:specifi-crate-search, r=QuietMisdreavus 2018-12-06 07:48:50 +01:00
toc.rs Prefer to_string() to format!() 2018-07-27 11:11:18 +02:00