diff options
author | Chris Lattner <sabre@nondot.org> | 2001-10-02 03:41:24 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2001-10-02 03:41:24 +0000 |
commit | b00c582b6d40e6b9ff2d1ed4f5eaf7930e792ace (patch) | |
tree | 44b5f879c16e7ecb2e9334ad120e3454270e1bb3 /include/llvm/Assembly | |
parent | 1d87bcf4909b06dcd86320722653341f08b8b396 (diff) | |
download | llvm-b00c582b6d40e6b9ff2d1ed4f5eaf7930e792ace.tar.gz llvm-b00c582b6d40e6b9ff2d1ed4f5eaf7930e792ace.tar.bz2 llvm-b00c582b6d40e6b9ff2d1ed4f5eaf7930e792ace.tar.xz |
Commit more code over to new cast style
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@697 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Assembly')
-rw-r--r-- | include/llvm/Assembly/Writer.h | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/include/llvm/Assembly/Writer.h b/include/llvm/Assembly/Writer.h index 39b0cb6cfb..020989e5d9 100644 --- a/include/llvm/Assembly/Writer.h +++ b/include/llvm/Assembly/Writer.h @@ -92,13 +92,13 @@ inline ostream &operator<<(ostream &o, const Type *T) { inline ostream &operator<<(ostream &o, const Value *I) { switch (I->getValueType()) { case Value::TypeVal: return o << cast<const Type>(I); - case Value::ConstantVal: WriteToAssembly((const ConstPoolVal*)I,o);break; + case Value::ConstantVal: WriteToAssembly(cast<ConstPoolVal>(I) , o); break; case Value::MethodArgumentVal: return o << I->getType() << " "<< I->getName(); - case Value::InstructionVal:WriteToAssembly((const Instruction *)I, o);break; - case Value::BasicBlockVal: WriteToAssembly((const BasicBlock *)I, o);break; - case Value::MethodVal: WriteToAssembly((const Method *)I, o);break; - case Value::GlobalVal: WriteToAssembly((const GlobalVariable*)I,o);break; - case Value::ModuleVal: WriteToAssembly((const Module *)I,o); break; + case Value::InstructionVal:WriteToAssembly(cast<Instruction>(I) , o); break; + case Value::BasicBlockVal: WriteToAssembly(cast<BasicBlock>(I) , o); break; + case Value::MethodVal: WriteToAssembly(cast<Method>(I) , o); break; + case Value::GlobalVal: WriteToAssembly(cast<GlobalVariable>(I), o); break; + case Value::ModuleVal: WriteToAssembly(cast<Module>(I) , o); break; default: return o << "<unknown value type: " << I->getValueType() << ">"; } return o; |