Don't require the user to do something like isa<foo>(II->get()). The ->get

should be implicit.

llvm-svn: 6395
This commit is contained in:
Chris Lattner 2003-05-29 15:08:33 +00:00
parent 12d13d5751
commit d3eae6379d

View File

@ -73,4 +73,24 @@ public:
}
};
template<> struct simplify_type<User::op_iterator> {
typedef Value* SimpleType;
static SimpleType getSimplifiedValue(const User::op_iterator &Val) {
return (SimpleType)Val->get();
}
};
template<> struct simplify_type<const User::op_iterator>
: public simplify_type<User::op_iterator> {};
template<> struct simplify_type<User::const_op_iterator> {
typedef Value* SimpleType;
static SimpleType getSimplifiedValue(const User::const_op_iterator &Val) {
return (SimpleType)Val->get();
}
};
template<> struct simplify_type<const User::const_op_iterator>
: public simplify_type<User::const_op_iterator> {};
#endif