-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
ICE when using unboxed closures #17021
Comments
@reem do you know which version of rustc you were running on when this happened? For example, my
This code compiles and works for me.
|
Appears to work fine now, must have been fixed by some change in the last few days. Thanks for investigating! |
@reem Are you willing to additionally release this code snippet under the Apache License, for inclusion in a regression test? The test files are licensed as follows:
(considering you specify the MIT license in the sample code, I think it's worth asking) |
Sure! Weird thing is, this is still failing Travis. On my phone, so no link, but the most recent build for that repo shows the same ICE. On Sun, Sep 7, 2014 at 10:06 AM, Nathan Typanski [email protected]
|
Travis nightlies trail slightly behind the latest builds. Some ideas have gotten passed around about improving that rate: see #16649 for details. |
This code used to produce the following ICE: error: internal compiler error: get_unique_type_id_of_type() - unexpected type: closure, ty_unboxed_closure(syntax::ast::DefId{krate: 0u32, node: 66u32}, ReScope(63u32)) This is a regression test for issue rust-lang#17021.
It's still reproducible with
|
I can reproduce this, too, but only with the
If I drop
|
Reproducible on @huonw would you reopen this, please? |
@nathantypanski is #17093 being compiled with the |
@tomassedovic thanks, it breaks with Anywho, I'll try to look into it. Maybe someone more experienced than me will solve it first, though. |
This catches two unhandled patterns in middle/trans/debuginfo.rs where a ty::ty_unboxed_closure could show up, preventing various potential ICEs when #[feature(unboxed_closures)] is used with `-g`. It also updates the test case from rust-lang#17093 in response to new information from rust-lang#17021 showing that the test still caused an ICE when compiling with debuginfo. Closes rust-lang#17021.
I'm getting very similar symptoms with my code: dckc/rust-sqlite3@882347d
|
I'm also seeing this problem with:
…as described in #17454. A code snippet is attached to that issue, but it's basically the same code that everybody else is having problems with. |
I can confirm that the code builds with
…but fails with
|
This is falling through a wildcard match clause in
This is probably a relatively easy fix—it's generating some sort of unique representation for each type. |
@emk you can see my attempt at fixing that here It didn't work, for reasons that are unknown to me. But, hey, it adds to that pattern match like you suggest. |
Getting the same error with #![feature(unboxed_closures)]
#![feature(unboxed_closure_sugar)]
fn main() {
let b = 3u;
let a = |:| b;
}
Backtrace:
|
Taking a look |
This fixes an ICE. Closes issue rust-lang#17021
This causes it to hit the previously ICEing debuginfo codepath
my symptoms above (#17021 (comment)) seem to have subsided as of rustc 0.13.0-nightly (adb44f5 2014-10-12 00:07:15 +0000) |
Yep, #17803 did it for me. We can close this. |
…ykril Support hovering limits for adts Fix rust-lang#17009 1. Currently, r-a supports limiting the number of struct fields displayed when hovering. This PR extends it to support enum variants and union fields. Since the display of these three (ADTs) is similar, this PR extends 'hover_show_structFields' to 'hover_show_adtFieldsOrVariants'. 2. This PR also resolved the problem that the layout of ADT was not restricted by display limitations when hovering on the Self type. 3. Additionally, this PR changes the default value of display limitations to `10` (instead of the original `null`), which helps users discover this feature.
…ykril Support hovering limits for adts Fix rust-lang#17009 1. Currently, r-a supports limiting the number of struct fields displayed when hovering. This PR extends it to support enum variants and union fields. Since the display of these three (ADTs) is similar, this PR extends 'hover_show_structFields' to 'hover_show_adtFieldsOrVariants'. 2. This PR also resolved the problem that the layout of ADT was not restricted by display limitations when hovering on the Self type. 3. Additionally, this PR changes the default value of display limitations to `10` (instead of the original `null`), which helps users discover this feature.
Full log here: https://travis-ci.org/reem/rust-replace-map/builds/34311513
Code in the repo here: https://github.com/reem/rust-replace-map/blob/master/src/lib.rs
The text was updated successfully, but these errors were encountered: