regex: Fix control flow in the parser
regex: Escaped literals can end ranges
regex: The first range in a character class can start with a left bracket
Guide: Patterns: use non-x variables in match blocks
Guide: Closures: minor wording fixes
Guide: Closures fix suggested by @cakebaker
simplify shootout-reverse-complement.rs

Simpler, safer and shorter, in the same spirit of the current version, and the
same performances.
libcore: Inline atomic constructors.

Servo really wants this.
Fix some wording about errors

see https://github.com/rust-lang/rust/pull/18176#discussion_r19374679
return &mut T from the arenas, not &T

The arenas write the value to memory and then return a non-aliasing
reference to it. The returned reference can be mutable and can be
coerced to an immutable one.

[breaking-change]
DSTify [T]/str extension traits

This PR changes the signature of several methods from `foo(self, ...)` to
`foo(&self, ...)`/`foo(&mut self, ...)`, but there is no breakage of the usage
of these methods due to the autoref nature of `method.call()`s. This PR also
removes the lifetime parameter from some traits (`Trait<'a>` -> `Trait`). These
changes break any use of the extension traits for generic programming, but
those traits are not meant to be used for generic programming in the first
place. In the whole rust distribution there was only one misuse of a extension
trait as a bound, which got corrected (the bound was unnecessary and got
removed) as part of this PR.

[breaking-change]
Small grammar fix in rustdoc.md

Happened to be reading through
Use PascalCase for token variants
Convert some token  functions into methods
Use an enum rather than a bool in token::Ident
Move token-to-string functions into print::pprust
Respect mut in &mut str in astconv

Closes #17361
Add regression test for issue #17361
Remove double negation from sqrt's doc comment
Fix the output of negative duration

Technically speaking, negative duration is not valid ISO 8601, but we need to
print it anyway. If `d` is a positive duration with the output `xxxxxxx`, then
the expected output of negative `-d` value is `-xxxxxxx`. I.e. the idea is to
print negative durations as positive with a leading minus sign.

Closes #18181.