| Age | Commit message (Collapse) | Author | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
Not gen bits
|
|
|
|
|
|
Also:
- Extract common helper functions into a helper trait.
- Kill a bit of dead code.
|
|
|
|
|
|
|
|
two-phase borrows: support multiple activations in one statement
The need for this has arisen since the introduction of two-phase borrows on
method autorefs in #49348. r'ing @pnkfelix to keep things off Niko's plate so he can make this redundant, and @pnkfelix is familiar with the code.
Fixes #49635
Fixes #49662
r? @pnkfelix
|
|
|
|
The need for this has arisen since the introduction of two-phase borrows on
method autorefs.
Fixes 49635
Fixes 49662
|
|
This makes sure that all bits in each IdxSet between the universe length
and the end of the word are all zero instead of being in an indeterminate state.
This fixes a crash with RUST_LOG=rustc_mir, and is probably a good idea
anyway.
|
|
NLL should identify and respect the lifetime annotations that the user wrote
Part of #47184.
r? @nikomatsakis
|
|
|
|
|
|
Remove some unnecessary IdxSet methods
This replaces `IdxSet:: reset_to_empty` with `IdxSet:: clear`, and `IdxSet::elems`/`IdxSet::each_bit` with `IdxSet::iter`. Based on some [comments on #rustc](https://botbot.me/mozilla/rustc/2018-01-23/?msg=96063396).
r? @pnkfelix
|
|
Left over from prior experimentation, no longer required.
|
|
Fix a small compilation issue after I missed a critical change after rebasing
yesterday (ref c933440)
|
|
|
|
|
|
See #48431 for discussion as to why this was necessary and what we hoped to
accomplish. A brief summary:
- the first implementation of 2-phase borrows was hard to limit in the way we
wanted. That is, it was too good at accepting all 2-phase borrows rather than
just autorefs =)
- Numerous diagnostic regressions were introduced by 2-phase borrow support
which were difficult to fix
|
|
The new output format is perhaps a little more readable. As a bonus, we get
labels on the outgoing edges to more easily corroborate the dataflow with the
plain MIR graphviz output.
|
|
|
|
in preparation for rewritting two phase borrow support
|
|
|
|
|
|
|
|
|
|
|
|
|
|
mir: Gather move at SwitchInt, Assert terminators
Previously, `_1` was not marked as "definitely uninitialized" after a `switchInt(move _1)` terminator.
I think the same goes for the `assert` terminator.
Related discussion: https://internals.rust-lang.org/t/why-is-2-definitely-initialized-after-switchint-move-2/6760
|
|
|
|
Previously, "_1" was not marked as "definitely uninitialized" after a "switchInt(move _1)" terminator.
Related discussion: https://internals.rust-lang.org/t/why-is-2-definitely-initialized-after-switchint-move-2/6760
|
|
[NLL] Add false edges out of infinite loops
Resolves #46036 by adding a `cleanup` member to the `FalseEdges` terminator kind. There's also a small doc fix to one of the other comments in `into.rs` which I can pull out in to another PR if desired =)
This PR should pass CI but the test suite has been relatively unstable on my system so I'm not 100% sure.
r? @nikomatsakis
|
|
This is foundation for issue 46747 (limit two-phase borrows to method-call autorefs).
|
|
Sometimes a simple goto misses the cleanup/unwind edges. Specifically, in the
case of infinite loops such as those introduced by a loop statement without any
other out edges. Analogous to TerminatorKind::FalseEdges; this new terminator
kind is used when we want borrowck to consider an unwind path, but real control
flow should never actually take it.
|
|
Generator bugfixes
r? @nikomatsakis
|
|
is_unsafe_place only filters out statics in the rhs, not the lhs. Since
it's possible to reach that 'Place::Static', we handle statics the same
way as we do locals.
Fixes #47789
|
|
Fixes #47736
|
|
|
|
|
|
Resolves #46137.
|
|
|
|
NLL fixes
First, introduce pre-statement effects to dataflow to fix #46875. Edge dataflow effects might make that redundant, but I'm not sure of the best way to integrate them with liveness etc., and if this is a hack, this is one of the cleanest hacks I've seen.
And I want a small fix to avoid the torrent of bug reports.
Second, fix linking of projections to fix #46974
r? @pnkfelix
|
|
[MIR Borrowck] Moveck inline asm statements
Closes #45695
New behavior:
* Input operands to `asm!` are moved, direct output operands are initialized.
* Direct, non-read-write outputs match the assignment changes in #46752 (Shallow writes, end borrows).
|