-
Notifications
You must be signed in to change notification settings - Fork 13.2k
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: None != Some(()) with method call on unknown type #19297
Comments
Just saw this when looking at rust-lang#19297 and couldn't find an issue/PR dealing with this. rust-lang#18773 seems to have missed this file. Compiler output is generated [here](https://github.com/rust-lang/rust/blob/770378a313a573776b16237a46b75bafa49072c1/src/librustc_trans/driver/mod.rs#L466). cc @steveklabnik
The ICE seems to be caused by a bug in auto-dereferencing. Taking the following code as an example, [].split(|x| x.clone()); // This code causes an ICE, but
[].split(|&x| x.clone()); // This code doesn't cause an ICE This should be fixed by #19813. |
check::autoderef() returns a ty_err when it fails to infer the type. probe::probe() should respect this failure and fail together to prevent further corruption. Call stack: check::check_method_call() -> method::lookup() -> probe::probe() + confirm::confirm() Fixes rust-lang#19692. Fixes rust-lang#19583. Fixes rust-lang#19297.
I've got another repro of what looks to be the same issue, if it's helpful. Moving the &mut on line 9 to its correct location in front of fmt::Formatter doesn't ICE. Code: https://gist.github.com/swgillespie/a1c7bf117f2fadfd2504 |
Adjust relevance scoring threshold to consistent with existing implem…
Fix logical error in PR rust-lang#19297
The text was updated successfully, but these errors were encountered: