Skip to content

Instantiating the type parameters of a function without calling it fails in LLVM #523

@paulstansifer

Description

@paulstansifer
fn f1[T](int x) {
  log x;
}

fn main() {
  auto f2 = f1[str];
}

results in
rustc: Instructions.cpp:962: void llvm::StoreInst::AssertOK(): Assertion `getOperand(0)->getType() == cast(getOperand(1)->getType())->getElementType() && "Ptr must be a pointer to Val type!"' failed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions