about summary refs log tree commit diff
path: root/library/std/src/sys/unix/stack_overflow.rs
diff options
context:
space:
mode:
authorTyler Mandry <tmandry@gmail.com>2020-04-30 15:23:17 -0700
committerGitHub <noreply@github.com>2020-04-30 15:23:17 -0700
commita8e0511b3288f40570812fe6524e0d80cf630f2c (patch)
tree06b28d2cb7806fb0bd291474ed3028c43aecc1da /library/std/src/sys/unix/stack_overflow.rs
parent8192cb6ea3e4456519bce0b176af221b960fd289 (diff)
parent0592976f7ee4b31046e3d23457699ef038c3e6e7 (diff)
downloadrust-a8e0511b3288f40570812fe6524e0d80cf630f2c.tar.gz
rust-a8e0511b3288f40570812fe6524e0d80cf630f2c.zip
Rollup merge of #71688 - ecstatic-morse:const-downcast, r=oli-obk
Allow `Downcast` projections unconditionally in const-checking

`ProjectionElem::Downcast` sounds scary, but it's really just the projection we use to access a particular enum variant. They usually appear in the lowering of a `match` statement, so they have been associated with control flow in const-checking, but they don't do any control flow by themselves. We already have a HIR pass that looks for `if` and `match` (even ones that have 1 or fewer reachable branches). That pass is double-checked by a MIR pass that looks for `SwitchInt`s and `FakeRead`s for match scrutinees. In my opinion, there's no need to look for `Downcast` as well.

r? @oli-obk
Diffstat (limited to 'library/std/src/sys/unix/stack_overflow.rs')
0 files changed, 0 insertions, 0 deletions