about summary refs log tree commit diff
path: root/src/libstd/sys/unix/stack_overflow.rs
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2020-02-19 04:57:10 +0000
committerbors <bors@rust-lang.org>2020-02-19 04:57:10 +0000
commit3a8108d8e52e13f3f1a151a93addfcf4a86b97f5 (patch)
treecc8222823aa713e37dbc4bf0c0444bbd16377a17 /src/libstd/sys/unix/stack_overflow.rs
parenta2fb0c28be794f28028884650db70c17fea8e35b (diff)
parent077a93c6a9b1c8ee0e541ea484f7e13c207d50d0 (diff)
downloadrust-3a8108d8e52e13f3f1a151a93addfcf4a86b97f5.tar.gz
rust-3a8108d8e52e13f3f1a151a93addfcf4a86b97f5.zip
Auto merge of #69113 - ecstatic-morse:unified-dataflow-borrowed, r=wesleywiser
Combine `HaveBeenBorrowedLocals` and `IndirectlyMutableLocals` into one dataflow analysis

This PR began as an attempt to port `HaveBeenBorrowedLocals` to the new dataflow framework (see #68241 for prior art). Along the way, I noticed that it could share most of its code with `IndirectlyMutableLocals` and then found a few bugs in the two analyses:
- Neither one marked locals as borrowed after an `Rvalue::AddressOf`.
- `IndirectlyMutableLocals` was missing a minor fix that `HaveBeenBorrowedLocals` got in #61069. This is not a problem today since it is only used during const-checking, where custom drop glue is forbidden. However, this may change some day.

I decided to combine the two analyses so that they wouldn't diverge in the future while ensuring that they remain distinct types (called `MaybeBorrowedLocals` and `MaybeMutBorrowedLocals` to be consistent with the `Maybe{Un,}InitializedPlaces` naming scheme). I fixed the bugs and switched to exhaustive matching where possible to make them less likely in the future. Finally, I added comments explaining some of the finer points of the transfer function for these analyses (see #61069 and #65006).
Diffstat (limited to 'src/libstd/sys/unix/stack_overflow.rs')
0 files changed, 0 insertions, 0 deletions