From: Chris Lattner Date: Mon, 16 Jun 2008 06:43:06 +0000 (+0000) Subject: add a const version of stripPointerCasts X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=0ad4d9be0310b79e47561abeef39daf322d06760;p=oota-llvm.git add a const version of stripPointerCasts git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52305 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/llvm/Value.h b/include/llvm/Value.h index 26d2d1df4c6..6d4d7cc74ac 100644 --- a/include/llvm/Value.h +++ b/include/llvm/Value.h @@ -226,6 +226,9 @@ public: /// casts from the specified value, returning the original uncasted value. /// Note that the returned value is guaranteed to have pointer type. Value *stripPointerCasts(); + const Value *stripPointerCasts() const { + return const_cast(this)->stripPointerCasts(); + } }; inline std::ostream &operator<<(std::ostream &OS, const Value &V) {