-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Closed
Labels
I-crashIssue: The compiler crashes (SIGSEGV, SIGABRT, etc). Use I-ICE instead when the compiler panics.Issue: The compiler crashes (SIGSEGV, SIGABRT, etc). Use I-ICE instead when the compiler panics.P-highHigh priorityHigh priorityT-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.regression-from-stable-to-betaPerformance or correctness regression from stable to beta.Performance or correctness regression from stable to beta.
Description
Running this code in either release or debug mode will yield a segfault:
#[derive(Debug)]
pub struct Binding {
action: Action,
mode: u32,
}
#[derive(Debug)]
pub enum Action {
Esc(&'static str),
Paste,
Char(char)
}
static V_BINDINGS: &'static [Binding] = &[
Binding { action: Action::Paste, mode: 0 },
Binding { action: Action::Char('v'), mode: 1 },
];
fn main() {
println!("{:?}", V_BINDINGS);
}
It looks like this also runs successfully on stable, just failing on beta/nightly
cc @jwilm
Metadata
Metadata
Assignees
Labels
I-crashIssue: The compiler crashes (SIGSEGV, SIGABRT, etc). Use I-ICE instead when the compiler panics.Issue: The compiler crashes (SIGSEGV, SIGABRT, etc). Use I-ICE instead when the compiler panics.P-highHigh priorityHigh priorityT-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.regression-from-stable-to-betaPerformance or correctness regression from stable to beta.Performance or correctness regression from stable to beta.