Closed
Description
type FontTableTag = u32;
trait FontTableTagConversions {
fn tag_to_str(self);
}
impl FontTableTagConversions for FontTableTag {
fn tag_to_str(self) {
&self;
}
}
fn main() {
5.tag_to_str();
}
rustc: /run/media/jdm/ssd/rust/src/llvm/lib/VMCore/Instructions.cpp:2383: static llvm::CastInst* llvm::CastInst::CreatePointerCast(llvm::Value*, llvm::Type*, const llvm::Twine&, llvm::Instruction*): Assertion
S->getType()->isPointerTy() && "Invalid cast"' failed.`