Make analyze_move_out_from use a loop rather than recursion

It will be simpler to make some of the changes that I need to make to
analyze_move_out if it uses a loop rather than recursion.
Make check_for_move_of_borrowed_path take an &LoanPath rather than an &Rc<LoanPath>

It doesn't actually need the Rc, and it reduces the net number of
pointer manipulations.
Make analyze_move_out_from more field-sensitive

Currently analyze_move_out_from checks all restrictions on all base
paths of the move path, but it only needs to check restrictions from
loans of the base paths, and can disregard restrictions from loans of
extensions of those base paths.

Arguably, gather_loans should be generating precise restrictions for
every path that is used, and check_loans shouldn't be second-guessing
them like this. However, other code in check_loans already does similar
things, and refactoring borrowck to do this would be a much larger
endeavour.
Make analyze_move_out_from take a RestrictionSet

Currently analyze_move_out_from ignores the RestrictionSet of any loan
restrictions, but the same logic is useful with arbitrary restriction
sets.
Rename analyze_move_out_from to analyze_restrictions_on_use

Also rename MoveError to UseError and MoveOk / MoveWhileBorrowed to
UseOk / UseWhileBorrowed.
Fix all violations of stronger guarantees for mutable borrows

Fix all violations in the Rust source tree of the stronger guarantee
of a unique access path for mutable borrows as described in #12624.
Enforce stronger guarantees for mutable borrows

Implement the stronger guarantees for mutable borrows from #12624. This
removes the ability to read from a mutably borrowed path for the
duration of the borrow, and enforces a unique access path for any
mutable borrow, for both reads and writes.

This makes mutable borrows work better with concurrent accesses from
multiple threads, and it opens the door for allowing moves out of
mutably borrowed values, as long as a new value is written before the
mutable borrow ends. This also aligns Rust more closely with academic
languages based on substructural types and separation logic.

The most common situation triggering an error after this change is a
call to a function mutably borrowing self with self.field as one of the
arguments. The workaround is to bind self.field to a temporary, but the
need for these temporaries will hopefully go away after #6268 is fixed.

Another situation that triggers an error is using the head expression of
a match in an arm that binds a variable with a mutable reference. The
use of the head expression needs to be replaced with an expression that
reconstructs it from match-bound variables.

This fixes #12624.

[breaking-change]
Add new tests for uses of mutably borrowed paths
Reorganize code in check_loans

Move analyze_restrictions_on_use and check_if_path_is_moved so that all
of the code related to assignments is in a contiguous block at the end
of the file.