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

Rustup to rustc 1.42.0-nightly (005cf38f7 2019-12-22) #1121

Merged
merged 1 commit into from
Dec 23, 2019
Merged

Rustup to rustc 1.42.0-nightly (005cf38f7 2019-12-22) #1121

merged 1 commit into from
Dec 23, 2019

Conversation

oli-obk
Copy link
Contributor

@oli-obk oli-obk commented Dec 22, 2019

No description provided.

@RalfJung
Copy link
Member

RalfJung commented Dec 22, 2019 via email

@bors
Copy link
Contributor

bors commented Dec 22, 2019

📌 Commit c335eca has been approved by RalfJung

@bors
Copy link
Contributor

bors commented Dec 22, 2019

⌛ Testing commit c335eca with merge d7871e5...

bors added a commit that referenced this pull request Dec 22, 2019
Rustup to rustc 1.42.0-nightly (005cf38f7 2019-12-22)
@bors
Copy link
Contributor

bors commented Dec 22, 2019

💔 Test failed - status-appveyor

@oli-obk
Copy link
Contributor Author

oli-obk commented Dec 22, 2019

I can't figure out how to build a self-contained const eval repro :(

@RalfJung
Copy link
Member

I don't understand that assertion anyway... why does it make any sense?

@oli-obk
Copy link
Contributor Author

oli-obk commented Dec 22, 2019

I don't understand that assertion anyway... why does it make any sense?

Good question, I haven't looked into it at all yet.

@bjorn3
Copy link
Member

bjorn3 commented Dec 22, 2019

When using for example:

match &[0, 1] as &[u8] {
    [x, y, a @ ..] => {}
    _ => {}
}

There will be a _4 = &(*_1)[0 of 2]; for x. This is equivalent to ConstantIndex { offset: 0, min_length: 2, from_end: false }. The assertion says that the offset must be less than min_length. So for example _4 = &(*_1)[2 of 2]; would not be allowed.

@oli-obk
Copy link
Contributor Author

oli-obk commented Dec 22, 2019

Thanks, I now have a minimal repro that works on just nightly without miri

#![feature(slice_patterns)]

fn main() {
    match &[0, 1] as &[i32] {
        [a @ .., x] => {}
        &[] => {}
    }
}

Since from_end is true, the index is 1 and min_length is also 1 because a could be empty for all the pattern knows.

@oli-obk
Copy link
Contributor Author

oli-obk commented Dec 23, 2019

Fix PR: rust-lang/rust#67546

@bors
Copy link
Contributor

bors commented Dec 23, 2019

☔ The latest upstream changes (presumably #1118) made this pull request unmergeable. Please resolve the merge conflicts.

@RalfJung
Copy link
Member

@bors r+

@bors
Copy link
Contributor

bors commented Dec 23, 2019

📌 Commit 1ffa62f has been approved by RalfJung

@bors
Copy link
Contributor

bors commented Dec 23, 2019

⌛ Testing commit 1ffa62f with merge 5744aea...

bors added a commit that referenced this pull request Dec 23, 2019
Rustup to rustc 1.42.0-nightly (005cf38f7 2019-12-22)
@bors
Copy link
Contributor

bors commented Dec 23, 2019

💔 Test failed - status-appveyor

@RalfJung
Copy link
Member

@bors r+
(can't test locally as the toolchain download takes hours despite my 50 MBit/s connection :/ stupid AWS )

@bors
Copy link
Contributor

bors commented Dec 23, 2019

📌 Commit bac2615 has been approved by RalfJung

@bors
Copy link
Contributor

bors commented Dec 23, 2019

⌛ Testing commit bac2615 with merge b1e97df...

bors added a commit that referenced this pull request Dec 23, 2019
Rustup to rustc 1.42.0-nightly (005cf38f7 2019-12-22)
@bors
Copy link
Contributor

bors commented Dec 23, 2019

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

@bors bors merged commit bac2615 into master Dec 23, 2019
@RalfJung RalfJung deleted the rustup branch December 24, 2019 10:22
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.

4 participants