Skip to content

Rollup of 10 pull requests #93191

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 29 commits into from
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
528c4f9
Add PanicInfo::can_unwind which indicates whether a panic handler is
Amanieu Dec 18, 2021
fe9dc6e
Change TerminatorKind::Abort to call the panic handler instead of
Amanieu Jan 12, 2022
ecd39aa
Update pulldown-cmark version to fix markdown list issue
GuillaumeGomez Jan 17, 2022
80b26bd
Update dependencies
GuillaumeGomez Jan 19, 2022
8d0d023
Simplify use of `map_or`
oli-obk Jan 20, 2022
1521b53
Increase the format version of rustdoc-json-types
Urgau Jan 20, 2022
c55819a
Make stability interning follow the usual pattern.
nnethercote Jan 20, 2022
d46ed5d
Clarify some code relating to interning and types.
nnethercote Jan 21, 2022
d984287
Add L4Bender as linker variant
humenda Apr 3, 2018
24588e6
Old versions of Android generate SIGSEGV from libc::abort
Amanieu Jan 21, 2022
660d993
adapt L4Bender implementation
atopia May 31, 2021
29d6235
Gate `l4-bender` linker flavor
petrochenkov Jan 7, 2022
888332f
Reject unsupported naked functions
tmiasko Jan 21, 2022
beeba4b
Reject may_unwind option in naked functions
tmiasko Jan 21, 2022
1309088
Disable drop range tracking in generators
eholk Jan 21, 2022
2c2deff
Add regression test for #93161
eholk Jan 21, 2022
ead84d0
Add reference to breakage this works around
eholk Jan 21, 2022
78cee22
Add missing GUI test explanations
GuillaumeGomez Jan 21, 2022
2eb8bfc
rustdoc: remove dashed underline under main heading
jsha Jan 21, 2022
6e5ec70
Rollup merge of #85967 - atopia:update-l4re-target, r=petrochenkov
matthiaskrgr Jan 22, 2022
87b7ad4
Rollup merge of #92828 - Amanieu:unwind-abort, r=dtolnay
matthiaskrgr Jan 22, 2022
3c37d63
Rollup merge of #93012 - GuillaumeGomez:pulldown-list, r=camelid
matthiaskrgr Jan 22, 2022
287d439
Rollup merge of #93116 - rust-lang:oli-obk-patch-1, r=jackh726
matthiaskrgr Jan 22, 2022
dca374f
Rollup merge of #93132 - Urgau:fix-rustdoc-json-format-version, r=oli…
matthiaskrgr Jan 22, 2022
2aa8b90
Rollup merge of #93147 - nnethercote:interner-cleanups, r=lcnr
matthiaskrgr Jan 22, 2022
7d624e1
Rollup merge of #93153 - tmiasko:reject-unsupported-naked-functions, …
matthiaskrgr Jan 22, 2022
828b28c
Rollup merge of #93165 - eholk:disable-generator-drop-tracking, r=nik…
matthiaskrgr Jan 22, 2022
0bfa1a4
Rollup merge of #93170 - GuillaumeGomez:gui-tests-explanations, r=jsha
matthiaskrgr Jan 22, 2022
9a93de8
Rollup merge of #93172 - jsha:re-remove-line, r=camelid
matthiaskrgr Jan 22, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Disable drop range tracking in generators
Generator drop tracking caused an ICE for generators involving the Never
type (Issue #93161). Since this breaks miri, we temporarily disable drop
tracking so miri is unblocked while we properly fix the issue.
  • Loading branch information
eholk committed Jan 21, 2022
commit 13090889f5b8cbc72b1a14c2cb038dca5727d55c
9 changes: 8 additions & 1 deletion compiler/rustc_typeck/src/check/generator_interior.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,10 @@ use tracing::debug;

mod drop_ranges;

// FIXME(eholk): This flag is here to give a quick way to disable drop tracking in case we find
// unexpected breakages while it's still new. It should be removed before too long.
const ENABLE_DROP_TRACKING: bool = false;

struct InteriorVisitor<'a, 'tcx> {
fcx: &'a FnCtxt<'a, 'tcx>,
types: FxIndexSet<ty::GeneratorInteriorTypeCause<'tcx>>,
Expand Down Expand Up @@ -77,7 +81,10 @@ impl<'a, 'tcx> InteriorVisitor<'a, 'tcx> {
yield_data.expr_and_pat_count, self.expr_count, source_span
);

if self.drop_ranges.is_dropped_at(hir_id, yield_data.expr_and_pat_count)
if ENABLE_DROP_TRACKING
&& self
.drop_ranges
.is_dropped_at(hir_id, yield_data.expr_and_pat_count)
{
debug!("value is dropped at yield point; not recording");
return false;
Expand Down
4 changes: 4 additions & 0 deletions src/test/ui/async-await/async-fn-nonsend.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
// edition:2018
// compile-flags: --crate-type lib

// FIXME(eholk): temporarily disabled while drop range tracking is disabled
// (see generator_interior.rs:27)
// ignore-test

use std::{cell::RefCell, fmt::Debug, rc::Rc};

fn non_sync() -> impl Debug {
Expand Down
4 changes: 4 additions & 0 deletions src/test/ui/async-await/unresolved_type_param.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@
// (rather than give a general error message)
// edition:2018

// FIXME(eholk): temporarily disabled while drop range tracking is disabled
// (see generator_interior.rs:27)
// ignore-test

async fn bar<T>() -> () {}

async fn foo() {
Expand Down
4 changes: 4 additions & 0 deletions src/test/ui/generator/drop-control-flow.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
// build-pass

// FIXME(eholk): temporarily disabled while drop range tracking is disabled
// (see generator_interior.rs:27)
// ignore-test

// A test to ensure generators capture values that were conditionally dropped,
// and also that values that are dropped along all paths to a yield do not get
// included in the generator type.
Expand Down
4 changes: 4 additions & 0 deletions src/test/ui/generator/issue-57478.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
// check-pass

// FIXME(eholk): temporarily disabled while drop range tracking is disabled
// (see generator_interior.rs:27)
// ignore-test

#![feature(negative_impls, generators)]

struct Foo;
Expand Down
4 changes: 4 additions & 0 deletions src/test/ui/generator/partial-drop.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// FIXME(eholk): temporarily disabled while drop range tracking is disabled
// (see generator_interior.rs:27)
// ignore-test

#![feature(negative_impls, generators)]

struct Foo;
Expand Down