Some improvements to the Cargo compiler file.
Use rustc's errorformat and add option to specify permanent parameters.
Updates based on kballard's feedback.
Added check for absolute file path, removed hard tab, and added documentation for new option.
Properly escape paths to executables. Fixes #18632.
Correct building documenation with Pandoc and TeX on Windows.
Guide: Puts the toc again in the doc

Closes #17505
Fix atomic::fence documentation typos
Fix handling of unboxed closure type param substitutions

- When selecting an implicit trait impl for an unboxed closure, plumb
  through and use the substitutions from impl selection instead of
  using those from the current param environment in trans, which may
  be incorrect.
- When generating a function declaration for an unboxed closure, plumb
  through the substitutions from the param environment of the closure
  as above.  Also normalize the type to avoid generating duplicate
  declarations due to regions being inconsistently replaced with
  ReStatic elsewhere.
- Do not place the closure type in the self param space when
  translating the unboxed closure callee, etc.  It is not actually
  used, and doing so conflicts with the self substitution from
  default trait methods.

Closes #18661
Closes #18685
Add regression test for #18661
Add regression test for #18685
Fix panic due to overly long borrow of RefCell

Closes #18711
Add regression test for #18711
Remove incorrect assert in trans

As an optimization, once unboxed closures receive their environment by
value if it fits within the size of an `int`.  An assert in this code
path assumed that this would only occur if the environment had no more
than a single free variable in it, but multiple smaller free variables
can easily be packed into the space of an `int`, particularly if any
of them are 0-sized.  The assert can simply be removed.

Closes #18652
Add regression test for #18652
Derive Clone for TypeId.
Remove unnecessary `.to_string()`s from `Vec.swap_remove`'s doc example.
Do not put double quotes around empty variables.
Properly static lib packaging

Fixes #18574
auto merge of #18673 : VHaravy/rust/issue-18632, r=alexcrichton

1. Introduce `putpathvar` function that prints variable shell-quoted by using `%q` format specifier. This function is used within `probe` to save the result into `config.tmp`.
2. Removes search-and-replace pattern that transforms `\` into `/` as it messes up shell-quoted strings.