Skip to content

LLVM assertion: Ptr must be a pointer to Val type #32389

Closed
@alexcrichton

Description

@alexcrichton

This code compiles fine on stable/beta, but ICEs on nightly:

pub struct Foo {
    raw: u8
}

pub struct Bar {
    raw: u8,
}

impl Drop for Bar {
    fn drop(&mut self) {}
}

fn foo<T>() -> T { loop {} }

fn main() {
    let mut a: &mut FnMut(Foo, Bar) = foo();
    let ref mut b = a;
    b(foo(), foo());
}

cc @eddyb, happened last night, maybe recent trans changes?

Metadata

Metadata

Assignees

Labels

T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.regression-from-stable-to-nightlyPerformance or correctness regression from stable to nightly.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions