[llvm-commits] [llvm] r123577 - /llvm/trunk/include/llvm/User.h

Jay Foad jay.foad at gmail.com
Sun Jan 16 00:23:16 PST 2011


Author: foad
Date: Sun Jan 16 02:23:16 2011
New Revision: 123577

URL: http://llvm.org/viewvc/llvm-project?rev=123577&view=rev
Log:
Remove unnecessary specialization OperandTraits<User>.

Modified:
    llvm/trunk/include/llvm/User.h

Modified: llvm/trunk/include/llvm/User.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/User.h?rev=123577&r1=123576&r2=123577&view=diff
==============================================================================
--- llvm/trunk/include/llvm/User.h (original)
+++ llvm/trunk/include/llvm/User.h Sun Jan 16 02:23:16 2011
@@ -29,16 +29,6 @@
 template <class>
 struct OperandTraits;
 
-class User;
-
-/// OperandTraits<User> - specialization to User
-template <>
-struct OperandTraits<User> {
-  static inline Use *op_begin(User*);
-  static inline Use *op_end(User*);
-  static inline unsigned operands(const User*);
-};
-
 class User : public Value {
   User(const User &);             // Do not implement
   void *operator new(size_t);     // Do not implement
@@ -152,18 +142,6 @@
   }
 };
 
-inline Use *OperandTraits<User>::op_begin(User *U) {
-  return U->op_begin();
-}
-
-inline Use *OperandTraits<User>::op_end(User *U) {
-  return U->op_end();
-}
-
-inline unsigned OperandTraits<User>::operands(const User *U) {
-  return U->getNumOperands();
-}
-
 template<> struct simplify_type<User::op_iterator> {
   typedef Value* SimpleType;
 





More information about the llvm-commits mailing list