rustdoc: Inline reexported items if possible

Fixes #13414 and possibly #13045. Some examples to look at: `std::io`, `std::prelude`, `libc`. (Sorry, no tests yet!)

There are some known exceptions to inlining (e.g. statics), so they are preserved to the reexport section as much as possible. It would be desirable to remove such exceptions in the future.