-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Closed
Labels
A-codegenArea: Code generationArea: Code generationI-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
Milestone
Description
I'm not even sure if this should work, but it does pass typechecking.
enum Animal {
Dog (~str, float),
Cat { name: ~str, weight: float }
}
fn main() {
let mut a: Animal = Dog(~"Cocoa", 37.2);
a = Cat{ name: ~"Spotty", weight: 2.7 };
}
This yields an ICE in trans:
error: internal compiler error: iter_variant: not a function type
The message is from trans::base::iter_structural_ty
.
Metadata
Metadata
Assignees
Labels
A-codegenArea: Code generationArea: Code generationI-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️