-
Notifications
You must be signed in to change notification settings - Fork 13k
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
rustc: "error: internal compiler error: no type for node 41: local x (id=41) in fcx 0x7ff2ddbade98" #13624
Comments
Seems to be fine now but potentially needs a test. |
Nope, still failing. An updated example: #![feature(struct_variant)]
mod a {
pub enum Enum {
EnumStructVariant { x: u8, y: u8, z: u8 }
}
pub fn get_enum_struct_variant() {
EnumStructVariant { x: 1, y: 2, z: 3 }
//~^ ERROR mismatched types: expected `()` but found `a::Enum` (expected () but found enum a::Enum)
}
}
mod b {
mod test {
use a;
fn test_enum_struct_variant() {
let enum_struct_variant = ::a::get_enum_struct_variant();
match enum_struct_variant {
a::EnumStructVariant { x, y, z } => {
//~^ ERROR error: mismatched types: expected `()` but found a structure pattern
}
}
}
}
}
fn main() {} |
That code example fails to compile, but it's because the function signature for
When you make that change and make the struct fields public, the code compiles fine. Without the change I also didn't see any internal compiler errors. Rust Version: 0.12.0-pre-nightly, a1429bc, Linux x86_64 |
Yeah, I think this can be closed. |
Flagging as needstest (not sure if one is checked in already) |
…ble, r=lnicola fix: resolve inference variable before applying adjustments Fixes rust-lang#13619
Versions:
Code to reproduce the ICE:
Compilation output:
The text was updated successfully, but these errors were encountered: