Skip to content
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

Miri rename undef uninit #1487

Merged
merged 4 commits into from
Jul 27, 2020
Merged

Miri rename undef uninit #1487

merged 4 commits into from
Jul 27, 2020

Conversation

pnadon
Copy link
Contributor

@pnadon pnadon commented Jul 23, 2020

The changes made here are related to issue #71193 on Rust, and the pull request 74664 on Rust.

  1. renamed ScalarMaybeUninit::not_undef to check_init
  2. renamed Immediate::to_scalar_or_undef to Immediate::to_scalar_or_uninit

@RalfJung
Copy link
Member

This looks good, thanks. :)

@pnadon
Copy link
Contributor Author

pnadon commented Jul 23, 2020

I will check the build on my local machine, using rustc with the changes made in the previously mentioned PR

@pnadon
Copy link
Contributor Author

pnadon commented Jul 23, 2020

The local build I did of Miri, using the steps defined here compiled successfully using the changes made in this pull request.

@RalfJung
Copy link
Member

Awesome, thanks for checking that :)

@RalfJung
Copy link
Member

@pnadon can you extend this PR to update the rust-version file, now that your rustc PR landed?

@pnadon
Copy link
Contributor Author

pnadon commented Jul 26, 2020

@RalfJung it should be the hash for the commit below, correct?

rust-lang/rust@13f9aa1

@RalfJung
Copy link
Member

Yes, the hash of latest master.

@pnadon
Copy link
Contributor Author

pnadon commented Jul 26, 2020

It seems as though there is a conflict due to someone changing the rust-version since I started working on this.

@RalfJung
Copy link
Member

Ah good point... that someone is probably me. ;)
Can you rebase your PR on top of current master, and then do the rust-version edit again?

pnadon added 3 commits July 26, 2020 16:05
to Immediate::to_scalar_or_uninit

in src/shims/intrinsics.rs

related issue #71193
Updated Rust version since the latest version contains changes which allow this version of Miri to build.
@pnadon
Copy link
Contributor Author

pnadon commented Jul 26, 2020

@RalfJung done!

@RalfJung
Copy link
Member

RalfJung commented Jul 27, 2020

@pnadon CI isn't happy, something is not building:

error[E0599]: no method named `not_undef` found for enum `rustc_mir::interpret::ScalarMaybeUninit<stacked_borrows::Tag>` in the current scope
   --> src/shims/foreign_items.rs:203:50
    |
203 |                 let ptr = this.read_scalar(ptr)?.not_undef()?;
    |                                                  ^^^^^^^^^ method not found in `rustc_mir::interpret::ScalarMaybeUninit<stacked_borrows::Tag>`

Due to changes from upstream, a commit using not_undef was inserted, which had to be updated to use check_init.

related issue #71193
@pnadon
Copy link
Contributor Author

pnadon commented Jul 27, 2020

I checked just now, and the error was due to upstream insertions, one of which used "not_undef". The latest commit fixes this.

@RalfJung
Copy link
Member

Thanks. :)
@bors r+

@bors
Copy link
Contributor

bors commented Jul 27, 2020

📌 Commit 6dd700f has been approved by RalfJung

@bors
Copy link
Contributor

bors commented Jul 27, 2020

⌛ Testing commit 6dd700f with merge 345b033...

@bors
Copy link
Contributor

bors commented Jul 27, 2020

☀️ Test successful - checks-travis, status-appveyor
Approved by: RalfJung
Pushing 345b033 to master...

@bors bors merged commit 345b033 into rust-lang:master Jul 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants