diff --git a/lib/VMCore/AsmWriter.cpp b/lib/VMCore/AsmWriter.cpp index 41c139f9552..51ffbf6784d 100644 --- a/lib/VMCore/AsmWriter.cpp +++ b/lib/VMCore/AsmWriter.cpp @@ -48,8 +48,6 @@ static const Module *getModuleFromVal(const Value *V) { return M ? M->getParent() : 0; } else if (const GlobalValue *GV = dyn_cast(V)) return GV->getParent(); - else if (const Module *Mod = dyn_cast(V)) - return Mod; return 0; } @@ -65,8 +63,6 @@ static SlotCalculator *createSlotCalculator(const Value *V) { return new SlotCalculator(GV->getParent(), true); } else if (const Function *Func = dyn_cast(V)) { return new SlotCalculator(Func, true); - } else if (const Module *Mod = dyn_cast(V)) { - return new SlotCalculator(Mod, true); } return 0; } @@ -901,7 +897,6 @@ CachedWriter &CachedWriter::operator<<(const Value *V) { case Value::BasicBlockVal: AW->write(cast(V)); break; case Value::FunctionVal: AW->write(cast(V)); break; case Value::GlobalVariableVal: AW->write(cast(V)); break; - case Value::ModuleVal: AW->write(cast(V)); break; default: Out << "getValueType() << ">"; break; } return *this;