[llvm] r234189 - Add some type safety to GlobalObject/GlobalValue - they're always PointerTypes so let's type them that way.
David Blaikie
dblaikie at gmail.com
Mon Apr 6 11:06:06 PDT 2015
Author: dblaikie
Date: Mon Apr 6 13:06:06 2015
New Revision: 234189
URL: http://llvm.org/viewvc/llvm-project?rev=234189&view=rev
Log:
Add some type safety to GlobalObject/GlobalValue - they're always PointerTypes so let's type them that way.
Modified:
llvm/trunk/include/llvm/IR/GlobalObject.h
llvm/trunk/include/llvm/IR/GlobalValue.h
Modified: llvm/trunk/include/llvm/IR/GlobalObject.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/IR/GlobalObject.h?rev=234189&r1=234188&r2=234189&view=diff
==============================================================================
--- llvm/trunk/include/llvm/IR/GlobalObject.h (original)
+++ llvm/trunk/include/llvm/IR/GlobalObject.h Mon Apr 6 13:06:06 2015
@@ -27,7 +27,7 @@ class GlobalObject : public GlobalValue
GlobalObject(const GlobalObject &) = delete;
protected:
- GlobalObject(Type *Ty, ValueTy VTy, Use *Ops, unsigned NumOps,
+ GlobalObject(PointerType *Ty, ValueTy VTy, Use *Ops, unsigned NumOps,
LinkageTypes Linkage, const Twine &Name)
: GlobalValue(Ty, VTy, Ops, NumOps, Linkage, Name), ObjComdat(nullptr) {
setGlobalValueSubClassData(0);
Modified: llvm/trunk/include/llvm/IR/GlobalValue.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/IR/GlobalValue.h?rev=234189&r1=234188&r2=234189&view=diff
==============================================================================
--- llvm/trunk/include/llvm/IR/GlobalValue.h (original)
+++ llvm/trunk/include/llvm/IR/GlobalValue.h Mon Apr 6 13:06:06 2015
@@ -61,7 +61,7 @@ public:
};
protected:
- GlobalValue(Type *Ty, ValueTy VTy, Use *Ops, unsigned NumOps,
+ GlobalValue(PointerType *Ty, ValueTy VTy, Use *Ops, unsigned NumOps,
LinkageTypes Linkage, const Twine &Name)
: Constant(Ty, VTy, Ops, NumOps), Linkage(Linkage),
Visibility(DefaultVisibility), UnnamedAddr(0),
More information about the llvm-commits
mailing list