mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-29 10:25:12 +00:00
Fix broken assertion. Didn't allow for pointer case
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1034 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -60,7 +60,6 @@ PrintMethodNameForType(const Type* type)
|
|||||||
case Type::FloatTyID: return "printFloat";
|
case Type::FloatTyID: return "printFloat";
|
||||||
case Type::DoubleTyID: return "printDouble";
|
case Type::DoubleTyID: return "printDouble";
|
||||||
case Type::PointerTyID: return "printPointer";
|
case Type::PointerTyID: return "printPointer";
|
||||||
case Type::MethodTyID: return "printPointer";
|
|
||||||
default:
|
default:
|
||||||
assert(0 && "Unsupported type for printing");
|
assert(0 && "Unsupported type for printing");
|
||||||
return NULL;
|
return NULL;
|
||||||
@@ -270,11 +269,9 @@ InsertPrintInsts(Value *Val,
|
|||||||
{
|
{
|
||||||
const Type* ValTy = Val->getType();
|
const Type* ValTy = Val->getType();
|
||||||
|
|
||||||
assert(ValTy->isPrimitiveType() &&
|
assert((ValTy->isPrimitiveType() || isa<PointerType>(ValTy)) &&
|
||||||
ValTy->getPrimitiveID() != Type::VoidTyID &&
|
ValTy != Type::VoidTy && ValTy != Type::TypeTy &&
|
||||||
ValTy->getPrimitiveID() != Type::TypeTyID &&
|
ValTy != Type::LabelTy && "Unsupported type for printing");
|
||||||
ValTy->getPrimitiveID() != Type::LabelTyID &&
|
|
||||||
"Unsupported type for printing");
|
|
||||||
|
|
||||||
const Value* scopeToUse =
|
const Value* scopeToUse =
|
||||||
isMethodExit ? (const Value*)BB->getParent() : (const Value*)BB;
|
isMethodExit ? (const Value*)BB->getParent() : (const Value*)BB;
|
||||||
|
Reference in New Issue
Block a user