Stream: t-compiler

Topic: PlaceBase change


RalfJ (Jan 15 2020 at 18:13, on Zulip):

I am staring at this compilation failure in Miri:

error[E0433]: failed to resolve: could not find `PlaceBase` in `mir`
  --> src/helpers.rs:79:45
   |
79 |         let place = mir::Place { base: mir::PlaceBase::Local(local), projection: List::empty() };
   |                                             ^^^^^^^^^ could not find `PlaceBase` in `mir`

error[E0560]: struct `rustc::mir::Place<'_>` has no field named `base`
  --> src/helpers.rs:79:34
   |
79 |         let place = mir::Place { base: mir::PlaceBase::Local(local), projection: List::empty() };
   |                                  ^^^^ `rustc::mir::Place<'_>` does not have this field
   |
   = note: available fields are: `local`, `projection`

I am trying to find out what I have to change... does anyone know the PR that did this off the top of their head?

RalfJ (Jan 15 2020 at 18:14, on Zulip):

ah, it's https://github.com/rust-lang/rust/pull/67000

Wesley Wiser (Jan 15 2020 at 18:20, on Zulip):

PlaceBase doesn't exist any more because the base of a Place is now always a Local. So you just need to change base: mir::PlaceBase::Local(local) to local

Santiago Pastorino (Jan 15 2020 at 21:41, on Zulip):

@RalfJ have you fixed this already? if you didn’t I can go over this

RalfJ (Jan 15 2020 at 22:10, on Zulip):

@Santiago Pastorino thanks, it's all fixed :)

Santiago Pastorino (Jan 15 2020 at 22:34, on Zulip):

:+1:, it was merged meanwhile I’m on vacations 😊

Santiago Pastorino (Jan 15 2020 at 22:34, on Zulip):

will check if others crates broke too

Last update: Feb 25 2020 at 03:05UTC